概述
介绍
WebSecurityConfigurer
是Spring Security Config
的一个概念模型接口,用于建模"Web安全配置器"这一概念模型。
WebSecurityConfigurer
被设计用于配置某个构建目标为Filter
的某个SecurityBuilder
安全构建器,WebSecurityConfigurer
自身并没有定义任何方法,但是它继承自接口SecurityConfigurer
,表明这是一个"安全配置器",所以它也具有SecurityConfigurer
所具备的初始化能力#init
和构建能力#configure
。
继承关系
源代码
源代码版本 : Spring Security Config 5.1.4.RELEASE
package org.springframework.security.config.annotation.web;
import javax.servlet.Filter;
import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.SecurityBuilder;
import org.springframework.security.config.annotation.SecurityConfigurer;
import org.springframework.security.config.annotation.web.builders.WebSecurity;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
/**
* Allows customization to the WebSecurity. In most instances users will use
* EnableWebSecurity and a create Configuration that extends
* WebSecurityConfigurerAdapter which will automatically be applied to the
* WebSecurity by the EnableWebSecurity annotation.
*
* @see WebSecurityConfigurerAdapter
*
* @author Rob Winch
* @since 3.2
*/
public interface WebSecurityConfigurer<T extends SecurityBuilder<Filter>> extends
SecurityConfigurer<Filter, T> {
}