【发布时间】:2014-03-24 13:10:30
【问题描述】:
我一直在尝试在 java 中实现一个 WEB SSO 服务提供者。我正在使用 Shibboleth 身份提供程序。在身份验证步骤之前一切正常,我能够成功地为用户创建会话/设置 cookie。但是,当我尝试使用单点注销功能时,我收到了来自 shibboleth IdP 的“RequestDenied”响应。我检查了日志,上面写着入站消息发布者未通过身份验证。同一发布者在登录步骤中工作正常,但在注销步骤时出错。任何要为其更新的配置文件,任何指针,建议?这是我的注销请求。
<samlp:LogoutRequest xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol"
ID="jiojjcjckjaflbedlcjcpcnecigbjhaekalmfkcg"
IssueInstant="2014-02-24T23:30:25.257Z"
NotOnOrAfter="2014-02-24T23:35:25.257Z"
Version="2.0"
>
<saml:Issuer xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">https://localhost/sp/shibboleth</saml:Issuer>
<saml:NameID xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion"
Format="urn:oasis:names:tc:SAML:2.0:nameid-format:transient"
NameQualifier="urn:oasis:names:tc:SAML:2.0:assertion"
>rohit</saml:NameID>
<samlp:SessionIndex/>
</samlp:LogoutRequest>
这就是我得到的回应。
<saml2p:LogoutResponse xmlns:saml2p="urn:oasis:names:tc:SAML:2.0:protocol"
Destination="https://localhost:8091/SSO/consumer"
ID="_02a145f4992cb2e11a8fc4aa43a74096"
InResponseTo="jiojjcjckjaflbedlcjcpcnecigbjhaekalmfkcg"
IssueInstant="2014-02-24T23:30:25.334Z"
Version="2.0"
>
<saml2:Issuer xmlns:saml2="urn:oasis:names:tc:SAML:2.0:assertion"
Format="urn:oasis:names:tc:SAML:2.0:nameid-format:entity"
>https://localhost/shibboleth</saml2:Issuer>
<saml2p:Status>
<saml2p:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Responder">
<saml2p:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:RequestDenied" />
</saml2p:StatusCode>
<saml2p:StatusMessage>Message did not meet security requirements</saml2p:StatusMessage>
</saml2p:Status>
</saml2p:LogoutResponse>
【问题讨论】:
-
您点击哪个 url 进行注销,或者您向注销发送什么响应以及发送到哪个 url?
-
https://
/idp/profile/SAML2/Redirect/SLO?SAMLRequest= 为了注销,我将 IdP 的响应发送到 ACS url .哪里有一个 servlet 解码和读取响应消息。作为响应,写的是请求被拒绝 消息不符合安全要求。并且在 IdP 日志中写入 入站消息发布者未通过身份验证。 P.S 我很怀疑注销是否可能。您是否使用 shibboleth 实现了注销?
标签: java single-sign-on saml-2.0 shibboleth opensaml