gpt4 book ai didi

authentication - OAuth2 SAML授权授予中的SubjectConfirmation是什么意思?

转载 作者:行者123 更新时间:2023-12-04 12:22:37 24 4
gpt4 key购买 nike

OAuth2 SAML bearer spec描述了应用程序如何将声明作为授权授权呈现给 token 端点。例如,Salesforce's API允许该方法使应用程序能够自动请求用户帐户的访问 token (只要用户已经对此带外权限进行了授权)。

不过,我很难理解断言的含义。大部分内容都足够清楚,例如

  • Issuer是生成(并签名)断言
  • 的参与方
  • Subject是正在为其帐户请求访问 token 的用户
  • AudienceRestriction将访问者限制为 token 端点。

  • 但是我在理解以下含义时遇到了麻烦:
  • AuthnStatement-根据SAML规范,我的理解是,此声明的发布者正在声明它(发布者)已对主题进行了身份验证。这是正确的吗?
  • SubjectConfirmation-谁在这里确认什么? SAML规范有助于指出此元素“允许确认主题的信息”。但是什么是确认?以及由谁执行,如何,何时以及出于什么目的?
  • 最佳答案

    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”。
    SubjectConfirmation元素必须包含一个SubjectConfirmationData元素(带有异常(exception)),该元素指示授权服务器的 token 端点URL。授权服务器必须验证Recipient属性的值与断言所传递到的 token 终结点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 POTS token endpoint URL -->
    Recipient="https://sp.example.com/SAML2/SSO/POST"
    <!-- Not valid ON or After this Date-->
    NotOnOrAfter="2004-12-05T09:27:05"/>
    </saml:SubjectConfirmation>

    关于authentication - OAuth2 SAML授权授予中的SubjectConfirmation是什么意思?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15331539/

    24 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com