与 CAS 无缝 SSO
我有 Spring MVC 应用程序,Spring Security 设置为使用 CAS。我还配置了 Liferay Portal 5.2.3 以使用 CAS。
- 我从 app_1
- 打开 Liferay Portal (app_2) 进行
- 身份验证它不会立即检查身份验证(我看到登录链接)
- 如果我单击“登录”,则 CAS 会验证用户已通过身份验证并且我会自动登录。
如何在 app_1 中创建链接会建议 app_2 验证身份验证...
我有 spring 过滤器链
<filter>
<filter-name>springSecurityFilterChain</filter-name>
<filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
</filter>
,
<security:http entry-point-ref="casAuthenticationEntryPoint" auto-config="true" >
<security:intercept-url pattern="/*/secure/**" access="ROLE_USER" />
<security:custom-filter position="CAS_FILTER" ref="casAuthenticationFilter" />
<security:anonymous enabled="false"/>
</security:http>
如果我将 app_1 中的所有 url 指向 app_2 中的安全路径,则需要身份验证(用户被重定向到登录页面),所以这不起作用。
I have Spring MVC app with Spring Security set up to use CAS. Also I have Liferay Portal 5.2.3 configured to use CAS.
- I authenticate from app_1
- Open Liferay Portal (app_2)
- It does not check authentication immediately (I see sign in link)
- If I click Sign in then CAS verifies that user is authenticated and I'm automatically signed in.
How to create link in app_1 that would suggest app_2 to validate authentication...
I have spring filter chain
<filter>
<filter-name>springSecurityFilterChain</filter-name>
<filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
</filter>
And
<security:http entry-point-ref="casAuthenticationEntryPoint" auto-config="true" >
<security:intercept-url pattern="/*/secure/**" access="ROLE_USER" />
<security:custom-filter position="CAS_FILTER" ref="casAuthenticationFilter" />
<security:anonymous enabled="false"/>
</security:http>
If I point all urls from app_1 to secure paths in app_2 then authentication is required (user is redirected to login page) so this doesn't work.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论