Class FormLoginAuthenticationToken
- java.lang.Object
-
- org.springframework.security.authentication.AbstractAuthenticationToken
-
- org.springframework.security.authentication.UsernamePasswordAuthenticationToken
-
- com.broadleafcommerce.auth.user.session.FormLoginAuthenticationToken
-
- All Implemented Interfaces:
Serializable,Principal,org.springframework.security.core.Authentication,org.springframework.security.core.CredentialsContainer
- Direct Known Subclasses:
EmbeddedLoginAuthenticationToken
public class FormLoginAuthenticationToken extends org.springframework.security.authentication.UsernamePasswordAuthenticationTokenAnAuthenticationimplementation that is designed for simple presentation of an OAuth2 clientId, username, and password.- Author:
- Nick Crum (ncrum)
- See Also:
FormLoginAuthenticationFilter,FormLoginAuthenticationProvider, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description FormLoginAuthenticationToken(String clientId, Object principal, Object credentials)This constructor can be safely used by any code that wishes to create aOAuth2ClientAuthenticationToken, as theAbstractAuthenticationToken.isAuthenticated()will returnfalse.FormLoginAuthenticationToken(String clientId, Object principal, Object credentials, Collection<? extends org.springframework.security.core.GrantedAuthority> authorities)This constructor should only be used byAuthenticationManagerorAuthenticationProviderimplementations that are satisfied with producing a trusted (i.e.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetClientId()-
Methods inherited from class org.springframework.security.authentication.UsernamePasswordAuthenticationToken
eraseCredentials, getCredentials, getPrincipal, setAuthenticated
-
Methods inherited from class org.springframework.security.authentication.AbstractAuthenticationToken
equals, getAuthorities, getDetails, getName, hashCode, isAuthenticated, setDetails, toString
-
-
-
-
Constructor Detail
-
FormLoginAuthenticationToken
public FormLoginAuthenticationToken(String clientId, Object principal, Object credentials)
This constructor can be safely used by any code that wishes to create aOAuth2ClientAuthenticationToken, as theAbstractAuthenticationToken.isAuthenticated()will returnfalse.
-
FormLoginAuthenticationToken
public FormLoginAuthenticationToken(String clientId, Object principal, Object credentials, Collection<? extends org.springframework.security.core.GrantedAuthority> authorities)
This constructor should only be used byAuthenticationManagerorAuthenticationProviderimplementations that are satisfied with producing a trusted (i.e.AbstractAuthenticationToken.isAuthenticated()=true) authentication token.- Parameters:
clientId-principal-credentials-authorities-
-
-
Method Detail
-
getClientId
public String getClientId()
-
-