1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164
| spring
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
<beans>
<!-- ========================= filter chain proxy ========================= -->
<bean id="filterChainProxy"
class="org.springframework.security.util.FilterChainProxy">
<property name="filterInvocationDefinitionSource">
<value>
CONVERT_URL_TO_LOWERCASE_BEFORE_COMPARISON
PATTERN_TYPE_APACHE_ANT
/**=httpSessionContextIntegrationFilter,logoutFilter,novellProcessingFilter,securityContextHolderAwareRequestFilter,exceptionTranslationFilter
</value>
</property>
</bean>
<!-- ========================= les filtres ========================= -->
<bean id="httpSessionContextIntegrationFilter" class="org.springframework.security.context.HttpSessionContextIntegrationFilter" />
<bean id="logoutFilter" lass="org.springframework.security.ui.logout.LogoutFilter">
<constructor-arg value="/logoutSuccess.jsp" />
<constructor-arg>
<list>
<bean class="org.springframework.security.ui.logout.SecurityContextLogoutHandler" />
</list>
</constructor-arg>
</bean>
<bean id="novellProcessingFilter" class="be.toto.momo.ui.NovellProcessingFilter">
<property name="authenticationManager"
ref="authenticationManager" />
<property name="headers">
<list>
<value>${novell.headers.firstname}</value>
<value>${novell.headers.lastname}</value>
<value>${novell.headers.mail}</value>
<value>${novell.headers.cn}</value>
<value>${novell.headers.employeenumber}</value>
<value>${novell.headers.memberof}</value>
<value>${novell.headers.departmentnumber}</value>
<value>${novell.headers.description}</value>
<value>${novell.headers.uid}</value>
</list>
</property>
<property name="principalHeaderName" value="${novell.principal}" />
<property name="profilHeaderName" value="${novell.memberof}" />
</bean>
<bean id="securityContextHolderAwareRequestFilter" class="org.springframework.security.wrapper.SecurityContextHolderAwareRequestFilter" />
<bean id="exceptionTranslationFilter" class="org.springframework.security.ui.ExceptionTranslationFilter">
<property name="authenticationEntryPoint">
<bean class="org.springframework.security.ui.webapp.AuthenticationProcessingFilterEntryPoint">
<property name="loginFormUrl" value="/login.jsp" />
</bean>
</property>
<property name="accessDeniedHandler">
<bean class="org.springframework.security.ui.AccessDeniedHandlerImpl">
<property name="errorPage" value="/accessDenied.jsp" />
</bean>
</property>
</bean>
<!-- ========================= gestion des méthodes ========================= -->
<sec:global-method-security
secured-annotations="enabled" jsr250-annotations="enabled">
</sec:global-method-security>
<!-- Bean post-processor for activating any advisors -->
<bean class="org.springframework.aop.framework.autoproxy.DefaultAdvisorAutoProxyCreator"/>
<!-- The advisor that creates secured proxies for beans using security annotations such as @Secured -->
<bean id="methodDefinitionSourceAdvisor" class="org.acegisecurity.intercept.method.aopalliance.MethodDefinitionSourceAdvisor">
<constructor-arg>
<ref bean="methodInterceptor"/>
<ref bean="delegatingMethodDefinitionSource"/>
</constructor-arg>
</bean>
<bean id="methodInterceptor" class="org.acegisecurity.intercept.method.aopalliance.MethodSecurityInterceptor">
<property name="validateConfigAttributes" value="false"/>
<property name="authenticationManager" ref="authenticationManager"/>
<property name="accessDecisionManager" ref="accessDecisionManager"/>
<property name="objectDefinitionSource" ref="delegatingMethodDefinitionSource"/>
</bean>
<bean id="serviceAccessDecisionManager" class="org.acegisecurity.vote.AffirmativeBased">
<property name="allowIfAllAbstainDecisions">
<value>false</value>
</property>
<property name="decisionVoters">
<list>
<ref bean="roleVoter"/>
<ref bean="authVoter"/>
</list>
</property>
</bean>
<bean id="roleVoter" class="org.acegisecurity.vote.RoleVoter">
<property name="rolePrefix" value=""/>
</bean>
<bean id="authVoter" class="org.springframework.security.vote.AuthenticatedVoter"/>
<bean id="delegatingMethodDefinitionSource" class="org.springframework.security.intercept.method.DelegatingMethodDefinitionSource">
<property name="methodDefinitionSources">
<list>
<bean class="org.springframework.security.intercept.method.MapBasedMethodDefinitionSource" />
<bean class="org.springframework.security.annotation.SecuredMethodDefinitionSource" />
<bean class="org.springframework.security.annotation.Jsr250MethodDefinitionSource" />
</list>
</property>
</bean>
<!-- ========================= beans nécessaire aux filtres ========================= -->
<bean id="userDetailsService" class="be.toto.momo.providers.NovellUserDetailsService">
<property name="novellConvertValueToCode">
<ref local="novellConvertValueToCode" />
</property>
</bean>
<bean id="novellConvertValueToCode" class="be.toto.momo.helpers.NovellConvertValueToCode">
<property name="profilDao">
<ref bean="profilDao"/>
</property>
<property name="profilConvertEngine">
<ref bean="cfwbConvertProfilEngine"/>
</property>
</bean>
<bean id="cfwbConvertProfilEngine" class="be.toto.security.profil.NovellConvertAttProfilLdapToList">
</bean>
<bean id="novellAuthoritiesPopulator" class="be.toto.momo.providers.NovellAuthoritiesPopulator">
<property name="userDetailsService" ref="userDetailsService"/>
</bean>
<bean id="novellAuthenticationProvider" class="be.toto.momo.providers.NovellAuthenticationProvider">
<property name="novellAuthoritiesPopulator" ref="novellAuthoritiesPopulator"/>
</bean>
<bean id="authenticationManager" class="org.springframework.security.providers.ProviderManager">
<property name="providers">
<list>
<ref local="novellAuthenticationProvider" />
</list>
</property>
</bean>
<!-- <bean id="cfwbConvertProfilEngine" class="be.etnic.security.profil.HelperConvertAttProfilLdapToList">
</bean>-->
<!-- This bean is optional; it isn't used by any other bean as it only listens and logs -->
<bean id="loggerListener" class="org.springframework.security.event.authentication.LoggerListener" />
</beans> |
Partager