Authentication
object (including granted authorities) if successful.An AuthenticationManager
must honour the following contract concerning exceptions:
A {@link DisabledException} must be thrown if an account is disabled and theAuthenticationManager
can test for this state.
A {@link LockedException} must be thrown if an account is locked and theAuthenticationManager
can test for account locking.
A {@link BadCredentialsException} must be thrown if incorrect credentials are presented. Whilst theabove exceptions are optional, an AuthenticationManager
must always test credentials.
Exceptions should be tested for and if applicable thrown in the order expressed above (ie if an account is disabled or locked, the authentication request is immediately rejected and the credentials testing process is not performed). This prevents credentials being tested against disabled or locked accounts.
@param authentication the authentication request object @return a fully authenticated object including credentials @throws AuthenticationException if authentication fails
|
|
|
|