Class JWTAuthentication
- java.lang.Object
-
- org.apache.syncope.core.spring.security.JWTAuthentication
-
- All Implemented Interfaces:
Serializable
,Principal
,Authentication
public class JWTAuthentication extends Object implements Authentication
Represents the token for an authentication request or for an authenticated principal as JSON Web Token, once the request has been processed by theAuthenticationManager.authenticate(Authentication)
method.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description JWTAuthentication(com.nimbusds.jwt.JWTClaimsSet claims, SyncopeAuthenticationDetails details)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
Collection<SyncopeGrantedAuthority>
getAuthorities()
com.nimbusds.jwt.JWTClaimsSet
getClaims()
Object
getCredentials()
SyncopeAuthenticationDetails
getDetails()
String
getName()
Object
getPrincipal()
int
hashCode()
boolean
isAuthenticated()
void
setAuthenticated(boolean authenticated)
void
setUsername(String username)
String
toString()
-
-
-
Constructor Detail
-
JWTAuthentication
public JWTAuthentication(com.nimbusds.jwt.JWTClaimsSet claims, SyncopeAuthenticationDetails details)
-
-
Method Detail
-
getClaims
public com.nimbusds.jwt.JWTClaimsSet getClaims()
-
getAuthorities
public Collection<SyncopeGrantedAuthority> getAuthorities()
- Specified by:
getAuthorities
in interfaceAuthentication
-
getCredentials
public Object getCredentials()
- Specified by:
getCredentials
in interfaceAuthentication
-
getDetails
public SyncopeAuthenticationDetails getDetails()
- Specified by:
getDetails
in interfaceAuthentication
-
getPrincipal
public Object getPrincipal()
- Specified by:
getPrincipal
in interfaceAuthentication
-
setUsername
public void setUsername(String username)
-
isAuthenticated
public boolean isAuthenticated()
- Specified by:
isAuthenticated
in interfaceAuthentication
-
setAuthenticated
public void setAuthenticated(boolean authenticated) throws IllegalArgumentException
- Specified by:
setAuthenticated
in interfaceAuthentication
- Throws:
IllegalArgumentException
-
hashCode
public int hashCode()
-
equals
public boolean equals(Object obj)
-
-