public class WindowsAuthenticationToken extends Object implements org.springframework.security.core.Authentication
| Modifier and Type | Field and Description |
|---|---|
static org.springframework.security.core.GrantedAuthority |
DEFAULT_GRANTED_AUTHORITY
The
GrantedAuthority that will be added to every WindowsAuthenticationToken, unless another (or null) is
specified. |
static GrantedAuthorityFactory |
DEFAULT_GRANTED_AUTHORITY_FACTORY
The
GrantedAuthorityFactory that is used by default if a custom one is not specified. |
| Constructor and Description |
|---|
WindowsAuthenticationToken(WindowsPrincipal identity)
Convenience constructor that calls
WindowsAuthenticationToken(WindowsPrincipal, GrantedAuthorityFactory, GrantedAuthority) with:
the given identity,
the DEFAULT_GRANTED_AUTHORITY_FACTORY
the DEFAULT_GRANTED_AUTHORITY
. |
WindowsAuthenticationToken(WindowsPrincipal identity,
GrantedAuthorityFactory grantedAuthorityFactory,
org.springframework.security.core.GrantedAuthority defaultGrantedAuthority)
Instantiates a new windows authentication token.
|
| Modifier and Type | Method and Description |
|---|---|
Collection<org.springframework.security.core.GrantedAuthority> |
getAuthorities() |
Object |
getCredentials() |
Object |
getDetails() |
String |
getName() |
Object |
getPrincipal() |
boolean |
isAuthenticated() |
void |
setAuthenticated(boolean authenticated) |
public static final GrantedAuthorityFactory DEFAULT_GRANTED_AUTHORITY_FACTORY
GrantedAuthorityFactory that is used by default if a custom one is not specified. This default
GrantedAuthorityFactory is a FqnGrantedAuthorityFactory with prefix "ROLE_" and will
convert the fqn to uppercasepublic static final org.springframework.security.core.GrantedAuthority DEFAULT_GRANTED_AUTHORITY
GrantedAuthority that will be added to every WindowsAuthenticationToken, unless another (or null) is
specified.public WindowsAuthenticationToken(WindowsPrincipal identity)
WindowsAuthenticationToken(WindowsPrincipal, GrantedAuthorityFactory, GrantedAuthority) with:
DEFAULT_GRANTED_AUTHORITY_FACTORYDEFAULT_GRANTED_AUTHORITYidentity - the identitypublic WindowsAuthenticationToken(WindowsPrincipal identity, GrantedAuthorityFactory grantedAuthorityFactory, org.springframework.security.core.GrantedAuthority defaultGrantedAuthority)
identity - The WindowsPrincipal for which this token exists.grantedAuthorityFactory - used to construct GrantedAuthoritys for each of the groups to which the
WindowsPrincipal belongsdefaultGrantedAuthority - if not null, this GrantedAuthority will always be added to the granted authorities listpublic Collection<org.springframework.security.core.GrantedAuthority> getAuthorities()
getAuthorities in interface org.springframework.security.core.Authenticationpublic Object getCredentials()
getCredentials in interface org.springframework.security.core.Authenticationpublic Object getDetails()
getDetails in interface org.springframework.security.core.Authenticationpublic Object getPrincipal()
getPrincipal in interface org.springframework.security.core.Authenticationpublic boolean isAuthenticated()
isAuthenticated in interface org.springframework.security.core.Authenticationpublic void setAuthenticated(boolean authenticated)
setAuthenticated in interface org.springframework.security.core.AuthenticationCopyright © 2010–2020 com.github.waffle. All rights reserved.