fix(auth): SSO confirmation works in the desktop app; allow switching to SSO #474
Merged
jared
merged 1 commits from 2026-10-26 12:12:02 -04:00
fix/sso-uia-desktop into lotus
No Reviewers
Labels
Clear labels
a11y
area: appearance
area: auth-session
area: build-ci
area: calls
area: desktop
area: media
area: messaging
area: mobile
area: moderation
area: navigation
area: notifications
area: settings
area: threads
bug
dependencies
docs
duplicate
enhancement
help wanted
invalid
needs-human-review
performance
planning
priority: critical
priority: high
priority: low
priority: medium
qa
question
research
security
tech-debt
ux
wontfix
Accessibility: keyboard, screen reader, contrast, motion
Client area: appearance
Client area: auth-session
Client area: build-ci
Client area: calls
Client area: desktop
Client area: media
Client area: messaging
Client area: mobile
Client area: moderation
Client area: navigation
Client area: notifications
Client area: settings
Client area: threads
Something is not working
Third-party package versions and advisories
README / LOTUS_* docs wrong or missing
This issue or pull request already exists
New feature
Need some help
Something is wrong
Re-render storms, leaks, heavy work on hot paths
Data loss, security hole, or crash on a main path
Broken feature or serious usability problem
Minor issue or polish
Wrong behaviour in an edge case or notable degradation
Manual QA: shipped, needs a human in a real environment
More information is needed
XSS, unsafe URLs, data leaks, auth/session
Code health, dead code, fragile patterns
Usability or visual inconsistency
This won't be fixed
No labels
Milestone
No items
No Milestone
Projects
Clear projects
No projects
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: LotusGuild/cinny#474
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Reported by a user (Jeff): signing out other sessions with SSO doesn't work.
What the server logs show (Synapse, @bigmanjeff, Oct 25–26):
POST /delete_devices→ 401 → SSO fallback page → OIDC callback →mark_ui_auth_stage_complete. So the SSO step succeeded every time.delete_deviceswas a fresh 401 challenge (119 B, the size of a new session with password and SSO flows). It was never a retry carrying the completed session. 4 attempts, none succeeded.Edg/155(the Windows desktop app's WebView2). The SSO pages came fromChrome/156, his system browser.Cause
SSOStageonly showed "Continue" oncewindow.openreturned a window. The desktop app opens the SSO page in the system browser and gets no window back. A popup can also lose its opener. Either wayauthDonenever arrives, the dialog stays on "Continue with SSO", and the only way on is starting over: a new request without the session, in a loop.ActionUIAforced the first supported flow. With password and SSO both offered, that's often password, which an SSO-only account may not know, and there was no way to pick SSO.Fix
authDonedoes arrive, it still continues automatically.Tested
delete_devicesmocked so it succeeds only if the retry carries the session:window.openreturns null): Continue appears; the retry sends{"session":"S1"}and the device is signed out;lotusbuild loops in the desktop case: the SSO dialog never offers Continue.e2e/sso-uia.spec.tscovers the desktop and password-first cases (2/2).Server-side note (not changed here): Synapse logs "SSO mapping for IdP
https://auth.lotusguild.org, but this is no longer configured", and "has previously logged in with multiple SSO IdPs" for this user. That's a leftover mapping from an older Authelia provider ID. It's harmless (Synapse picksoidc-authelia) but could be cleaned up inuser_external_ids.🤖 Generated with Claude Code
https://claude.ai/code/session_017PCb59uY3UKqDqt7B6hzd5