java.lang.Object
de.hybris.platform.webservicescommons.oauth2.token.provider.HybrisOAuthTokenStore
All Implemented Interfaces:
org.springframework.security.oauth2.provider.token.TokenStore

public class HybrisOAuthTokenStore extends Object implements org.springframework.security.oauth2.provider.token.TokenStore
  • Constructor Details

    • HybrisOAuthTokenStore

      public HybrisOAuthTokenStore()
  • Method Details

    • getAccessToken

      public org.springframework.security.oauth2.common.OAuth2AccessToken getAccessToken(org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
      Specified by:
      getAccessToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • replaceToken

      protected void replaceToken(org.springframework.security.oauth2.provider.OAuth2Authentication authentication, org.springframework.security.oauth2.common.OAuth2AccessToken accessToken)
    • storeAccessToken

      public void storeAccessToken(org.springframework.security.oauth2.common.OAuth2AccessToken token, org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
      Specified by:
      storeAccessToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • isSpringDuplicateKeyException

      protected boolean isSpringDuplicateKeyException(Exception e)
    • readAccessToken

      public org.springframework.security.oauth2.common.OAuth2AccessToken readAccessToken(String tokenValue)
      Specified by:
      readAccessToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • removeAccessToken

      public void removeAccessToken(org.springframework.security.oauth2.common.OAuth2AccessToken token)
      Specified by:
      removeAccessToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • removeAccessToken

      public void removeAccessToken(String tokenValue)
    • readAuthentication

      public org.springframework.security.oauth2.provider.OAuth2Authentication readAuthentication(org.springframework.security.oauth2.common.OAuth2AccessToken token)
      Specified by:
      readAuthentication in interface org.springframework.security.oauth2.provider.token.TokenStore
    • readAuthentication

      public org.springframework.security.oauth2.provider.OAuth2Authentication readAuthentication(String token)
      Specified by:
      readAuthentication in interface org.springframework.security.oauth2.provider.token.TokenStore
    • storeRefreshToken

      public void storeRefreshToken(org.springframework.security.oauth2.common.OAuth2RefreshToken refreshToken, org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
      Specified by:
      storeRefreshToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • readRefreshToken

      public org.springframework.security.oauth2.common.OAuth2RefreshToken readRefreshToken(String token)
      Specified by:
      readRefreshToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • removeRefreshToken

      public void removeRefreshToken(org.springframework.security.oauth2.common.OAuth2RefreshToken token)
      Specified by:
      removeRefreshToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • removeRefreshToken

      public void removeRefreshToken(String token)
    • readAuthenticationForRefreshToken

      public org.springframework.security.oauth2.provider.OAuth2Authentication readAuthenticationForRefreshToken(org.springframework.security.oauth2.common.OAuth2RefreshToken token)
      Specified by:
      readAuthenticationForRefreshToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • readAuthenticationForRefreshToken

      public org.springframework.security.oauth2.provider.OAuth2Authentication readAuthenticationForRefreshToken(String value)
    • removeAccessTokenUsingRefreshToken

      public void removeAccessTokenUsingRefreshToken(org.springframework.security.oauth2.common.OAuth2RefreshToken refreshToken)
      Specified by:
      removeAccessTokenUsingRefreshToken in interface org.springframework.security.oauth2.provider.token.TokenStore
    • removeAccessTokenUsingRefreshToken

      public void removeAccessTokenUsingRefreshToken(String refreshToken)
    • findTokensByClientId

      public Collection<org.springframework.security.oauth2.common.OAuth2AccessToken> findTokensByClientId(String clientId)
      Specified by:
      findTokensByClientId in interface org.springframework.security.oauth2.provider.token.TokenStore
    • findTokensByClientIdAndUserName

      public Collection<org.springframework.security.oauth2.common.OAuth2AccessToken> findTokensByClientIdAndUserName(String clientId, String userName)
      Specified by:
      findTokensByClientIdAndUserName in interface org.springframework.security.oauth2.provider.token.TokenStore
    • findTokensByUserName

      public Collection<org.springframework.security.oauth2.common.OAuth2AccessToken> findTokensByUserName(String userName)
    • extractTokenKey

      protected String extractTokenKey(String value)
    • serializeAccessToken

      protected byte[] serializeAccessToken(org.springframework.security.oauth2.common.OAuth2AccessToken token)
    • serializeRefreshToken

      protected byte[] serializeRefreshToken(org.springframework.security.oauth2.common.OAuth2RefreshToken token)
    • serializeAuthentication

      protected byte[] serializeAuthentication(org.springframework.security.oauth2.provider.OAuth2Authentication authentication)
    • deserializeAccessToken

      protected org.springframework.security.oauth2.common.OAuth2AccessToken deserializeAccessToken(byte[] token)
    • deserializeRefreshToken

      protected org.springframework.security.oauth2.common.OAuth2RefreshToken deserializeRefreshToken(byte[] token)
    • deserializeAuthentication

      protected org.springframework.security.oauth2.provider.OAuth2Authentication deserializeAuthentication(byte[] authentication)
    • getOauthTokenService

      public OAuthTokenService getOauthTokenService()
    • setOauthTokenService

      public void setOauthTokenService(OAuthTokenService oauthTokenService)