Class DefaultSignatureMessageExtensionExtractor
java.lang.Object
se.swedenconnect.spring.saml.idp.extensions.DefaultSignatureMessageExtensionExtractor
- All Implemented Interfaces:
SignatureMessageExtensionExtractor
public class DefaultSignatureMessageExtensionExtractor
extends Object
implements SignatureMessageExtensionExtractor
Default implementation of the
SignatureMessageExtensionExtractor
interface.- Author:
- Martin Lindström
-
Constructor Summary
ConstructorDescriptionDefaultSignatureMessageExtensionExtractor
(String entityId, List<PkiCredential> credentials) Constructor setting up the object for decryptingSignMessage
objects.Constructor setting up the object for decryptingSignMessage
objects. -
Method Summary
Modifier and TypeMethodDescriptionGiven an authentication request, the method will extract theSignMessage
extension, and if it is encrypted also decrypt it.
-
Constructor Details
-
DefaultSignatureMessageExtensionExtractor
Constructor setting up the object for decryptingSignMessage
objects.- Parameters:
entityId
- the IdP entityIDcredentials
- a list of decryption credentials (ifnull
decryption will not be supported)
-
DefaultSignatureMessageExtensionExtractor
Constructor setting up the object for decryptingSignMessage
objects.- Parameters:
settings
- IdP settings
-
-
Method Details
-
extract
public SignatureMessageExtension extract(Saml2AuthnRequestAuthenticationToken token) throws Saml2ErrorStatusException Given an authentication request, the method will extract theSignMessage
extension, and if it is encrypted also decrypt it.- Specified by:
extract
in interfaceSignatureMessageExtensionExtractor
- Parameters:
token
- the authentication request token- Returns:
- a
SignatureMessageExtension
ornull
if noSignMessage
is available - Throws:
Saml2ErrorStatusException
- for decryption errors
-