Class SAMLOutboundProtocolMessageSigningHandler
- java.lang.Object
-
- net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
-
- org.opensaml.messaging.handler.AbstractMessageHandler
-
- org.opensaml.saml.common.binding.security.impl.SAMLOutboundProtocolMessageSigningHandler
-
- All Implemented Interfaces:
Component
,DestructableComponent
,InitializableComponent
,MessageHandler
public class SAMLOutboundProtocolMessageSigningHandler extends AbstractMessageHandler
A message handler implementation that signs an outbound SAML protocol message if the message context contains an instance ofSignatureSigningParameters
as determined bySAMLMessageSecuritySupport.getContextSigningParameters(MessageContext)
.
-
-
Field Summary
Fields Modifier and Type Field Description private org.slf4j.Logger
log
Logger.private boolean
signErrorResponses
Whether to sign responses containing errors.
-
Constructor Summary
Constructors Constructor Description SAMLOutboundProtocolMessageSigningHandler()
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
doInvoke(MessageContext messageContext)
private boolean
isErrorResponse(Object message)
Get whether the message is a SAML response containing an error status.void
setSignErrorResponses(boolean flag)
Set whether to sign response messages that contain errors (defaults to true).-
Methods inherited from class org.opensaml.messaging.handler.AbstractMessageHandler
doPostInvoke, doPostInvoke, doPreInvoke, getActivationCondition, getLogPrefix, invoke, setActivationCondition
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
destroy, doDestroy, doInitialize, 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
-
-
-
-
Method Detail
-
setSignErrorResponses
public void setSignErrorResponses(boolean flag)
Set whether to sign response messages that contain errors (defaults to true).- Parameters:
flag
- flag to set
-
doInvoke
protected void doInvoke(@Nonnull MessageContext messageContext) throws MessageHandlerException
- Specified by:
doInvoke
in classAbstractMessageHandler
- Throws:
MessageHandlerException
-
isErrorResponse
private boolean isErrorResponse(@Nullable Object message)
Get whether the message is a SAML response containing an error status.- Parameters:
message
- message to check- Returns:
- true iff the message is a SAML response containing an error status
-
-