SEC-271: Replaced legacy bean definitions with the new namespace elements
This commit is contained in:
parent
1444f1087d
commit
ec02a3458f
|
@ -23,8 +23,6 @@
|
|||
- $Id: applicationContext-acegi-security.xml 1513 2006-05-29 13:32:12Z benalex $
|
||||
-->
|
||||
|
||||
|
||||
|
||||
<bean id="filterChainProxy"
|
||||
class="org.acegisecurity.util.FilterChainProxy">
|
||||
<property name="filterInvocationDefinitionSource">
|
||||
|
@ -62,7 +60,7 @@
|
|||
<security:authentication-mechanism id="authenticationManager" />
|
||||
|
||||
<!-- dao authentication provider "authenticationRepository" -->
|
||||
<security:authentication-repository id="daoAuthenticationProvider" />
|
||||
<security:authentication-repository id="daoAuthenticationProvider" repositoryBeanRef="userDetailsService"/>
|
||||
|
||||
<bean id="securityContextHolderAwareRequestFilter"
|
||||
class="org.acegisecurity.wrapper.SecurityContextHolderAwareRequestFilter" />
|
||||
|
@ -83,7 +81,14 @@
|
|||
<security:exception-translation id="exceptionTranslationFilter">
|
||||
<security:entry-point
|
||||
entryPointBeanRef="authenticationEntryPoint" />
|
||||
</security:exception-translation>
|
||||
</security:exception-translation>
|
||||
|
||||
|
||||
<!-- UserDetailsService is the most commonly frequently Acegi Security interface implemented by end users -->
|
||||
|
||||
<security:principal-repository id="userDetailsService">
|
||||
<security:properties resource="/WEB-INF/users.properties" />
|
||||
</security:principal-repository>
|
||||
|
||||
|
||||
<bean id="authenticationEntryPoint"
|
||||
|
@ -127,24 +132,6 @@
|
|||
</property>
|
||||
</bean>
|
||||
|
||||
|
||||
<!--<bean id="authenticationManager"
|
||||
class="org.acegisecurity.providers.ProviderManager">
|
||||
<property name="providers">
|
||||
<list>
|
||||
<ref local="daoAuthenticationProvider" />
|
||||
<bean
|
||||
class="org.acegisecurity.providers.anonymous.AnonymousAuthenticationProvider">
|
||||
<property name="key" value="changeThis" />
|
||||
</bean>
|
||||
<bean
|
||||
class="org.acegisecurity.providers.rememberme.RememberMeAuthenticationProvider">
|
||||
<property name="key" value="changeThis" />
|
||||
</bean>
|
||||
</list>
|
||||
</property>
|
||||
</bean>-->
|
||||
|
||||
<bean id="userCache"
|
||||
class="org.acegisecurity.providers.dao.cache.EhCacheBasedUserCache">
|
||||
<property name="cache">
|
||||
|
@ -160,13 +147,6 @@
|
|||
</bean>
|
||||
|
||||
|
||||
<!-- UserDetailsService is the most commonly frequently Acegi Security interface implemented by end users -->
|
||||
|
||||
<security:principal-repository id="userDetailsService">
|
||||
<security:properties resource="/WEB-INF/users.properties" />
|
||||
</security:principal-repository>
|
||||
|
||||
|
||||
<!-- This bean is optional; it isn't used by any other bean as it only listens and logs -->
|
||||
<bean id="loggerListener"
|
||||
class="org.acegisecurity.event.authentication.LoggerListener" />
|
|
@ -6,7 +6,7 @@
|
|||
xmlns:util="http://www.springframework.org/schema/util"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
|
||||
http://www.springframework.org/schema/util http://www.springframework.org/schema/beans/spring-util-2.0.xsd
|
||||
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-2.0.xsd">
|
||||
http://www.springframework.org/schema/security file:/Users/vpuri/interface21/acegisecurity/trunk/acegisecurity/core/src/main/resources/org/acegisecurity/config/spring-security-2.0.xsd">
|
||||
|
||||
<!--
|
||||
- A simple "base bones" Acegi Security configuration.
|
||||
|
@ -24,7 +24,6 @@
|
|||
-->
|
||||
|
||||
|
||||
|
||||
<bean id="filterChainProxy"
|
||||
class="org.acegisecurity.util.FilterChainProxy">
|
||||
<property name="filterInvocationDefinitionSource">
|
||||
|
@ -43,18 +42,17 @@
|
|||
|
||||
<!-- If LogoutFilter does not have setHandlers populated, introspect app ctx for LogoutHandlers, using Ordered (if present, otherwise assume Integer.MAX_VALUE) -->
|
||||
<!-- The logoutUrl and redirectAfterLogout are both optional and default to that shown -->
|
||||
<security:logout-support id="logoutFilter"
|
||||
redirectAfterLogoutUrl="/index.jsp" />
|
||||
<security:logout-support id="logoutFilter" redirectAfterLogoutUrl="/index.jsp" logoutUrl="/j_acegi_logout"/>
|
||||
|
||||
<security:authentication-remember-me-services
|
||||
id="rememberMeServices" key="someValue" />
|
||||
id="rememberMeServices" key="someValue" principalRepositoryBeanRef="userDetailsService"/>
|
||||
|
||||
|
||||
<bean id="securityContextLogoutHandler"
|
||||
class="org.acegisecurity.ui.logout.SecurityContextLogoutHandler" />
|
||||
|
||||
<!-- the URLs are all mandatory and have no defaults (well, except authenticationUrl) -->
|
||||
<security:authentication-form id="authenticationProcessinFilter"
|
||||
<security:authentication-form id="authenticationProcessingFilter"
|
||||
authenticationUrl="/j_acegi_security_check" defaultTargetUrl="/"
|
||||
errorFormUrl="/acegilogin.jsp?login_error=1" />
|
||||
|
||||
|
@ -62,13 +60,19 @@
|
|||
<security:authentication-mechanism id="authenticationManager" />
|
||||
|
||||
<!-- dao authentication provider "authenticationRepository" -->
|
||||
<security:authentication-repository id="daoAuthenticationProvider" />
|
||||
<security:authentication-repository id="daoAuthenticationProvider" repositoryBeanRef="userDetailsService"/>
|
||||
|
||||
|
||||
<!-- UserDetailsService is the most commonly frequently Acegi Security interface implemented by end users -->
|
||||
<security:principal-repository id="userDetailsService">
|
||||
<security:properties resource="/WEB-INF/users.properties" />
|
||||
</security:principal-repository>
|
||||
|
||||
<bean id="securityContextHolderAwareRequestFilter"
|
||||
class="org.acegisecurity.wrapper.SecurityContextHolderAwareRequestFilter" />
|
||||
|
||||
<!-- makes the filter, but does little else, as it auto-detects everything -->
|
||||
<security:authentication-remember-me-filter id="rememberMeFilter" />
|
||||
<security:authentication-remember-me-filter id="rememberMeProcessingFilter" />
|
||||
|
||||
<bean id="anonymousProcessingFilter"
|
||||
class="org.acegisecurity.providers.anonymous.AnonymousProcessingFilter">
|
||||
|
@ -159,14 +163,6 @@
|
|||
</property>
|
||||
</bean>
|
||||
|
||||
|
||||
<!-- UserDetailsService is the most commonly frequently Acegi Security interface implemented by end users -->
|
||||
|
||||
<security:principal-repository id="userDetailsService">
|
||||
<security:properties resource="/WEB-INF/users.properties" />
|
||||
</security:principal-repository>
|
||||
|
||||
|
||||
<!-- This bean is optional; it isn't used by any other bean as it only listens and logs -->
|
||||
<bean id="loggerListener"
|
||||
class="org.acegisecurity.event.authentication.LoggerListener" />
|
Loading…
Reference in New Issue