SEC-1298: Deleted custom-filter BeanDefinitionDecorator

This commit is contained in:
Luke Taylor 2009-11-17 21:36:11 +00:00
parent 9b49dce8b5
commit 66b1b1957c
2 changed files with 0 additions and 28 deletions

View File

@ -5,7 +5,6 @@ import org.springframework.security.config.authentication.AuthenticationManagerB
import org.springframework.security.config.authentication.AuthenticationProviderBeanDefinitionParser;
import org.springframework.security.config.authentication.JdbcUserServiceBeanDefinitionParser;
import org.springframework.security.config.authentication.UserServiceBeanDefinitionParser;
import org.springframework.security.config.http.CustomFilterBeanDefinitionDecorator;
import org.springframework.security.config.http.FilterChainMapBeanDefinitionDecorator;
import org.springframework.security.config.http.FilterInvocationSecurityMetadataSourceParser;
import org.springframework.security.config.http.HttpSecurityBeanDefinitionParser;
@ -43,6 +42,5 @@ public class SecurityNamespaceHandler extends NamespaceHandlerSupport {
// Decorators
registerBeanDefinitionDecorator(Elements.INTERCEPT_METHODS, new InterceptMethodsBeanDefinitionDecorator());
registerBeanDefinitionDecorator(Elements.FILTER_CHAIN_MAP, new FilterChainMapBeanDefinitionDecorator());
registerBeanDefinitionDecorator(Elements.CUSTOM_FILTER, new CustomFilterBeanDefinitionDecorator());
}
}

View File

@ -1,26 +0,0 @@
package org.springframework.security.config.http;
import org.springframework.beans.factory.config.BeanDefinitionHolder;
import org.springframework.beans.factory.xml.BeanDefinitionDecorator;
import org.springframework.beans.factory.xml.ParserContext;
import org.w3c.dom.Node;
/**
* No longer used in Spring Security 3, other than to report a warning. The <custom-filter> elements should
* be placed within the <http> block. See SEC-1186.
*
* @author Luke Taylor
* @version $Id$
*/
public class CustomFilterBeanDefinitionDecorator implements BeanDefinitionDecorator {
public BeanDefinitionHolder decorate(Node node, BeanDefinitionHolder holder, ParserContext parserContext) {
parserContext.getReaderContext().warning("The use of <custom-filter /> within a filter bean declaration " +
"is not supported in Spring Security 3.0+. If you are using Spring 3.0+, you should be place the " +
"<custom-filter /> element within the " +
"<http> block in our configuration and add a 'ref' attribute which points to your filter bean",
parserContext.extractSource(node));
return holder;
}
}