Class PasswdUserDBAuthentication
- java.lang.Object
-
- com.netscape.cmscore.authentication.PasswdUserDBAuthentication
-
- All Implemented Interfaces:
com.netscape.certsrv.authentication.IPasswdUserDBAuthentication
,AuthManager
public class PasswdUserDBAuthentication extends java.lang.Object implements AuthManager, com.netscape.certsrv.authentication.IPasswdUserDBAuthentication
Certificate Server admin authentication. Used to authenticate administrators in the Certificate Server Console. Authentications by checking the uid and password against the database.- Version:
- $Revision$, $Date$
- Author:
- lhsiao, cfu
-
-
Field Summary
Fields Modifier and Type Field Description static org.slf4j.Logger
logger
protected static java.lang.String[]
mConfigParams
protected static java.lang.String[]
mRequiredCred
-
Fields inherited from interface org.dogtagpki.server.authentication.AuthManager
CRED_CERT_SERIAL_TO_REVOKE, CRED_CMC_SELF_SIGNED, CRED_CMC_SIGNING_CERT, CRED_HOST_NAME, CRED_SESSION_ID, CRED_SSL_CLIENT_CERT
-
-
Constructor Summary
Constructors Constructor Description PasswdUserDBAuthentication()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.netscape.certsrv.authentication.IAuthToken
authenticate(com.netscape.certsrv.authentication.IAuthCredentials authCred)
authenticates administratrators by LDAP uid/pwdAuthenticationConfig
getAuthenticationConfig()
java.lang.String[]
getConfigParams()
Get the list of configuration parameter names required by this authentication manager.AuthManagerConfig
getConfigStore()
gets the configuretion substore used by this authentication managerjava.lang.String
getImplName()
gets the name of the authentication manager pluginjava.lang.String
getName()
gets the name of this authentication manager instancejava.lang.String[]
getRequiredCreds()
get the list of authentication credential attribute names required by this authentication manager.void
init(java.lang.String name, java.lang.String implName, AuthManagerConfig config)
initializes the PasswdUserDBAuthentication auth managervoid
setAuthenticationConfig(AuthenticationConfig authenticationConfig)
void
shutdown()
disconnects the member connection
-
-
-
Method Detail
-
getAuthenticationConfig
public AuthenticationConfig getAuthenticationConfig()
-
setAuthenticationConfig
public void setAuthenticationConfig(AuthenticationConfig authenticationConfig)
-
init
public void init(java.lang.String name, java.lang.String implName, AuthManagerConfig config) throws EBaseException
initializes the PasswdUserDBAuthentication auth managercalled by AuthSubsystem init() method, when initializing all available authentication managers.
- Specified by:
init
in interfaceAuthManager
- Parameters:
name
- - Name assigned to this authentication manager instance.implName
- - Name of the authentication plugin.config
- - The configuration store used by the authentication subsystem.- Throws:
EBaseException
- If an initialization error occurred.
-
authenticate
public com.netscape.certsrv.authentication.IAuthToken authenticate(com.netscape.certsrv.authentication.IAuthCredentials authCred) throws com.netscape.certsrv.authentication.EMissingCredential, com.netscape.certsrv.authentication.EInvalidCredentials, EBaseException
authenticates administratrators by LDAP uid/pwdcalled by other subsystems or their servlets to authenticate administrators
- Specified by:
authenticate
in interfaceAuthManager
- Parameters:
authCred
- Authentication credentials. "uid" and "pwd" are required.- Returns:
- the authentication token (authToken) that contains the following
userdn = [userdn, in case of success]
authMgrName = [authMgrName] - Throws:
com.netscape.certsrv.base.MissingCredential
- If either "uid" or "pwd" is missing from the given credentials.com.netscape.certsrv.base.InvalidCredentials
- If the the credentials failed to authenticate.EBaseException
- If an internal error occurred.com.netscape.certsrv.authentication.EMissingCredential
- If a required credential for this authentication manager is missing.com.netscape.certsrv.authentication.EInvalidCredentials
- If credentials cannot be authenticated.
-
getName
public java.lang.String getName()
gets the name of this authentication manager instance- Specified by:
getName
in interfaceAuthManager
- Returns:
- the name of this authentication manager.
-
getImplName
public java.lang.String getImplName()
gets the name of the authentication manager plugin- Specified by:
getImplName
in interfaceAuthManager
- Returns:
- the name of the authentication manager plugin.
-
getRequiredCreds
public java.lang.String[] getRequiredCreds()
get the list of authentication credential attribute names required by this authentication manager. Generally used by servlets that use this authentication manager, to retrieve required credentials from the user (e.g. Javascript form data)- Specified by:
getRequiredCreds
in interfaceAuthManager
- Returns:
- attribute names in Vector
-
getConfigParams
public java.lang.String[] getConfigParams()
Get the list of configuration parameter names required by this authentication manager. In this case, an empty list.- Specified by:
getConfigParams
in interfaceAuthManager
- Returns:
- String array of configuration parameters.
-
shutdown
public void shutdown()
disconnects the member connection- Specified by:
shutdown
in interfaceAuthManager
-
getConfigStore
public AuthManagerConfig getConfigStore()
gets the configuretion substore used by this authentication manager- Specified by:
getConfigStore
in interfaceAuthManager
- Returns:
- configuration store
-
-