This filter starts the initial authentication flow. It uses the configured org.springframework.security.authentication.AuthenticationManager bean, allowing to use any authentication provider defined by other plugins or by the application. If the authentication manager authenticates the request, a token is generated using a TokenGenerator and stored via TokenStorageService. Finally, a org.springframework.security.web.authentication.AuthenticationSuccessHandler is used to render the REST response to the client. If there is an authentication failure, the configured org.springframework.security.web.authentication.AuthenticationFailureHandler will render the response.
Type | Name and description |
---|---|
org.springframework.security.authentication.AuthenticationDetailsSource<javax.servlet.http.HttpServletRequest, ?> |
authenticationDetailsSource |
org.springframework.security.web.authentication.AuthenticationFailureHandler |
authenticationFailureHandler |
org.springframework.security.authentication.AuthenticationManager |
authenticationManager |
org.springframework.security.web.authentication.AuthenticationSuccessHandler |
authenticationSuccessHandler |
CredentialsExtractor |
credentialsExtractor |
java.lang.String |
endpointUrl |
TokenGenerator |
tokenGenerator |
TokenStorageService |
tokenStorageService |
Constructor and description |
---|
RestAuthenticationFilter
() |
Type | Name and description |
---|---|
void |
doFilter(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain chain) |
Methods inherited from class | Name |
---|---|
class org.springframework.web.filter.GenericFilterBean |
org.springframework.web.filter.GenericFilterBean#setEnvironment(org.springframework.core.env.Environment), org.springframework.web.filter.GenericFilterBean#afterPropertiesSet(), org.springframework.web.filter.GenericFilterBean#setServletContext(javax.servlet.ServletContext), org.springframework.web.filter.GenericFilterBean#setBeanName(java.lang.String), org.springframework.web.filter.GenericFilterBean#getFilterConfig(), org.springframework.web.filter.GenericFilterBean#init(javax.servlet.FilterConfig), org.springframework.web.filter.GenericFilterBean#destroy(), org.springframework.web.filter.GenericFilterBean#wait(long, int), org.springframework.web.filter.GenericFilterBean#wait(long), org.springframework.web.filter.GenericFilterBean#wait(), org.springframework.web.filter.GenericFilterBean#equals(java.lang.Object), org.springframework.web.filter.GenericFilterBean#toString(), org.springframework.web.filter.GenericFilterBean#hashCode(), org.springframework.web.filter.GenericFilterBean#getClass(), org.springframework.web.filter.GenericFilterBean#notify(), org.springframework.web.filter.GenericFilterBean#notifyAll(), org.springframework.web.filter.GenericFilterBean#doFilter(javax.servlet.ServletRequest, javax.servlet.ServletResponse, javax.servlet.FilterChain) |
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Groovy Documentation