Spring Security

Enable Spring security (web.xml):

<!-- spring security -->
<filter>
    <filter-name>springSecurityFilterChain</filter-name>
    <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
</filter>
<filter-mapping>
    <filter-name>springSecurityFilterChain</filter-name>
    <url-pattern>/*</url-pattern>
</filter-mapping>

The /* mapping ensures that every request is filtered through the Spring Security interceptor.

DelegatingFilterProxy delegates to a Spring injected Filter bean (FilterChainProxy)

FilterChainProxy

  • registered by spring using id : “springSecurityFilterChain”
  • chains together additional filters

Make sure XML configuration for Spring security is loaded, otherwise : “No bean named ‘springSecurityFilterChain’ is defined”

Advertisements
Posted in Spring, Spring Security

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: