Spring Security 모듈을 실행하기 위해 web.xml 을 변경한다.
<!-- ########################################## # RootContext ########################################## --> <context-param> <param-name>contextConfigLocation</param-name> <param-value> classpath:com/u2ware/springfield/sample/root-context.xml classpath:com/u2ware/springfield/context-security.xml </param-value> </context-param> <listener> <listener-class> org.springframework.web.context.ContextLoaderListener </listener-class> </listener> <!-- ########################################## # Spring Security Listener & Filter ########################################## --> <listener> <listener-class> org.springframework.security.web.session.HttpSessionEventPublisher </listener-class> </listener> <filter> <filter-name>springSecurityFilterChain</filter-name> <filter-class> org.springframework.web.filter.DelegatingFilterProxy </filter-class> </filter> <filter-mapping> <filter-name>springSecurityFilterChain</filter-name> <servlet-name>appServlet</servlet-name> </filter-mapping>
Spring Security 를 위해 @Springfield 는 다음과 같은 설정을 사용한다.
@Springfield 의 기본 설정 값은 다음과 같다.