mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2025-12-06 09:13:03 +03:00
Invited Users Not Redirected to SSO Login with SSO_ONLY Mode #9
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @kaeferpsd on GitHub.
Prerequisites
Vaultwarden Support String
Your environment (Generated via diagnostics page)
Config & Details (Generated via diagnostics page)
Show Config & Details
Config:
Vaultwarden Build Version
1.34.3-a2ad1dc7
Deployment method
Official Container Image
Custom deployment method
No response
Reverse Proxy
https://github.com/NginxProxyManager/nginx-proxy-manager?utm_source=nginx-proxy-manager
Host/Server Operating System
Linux
Operating System Version
No response
Clients
Web Vault
Client Version
No response
Steps To Reproduce
Environment
Vaultwarden Version: vaultwarden/server:testing
SSO Provider: Microsoft Azure AD (OpenID Connect)
Configuration: SSO_ONLY mode enabled
Problem Description
When SSO_ONLY: "true" is configured and a new user is invited to an organization, the user is not properly redirected to the SSO login flow. Instead, they are prompted to enter a master password that they never created, creating an impossible authentication loop.
Steps to Reproduce
Configure Vaultwarden with SSO_ONLY mode:
Admin invites a new user via organization invite
New user receives invitation email
User clicks "Accept Invite" link from email
User is presented with login form asking for master password
Expected Result
Expected Behavior
User should be automatically redirected to Microsoft Azure AD SSO login
After successful SSO authentication, user should then be prompted to create their first master password for vault encryption
User should then gain access to the organization
Actual Behavior
User is immediately prompted for master password without SSO redirect
Since user never created a master password, they cannot proceed
No way to access SSO login from this state
Actual Result
Additional Context
Regular SSO login works correctly when users access the main domain directly
The issue appears to be specific to the invitation acceptance flow
Temporarily disabling SSO_ONLY allows users to complete registration, but defeats the purpose of SSO-only mode
This creates a broken user experience where invited users cannot join the organization
Workaround
Currently, the only workaround is to:
Temporarily set SSO_ONLY: "false"
Have user complete initial registration
Re-enable SSO_ONLY: "true"
Expected Fix
The invitation acceptance flow should properly redirect to SSO authentication when SSO_ONLY mode is enabled, rather than presenting the traditional login form.
Logs
Screenshots or Videos
No response
Additional Context
No response