public interface OAuth2TokenContext extends Context
OAuth2TokenGenerator and OAuth2TokenCustomizer.Context,
OAuth2TokenGenerator,
OAuth2TokenCustomizer| Modifier and Type | Interface and Description |
|---|---|
static class |
OAuth2TokenContext.AbstractBuilder<T extends OAuth2TokenContext,B extends OAuth2TokenContext.AbstractBuilder<T,B>>
Base builder for implementations of
OAuth2TokenContext. |
| Modifier and Type | Method and Description |
|---|---|
default OAuth2Authorization |
getAuthorization()
Returns the
authorization. |
default <T extends org.springframework.security.core.Authentication> |
getAuthorizationGrant()
Returns the
Authentication representing the authorization grant. |
default org.springframework.security.oauth2.core.AuthorizationGrantType |
getAuthorizationGrantType()
Returns the
authorization grant type. |
default java.util.Set<java.lang.String> |
getAuthorizedScopes()
Returns the authorized scope(s).
|
default <T extends org.springframework.security.core.Authentication> |
getPrincipal()
Returns the
Authentication representing the Principal resource owner (or client). |
default ProviderContext |
getProviderContext()
Returns the
provider context. |
default RegisteredClient |
getRegisteredClient()
Returns the
registered client. |
default OAuth2TokenType |
getTokenType()
Returns the
token type. |
default RegisteredClient getRegisteredClient()
registered client.RegisteredClientdefault <T extends org.springframework.security.core.Authentication> T getPrincipal()
Authentication representing the Principal resource owner (or client).T - the type of the AuthenticationAuthentication representing the Principal resource owner (or client)default ProviderContext getProviderContext()
provider context.ProviderContext@Nullable default OAuth2Authorization getAuthorization()
authorization.OAuth2Authorization, or null if not availabledefault java.util.Set<java.lang.String> getAuthorizedScopes()
default OAuth2TokenType getTokenType()
token type.OAuth2TokenTypedefault org.springframework.security.oauth2.core.AuthorizationGrantType getAuthorizationGrantType()
authorization grant type.AuthorizationGrantTypedefault <T extends org.springframework.security.core.Authentication> T getAuthorizationGrant()
Authentication representing the authorization grant.T - the type of the AuthenticationAuthentication representing the authorization grant