【问题标题】:Shibboleth SP auto IdP discovery from user email来自用户电子邮件的 Shibboleth SP 自动 IdP 发现
【发布时间】:2018-07-22 15:32:42
【问题描述】:
我将 Shibboleth SP(服务提供商)与多个 IdP(身份提供商)一起使用。
我目前正在使用 SP EDS(嵌入式发现服务)来提供可用 IdP 的列表。
是否有办法(在 EDS 中或不在 EDS 中)根据用户的电子邮件域自动将用户重定向到适当的 IdP?在这种情况下,会要求用户提供他的电子邮件/登录名;然后提取域并用于确定正确的 IdP。
感谢您的建议。
【问题讨论】:
标签:
shibboleth
discovery
idp
【解决方案1】:
您可能需要编写一些代码来从电子邮件中提取域。
这可能对你有帮助,
在 Shibboleth.xml 文件中,将域映射到不同的 idp 或将安全路径映射到不同的 idp。
假设 example.com/secure1 映射到 example-idp1.com,example.com/secure2 映射到 example-idp2.com。
然后当用户 user1@example1.com 尝试登录时,将他重定向到 example.com/secure1,这样它就会自动转到 example.com/secure1。反之亦然。
如果你想了解如何配置多条路径,这里是取自official site的例子。
<RequestMap applicationId="default">
<Host name="www.example.org">
<Path name="secure1" authType="shibboleth" requireSession="true"/>
</Host>
<Host name="www.example.org" applicationId="app2" authType="shibboleth" requireSession="true">
<Path name="secure2" authType="shibboleth" requireSession="true"/>
<AccessControl>
<Rule require="affiliation">faculty@osu.edu student@osu.edu</Rule>
</AccessControl>
</Host>
</RequestMap>
并创建两个应用程序,如提到的here。