AuthnStatement
元素描述身份提供者的身份验证行为。如果断言发布者对主题进行了身份验证,则断言应该包含一个表示该身份验证事件的单个。
例子:
<AuthnStatement AuthnInstant="2010-10-01T20:07:34.371Z">
<AuthnContext>
<AuthnContextClassRef>
<!--Authentication method, was the client authenticated with digital cert, password, kerberos token?-->
urn:oasis:names:tc:SAML:2.0:ac:classes:X509
<!--For example, the Password class is applicable when a principal authenticates to an authentication authority through the presentation of a password over an unprotected HTTP session. -->
urn:oasis:names:tc:SAML:2.0:ac:classes:Password
urn:oasis:names:tc:SAML:2.0:ac:classes:Kerberos
</AuthnContextClassRef>
</AuthnContext>
</AuthnStatement>
SubjectConfirmation
元素允许授权服务器将其确认为承载断言。此类元素必须具有值为“urn:oasis:names:tc:SAML:2.0:cm:bearer”的 Method 属性。SubjectConfirmation 元素必须包含一个 SubjectConfirmationData 元素(有例外),指示授权服务器的令牌端点 URL。授权服务器必须验证 Recipient 属性的值是否与向其传递断言的令牌端点 URL 匹配。
例子:
<saml:SubjectConfirmation
<!-- Mandatory -->
Method="urn:oasis:names:tc:SAML:2.0:cm:bearer">
<saml:SubjectConfirmationData
<!-- The AuthRequest sent this ID -->
InResponseTo="aaf23196-1773-2113-474a-fe114412ab72"
<!-- It was through HTTP POST token endpoint URL -->
Recipient="https://sp.example.com/SAML2/SSO/POST"
<!-- Not valid ON or After this Date and Time -->
NotOnOrAfter="2004-12-05T09:27:05"/>
</saml:SubjectConfirmation>