私はこの構成を持っています:
<bean id="customizedFilterSecurityInterceptor"
class="org.springframework.security.web.access.intercept.FilterSecurityInterceptor">
<property name="authenticationManager" ref="authenticationManager"/>
<property name="accessDecisionManager" ref="accesDecisionManager"/>
<property name="securityMetadataSource">
<security:filter-security-metadata-source use-expressions="true" >
<security:intercept-url pattern="/css/**" access="permitAll" />
<security:intercept-url pattern="/js/**" access="permitAll" />
<security:intercept-url pattern="/externe*.do" access="permitAll" />
<security:intercept-url pattern="/*.do" access="isAuthenticated() or isRememberMe()" />
</security:filter-security-metadata-source>
</property>
</bean>
<bean id="loginUrlAuthenticationEntryPoint"
class="org.springframework.security.web.authentication.LoginUrlAuthenticationEntryPoint">
<property name="loginFormUrl">
<value>/login.jsp</value>
</property>
<property name="forceHttps">
<value>false</value>
</property>
</bean>
<bean id="externeServiceInterceptor" class="fr.global.commun.springSecurity.MySecurityInterceptor">
<property name="authenticationManager" ref="authenticationManager"/>
...
<property name="securityMetadataSource">
<security:filter-security-metadata-source use-expressions="true" >
<security:intercept-url pattern="/externe*.do" access="isAuthenticated()" />
</security:filter-security-metadata-source>
</property>
問題は、で始まるすべてのリクエストが/externe
ログイン ページにリダイレクトされる/*.do
ことです。