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
Builder
InOutOperationContext
instances for SAML SOAP client use cases.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Default TLS CriteriaSet strategy function. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate OutboundMessageType
The outbound message.private EntityDescriptor
The SAML peer EntityDescriptor.private String
The SAML peer entityID.private QName
The SAML peer entity role.private RoleDescriptor
The SAML peer RoleDescriptor.private String
SOAP client message pipeline name.private String
The SAML protocol in use.private String
SOAP client security configuration profile ID.private String
The SAML self entityID.private Function<MessageContext,
CriteriaSet> TLS CriteriaSet strategy. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Build the new operation context.private void
errorMissingData
(String details) Convenience method to report out an error due to missing required data.Get the outbound message.Get the SAML peer EntityDscriptor.Get the SAML peer entityID.Get the SAML peer role.Get the SAML peer RoleDescriptor.Get the SOAP client message pipeline name to use.Get the SAML protocol URI.Get the SOAP client security configuration profile ID to use.Get the SAML self entityID.Get the TLS CriteriaSet strategy.setOutboundMessage
(OutboundMessageType message) Set the outbound message.setPeerEntityDescriptor
(EntityDescriptor entityDescriptor) Set the SAML peer EntityDescriptor.setPeerEntityID
(String entityID) Set the SAML peer entityID.setPeerEntityRole
(QName role) Set the SAML peer role.setPeerRoleDescriptor
(RoleDescriptor roleDescriptor) Set the SAML peer RoleDescriptor.setPipelineName
(String name) Set the SOAP client message pipeline name to use.setProtocol
(String uri) Set the SAML protocol URI.setSecurityConfigurationProfileId
(String profileId) Set the SOAP client security configuration profile ID to use.setSelfEntityID
(String entityID) Set the SAML self entityID.Set the TLS CriteriaSet strategy.
-
Field Details
-
outboundMessage
The outbound message. -
protocol
The SAML protocol in use. -
selfEntityID
The SAML self entityID. -
peerEntityID
The SAML peer entityID. -
peerEntityRole
The SAML peer entity role. -
peerEntityDescriptor
The SAML peer EntityDescriptor. -
peerRoleDescriptor
The SAML peer RoleDescriptor. -
tlsCriteriaSetStrategy
TLS CriteriaSet strategy. -
pipelineName
SOAP client message pipeline name. -
securityConfigurationProfileId
SOAP client security configuration profile ID.
-
-
Constructor Details
-
SAMLSOAPClientContextBuilder
public SAMLSOAPClientContextBuilder()
-
-
Method Details
-
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
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
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
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
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
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
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
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
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
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
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
Convenience method to report out an error due to missing required data.- Parameters:
details
- the error details- Throws:
MessageException
- the error to be reported out
-