public class OAuth2FormLoginAuthenticationFilter
extends org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter
Description: OAuth2 表单登录过滤器
SPRING_SECURITY_FORM_PASSWORD_KEY, SPRING_SECURITY_FORM_USERNAME_KEY| 构造器和说明 |
|---|
OAuth2FormLoginAuthenticationFilter() |
OAuth2FormLoginAuthenticationFilter(org.springframework.security.authentication.AuthenticationManager authenticationManager) |
| 限定符和类型 | 方法和说明 |
|---|---|
org.springframework.security.core.Authentication |
attemptAuthentication(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response) |
void |
setPostOnly(boolean postOnly) |
protected void |
unsuccessfulAuthentication(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
org.springframework.security.core.AuthenticationException failed)
重写该方法,避免在日志Debug级别会输出错误信息的问题。
|
getPasswordParameter, getUsernameParameter, obtainPassword, obtainUsername, setDetails, setPasswordParameter, setUsernameParameterafterPropertiesSet, doFilter, getAllowSessionCreation, getAuthenticationManager, getFailureHandler, getRememberMeServices, getSuccessHandler, requiresAuthentication, setAllowSessionCreation, setApplicationEventPublisher, setAuthenticationDetailsSource, setAuthenticationFailureHandler, setAuthenticationManager, setAuthenticationSuccessHandler, setContinueChainBeforeSuccessfulAuthentication, setFilterProcessesUrl, setMessageSource, setRememberMeServices, setRequiresAuthenticationRequestMatcher, setSecurityContextRepository, setSessionAuthenticationStrategy, successfulAuthenticationpublic OAuth2FormLoginAuthenticationFilter()
public OAuth2FormLoginAuthenticationFilter(org.springframework.security.authentication.AuthenticationManager authenticationManager)
public org.springframework.security.core.Authentication attemptAuthentication(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
throws org.springframework.security.core.AuthenticationException
attemptAuthentication 在类中 org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilterorg.springframework.security.core.AuthenticationExceptionpublic void setPostOnly(boolean postOnly)
setPostOnly 在类中 org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilterprotected void unsuccessfulAuthentication(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response,
org.springframework.security.core.AuthenticationException failed)
throws IOException,
javax.servlet.ServletException
unsuccessfulAuthentication 在类中 org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilterrequest - 请求response - 响应failed - 失败内容IOException - IOExceptionjavax.servlet.ServletException - ServletExceptionCopyright © 2023 Dromara. All rights reserved.