Interface OauthAuthenticationMapper
public interface OauthAuthenticationMapper
A contract for mapping an OAuth 2.0 token endpoint response to a
AuthenticationResponse object.- Since:
- 1.2.0
- Author:
- James Kleeh
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringA key to be stored in the user details to store the access token returned by the provider.static final StringA key to be stored in the user details to denote which provider authenticated the user.static final StringA key to be stored in the user details to store the refresh token returned by the provider. -
Method Summary
Modifier and TypeMethodDescriptionorg.reactivestreams.Publisher<AuthenticationResponse>createAuthenticationResponse(TokenResponse tokenResponse, @Nullable State state) Convert the token response and state into an authentication response.
-
Field Details
-
PROVIDER_KEY
A key to be stored in the user details to denote which provider authenticated the user.- See Also:
-
ACCESS_TOKEN_KEY
A key to be stored in the user details to store the access token returned by the provider.- See Also:
-
REFRESH_TOKEN_KEY
A key to be stored in the user details to store the refresh token returned by the provider.- See Also:
-
-
Method Details
-
createAuthenticationResponse
org.reactivestreams.Publisher<AuthenticationResponse> createAuthenticationResponse(TokenResponse tokenResponse, @Nullable @Nullable State state) Convert the token response and state into an authentication response.- Parameters:
tokenResponse- The token responsestate- The OAuth state- Returns:
- The authentication response
-