Interface NameIDGeneratorFactory
- All Known Implementing Classes:
DefaultNameIDGeneratorFactory
public interface NameIDGeneratorFactory
A
NameIDGenerator
is assigned each Saml2AuthnRequestAuthenticationToken
when an AuthnRequest
is being processed. When the user has been authenticated and an Assertion
is created this generator will be
used to generate a NameID
.- Author:
- Martin Lindström
-
Method Summary
Modifier and TypeMethodDescriptiongetNameIDGenerator
(org.opensaml.saml.saml2.core.AuthnRequest authnRequest, org.opensaml.saml.saml2.metadata.EntityDescriptor peerMetadata) Given the requirements for aNameID
in theAuthnRequest
andEntityDescriptor
along with the IdP policy the method returns aNameIDGenerator
.Gets a list of theNameIDFormat
s that are supported by the factory.
-
Method Details
-
getNameIDGenerator
NameIDGenerator getNameIDGenerator(org.opensaml.saml.saml2.core.AuthnRequest authnRequest, org.opensaml.saml.saml2.metadata.EntityDescriptor peerMetadata) throws Saml2ErrorStatusException, UnrecoverableSaml2IdpException Given the requirements for aNameID
in theAuthnRequest
andEntityDescriptor
along with the IdP policy the method returns aNameIDGenerator
.- Parameters:
authnRequest
- theAuthnRequest
peerMetadata
- the peer metadata- Returns:
- a
NameIDGenerator
- Throws:
Saml2ErrorStatusException
- for errors that should be reported back to the Service ProviderUnrecoverableSaml2IdpException
- for non-recoverable errors
-
getSupportedFormats
Gets a list of theNameIDFormat
s that are supported by the factory. The most preferred should be added first.- Returns:
- a list of the supported formats
-