Federated Signout Requests - Automatic iframe rendering #204
-
I have a question regarding External Logout notification (https://docs.duendesoftware.com/identityserver/ui/logout/external-notification/)
According to that documentation, it sounds like I don't need to do anything for IdentityServer to automatically render the necessary iframes for logout. However, this is the behavoiur I'm getting. Scenario 1 - user logs into site A and B, both authenticated using IdentityServer (with the local provider). Site A has frontChannel logout uri configured. When Site B is logged out, IdentityServer is logged out, as is site A. This works as expected. I do not use the Duende implementation of dynamic providers.
Identityserver does receive the federated signout request, as I can debug and see that OnRemoteSignout is being hit. According to the doco, it sounds like you don't have to implement a custom OnRemoteSignout, but that doesn't seem to be the case unless perhaps you're using Duende's Dynamic Providers? I am looking at creating the necessary iframes myself in OnRemoteSignout, but not entirely sure of the most appropriate way to go about this. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
Just to rule this out: when a signout from the external IdP occurs, is IdentityServer's logout page (which contains the iFrame) rendered? |
Beta Was this translation helpful? Give feedback.
Thanks for the additional information.
The front-channel logout using hidden iframes relies on both IdentityServer and all client applications to be able to interact with any cookies on each host. For this to work, all cookies must be set to SameSite=None when a cross-site upstream provider is used. As Entra Id is hosted on it's own domain, it's always cross-site to any of your applications.
The IdentityServer session cookie is SameSite=None by default, did you change that to SameSite=Lax or SameSite=Strict? The client cookies are SameSite=Lax by default in the Microsoft OpenIdConnect handler, you need to change them to SameSite=None in the settings. If you check the browser dev tools, yo…