Sustainsys / Saml2

Saml2 Authentication services for ASP.NET
Other
955 stars 602 forks source link

Dynamic Idp provider list sign out Issue #1461

Open AnisAli opened 2 months ago

AnisAli commented 2 months ago

In my project, I use the SustainSys library to allow companies to set up their SSO IDP. Since we don't have a predefined list of providers when configuring Saml2, we inject dynamic IdPs using the GetIdentityProvider and SelectIdentityProvider notifications. These notifications are handy for executing login commands. However, the main issue arises during the InitiateLogout command because the InitiateLogout command does not use notifications to fetch the IdP. Instead, it uses the following code.

File: https://github.com/Sustainsys/Saml2/blob/v2/Sustainsys.Saml2/WebSSO/LogOutCommand.cs var knownIdp = options.IdentityProviders.TryGetValue(new EntityId(idpEntityId), out IdentityProvider idp);

It would be helpful to support fetching the IDP using notifications, instead of relying solely on a predefined list of providers. Alternatively, please suggest a solution to accommodate dynamic IDP providers.

AndersAbel commented 2 months ago

This is a clearly a missing feature - the dynamic support doesn't work with logout.