public class PreAuthenticatedAuthenticationToken extends AbstractAuthenticationToken
Authentication
implementation for
pre-authenticated authentication.Constructor and Description |
---|
PreAuthenticatedAuthenticationToken(Object aPrincipal,
Object aCredentials)
Constructor used for an authentication request.
|
PreAuthenticatedAuthenticationToken(Object aPrincipal,
Object aCredentials,
Collection<? extends GrantedAuthority> anAuthorities)
Constructor used for an authentication response.
|
Modifier and Type | Method and Description |
---|---|
Object |
getCredentials()
Get the credentials
|
Object |
getPrincipal()
Get the principal
|
equals, eraseCredentials, getAuthorities, getDetails, getName, hashCode, isAuthenticated, setAuthenticated, setDetails, toString
public PreAuthenticatedAuthenticationToken(Object aPrincipal, Object aCredentials)
Authentication.isAuthenticated()
will
return false
.aPrincipal
- The pre-authenticated principalaCredentials
- The pre-authenticated credentialspublic PreAuthenticatedAuthenticationToken(Object aPrincipal, Object aCredentials, Collection<? extends GrantedAuthority> anAuthorities)
Authentication.isAuthenticated()
will
return true
.aPrincipal
- The authenticated principalanAuthorities
- The granted authoritiespublic Object getCredentials()
Principal
public Object getPrincipal()
Principal
being authenticated or the authenticated
principal after authentication.