CVE-2026-88005: Open WebUI: Users denied by the OAuth domain allowlist or role policy can still sign in via token exchange
In Open WebUI 0.8.x, the OAuth token exchange endpoint issues a session without applying the email domain allowlist that the normal OAuth login callback enforces. A user whose domain the callback would refuse can still get a working session. Only deployments with token exchange enabled and a domain allowlist are affected. Fixed in Open WebUI 0.9.0.
Published Sep 10, 2026 · Analysis Oct 24, 2026
What an attacker can do
The OAuth token exchange endpoint in backend/open_webui/routers/auths.py was added as a second way into the session-issuing path used by the login callback. It re-implemented the identity lookup but not the policy checks around it. The domain allowlist check lived inside the callback's own body, so the endpoint never ran it.
An administrator who narrows OAUTH_ALLOWED_DOMAINS expects users outside it to lose access at their next sign-in. The callback denies them. Token exchange kept issuing sessions. A user whose domain was removed can present a valid provider access token and get a session as their existing account, at its existing role.
The limits are real. The endpoint never creates accounts, so a token for a subject with no linked account is rejected. It cannot raise anyone's role. The result is continued access, not new or elevated access.
The preconditions are all required. ENABLE_OAUTH_TOKEN_EXCHANGE must be true (off by default). OAUTH_ALLOWED_DOMAINS must be set to something other than *. The user needs a valid, unexpired access token on the configured provider, plus an account already linked to that provider subject, or one matched by email when OAUTH_MERGE_ACCOUNTS_BY_EMAIL is on.
Who is affected
Affected: open-webui from 0.8.0 up to but not including 0.9.0, with ENABLE_OAUTH_TOKEN_EXCHANGE=True and OAUTH_ALLOWED_DOMAINS set to a value other than *. Default deployments, and those with no domain allowlist, are not affected. Check the version:
pip show open-webuiThen check both environment variables in your deployment.
open-webui
- Ecosystem
- PyPI
- Affected
- >= 0.8.0, < 0.9.0
- Fixed in
- 0.9.0
- Check
pip show open-webui
How to fix it
Upgrade to 0.9.0:
pip install --upgrade open-webui==0.9.0The fix (commit fb5ef978, pull request 23639) adds the same domain allowlist check to the token exchange endpoint that the login callback runs. It returns 403 when the email domain is not allowed. No further action is needed. The sources give no workaround. Setting ENABLE_OAUTH_TOKEN_EXCHANGE to false removes the exposure if you do not use that endpoint. The sources do not state this, but it follows from the precondition.
How to tell if you were hit
Review sign-in activity for accounts whose email domain is no longer in OAUTH_ALLOWED_DOMAINS but that still start sessions. Check access logs for calls to the OAuth token exchange endpoint from those accounts. After the fix, such calls return 403. The advisory gives no log line.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Summary
Open WebUI's OAuth token exchange endpoint issues a session for a provider access token without applying the email domain allowlist that the normal OAuth login callback enforces. An account whose email domain the login callback would refuse could still obtain a working session through this endpoint.
Preconditions
ENABLE_OAUTH_TOKEN_EXCHANGE=True. It is disabled by default, so a default deployment is not affected.OAUTH_ALLOWED_DOMAINSset to something other than*. Deployments without a domain allowlist are not affected.- A valid, unexpired access token on the configured provider.
- An Open WebUI account already linked to that provider subject, or an account with a matching email when
OAUTH_MERGE_ACCOUNTS_BY_EMAILis enabled. This endpoint never creates accounts, so a token for a subject with no existing account is rejected.
Impact
An admin who narrows the domain allowlist expects users outside it to lose access at their next sign-in. The login callback does deny them. Token exchange kept issuing sessions, so a user whose domain was removed retained working access as their existing account at its existing role. The endpoint cannot create an account and cannot raise anyone's role, so this grants continued access rather than new or elevated access.
Fix
fb5ef978b, released in 0.9.0, adds the same domain allowlist check to the token exchange endpoint that the login callback runs, and denies the exchange with 403 when the email domain is not allowed. Upgrading restores the check with no further action.
Root cause
The affected component is the OAuth token exchange endpoint in backend/open_webui/routers/auths.py, present in builds from 0.8.0 onward.
The endpoint was added as a second entry point into the same session-issuing path the OAuth login callback uses, but it re-implemented only the identity lookup and not the policy checks surrounding it. The domain allowlist check lived inside the callback's own body rather than in shared code, so the second caller inherited none of it.
Credits
@Classic298
Credited to Classic298.
Questions
- Is CVE-2026-88005 exploitable by default?
No.
ENABLE_OAUTH_TOKEN_EXCHANGEis off by default, and deployments without anOAUTH_ALLOWED_DOMAINSallowlist are not affected.- Can the attacker create a new account or become admin?
No. The endpoint never creates accounts and cannot raise a role. It lets an existing, linked account keep working at its existing role after its domain was removed from the allowlist.
- Does it cover the role policy mentioned in the title?
The advisory text and the fix pull request describe only the domain allowlist. Neither mentions a role-policy check, so treat this as a domain allowlist bypass.
- Which version fixes it?
0.9.0. The endpoint exists from 0.8.0, so 0.8.x builds are affected.
References
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology
More Open WebUI vulnerabilities
All Open WebUI entriesCVE-2026-87011
Open WebUI: Unauthenticated requests can stall the server via uncached OIDC fetches in back-channel logout
high7.5Sep 10, 2026CVE-2026-87012
Open WebUI: Any authenticated user can suppress calendar alerts instance-wide via a non-numeric alert value
medium4.3Sep 10, 2026CVE-2026-87013
Open WebUI: Any authenticated user can start a non-terminating request via a folder parent cycle
medium4.3Sep 10, 2026CVE-2026-87014
Open WebUI: Admin demoted through SSO role sync keeps read and write access to all users' notes
medium6.5Sep 10, 2026CVE-2026-87015
Open WebUI: A user's session cookies are sent to tool servers configured for bearer authentication
medium6.8Sep 10, 2026CVE-2026-87016
Open WebUI: Sign-in as another user via wildcard characters in the OAuth subject claim on SQLite
high8.1Sep 10, 2026
