|  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @Override | 
|---|
|  |  |  | protected void additionalAuthenticationChecks(UserDetails userDetails, Authentication authentication) throws AuthenticationException { | 
|---|
|  |  |  | if (authentication.getCredentials() == null) { | 
|---|
|  |  |  | log.debug("Authentication failed: no credentials provided"); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | throw new BadCredentialsException(messages.getMessage( | 
|---|
|  |  |  | "AbstractUserDetailsAuthenticationProvider.badCredentials", | 
|---|
|  |  |  | "Bad credentials")); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | //        if (authentication.getCredentials() == null) { | 
|---|
|  |  |  | //            log.debug("Authentication failed: no credentials provided"); | 
|---|
|  |  |  | // | 
|---|
|  |  |  | //            throw new BadCredentialsException(messages.getMessage( | 
|---|
|  |  |  | //                    "AbstractUserDetailsAuthenticationProvider.badCredentials", | 
|---|
|  |  |  | //                    "Bad credentials")); | 
|---|
|  |  |  | //        } | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @Override | 
|---|