saml IDP / SP 如何与 auth0 一起使用?

How does the saml IDP / SP work with auth0?

我正在尝试按照此 auth0 教程来理解 SAML 和 IDP/SP 模型。

https://auth0.com/docs/protocols/saml/samlsso-auth0-to-auth0

在本教程中,您将创建两个 auth0 租户。

第一个租户(租户 1)是服务提供者,第二个(租户 2)是身份提供者。

在我们设置第二个租户的部分中,我无法理解这一行中描述的内容:

In this section you will configure one Auth0 tenant (tenant 2) to serve as an Identity Provider. You will do this by registering an application, but in this case, the 'application' you register is really a representation of tenant 1, the SAML Service Provider.

我对此感到困惑,因为我认为服务提供商本质上是您需要通过 IDP 访问的所有不同应用程序的包装器。所以在我的解释中,我认为我们创建的应用程序将存在于第一个租户中。

有人能解释一下为什么在这个例子中我们设置 IDP 来包含应用程序以及它如何代表服务提供商(租户 1)吗?

同意这篇文章有些令人困惑。

关键是"In this step, you will test your sample HTML application that uses the Auth0 SAML connection you set up in Tenant 1 to perform SSO via SAML against Tenant 2, serving as the SAML Identity Provider."

在SAML中,有两种SP。

SP 可以是应用程序,因此路径为:

应用 --> SAML IDP

或者您可以拥有一个 SP-STS(安全令牌服务),即充当 SP 的中间 IDP。

这里的路径是:

应用 --> SAML SP --> SAML IDP

基本上,SAML SP 只是传递。

通常情况下,当您进行身份验证时,应用程序会重定向到 STS。您可以在此处进行身份验证。但是,如果此 STS 知道上游还有另一个 STS,它将通过 Home Realm Discovery 询问您要使用哪个 STS。