【发布时间】:2015-04-19 07:09:25
【问题描述】:
我有一台 Windows Server 2012 机器,它安装了 Active Directory 联合身份验证服务以允许它充当身份提供者。我有一个 Shibboleth 服务提供商,它正在使用我的 IDP 进行身份验证,但是工件解析绑定似乎不起作用。
我可以确认我的 ADFS 配置数据库已设置为使用 SQL Server,并且工件解析端点已启用。我查看了 artifactsstore 数据库,似乎生成并存储了一个 SAML 响应。我已经通过 SAML 验证器运行了这个,它是一个有效的响应。 Shibboleth端返回的错误信息是:
身份提供程序在工件解析期间返回了 SAML 错误。
来自身份提供者的错误:
状态:urn:oasis:names:tc:SAML:2.0:status:Requester 当我检查 ADFS 事件日志时,报告的错误是:
工件解析请求失败。
附加数据 异常消息: MSIS0018:无法读取 SAML 协议消息,因为它包含无效数据。
我已启用 ADFS 跟踪,这也是那里返回的唯一消息。有人可以帮忙吗?
更新 - 我在使用 Firefox 时运行了 SAML Tracer,从 SP 发送到 IDP 的请求如下(我已经删除了细节):
<samlp:AuthnRequest xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol"
AssertionConsumerServiceURL="https://xxx.xxx.com/Shibboleth.sso/SAML2/Artifact"
Destination="https://ccc.ccc.co.uk/adfs/ls/"
ID="_1xxxxxxxxxxxxxxx"
IssueInstant="2015-02-19T10:10:53Z"
ProtocolBinding="urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Artifact"
Version="2.0"
>
<saml:Issuer xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">https://xxx.xxx.com/shibboleth</saml:Issuer>
<samlp:NameIDPolicy AllowCreate="1" />
</samlp:AuthnRequest>
没有通过浏览器发送响应,但是 ADFS 正在生成 SAML 响应并将其存储在 adfs 工件数据库中。响应如下(具体内容已删除):
<samlp:Response ID="_1xxxxxxxxxxx" Version="2.0" IssueInstant="2015-02-19T10:11:05.391Z"
Destination="https://xxx.xxx.com/Shibboleth.sso/SAML2/Artifact" Consent="urn:oasis:names:tc:SAML:2.0:consent:unspecified"
InResponseTo="_1xxxxxxxxxxxxxxx" xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol">
<Issuer xmlns="urn:oasis:names:tc:SAML:2.0:assertion">http://ccc.ccc.co.uk/adfs/services/trust</Issuer>
<samlp:Status>
<samlp:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Success" />
</samlp:Status>
<Assertion ID="_dxxxxxxxxxxx" IssueInstant="2015-02-19T10:11:05.282Z" Version="2.0" xmlns="urn:oasis:names:tc:SAML:2.0:assertion">
<Issuer>http://ccc.ccc.co.uk/adfs/services/trust</Issuer>
<ds:Signature xmlns:ds="http://www.w3.org/2000/09/xmldsig#">
<ds:SignedInfo>
<ds:CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" />
<ds:SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha1" />
<ds:Reference URI="#_dxxxxxxxxxxx">
<ds:Transforms>
<ds:Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature" />
<ds:Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" />
</ds:Transforms>
<ds:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
<ds:DigestValue>xxxxxxxxxx=</ds:DigestValue>
</ds:Reference>
</ds:SignedInfo>
<ds:SignatureValue>xxxxxxxxxxxxx</ds:SignatureValue>
<KeyInfo xmlns="http://www.w3.org/2000/09/xmldsig#">
<ds:X509Data>
<ds:X509Certificate>xxxxxxxxxxxxxxxxxx==</ds:X509Certificate>
</ds:X509Data>
</KeyInfo>
</ds:Signature>
<Subject>
<NameID Format="urn:oasis:names:tc:SAML:2.0:nameid-format:transient"
NameQualifier="http://ccc.ccc.co.uk/adfs/services/trust"
SPNameQualifier="http://xxx.xxx.com/shibboleth">
xxxxxxxxxxxx=
</NameID>
<SubjectConfirmation Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
<SubjectConfirmationData InResponseTo="_1xxxxxxxxxxx" NotOnOrAfter="2015-02-19T10:16:05.407Z"
Recipient="https://sp.cobweb.secure-dimensions.de/Shibboleth.sso/SAML2/Artifact" />
</SubjectConfirmation>
</Subject>
<Conditions NotBefore="2015-02-19T10:11:05.188Z" NotOnOrAfter="2015-02-19T18:11:05.188Z">
<AudienceRestriction>
<Audience>
https://xxx.xxx.com/shibboleth
</Audience>
</AudienceRestriction>
</Conditions>
<AuthnStatement AuthnInstant="2015-02-19T10:11:03.766Z" SessionIndex="_dxxxxxxxxxx">
<AuthnContext>
<AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</AuthnContextClassRef>
</AuthnContext>
</AuthnStatement>
</Assertion>
</samlp:Response>
我现在只有 NameID 和没有属性的基本响应,因为无论它们是否存在,我都会收到相同的错误消息。 谢谢,
弗兰
【问题讨论】:
标签: saml-2.0 adfs shibboleth