mirror of
https://github.com/open-webui/open-webui.git
synced 2026-06-05 16:28:32 -05:00
[PR #18572] [MERGED] feat: OAUTH_ROLES_SEPARATOR env var #63691
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/18572
Author: @attilaolah
Created: 10/24/2025
Status: ✅ Merged
Merged: 10/26/2025
Merged by: @tjbck
Base:
dev← Head:issue-18542📝 Commits (2)
35504e8feat: add OAUTH_ROLES_SEPARATOR env varc165a6bfix: exclude empty roles📊 Changes
1 file changed (+5 additions, -2 deletions)
View changed files
📝
backend/open_webui/config.py(+5 -2)📄 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. Not targeting thedevbranch may lead to immediate closure of the PR.Changelog Entry
Add OAUTH_ROLES_SEPARATOR env var to support roles with commas
Description
Add the
OAUTH_ROLES_SEPARATORenv var (not a stored setting), a helper for specifying roles in the edge-case where the roles contain commas. The easiest solution is to set this to something like;or just a whitespace (). The target audience is roles specified in LDAP syntax, e.g.cn=rolename,ou=unit,o=org.This should be fully backwards compatible, with one exception: empty roles are now filtered out, so if someone specified e.g.
admin,oradmin,,userthe empty one will now be filtered out. I don't expect this to break anyone's setup.Added
OAUTH_ROLES_SEPARATORoption (env var only).Changed
Deprecated
Removed
Fixed
Security
Breaking Changes
Additional Information
I'm happy to revert the second commit if we want to make this 100% backwards-compatible, although I don't expect it to brake anyone's setup.
Screenshots or Videos
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.