AuthenticationManager
instead@Deprecated
public interface Authenticator
Modifier and Type | Method and Description |
---|---|
AuthenticationInformation |
authenticate(java.lang.String login,
java.lang.String password)
Deprecated.
Authenticates a user.
|
void |
init(java.lang.String settings)
Deprecated.
Initialises the object.
|
boolean |
supportsExtraInformation()
Deprecated.
Should return TRUE or FALSE depending on if the authentication
server returns additional information about the user.
|
void init(java.lang.String settings) throws AuthenticationException
settings
string should be defined by the implementing class. It may for
example be the URL for a database connection,
the path to a properties file or simply the host name of the
directory service provider.settings
- A string containing initialisation parametersAuthenticationException
- If the parameters are invalidboolean supportsExtraInformation()
AuthenticationInformation
,
authenticate(String,String)
AuthenticationInformation authenticate(java.lang.String login, java.lang.String password) throws UnknownLoginException, InvalidPasswordException, AuthenticationException
AuthenticationInformation
object
should be returned. The only required information in this object is
the AuthenticationInformation.id
and
AuthenticationInformation.login
fields. The id
may or may not be the same as the login
, but must be a unique
string identifying the user.
If the authentication fails an exception should be thrown. Note! An
implementation may choose to throw a AuthenticationException
for all errors, even if it is an unknown user or invalid password.
login
- The login name for the userpassword
- The password for the userAuthenticationInformation
objectUnknownLoginException
- This exception may be thrown if the
server doesn't know about the user. It is also possible for an
implmentation to throw an AuthenticationException
InvalidPasswordException
- This exception may be thrown if the
password is invalid. It is also possible for an implementation to throw
an AuthenticationException
AuthenticationException
- This exception is thrown if the
authentication fails