Class AdvancedOAuth2RefreshTokenGenerator
java.lang.Object
com.broadleafcommerce.auth.authorization.security.AdvancedOAuth2RefreshTokenGenerator
- All Implemented Interfaces:
org.springframework.security.oauth2.server.authorization.token.OAuth2TokenGenerator<org.springframework.security.oauth2.core.OAuth2RefreshToken>
public class AdvancedOAuth2RefreshTokenGenerator
extends Object
implements org.springframework.security.oauth2.server.authorization.token.OAuth2TokenGenerator<org.springframework.security.oauth2.core.OAuth2RefreshToken>
Token generator for refresh tokens. Creates a composite key that contains both the newly
generated secure random string, but also the OID. The OID is an original ID generated for the
first refresh token and is included with every token rotation thereafter. The OID serves to
relate all rotated refresh tokens issued.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
extractOid
(String refreshTokenValue) org.springframework.security.oauth2.core.OAuth2RefreshToken
generate
(org.springframework.security.oauth2.server.authorization.token.OAuth2TokenContext context)
-
Field Details
-
AUTH_CODE_GRANT_KEY_NAME
- See Also:
-
OID_KEY_NAME
- See Also:
-
-
Constructor Details
-
AdvancedOAuth2RefreshTokenGenerator
public AdvancedOAuth2RefreshTokenGenerator()
-
-
Method Details
-
generate
public org.springframework.security.oauth2.core.OAuth2RefreshToken generate(org.springframework.security.oauth2.server.authorization.token.OAuth2TokenContext context) - Specified by:
generate
in interfaceorg.springframework.security.oauth2.server.authorization.token.OAuth2TokenGenerator<org.springframework.security.oauth2.core.OAuth2RefreshToken>
-
extractOid
-