-
Notifications
You must be signed in to change notification settings - Fork 475
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ENHANCE] provide means to associate state with each saml request before the redirect to the idp #541
Comments
I'm not sure how this would add to what is already possible. I know many users of this library federate with multiple IdP without issue, in fact, we have a special class just for that. However, if you care to put together a PR, I'll have a look. |
@cjbarth am I understanding the concept of inResponseTo correctly? I'm not using multiple idps, but it would be useful to get an identifier for any outbound redirect to an IDP for each unique request to the IDP. Again, imagine you open your browser to 10 github(configured with saml) PR request tabs. Each tab is a different PR. Each of those tabs is operating on the same expired authentication session with github. each of those tabs will redirect you to the IDP to log in. If each of those redirects had a unique identifier saved in the github session, it could map those requests and understand where the correct redirect should go when the authentication succeds. I'm not implying that github uses this software, just demonstrating the scenario. |
@hcldan Your use case sound like use case of
source: https://docs.oasis-open.org/security/saml/v2.0/saml-bindings-2.0-os.pdf If that is the case see additional more down to earth description about Current state of
|
I think that might work. I'm going to close this until I have a chance to play with that. |
If you get it working using |
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
When users have saved tabs in a browser, and they open their browser after a session has expired, it results in all tabs getting a redirect to log in. If the site uses a cookie to figure out where to return, then all tabs get clobbered.
I notice there is an inResponseTo attribute in the profile that comes back from the idp... can I hook somewhere to inspect this value before the request is made so that I can map the various saml requests to the redirect they should go to properly?
Describe the solution you'd like
passport.authenticate('saml', { state: (requestId) => { /* save reference to redirect keyed by requestId in session */ } })
The text was updated successfully, but these errors were encountered: