List of usage examples for org.springframework.security.config Elements INTERCEPT_URL
String INTERCEPT_URL
To view the source code for org.springframework.security.config Elements INTERCEPT_URL.
Click Source Link
From source file:org.springframework.security.config.http.FilterInvocationSecurityMetadataSourceParser.java
public BeanDefinition parse(Element element, ParserContext parserContext) { List<Element> interceptUrls = DomUtils.getChildElementsByTagName(element, Elements.INTERCEPT_URL); // Check for attributes that aren't allowed in this context for (Element elt : interceptUrls) { if (StringUtils.hasLength(elt.getAttribute(HttpSecurityBeanDefinitionParser.ATT_REQUIRES_CHANNEL))) { parserContext.getReaderContext().error("The attribute '" + HttpSecurityBeanDefinitionParser.ATT_REQUIRES_CHANNEL + "' isn't allowed here.", elt); }/* w w w . j a va 2s.c o m*/ if (StringUtils.hasLength(elt.getAttribute(HttpSecurityBeanDefinitionParser.ATT_FILTERS))) { parserContext.getReaderContext().error( "The attribute '" + HttpSecurityBeanDefinitionParser.ATT_FILTERS + "' isn't allowed here.", elt); } if (StringUtils.hasLength(elt.getAttribute(ATT_SERVLET_PATH))) { parserContext.getReaderContext() .error("The attribute '" + ATT_SERVLET_PATH + "' isn't allowed here.", elt); } } BeanDefinition mds = createSecurityMetadataSource(interceptUrls, false, element, parserContext); String id = element.getAttribute(AbstractBeanDefinitionParser.ID_ATTRIBUTE); if (StringUtils.hasText(id)) { parserContext.registerComponent(new BeanComponentDefinition(mds, id)); parserContext.getRegistry().registerBeanDefinition(id, mds); } return mds; }