public final class MutableAccessTokenAuthorization extends Object implements AccessTokenAuthorization
Constructor and Description |
---|
MutableAccessTokenAuthorization()
Creates a new empty mutable access token authorisation.
|
MutableAccessTokenAuthorization(AccessTokenAuthorization source)
Creates a new mutable access token authorisation from the specified
one.
|
Modifier and Type | Method and Description |
---|---|
com.nimbusds.oauth2.sdk.id.Actor |
getActor()
Returns the token actor, in impersonation and delegation scenarios.
|
List<com.nimbusds.oauth2.sdk.id.Audience> |
getAudienceList()
Returns the audience list of the token, which may be the logical
names of the intended resource servers.
|
Set<String> |
getClaimNames()
Returns the names of the consented OpenID claims to be accessed at
the UserInfo endpoint.
|
net.minidev.json.JSONObject |
getClaimsData()
Returns the optional claims fulfillment data.
|
List<com.nimbusds.langtag.LangTag> |
getClaimsLocales()
Returns the preferred locales for the consented OpenID claims.
|
com.nimbusds.oauth2.sdk.auth.X509CertificateConfirmation |
getClientCertificateConfirmation()
Returns the client X.509 certificate confirmation (SHA-256
thumbprint) for mutual TLS.
|
com.nimbusds.oauth2.sdk.id.ClientID |
getClientID()
Returns the identifier of the client to which the token is issued.
|
net.minidev.json.JSONObject |
getData()
Returns the optional data for the token.
|
Instant |
getExpirationTime()
Returns the expiration time of the token.
|
com.nimbusds.oauth2.sdk.id.Issuer |
getIssuer()
Returns the issuer of the token.
|
Instant |
getIssueTime()
Returns the issue time of the token.
|
com.nimbusds.oauth2.sdk.id.JWTID |
getJWTID()
Returns the JSON Web Token (JWT) identifier of the token.
|
Map<String,Object> |
getOtherTopLevelParameters()
Returns a map of other top-level parameters.
|
net.minidev.json.JSONObject |
getPresetClaims()
Returns the preset OpenID claims to be included in the UserInfo
response.
|
com.nimbusds.oauth2.sdk.Scope |
getScope()
Returns the scope of the token.
|
com.nimbusds.oauth2.sdk.id.Subject |
getSubject()
Returns the token subject.
|
String |
toString() |
MutableAccessTokenAuthorization |
withActor(com.nimbusds.oauth2.sdk.id.Actor act)
Sets the token actor, in impersonation and delegation scenarios.
|
MutableAccessTokenAuthorization |
withAudienceList(List<com.nimbusds.oauth2.sdk.id.Audience> audList)
Sets the audience list of the token, which may be the logical
names of the intended resource servers.
|
MutableAccessTokenAuthorization |
withClaimNames(Set<String> claimNames)
Sets the names of the consented OpenID claims to be accessed at
the UserInfo endpoint.
|
MutableAccessTokenAuthorization |
withClaimsData(net.minidev.json.JSONObject claimsData)
Sets the claims fulfillment data for the claims source at the
UserInfo endpoint.
|
MutableAccessTokenAuthorization |
withClaimsLocales(List<com.nimbusds.langtag.LangTag> claimsLocales)
Sets the preferred locales for the consented OpenID claims.
|
MutableAccessTokenAuthorization |
withClientCertificateConfirmation(com.nimbusds.oauth2.sdk.auth.X509CertificateConfirmation cnfX5t)
Sets the client X.509 certificate confirmation (SHA-256 thumbprint)
for mutual TLS.
|
MutableAccessTokenAuthorization |
withClientID(com.nimbusds.oauth2.sdk.id.ClientID clientID)
Sets the identifier of the client to which the token is issued.
|
MutableAccessTokenAuthorization |
withData(net.minidev.json.JSONObject data)
Sets the optional data for the token.
|
MutableAccessTokenAuthorization |
withExpirationTime(Instant exp)
Sets the expiration time of the token.
|
MutableAccessTokenAuthorization |
withIssuer(com.nimbusds.oauth2.sdk.id.Issuer iss)
Sets the issuer of the token.
|
MutableAccessTokenAuthorization |
withIssueTime(Instant iat)
Sets the issue time of the token.
|
MutableAccessTokenAuthorization |
withJWTID(com.nimbusds.oauth2.sdk.id.JWTID jti)
Sets the JSON Web Token (JWT) identifier of the token.
|
MutableAccessTokenAuthorization |
withOtherTopLevelParameters(Map<String,Object> params)
Sets the other top-level parameters.
|
MutableAccessTokenAuthorization |
withPresetClaims(net.minidev.json.JSONObject presetClaims)
Sets the preset OpenID claims to be included in the UserInfo
response.
|
MutableAccessTokenAuthorization |
withScope(com.nimbusds.oauth2.sdk.Scope scope)
Sets the scope of the token.
|
MutableAccessTokenAuthorization |
withSubject(com.nimbusds.oauth2.sdk.id.Subject sub)
Sets the token subject.
|
public MutableAccessTokenAuthorization()
public MutableAccessTokenAuthorization(AccessTokenAuthorization source)
source
- The source access token authorisation. Must not be
null
.public MutableAccessTokenAuthorization withSubject(com.nimbusds.oauth2.sdk.id.Subject sub)
sub
- The subject, null
if not specified.public com.nimbusds.oauth2.sdk.id.Subject getSubject()
AccessTokenAuthorization
getSubject
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withActor(com.nimbusds.oauth2.sdk.id.Actor act)
act
- The actor, null
if not specified.public com.nimbusds.oauth2.sdk.id.Actor getActor()
AccessTokenAuthorization
getActor
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withClientID(com.nimbusds.oauth2.sdk.id.ClientID clientID)
clientID
- The client identifier, null
if not
specified.public com.nimbusds.oauth2.sdk.id.ClientID getClientID()
AccessTokenAuthorization
getClientID
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withScope(com.nimbusds.oauth2.sdk.Scope scope)
scope
- The scope, null
if not specified.public com.nimbusds.oauth2.sdk.Scope getScope()
AccessTokenAuthorization
getScope
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withExpirationTime(Instant exp)
exp
- The expiration time, null
if not specified.public Instant getExpirationTime()
AccessTokenAuthorization
getExpirationTime
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withIssueTime(Instant iat)
iat
- The issue time, null
if not specified.public Instant getIssueTime()
AccessTokenAuthorization
getIssueTime
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withIssuer(com.nimbusds.oauth2.sdk.id.Issuer iss)
iss
- The issuer, null
if not specified.public com.nimbusds.oauth2.sdk.id.Issuer getIssuer()
AccessTokenAuthorization
getIssuer
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withAudienceList(List<com.nimbusds.oauth2.sdk.id.Audience> audList)
audList
- The audience list, null
if not specified.public List<com.nimbusds.oauth2.sdk.id.Audience> getAudienceList()
AccessTokenAuthorization
getAudienceList
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withJWTID(com.nimbusds.oauth2.sdk.id.JWTID jti)
jti
- The JWT ID, null
if not specified or applicable.public com.nimbusds.oauth2.sdk.id.JWTID getJWTID()
AccessTokenAuthorization
getJWTID
in interface AccessTokenAuthorization
null
if not specified or applicable.public MutableAccessTokenAuthorization withClaimNames(Set<String> claimNames)
claimNames
- The claim names, null
if not specified.public Set<String> getClaimNames()
AccessTokenAuthorization
getClaimNames
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withClaimsLocales(List<com.nimbusds.langtag.LangTag> claimsLocales)
claimsLocales
- The preferred claims locales, null
if
not specified.public List<com.nimbusds.langtag.LangTag> getClaimsLocales()
AccessTokenAuthorization
getClaimsLocales
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withPresetClaims(net.minidev.json.JSONObject presetClaims)
presetClaims
- The preset OpenID claims, null
if not
specified.public net.minidev.json.JSONObject getPresetClaims()
AccessTokenAuthorization
getPresetClaims
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withClaimsData(net.minidev.json.JSONObject claimsData)
claimsData
- The claims fulfillment data, null
if not
specified.public net.minidev.json.JSONObject getClaimsData()
AccessTokenAuthorization
getClaimsData
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withData(net.minidev.json.JSONObject data)
data
- The optional data, represented as a JSON object,
null
if not specified.public net.minidev.json.JSONObject getData()
AccessTokenAuthorization
getData
in interface AccessTokenAuthorization
null
if not specified.public MutableAccessTokenAuthorization withClientCertificateConfirmation(com.nimbusds.oauth2.sdk.auth.X509CertificateConfirmation cnfX5t)
cnfX5t
- The client X.509 certificate confirmation,
null
if not specified.public com.nimbusds.oauth2.sdk.auth.X509CertificateConfirmation getClientCertificateConfirmation()
AccessTokenAuthorization
getClientCertificateConfirmation
in interface AccessTokenAuthorization
null
if
not specified.public MutableAccessTokenAuthorization withOtherTopLevelParameters(Map<String,Object> params)
params
- Other top-level parameters, the values should map to
JSON entities, null
if none.public Map<String,Object> getOtherTopLevelParameters()
AccessTokenAuthorization
getOtherTopLevelParameters
in interface AccessTokenAuthorization
null
if none.Copyright © 2021 Connect2id Ltd.. All rights reserved.