Package net.shibboleth.idp.cas.flow.impl
Class BuildSamlValidationSuccessMessageAction
- java.lang.Object
-
- net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
-
- org.opensaml.profile.action.AbstractProfileAction
-
- org.opensaml.profile.action.AbstractConditionalProfileAction
-
- net.shibboleth.idp.profile.AbstractProfileAction
-
- net.shibboleth.idp.cas.flow.impl.AbstractCASProtocolAction<TicketValidationRequest,TicketValidationResponse>
-
- net.shibboleth.idp.cas.flow.impl.AbstractOutgoingSamlMessageAction
-
- net.shibboleth.idp.cas.flow.impl.BuildSamlValidationSuccessMessageAction
-
- All Implemented Interfaces:
Component,DestructableComponent,InitializableComponent,ProfileAction,Aware,MessageSource,MessageSourceAware,Action
public class BuildSamlValidationSuccessMessageAction extends AbstractOutgoingSamlMessageAction
Creates the SAML response message for successful ticket validation at the/samlValidateURI.
-
-
Field Summary
Fields Modifier and Type Field Description private XMLObjectBuilder<XSString>attrValueBuilderAttribute value node builder.private StringentityIDIdP entity ID used to set issuer field of generated assertions.private IdentifierGenerationStrategyidentifierGenerationStrategySAML identifier generation strategy.private org.slf4j.LoggerlogClass logger.private static StringNAMESPACEAttribute namespace.
-
Constructor Summary
Constructors Constructor Description BuildSamlValidationSuccessMessageAction(IdentifierGenerationStrategy strategy, String id)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected ResponsebuildSamlResponse(ProfileRequestContext profileRequestContext)Build the SAML response.private XSStringnewAttributeValue(String value)Build new attribute value.private AuthenticationStatementnewAuthenticationStatement(Instant authnInstant, String authnMethod, String principal)Build new authentication statement.private SubjectnewSubject(String identifier)Build a new subject.-
Methods inherited from class net.shibboleth.idp.cas.flow.impl.AbstractOutgoingSamlMessageAction
doExecute, doInitialize, newSAMLObject, setOutgoingBinding
-
Methods inherited from class net.shibboleth.idp.cas.flow.impl.AbstractCASProtocolAction
getCASRequest, getCASResponse, getCASService, getCASTicket, getProtocolContext, setCASRequest, setCASResponse, setCASService, setCASTicket
-
Methods inherited from class net.shibboleth.idp.profile.AbstractProfileAction
doExecute, execute, getBean, getBean, getMessage, getMessage, getMessage, getParameter, getParameter, getProfileContextLookupStrategy, getRequestContext, getResult, setMessageSource, setProfileContextLookupStrategy
-
Methods inherited from class org.opensaml.profile.action.AbstractConditionalProfileAction
doPreExecute, getActivationCondition, setActivationCondition
-
Methods inherited from class org.opensaml.profile.action.AbstractProfileAction
doPostExecute, doPostExecute, execute, getHttpServletRequest, getHttpServletRequestSupplier, getHttpServletResponse, getHttpServletResponseSupplier, getLogPrefix, setHttpServletRequest, setHttpServletRequestSupplier, setHttpServletResponse, setHttpServletResponseSupplier
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
destroy, doDestroy, initialize, isDestroyed, isInitialized
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.shibboleth.utilities.java.support.component.InitializableComponent
initialize, isInitialized
-
-
-
-
Field Detail
-
NAMESPACE
private static final String NAMESPACE
Attribute namespace.- See Also:
- Constant Field Values
-
log
private final org.slf4j.Logger log
Class logger.
-
attrValueBuilder
private final XMLObjectBuilder<XSString> attrValueBuilder
Attribute value node builder.
-
identifierGenerationStrategy
@Nonnull private final IdentifierGenerationStrategy identifierGenerationStrategy
SAML identifier generation strategy.
-
entityID
@Nonnull private final String entityID
IdP entity ID used to set issuer field of generated assertions.
-
-
Constructor Detail
-
BuildSamlValidationSuccessMessageAction
public BuildSamlValidationSuccessMessageAction(@Nonnull IdentifierGenerationStrategy strategy, @Nonnull @NotEmpty String id)Constructor.- Parameters:
strategy- SAML identifier generation strategy.id- IdP entity ID.
-
-
Method Detail
-
buildSamlResponse
@Nonnull protected Response buildSamlResponse(@Nonnull ProfileRequestContext profileRequestContext) throws EventException
Description copied from class:AbstractOutgoingSamlMessageActionBuild the SAML response.- Specified by:
buildSamlResponsein classAbstractOutgoingSamlMessageAction- Parameters:
profileRequestContext- profile request context- Returns:
- SAML response
- Throws:
EventException- to signal an event
-
newSubject
@Nonnull private Subject newSubject(String identifier)
Build a new subject.- Parameters:
identifier- subject identifier- Returns:
- new subject
-
newAuthenticationStatement
private AuthenticationStatement newAuthenticationStatement(Instant authnInstant, String authnMethod, String principal)
Build new authentication statement.- Parameters:
authnInstant- authentication instantauthnMethod- authentication methodprincipal- authenticated principal- Returns:
- new authentication statement
-
-