org.pac4j.springframework.security.web
Class ClientAuthenticationFilter

java.lang.Object
  extended by org.springframework.web.filter.GenericFilterBean
      extended by org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter
          extended by org.pac4j.springframework.security.web.ClientAuthenticationFilter
All Implemented Interfaces:
javax.servlet.Filter, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationEventPublisherAware, org.springframework.context.MessageSourceAware, org.springframework.web.context.ServletContextAware

public final class ClientAuthenticationFilter
extends org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter

This filter handles callbacks after authentication from the provider. It listens HTTP requests on /j_spring_pac4j_security_check by default or whatever suffix url you can define by constructor. An ClientAuthenticationToken is created to finish the authentication process.

Since:
1.0.0
Author:
Jerome Leleu

Field Summary
static String ATTEMPTED_AUTHENTICATION_SUFFIX
           
 
Fields inherited from class org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter
authenticationDetailsSource, eventPublisher, messages, SPRING_SECURITY_LAST_EXCEPTION_KEY
 
Constructor Summary
protected ClientAuthenticationFilter()
           
  ClientAuthenticationFilter(String suffixUrl)
          Define the suffix url on which the filter will listen for HTTP requests.
 
Method Summary
 void afterPropertiesSet()
           
 org.springframework.security.core.Authentication attemptAuthentication(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 org.pac4j.core.client.Clients getClients()
           
 void setClients(org.pac4j.core.client.Clients clients)
           
 
Methods inherited from class org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter
doFilter, getAllowSessionCreation, getAuthenticationManager, getFailureHandler, getFilterProcessesUrl, getRememberMeServices, getSuccessHandler, requiresAuthentication, setAllowSessionCreation, setApplicationEventPublisher, setAuthenticationDetailsSource, setAuthenticationFailureHandler, setAuthenticationManager, setAuthenticationSuccessHandler, setContinueChainBeforeSuccessfulAuthentication, setFilterProcessesUrl, setMessageSource, setRememberMeServices, setSessionAuthenticationStrategy, successfulAuthentication, successfulAuthentication, unsuccessfulAuthentication
 
Methods inherited from class org.springframework.web.filter.GenericFilterBean
addRequiredProperty, destroy, getFilterConfig, getFilterName, getServletContext, init, initBeanWrapper, initFilterBean, setBeanName, setServletContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ATTEMPTED_AUTHENTICATION_SUFFIX

public static final String ATTEMPTED_AUTHENTICATION_SUFFIX
See Also:
Constant Field Values
Constructor Detail

ClientAuthenticationFilter

public ClientAuthenticationFilter(String suffixUrl)
Define the suffix url on which the filter will listen for HTTP requests.

Parameters:
suffixUrl -

ClientAuthenticationFilter

protected ClientAuthenticationFilter()
Method Detail

afterPropertiesSet

public void afterPropertiesSet()
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
Overrides:
afterPropertiesSet in class org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter

attemptAuthentication

public org.springframework.security.core.Authentication attemptAuthentication(javax.servlet.http.HttpServletRequest request,
                                                                              javax.servlet.http.HttpServletResponse response)
                                                                       throws org.springframework.security.core.AuthenticationException,
                                                                              IOException,
                                                                              javax.servlet.ServletException
Specified by:
attemptAuthentication in class org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter
Throws:
org.springframework.security.core.AuthenticationException
IOException
javax.servlet.ServletException

getClients

public org.pac4j.core.client.Clients getClients()

setClients

public void setClients(org.pac4j.core.client.Clients clients)


Copyright © 2013. All Rights Reserved.