Class ReferenceTokenClaimsCustomizer
java.lang.Object
com.irurueta.authserver.authorization.api.web.tokens.ReferenceTokenClaimsCustomizer
- All Implemented Interfaces:
org.springframework.security.oauth2.server.authorization.token.OAuth2TokenCustomizer<org.springframework.security.oauth2.server.authorization.token.OAuth2TokenClaimsContext>
@Component
public class ReferenceTokenClaimsCustomizer
extends Object
implements org.springframework.security.oauth2.server.authorization.token.OAuth2TokenCustomizer<org.springframework.security.oauth2.server.authorization.token.OAuth2TokenClaimsContext>
Adds the claims of
IssuedTokenClaims to the reference (opaque) access tokens. Such a token carries no
claims itself: the claims are stored with the authorization and returned by the introspection endpoint, so a
resource server that introspects it sees the same roles, tenant, aud and contributed
claims as one that decodes a JWT. It is the one OAuth2TokenCustomizer<OAuth2TokenClaimsContext> of the
server.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final IssuedTokenClaimsThe claims every issued token gets. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcustomize(org.springframework.security.oauth2.server.authorization.token.OAuth2TokenClaimsContext context)
-
Field Details
-
issuedTokenClaims
The claims every issued token gets.
-
-
Constructor Details
-
ReferenceTokenClaimsCustomizer
public ReferenceTokenClaimsCustomizer()
-
-
Method Details
-
customize
public void customize(org.springframework.security.oauth2.server.authorization.token.OAuth2TokenClaimsContext context) - Specified by:
customizein interfaceorg.springframework.security.oauth2.server.authorization.token.OAuth2TokenCustomizer<org.springframework.security.oauth2.server.authorization.token.OAuth2TokenClaimsContext>
-