简体   繁体   English

使用Thinktecture Identity Server 2进行单点注销

[英]Single Sign Out with Thinktecture Identity Server 2

My understanding with regard to Thinktecture's Identity Server 2 is that Single Sign Out is not implemented. 我对Thinktecture的Identity Server 2的理解是没有实现单点登出。 In other words, when you sign out of one Relying Party, Identity Server does not sign the user out of any other RPs automatically. 换句话说,当您退出一个依赖方时,Identity Server不会自动将用户从任何其他RP中签名。 I know there have been posts regarding this but I have not been able to find anything on how to extend Identity Server to do this. 我知道有关于此的帖子,但我还没有找到任何关于如何扩展Identity Server来执行此操作的内容。 I've seen some posts that say Identity Server already does this out of the box...if it does I haven't been able to find out how. 我已经看到一些帖子说Identity Server已经开箱即用了...如果确实如此,我还是无法找到方法。

I have SSO working just fine with Asp.NET Web Forms, WIF and Identity Server 2, and I'm able to sign out of an RP just fine, but from what I can tell some additional code is required in Identity Server in order to completely sign the user out of any other RPs he might be signed into. 我有SSO与Asp.NET Web Forms,WIF和Identity Server 2一起正常工作,我能够很好地退出RP,但从我可以看出,Identity Server中需要一些额外的代码才能将用户从他可能登录的任何其他RP中完全签名。

Has anyone extended Identity Server to implement Single Sign Out? 有没有人扩展Identity Server以实现单点注销?

Is this something that can be configured in Identity Server or is there some coding required? 这是可以在Identity Server中配置还是需要一些编码的东西?

I'd really appreciate some insight if you have it. 如果你拥有它,我真的很感激。

Thank you. 谢谢。

IdentityServer supports single signout via WS-Federation. IdentityServer支持通过WS-Federation进行单点注销。 Your RP would need to make the signout request to IdentityServer to have the user logged out of IdentityServer and any other RP that had authenticated with IdentityServer via WS-Fed. 您的RP需要向IdentityServer发出注销请求,让用户退出IdentityServer以及通过WS-Fed通过IdentityServer验证的任何其他RP。 Here's a snippet of how your RP would make such a request: 以下是您的RP如何提出此类请求的摘要:

var sam = FederatedAuthentication.SessionAuthenticationModule;
sam.SignOut();

var fam = FederatedAuthentication.WSFederationAuthenticationModule;
var signOutRequest = new SignOutRequestMessage(new Uri(fam.Issuer));
// optional -- put your RP's URL here
// signOutRequest.Reply = "https://localhost:44321/";
var url = signOutRequest.WriteQueryString();
Response.Redirect(url);

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM