使用AuthenticationProcessingFilter遇到怪事。求救!

图D 2012-09-17 04:09:44
这是我的两个过滤器。
<!-- 配置Authentication Processing Filter(APF,进行身份验证) -->
<bean id="authenticationProcessingFilter" class="org.acegisecurity.ui.webapp.AuthenticationProcessingFilter">
<property name="authenticationManager" ref="authenticationManager"/>
<property name="filterProcessesUrl" value="/j_spring_security_check"/>
<property name="defaultTargetUrl" value="/manage/home/index.jsp"/>
<property name="authenticationFailureUrl" value="/manage/home/login.jsp?login_error=1"/>
<property name="alwaysUseDefaultTargetUrl" value="true"/>
</bean>
<!-- 用户登录 -->
<bean id="userloginFilter" class="org.acegisecurity.ui.webapp.AuthenticationProcessingFilter">
<property name="authenticationManager" ref="authenticationManager" />
<property name="authenticationFailureUrl" value="/client/rightfail.jsp?login_error=1"/>
<property name="defaultTargetUrl" value="/client/right.jsp"/>
<property name="filterProcessesUrl" value="/userlogin_action"/>
<property name="alwaysUseDefaultTargetUrl" value="true"/>
</bean>
分别在前端和后台使用。但每次登录成功后,页面却都会往“authenticationFailureUrl”路径跳转。authenticationFailureUrl这个不是登录失败是才跳转的吗?非常郁闷!求救!
...全文
235 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复

81,092

社区成员

发帖
与我相关
我的任务
社区描述
Java Web 开发
社区管理员
  • Web 开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧