Class SAMLSOAPClientContextBuilder<InboundMessageType extends SAMLObject,OutboundMessageType extends SAMLObject>
- java.lang.Object
-
- org.opensaml.saml.common.messaging.soap.SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType>
-
- Type Parameters:
InboundMessageType- the inbound message typeOutboundMessageType- the outbound message type
public class SAMLSOAPClientContextBuilder<InboundMessageType extends SAMLObject,OutboundMessageType extends SAMLObject> extends Object
BuilderInOutOperationContextinstances for SAML SOAP client use cases.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSAMLSOAPClientContextBuilder.DefaultTLSCriteriaSetStrategyDefault TLS CriteriaSet strategy function.
-
Field Summary
Fields Modifier and Type Field Description private OutboundMessageTypeoutboundMessageThe outbound message.private EntityDescriptorpeerEntityDescriptorThe SAML peer EntityDescriptor.private StringpeerEntityIDThe SAML peer entityID.private QNamepeerEntityRoleThe SAML peer entity role.private RoleDescriptorpeerRoleDescriptorThe SAML peer RoleDescriptor.private StringpipelineNameSOAP client message pipeline name.private StringprotocolThe SAML protocol in use.private StringsecurityConfigurationProfileIdSOAP client security configuration profile ID.private StringselfEntityIDThe SAML self entityID.private Function<MessageContext,CriteriaSet>tlsCriteriaSetStrategyTLS CriteriaSet strategy.
-
Constructor Summary
Constructors Constructor Description SAMLSOAPClientContextBuilder()
-
Method Summary
-
-
-
Field Detail
-
outboundMessage
private OutboundMessageType extends SAMLObject outboundMessage
The outbound message.
-
protocol
private String protocol
The SAML protocol in use.
-
selfEntityID
private String selfEntityID
The SAML self entityID.
-
peerEntityID
private String peerEntityID
The SAML peer entityID.
-
peerEntityRole
private QName peerEntityRole
The SAML peer entity role.
-
peerEntityDescriptor
private EntityDescriptor peerEntityDescriptor
The SAML peer EntityDescriptor.
-
peerRoleDescriptor
private RoleDescriptor peerRoleDescriptor
The SAML peer RoleDescriptor.
-
tlsCriteriaSetStrategy
private Function<MessageContext,CriteriaSet> tlsCriteriaSetStrategy
TLS CriteriaSet strategy.
-
pipelineName
private String pipelineName
SOAP client message pipeline name.
-
securityConfigurationProfileId
private String securityConfigurationProfileId
SOAP client security configuration profile ID.
-
-
Method Detail
-
getOutboundMessage
@Nullable public OutboundMessageType getOutboundMessage()
Get the outbound message.- Returns:
- the outbound message
-
setOutboundMessage
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setOutboundMessage(OutboundMessageType message)
Set the outbound message.- Parameters:
message- the outbound message- Returns:
- this builder instance
-
getProtocol
@Nullable public String getProtocol()
Get the SAML protocol URI.- Returns:
- the SAML protocol URI
-
setProtocol
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setProtocol(String uri)
Set the SAML protocol URI.- Parameters:
uri- the SAML protocol.- Returns:
- this builder instance
-
getSelfEntityID
@Nullable public String getSelfEntityID()
Get the SAML self entityID.- Returns:
- the SAML self entityID
-
setSelfEntityID
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setSelfEntityID(String entityID)
Set the SAML self entityID.- Parameters:
entityID- the SAML self entityID.- Returns:
- this builder instance
-
getPeerEntityID
@Nullable public String getPeerEntityID()
Get the SAML peer entityID.- Returns:
- the SAML peer entityID
-
setPeerEntityID
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setPeerEntityID(String entityID)
Set the SAML peer entityID.- Parameters:
entityID- the SAML peer entityID- Returns:
- this builder instance
-
getPeerEntityRole
@Nullable public QName getPeerEntityRole()
Get the SAML peer role.- Returns:
- the SAML peer role
-
setPeerEntityRole
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setPeerEntityRole(QName role)
Set the SAML peer role.- Parameters:
role- the SAML peer role- Returns:
- this builder instance
-
getPeerEntityDescriptor
@Nullable public EntityDescriptor getPeerEntityDescriptor()
Get the SAML peer EntityDscriptor.- Returns:
- the SAML peer EntityDescriptor
-
setPeerEntityDescriptor
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setPeerEntityDescriptor(EntityDescriptor entityDescriptor)
Set the SAML peer EntityDescriptor.- Parameters:
entityDescriptor- the SAML peer EntityDescriptor- Returns:
- this builder instance
-
getPeerRoleDescriptor
@Nullable public RoleDescriptor getPeerRoleDescriptor()
Get the SAML peer RoleDescriptor.- Returns:
- the SAML peer RoleDescriptor
-
setPeerRoleDescriptor
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setPeerRoleDescriptor(RoleDescriptor roleDescriptor)
Set the SAML peer RoleDescriptor.- Parameters:
roleDescriptor- the SAML peer RoleDescriptor.- Returns:
- this builder instance
-
getTLSCriteriaSetStrategy
@Nullable public Function<MessageContext,CriteriaSet> getTLSCriteriaSetStrategy()
Get the TLS CriteriaSet strategy.- Returns:
- the TLS CriteriaSet strategy, or null
-
setTLSCriteriaSetStrategy
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setTLSCriteriaSetStrategy(@Nullable Function<MessageContext,CriteriaSet> strategy)
Set the TLS CriteriaSet strategy.- Parameters:
strategy- the strategy- Returns:
- this builder instance
-
getPipelineName
@Nullable public String getPipelineName()
Get the SOAP client message pipeline name to use.- Returns:
- the pipeline name, or null
-
setPipelineName
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setPipelineName(@Nullable String name)
Set the SOAP client message pipeline name to use.- Parameters:
name- the pipeline name, or null- Returns:
- this builder instance
-
getSecurityConfigurationProfileId
@Nullable public String getSecurityConfigurationProfileId()
Get the SOAP client security configuration profile ID to use.- Returns:
- the client security configuration profile ID, or null
-
setSecurityConfigurationProfileId
@Nonnull public SAMLSOAPClientContextBuilder<InboundMessageType,OutboundMessageType> setSecurityConfigurationProfileId(@Nullable String profileId)
Set the SOAP client security configuration profile ID to use.- Parameters:
profileId- the profile ID, or null- Returns:
- this builder instance
-
build
public InOutOperationContext build() throws MessageException
Build the new operation context.- Returns:
- the operation context
- Throws:
MessageException- if any required data is not supplied and can not be derived from other supplied data
-
errorMissingData
private void errorMissingData(@Nonnull String details) throws MessageExceptionConvenience method to report out an error due to missing required data.- Parameters:
details- the error details- Throws:
MessageException- the error to be reported out
-
-