mirror of
https://github.com/open-webui/open-webui.git
synced 2026-07-11 09:33:54 -05:00
[PR #16392] [CLOSED] feat: OAUTH_SUB_CLAIM_OVERRIDE #127775
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?
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/16392
Author: @Ithanil
Created: 8/8/2025
Status: ❌ Closed
Base:
dev← Head:oauth_sub_override📝 Commits (1)
622a98eimplement OAUTH_SUB_CLAIM_OVERRIDE📊 Changes
3 files changed (+15 additions, -1 deletions)
View changed files
📝
backend/open_webui/config.py(+6 -0)📝
backend/open_webui/main.py(+2 -0)📝
backend/open_webui/utils/oauth.py(+7 -1)📄 Description
Pull Request Checklist
Note to first-time contributors: Please open a discussion post in Discussions and describe your changes before submitting a pull request.
Before submitting, make sure you've checked the following:
devbranch.Changelog Entry
Description
OpenWebUI try to infer the claim to use as sub from the IDP and defaults to "sub". In some cases however, it is preferable to decide on application side which claim to use as sub and not deal with changing what the IDP side provides.
Setting the new env OAUTH_SUB_CLAIM_OVERRIDE allows to force a certain claim as sub, regardless of IDP configuration.
Added
Contributor License Agreement
By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.