问题1: 我登录了client2,又登录了client3,现在我把client2退出了,在client3里面我F5刷新了一下,结果页面报错:
未能够识别出目标 'ST-41-2VcnVMguCDWJX5zHaaaD-cas01.example.org'票根
问题2:登录了client,然后退出,再重新输入用户名,结果页面也会报错 验证 'ST-41-2VcnVMguCDWJX5zHaaaD-cas01.example.org'失败
解决方法:自己测试了多遍并在网上做了参考后修改,最后验证成功,之后就不报错了。解决办法如下:
单点登出,客户端配置。我尝试使用SAML作为认证和Ticket校验,但是调试时发现单点登出取标识的方式只能识别CAS的认证和校验。
认证:org.jasig.cas.client.authentication.AuthenticationFilter
校验:org.jasig.cas.client.validation.Cas20ProxyReceivingTicketValidationFilter
过滤器顺序:
1. CAS Single Sign Out Filter
2. CAS Validation Filter
3. CAS Authentication Filter
4. CAS HttpServletRequest Wrapper Filter
5. CAS Assertion Thread Local Filter
特别注意Validation在Authentication之前,因为我使用的是Cas20ProxyReceivingTicketValidationFilter。
根据CAS文档描述:If you are using proxy validation, you should map the validation filter before the authentication filter.
1
2
3
4 characterEncodingFilter
5 org.springframework.web.filter.CharacterEncodingFilter
6
7 encoding
8 UTF-8
9
10
11
12 characterEncodingFilter
13 /*
14
15
16
17 org.jasig.cas.client.session.SingleSignOutHttpSessionListener
18
19
20
21 CAS Single Sign Out Filter
22 org.jasig.cas.client.session.SingleSignOutFilter
23
24
25 CAS Single Sign Out Filter
26 /*
27
28
29
30
31 CAS Validation Filter
32 org.jasig.cas.client.validation.Cas20ProxyReceivingTicketValidationFilter
33
34 casServerUrlPrefix
35 http://cas.youjiao.tjxddfdfqjy.com/cas
36
37
38 serverName
39 http://xxpt.yodfdfujiao.tjxqjy.com
40
41
42
43
44 CAS Validation Filter
45 /system/login/fm.jsp
46
47
48
49
50 CAS Filter
51 org.jasig.cas.client.authentication.AuthenticationFilter
52
53 casServerLoginUrl
54 http://cas.youjiao.tjxqjdcfdy.com/cas/login
55
56
57 serverName
58 http://xxpt.youdfdjiao.1tssjxqjy.com
59
60
61
62 CAS Filter
63 /system/login/fm.jsp
64
65
66
67
68 CAS HttpServletRequest Wrapper Filter
69 org.jasig.cas.client.util.HttpServletRequestWrapperFilter
70
71
72 CAS HttpServletRequest Wrapper Filter
73 /*
74
75
76
77 CAS Assertion Thread Local Filter
78 org.jasig.cas.client.util.AssertionThreadLocalFilter
79
80
81 CAS Assertion Thread Local Filter
82 /*
83
这样配置以后基本就解决这个问题了。