Class DefaultAuthnRequestGenerator

java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
se.swedenconnect.opensaml.saml2.request.AbstractAuthnRequestGenerator
se.swedenconnect.opensaml.saml2.request.DefaultAuthnRequestGenerator
All Implemented Interfaces:
net.shibboleth.shared.component.Component, net.shibboleth.shared.component.DestructableComponent, net.shibboleth.shared.component.InitializableComponent, AuthnRequestGenerator

public class DefaultAuthnRequestGenerator extends AbstractAuthnRequestGenerator
A default implementation of the AuthnRequestGenerator where a metadata resolver is used to locate metadata.
Author:
Martin Lindström (martin@idsec.se)
  • Constructor Details

    • DefaultAuthnRequestGenerator

      public DefaultAuthnRequestGenerator(String spEntityID, org.opensaml.security.x509.X509Credential signCredential, org.opensaml.saml.metadata.resolver.MetadataResolver metadataResolver)
      Constructor.
      Parameters:
      spEntityID - the SP entityID
      signCredential - the signing credential
      metadataResolver - the metadata resolver
    • DefaultAuthnRequestGenerator

      public DefaultAuthnRequestGenerator(org.opensaml.saml.saml2.metadata.EntityDescriptor spMetadata, org.opensaml.security.x509.X509Credential signCredential, org.opensaml.saml.metadata.resolver.MetadataResolver metadataResolver)
      Constructor.
      Parameters:
      spMetadata - the SP metadata
      signCredential - the signing credential
      metadataResolver - the metadata resolver
  • Method Details

    • getMetadataResolver

      protected org.opensaml.saml.metadata.resolver.MetadataResolver getMetadataResolver()
      Gets the metadata resolver that this generator uses to find IdP (and SP) metadata.
      Returns:
      a metadata resolver
    • getSpMetadata

      protected org.opensaml.saml.saml2.metadata.EntityDescriptor getSpMetadata()
      Gets the metadata for the SP that this generator services.
      Specified by:
      getSpMetadata in class AbstractAuthnRequestGenerator
      Returns:
      the SP metadata, or null if no metadata is found
    • getIdpMetadata

      protected org.opensaml.saml.saml2.metadata.EntityDescriptor getIdpMetadata(String idpEntityID)
      Gets the IdP metadata for the given entityID.
      Overrides:
      getIdpMetadata in class AbstractAuthnRequestGenerator
      Parameters:
      idpEntityID - the entityID for the IdP
      Returns:
      the metadata or null if no metadata could be found