mirror of
https://github.com/open-webui/open-webui.git
synced 2026-08-02 21:59:02 -05:00
[PR #23622] [CLOSED] fix: add DB-backed token revocation fallback when Redis is absent #130947
Reference in New Issue
Block a user
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/23622
Author: @Classic298
Created: 4/12/2026
Status: ❌ Closed
Base:
dev← Head:fix/token-revocation-without-redis📝 Commits (1)
b87aae3fix: add DB-backed token revocation fallback when Redis is absent📊 Changes
5 files changed (+95 additions, -11 deletions)
View changed files
➕
backend/open_webui/migrations/versions/c66045cb0f67_add_user_token_version_column.py(+29 -0)📝
backend/open_webui/models/users.py(+19 -0)📝
backend/open_webui/routers/auths.py(+12 -3)📝
backend/open_webui/utils/auth.py(+26 -2)📝
backend/open_webui/utils/oauth.py(+9 -6)📄 Description
Add a token_version counter to the User model that gets embedded in JWTs and checked on every request. When Redis is not configured, sign-out and password change now increment token_version in the DB, causing all previously issued tokens to be rejected.
Changes:
Contributor License Agreement
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.