【问题标题】:Requested Authentication Method is not supported on the STSSTS 不支持请求的身份验证方法
【发布时间】:2015-06-21 09:52:00
【问题描述】:

我们的 Java 应用程序与客户 ADFS 3.0 服务器联合。 通过 SAMLP 向 ADFS 服务器发送身份验证请求(SP 启动)后出现问题。 它适用于 Intranet 用例,其中 Windows 身份验证在身份验证策略中的 ADFS 服务器上指定。 SP 应用正在使用 ForgeRock 的 Fedlet 库,该库强制发送带有 SAML 身份验证请求的 RequestedAuthnContext 属性:

samlp:RequestedAuthnContext xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol"
                             Comparison="exact"
                             >
    <saml:AuthnContextClassRef xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">urn:oasis:names:tc:SAML:2.0:ac:classes:Password</saml:AuthnContextClassRef>
</samlp:RequestedAuthnContext>

我们最初也遇到了 Extranet 身份验证问题,在 ADFS 上选择了 Forms 身份验证。我们通过为我们的 RP 添加 Claim 自定义规则解决了这个问题:

exists([Type == "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier"]) => issue(Type = "http://schemas.microsoft.com/ws/2008/06/identity/claims/authenticationmethod", Value = "urn:oasis:names:tc:SAML:2.0:ac:classes:Password");

现在我们正在处理 Intranet 用例。 在 ADFS 方面,我们收到以下错误:

MSIS7102: Requested Authentication Method is not supported on the STS.
   at Microsoft.IdentityServer.Web.Authentication.GlobalAuthenticationPolicyEvaluator.EvaluatePolicy(IList`1 mappedRequestedAuthMethods, AccessLocation location, ProtocolContext context, HashSet`1 authMethodsInToken, Boolean& validAuthMethodsInToken)
   at Microsoft.IdentityServer.Web.Authentication.AuthenticationPolicyEvaluator.RetrieveFirstStageAuthenticationDomain(Boolean& validAuthMethodsInToken)
   at Microsoft.IdentityServer.Web.Authentication.AuthenticationPolicyEvaluator.EvaluatePolicy(Boolean& isLastStage, AuthenticationStage& currentStage, Boolean& strongAuthRequried)
   at Microsoft.IdentityServer.Web.PassiveProtocolListener.GetAuthMethodsFromAuthPolicyRules(PassiveProtocolHandler protocolHandler, ProtocolContext protocolContext)
   at Microsoft.IdentityServer.Web.PassiveProtocolListener.GetAuthenticationMethods(PassiveProtocolHandler protocolHandler, ProtocolContext protocolContext)
   at Microsoft.IdentityServer.Web.PassiveProtocolListener.OnGetContext(WrappedHttpListenerContext context)

我可以为它添加/做点什么吗?是否可以在自定义规则中说 IF IT IS INTRANET, AUTH METHOD IS WINDOWS 或类似的东西?

【问题讨论】:

    标签: windows-authentication saml saml-2.0 adfs adfs3.0


    【解决方案1】:

    您总是可以尝试authnContextClassRef="urn:oasis:names:tc:SAML:2.0:ac:classes:unspecified",它应该让 IdP 选择它可以使用的任何东西。作为 SP,您并不真正知道(您应该关心吗?)IdP 可以使用哪些方法...

    【讨论】:

      【解决方案2】:

      我们通过发送更多身份验证选项并将 Comparison 指定为 minimum

      解决了这个问题
      <samlp:RequestedAuthnContext xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol"
                                   Comparison="minimum"
                                   >
          <saml:AuthnContextClassRef xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">urn:oasis:names:tc:SAML:2.0:ac:classes:unspecified</saml:AuthnContextClassRef>
          <saml:AuthnContextClassRef xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">urn:oasis:names:tc:SAML:2.0:ac:classes:Password</saml:AuthnContextClassRef>
          <saml:AuthnContextClassRef xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
          <saml:AuthnContextClassRef xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">urn:oasis:names:tc:SAML:2.0:ac:classes:Kerberos</saml:AuthnContextClassRef>
          <saml:AuthnContextClassRef xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion">urn:federation:authentication:windows</saml:AuthnContextClassRef>
      </samlp:RequestedAuthnContext>
      

      【讨论】:

        猜你喜欢
        • 2014-11-07
        • 2021-02-05
        • 1970-01-01
        • 2013-02-04
        • 2017-03-08
        • 1970-01-01
        • 1970-01-01
        • 2014-02-11
        相关资源
        最近更新 更多