Class OAuth2ClientCredentialsAuthenticationProvider

java.lang.Object
cn.herodotus.engine.oauth2.authentication.provider.AbstractAuthenticationProvider
cn.herodotus.engine.oauth2.authentication.provider.OAuth2ClientCredentialsAuthenticationProvider
All Implemented Interfaces:
org.springframework.security.authentication.AuthenticationProvider

public class OAuth2ClientCredentialsAuthenticationProvider extends AbstractAuthenticationProvider

Description: 扩展的 OAuth2ClientCredentialsAuthenticationProvider

用于支持 客户端权限验证 以及 支持 Refresh_Token

Author:
: gengwei.zheng
Date:
: 2022/3/31 14:57
  • Constructor Details

    • OAuth2ClientCredentialsAuthenticationProvider

      public OAuth2ClientCredentialsAuthenticationProvider(org.springframework.security.oauth2.server.authorization.OAuth2AuthorizationService authorizationService, org.springframework.security.oauth2.server.authorization.token.OAuth2TokenGenerator<? extends org.springframework.security.oauth2.core.OAuth2Token> tokenGenerator, cn.herodotus.engine.oauth2.core.definition.service.ClientDetailsService clientDetailsService)
      Constructs an OAuth2ClientCredentialsAuthenticationProvider using the provided parameters.
      Parameters:
      authorizationService - the authorization service
      tokenGenerator - the token generator
      Since:
      0.2.3
  • Method Details

    • authenticate

      public org.springframework.security.core.Authentication authenticate(org.springframework.security.core.Authentication authentication) throws org.springframework.security.core.AuthenticationException
      Throws:
      org.springframework.security.core.AuthenticationException
    • supports

      public boolean supports(Class<?> authentication)