Skip to content

feat: oidc rp-initiated logout#113

Open
aymericcousaert wants to merge 2 commits intomasterfrom
feat/oidc-rp-initiated-logout
Open

feat: oidc rp-initiated logout#113
aymericcousaert wants to merge 2 commits intomasterfrom
feat/oidc-rp-initiated-logout

Conversation

@aymericcousaert
Copy link
Copy Markdown
Collaborator

Summary

  • When an OIDC user logs out, redirect to the provider's end_session_endpoint to terminate the SSO session
  • User must re-authenticate on next visit instead of silent re-login
  • Extract resolveCoreIdProvider helper to deduplicate provider resolution (keepalive + logout)
  • Add endSessionEndpoint to OAuthProvider type from OIDC discovery doc
  • Clean up stored OAuth token on logout
  • Include client_id and id_token_hint per OIDC RP-Initiated Logout spec
  • Graceful fallback to current 204 behavior for non-OIDC users

Involved services

Test plan

  • Logout with OIDC coreIdProvider user: verify redirect to SSO end_session_endpoint
  • Verify SSO session is terminated (re-authentication required)
  • Logout with password-only user: verify existing 204 behavior unchanged
  • Verify post_logout_redirect_uri is registered in IdP client config
  • Multi-site: verify logout from secondary site redirects back to correct site login page

When a user authenticated via OIDC logs out, redirect them to the
provider's end_session_endpoint to terminate the SSO session.
This forces re-authentication on next visit instead of silent re-login.

- Extract resolveCoreIdProvider helper (shared between keepalive and logout)
- Add endSessionEndpoint to OAuthProvider type from discovery doc
- Return endSessionUrl in DELETE /auth/ response for OIDC users
- Clean up stored OAuth token on logout
- Include client_id and id_token_hint per OIDC RP-Initiated Logout spec
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant