Class AuthManager

java.lang.Object
org.dogtagpki.server.authentication.AuthManager
Direct Known Subclasses:
AgentCertAuthentication, CertUserDBAuthentication, DirBasedAuthentication, HashAuthentication, NullAuthentication, PasswdUserDBAuthentication, SessionAuthentication, SSLclientCertAuthentication, TokenAuthentication

public abstract class AuthManager extends Object
Authentication Manager interface. This interface can also be used for profile authentication. If authentication is successful, request will be processed immediately. Otherwise, the request will be deferred and manual approval is then required.
  • Field Details

  • Constructor Details

    • AuthManager

      public AuthManager()
  • Method Details

    • getCMSEngine

      public CMSEngine getCMSEngine()
    • setCMSEngine

      public void setCMSEngine(CMSEngine engine)
    • getAuthenticationConfig

      public AuthenticationConfig getAuthenticationConfig()
    • setAuthenticationConfig

      public void setAuthenticationConfig(AuthenticationConfig authenticationConfig)
    • getName

      public String getName()
      Get the name of this authentication manager instance.
      Returns:
      the name of this authentication manager.
    • getName

      public String getName(Locale locale)
      Retrieves the localizable name of this policy.
      Parameters:
      locale - end user locale
      Returns:
      localized authenticator name
    • getImplName

      public String getImplName()
      Get name of authentication manager plugin.
      Returns:
      the name of the authentication manager plugin.
    • getText

      public abstract String getText(Locale locale)
      Retrieves the localizable description of this policy.
      Parameters:
      locale - end user locale
      Returns:
      localized authenticator description
    • getConfigStore

      public AuthManagerConfig getConfigStore()
      Get the configuration store for this authentication manager.
      Returns:
      The configuration store of this authentication manager.
    • getConfigParams

      public String[] getConfigParams()
      Get configuration parameters for this implementation. The configuration parameters returned is passed to the configuration console so configuration for instances of this implementation can be made through the console.
      Returns:
      a list of configuration parameters.
      Throws:
      EBaseException - If an internal error occurred
    • getValueNames

      public abstract Enumeration<String> getValueNames()
      Retrieves a list of names of the property.
      Returns:
      a list of property names
    • getValueDescriptor

      public abstract IDescriptor getValueDescriptor(Locale locale, String name)
      Retrieves the descriptor of the given value property by name.
      Parameters:
      locale - user locale
      name - property name
      Returns:
      descriptor of the requested property
    • isValueWriteable

      public abstract boolean isValueWriteable(String name)
      Checks if the value of the given property should be serializable into the request. Passsword or other security-related value may not be desirable for storage.
      Parameters:
      name - property name
      Returns:
      true if the property is not security related
    • isSSLClientRequired

      public abstract boolean isSSLClientRequired()
      Checks if this authenticator requires SSL client authentication.
      Returns:
      client authentication required or not
    • init

      public abstract void init(AuthenticationConfig authenticationConfig, String name, String implName, AuthManagerConfig config) throws EBaseException
      Initialize this authentication manager.
      Parameters:
      name - The name of this authentication manager instance.
      implName - The name of the authentication manager plugin.
      config - The configuration store for this authentication manager.
      Throws:
      EBaseException - If an initialization error occurred.
    • init

      public abstract void init(ConfigStore config) throws EProfileException
      Initializes this default policy.
      Parameters:
      config - configuration store
      Throws:
      EProfileException - failed to initialize
    • authenticate

      public abstract AuthToken authenticate(AuthCredentials authCred) throws EMissingCredential, EInvalidCredentials, EBaseException
      Authenticate the given credentials.
      Parameters:
      authCred - The authentication credentials
      Returns:
      authentication token
      Throws:
      EMissingCredential - If a required credential for this authentication manager is missing.
      EInvalidCredentials - If credentials cannot be authenticated.
      EBaseException - If an internal error occurred.
    • populate

      public abstract void populate(AuthToken token, Request request) throws EProfileException
      Populates authentication specific information into the request for auditing purposes.
      Parameters:
      token - authentication token
      request - request
      Throws:
      EProfileException - failed to populate
    • shutdown

      public abstract void shutdown()
      Prepare this authentication manager for a shutdown. Called when the server is exiting for any cleanup needed.
    • getRequiredCreds

      public abstract String[] getRequiredCreds()
      Gets a list of the required credentials for this authentication manager.
      Returns:
      The required credential attributes.