Spring / Spring Security
How to restrict static resources using spring security?
The Ant matchers match against the request path and not the path of the resource on the filesystem.So ignore any request that starts with "/resources/".This is similar to configuring http@security=none when using the XML namespace configuration.
@Override public void configure(WebSecurity web) throws Exception { web .ignoring() .antMatchers("/resources/**"); }
More Related questions...