Class JaspiAuthenticatorFactory

  • All Implemented Interfaces:

    public class JaspiAuthenticatorFactory
    extends DefaultAuthenticatorFactory
    Javax Authentication (JASPI) Authenticator Factory. This is used to link a jetty-security Authenticator.Factory to a Javax Authentication AuthConfigFactory.

    This should be initialized with the provided DefaultAuthConfigFactory to set up Javax Authentication AuthConfigFactory before use. (A different AuthConfigFactory may also be provided using the same steps below)

    To initialize either:

    • invoke AuthConfigFactory.setFactory(AuthConfigFactory)
    • Alternatively: set AuthConfigFactory.DEFAULT_FACTORY_SECURITY_PROPERTY
    • Constructor Detail

      • JaspiAuthenticatorFactory

        public JaspiAuthenticatorFactory()
    • Method Detail

      • getServiceSubject

        public getServiceSubject()
        the serviceSubject
      • setServiceSubject

        public void setServiceSubject​( serviceSubject)
        serviceSubject - the serviceSubject to set
      • getServerName

        public java.lang.String getServerName()
        the serverName
      • setServerName

        public void setServerName​(java.lang.String serverName)
        serverName - the serverName to set
      • findServiceSubject

        protected findServiceSubject​(Server server)
        Find a service Subject. If setServiceSubject(Subject) has not been used to set a subject, then the ContainerLifeCycle.getBeans(Class) method is used to look for a Subject.
        server - the server to pull the Subject from
        the subject
      • findServerName

        protected java.lang.String findServerName​(javax.servlet.ServletContext context,
                                                  Server server)
        Find a servername. If setServerName(String) has not been called, then use the virtualServerName of the context. If this is also null, then use the name of the a principal in the service subject. If none are found, return "server".
        context -
        server - the server to find the name of
        the server name from the service Subject (or default value if not found in subject or principals)