Class AbstractUserDetailsAuthenticationProvider

java.lang.Object
cn.herodotus.engine.oauth2.authentication.provider.AbstractAuthenticationProvider
cn.herodotus.engine.oauth2.authentication.provider.AbstractUserDetailsAuthenticationProvider
All Implemented Interfaces:
org.springframework.security.authentication.AuthenticationProvider
Direct Known Subclasses:
OAuth2ResourceOwnerPasswordAuthenticationProvider, OAuth2SocialCredentialsAuthenticationProvider

public abstract class AbstractUserDetailsAuthenticationProvider extends AbstractAuthenticationProvider

Description: 抽象的用户认证Provider

提取公共的用户通用基类,方便涉及用户校验的自定义认证模式使用

Author:
: gengwei.zheng
See Also:
  • AbstractUserDetailsAuthenticationProvider
Date:
: 2022/7/6 16:07
  • Constructor Details

    • AbstractUserDetailsAuthenticationProvider

      public AbstractUserDetailsAuthenticationProvider(org.springframework.security.oauth2.server.authorization.OAuth2AuthorizationService authorizationService, org.springframework.security.core.userdetails.UserDetailsService userDetailsService, OAuth2AuthenticationProperties authenticationProperties)
  • Method Details

    • getUserDetailsService

      public cn.herodotus.engine.oauth2.core.definition.service.EnhanceUserDetailsService getUserDetailsService()
    • getPasswordEncoder

      protected org.springframework.security.crypto.password.PasswordEncoder getPasswordEncoder()
    • setPasswordEncoder

      public void setPasswordEncoder(org.springframework.security.crypto.password.PasswordEncoder passwordEncoder)
    • additionalAuthenticationChecks

      protected abstract void additionalAuthenticationChecks(org.springframework.security.core.userdetails.UserDetails userDetails, Map<String,Object> additionalParameters) throws org.springframework.security.core.AuthenticationException
      Throws:
      org.springframework.security.core.AuthenticationException
    • retrieveUser

      protected abstract org.springframework.security.core.userdetails.UserDetails retrieveUser(Map<String,Object> additionalParameters) throws org.springframework.security.core.AuthenticationException
      Throws:
      org.springframework.security.core.AuthenticationException
    • getUsernamePasswordAuthentication

      protected org.springframework.security.core.Authentication getUsernamePasswordAuthentication(Map<String,Object> additionalParameters, String registeredClientId) throws org.springframework.security.core.AuthenticationException
      Throws:
      org.springframework.security.core.AuthenticationException