@ThreadSafe public abstract class BaseSelfContainedAccessTokenClaimsCodec extends Object implements SelfContainedAccessTokenClaimsCodec
Provides encoding and decoding for all token parameters for which there is an appropriate standard JWT claim (see JSON Web Token (JWT) (RFC 7519), section 4.1, draft-ietf-oauth-mtls-07):
The extending class should implement encoding and decoding for the remaining token parameters:
Constructor and Description |
---|
BaseSelfContainedAccessTokenClaimsCodec() |
Modifier and Type | Method and Description |
---|---|
AccessTokenAuthorization |
decode(com.nimbusds.jwt.JWTClaimsSet claimsSet,
TokenCodecContext context)
Decodes the specified JWT claims set into an access token
authorisation.
|
com.nimbusds.jwt.JWTClaimsSet |
encode(AccessTokenAuthorization tokenAuthz,
TokenEncoderContext context)
Encodes the specified access token authorisation into a JWT claims
set.
|
public BaseSelfContainedAccessTokenClaimsCodec()
public com.nimbusds.jwt.JWTClaimsSet encode(AccessTokenAuthorization tokenAuthz, TokenEncoderContext context)
SelfContainedAccessTokenClaimsCodec
encode
in interface SelfContainedAccessTokenClaimsCodec
tokenAuthz
- The access token authorisation. Not null
.context
- The token encoder context. Not null
.public AccessTokenAuthorization decode(com.nimbusds.jwt.JWTClaimsSet claimsSet, TokenCodecContext context) throws TokenDecodeException
SelfContainedAccessTokenClaimsCodec
decode
in interface SelfContainedAccessTokenClaimsCodec
claimsSet
- The JWT claims set. Not null
.context
- The token codec context. Not null
.TokenDecodeException
- If decoding failed.Copyright © 2019 Connect2id Ltd.. All rights reserved.