public abstract class AbstractJwt extends Object implements Serializable
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractJwt(de.samply.common.config.OAuth2Client config,
String serialized)
Initializes this Jwt with an OAuth2Client configuration and the serialized string.
|
protected |
AbstractJwt(PublicKey publicKey,
String serialized)
Initializes this Jwt with a public key and the serialized string.
|
| Modifier and Type | Method and Description |
|---|---|
com.nimbusds.jwt.JWTClaimsSet |
getClaimsSet()
Returns all claims.
|
PublicKey |
getPublicKey()
Returns the public key that has been used to verify this Jwt.
|
String |
getSerialized()
Returns the serialized string of this Jwt.
|
String |
getSubject()
Returns the subject.
|
protected abstract String |
getTokenType()
This method must return one of the currently defined token types.
|
boolean |
isValid()
Checks if this Jwt is valid.
|
protected AbstractJwt(de.samply.common.config.OAuth2Client config,
String serialized)
throws JwtException
config - the OAuth2 client side configuration. The public key is needed to check the
signature.serialized - the serialized JwtJwtException - if any error occurs during deserialization
or signature verificationprotected AbstractJwt(PublicKey publicKey, String serialized) throws JwtException
publicKey - The identity providers public key (needed to check the signature)serialized - the serialized JwtJwtException - if any error occurs during deserialization
or signature verificationpublic boolean isValid()
public com.nimbusds.jwt.JWTClaimsSet getClaimsSet()
JWTClaimsSet object.public String getSerialized()
String object.public String getSubject()
String object.public PublicKey getPublicKey()
protected abstract String getTokenType()
ACCESS_TOKEN ID_TOKEN REFRESH_TOKEN
Copyright © 2020 Samply Community. All rights reserved.