GHSA-x2ff-v5v8-m75m CVE-2026-59714 PYSEC-2026-3605
Open WebUI: Cross-channel message overwrite via chat completion API (single-model and multimodel message_ids)
- Severity
- 7.1 / 10
- High · CVSS 3.1
- Exploit chance (EPSS)
- 0.48%
- Chance of exploitation in the next 30 days. Higher than 41.25% of scored vulnerabilities.
- Known exploited
- No
- Not in CISA's catalog
- Weakness
- CWE-862 Missing Authorization
- Fix
0.10.0- Upgrade open-webui to this version or later
Description
Summary
Any authenticated user can overwrite the content of a message in a channel they do not belong to (including private and DM channels) by sending a chat completion request with a channel:-prefixed chat_id and a target message_id. The channel: path routes pipeline output through _make_channel_emitter, which writes to the Messages table using the caller-supplied message_id without binding it to the channel.
This advisory consolidates two filings of the same flaw: the original single-model form, and a multimodel message_ids variant that survives the partial fix shipped in v0.9.6 (see "Fix status" below).
Details (as introduced in v0.9.5)
When a user submits a chat completion request with a chat_id starting with channel:, three authorization gaps combined in v0.9.5:
- Ownership check skipped (
main.py): thechannel:prefix caused the entire ownership/membership verification block to be skipped, with no channel membership/write check replacing it.
if not chat_id.startswith('local:') and not chat_id.startswith('channel:'): # temporary/channel chats are not stored
if is_new_chat:
...
else:
if not await Chats.is_chat_owner(chat_id, user.id) and user.role != 'admin':
raise HTTPException(...)
-
Message ID from user input:
id(and each value of the multimodelmessage_idsmap) comes directly from the request body and is passed asmessage_idto the channel emitter. -
Unchecked database write (
socket/main.py_make_channel_emitter):
async def _make_channel_emitter(request_info):
channel_id = request_info['chat_id'].removeprefix('channel:')
message_id = request_info['message_id'] # user-supplied
...
await Messages.update_message_by_id(message_id, update_form) # no channel/user authz
Messages.update_message_by_id performs a direct primary-key update with no channel_id/user_id validation.
Fix (shipped in v0.10.0)
v0.9.6 added a channel gate to the channel: branch (PR #24725) that closed the single-model path, but it validated only the first entry of the multimodel message_ids map, leaving the multimodel fan-out exploitable. v0.10.0 closes the remaining gap with two layers:
- Request-time per-entry validation (
backend/open_webui/main.py): every entry ofmessage_idsis validated against the target channel, not just the first; any entry whose target message does not belong to the channel inchat_idis rejected. - Fail-closed emitter (
backend/open_webui/socket/main.py,_make_channel_emitter): before writing, it re-reads the target message and returns without writing unlessmsg.channel_idmatches the channel derived fromchat_id. A missing or mismatched message is a no-op, so a write can no longer land in a channel the caller does not target.
PoC
Single-model (fixed in v0.9.6):
curl -X POST http://target:8080/api/chat/completions \
-H "Authorization: Bearer $USER_JWT" -H "Content-Type: application/json" \
-d '{
"model": "llama3", "stream": true,
"chat_id": "channel:any-channel-uuid-here",
"id": "target-message-uuid-to-overwrite",
"messages": [{"role": "user", "content": "Repeat exactly: This message has been tampered with"}]
}'
Multimodel (still works on v0.9.6):
POST /api/chat/completions
{
"chat_id": "channel:<attacker_channel_id>",
"message_ids": {
"model-a": "<message_id_in_attacker_channel>",
"model-b": "<victim_channel_message_id>"
},
"messages": [{"role": "user", "content": "..."}]
}
The first id passes channel scope validation; the second id is used by the per-model fan-out and overwrites the victim-channel message (with model output, or the provider-error string on a deterministic error). Even a failing model call writes error content to the target message.
Impact
Message integrity destruction: an authenticated user can overwrite a message in a channel they cannot access, regardless of membership. The overwritten message retains the original author attribution while displaying attacker-chosen content (impersonation). Private channels, DM channels, and channels the attacker has no access to are all affected; the REST channel routes correctly return 403 for the same attacker, so the bypass is specific to the chat-completion channel pipeline.
Affected versions
- Single-model path: introduced in commit
0037baeb2(v0.9.5), fixed in v0.9.6 (#24725). - Multimodel
message_idspath: present from v0.9.6, fixed in v0.10.0. - Consolidated Affected:
>= 0.9.5, < 0.10.0. Patched:>= 0.10.0.
Distinction from existing CVEs
CVE-2026-45385 (GHSA-wwhq-cx22-f7vv) covered IDOR in the REST endpoint POST /channels/{id}/messages/{message_id}/update (routers/channels.py); its fix (commit f5e110f) only touched channels.py. This finding uses a different code path (POST /api/chat/completions with chat_id: "channel:<id>" → main.py → socket/main.py:_make_channel_emitter), untouched by that fix.
Suggested fix
Validate every value in message_ids against the channel (not just the first), rejecting any whose target message does not belong to the channel in chat_id. Additionally, make _make_channel_emitter fail closed: re-check that the target message's channel_id matches the channel before calling Messages.update_message_by_id, treating a missing or mismatched message as an error/no-op.
Consolidation
Per Open WebUI's Report Handling policy this advisory consolidates independent reports of the same chat-completions channel-overwrite flaw:
- Single-model cross-channel overwrite via the
channel:path: @sfwani (earliest filing). - Multimodel
message_idsfan-out variant that bypasses the v0.9.6 first-id-only gate: @DavidCarliez.
One CVE for the consolidated advisory.
Affected versions
PyPI
| Package | Vulnerable | Fixed in |
|---|---|---|
| open-webui | >= 0.9.5, < 0.10.0 |
0.10.0 |
How to fix
Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.
open-webui PyPI → 0.10.0
- pip
pip install --upgrade "open-webui>=0.10.0"- poetry
poetry add "open-webui>=0.10.0"- uv
uv add "open-webui>=0.10.0"
Severity breakdown
CVSS 3.1 7.1
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:L
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- Low
- User interaction
- None
- Scope
- Unchanged
- Confidentiality
- None
- Integrity
- High
- Availability
- Low
Weakness
CWE-862: Missing Authorization
The product does not perform an authorization check when an actor attempts to access a resource or perform an action.
How to prevent it
- Architecture and Design: Divide the product into anonymous, normal, privileged, and administrative areas. Reduce the attack surface by carefully mapping roles with data and functionality. Use role-based access control (RBAC) [REF-229] to enforce the roles at the appropriate boundaries. Note that this approach may not protect against horizontal authorization, i.e., it will not protect a user from attacking others with the same role.
- Architecture and Design: Ensure that access control checks are performed related to the business logic. These checks may be different than the access control checks that are applied to more generic resources such as files, connections, processes, memory, and database records. For example, a database may restrict access for medical records to a specific database user, but each record might only be intended to be accessible to the patient and the patient's doctor [REF-7].
- Architecture and Design: Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid. For example, consider using authorization frameworks such as the JAAS Authorization Framework [REF-233] and the OWASP ESAPI Access Control feature [REF-45].
- Architecture and Design: For web applications, make sure that the access control mechanism is enforced correctly at the server side on every page. Users should not be able to access any unauthorized functionality or information by simply requesting direct access to that page. One way to do this is to ensure that all pages containing sensitive information are not cached, and that all such pages restrict access to requests that are accompanied by an active and authenticated session token associated with a user who has the required permissions to access that page.
- System Configuration, Installation: Use the access control capabilities of your operating system and server environment and define your access control lists accordingly. Use a "default deny" policy when defining these ACLs.
References
Advisories
Packages
Other links
- github.com/open-webui/open-webui/security/advisories/GHSA-x2ff-v5v8-m75m
- github.com/open-webui/open-webui/commit/33e4e0dcc43afcca80f9c635d762cdc76c768ba9
- github.com/open-webui/open-webui/commit/ac3449cac91e62b08a7c28e54fcd044d14dea791
- github.com/open-webui/open-webui/releases/tag/v0.10.0
- github.com/open-webui/open-webui/pull/26385
Timeline
- Published
- Last updated by the source
- Latest EPSS score
Related advisories
| Advisory | Severity | Why it's related |
|---|---|---|
| GHSA-wvm9-9g5j-623f Open WebUI: Users denied by the OAuth role policy can still sign in via token exchange | Medium | Also affects open-webui |
| GHSA-4qg5-cxx4-g927 Open WebUI: Users denied by the OAuth domain allowlist or role policy can still sign in via token exchange | Medium | Also affects open-webui |
| GHSA-jqhh-cjmq-vmv6 Open WebUI: Any authenticated user can hang the server via a cyclic chat message history | Medium | Also affects open-webui |
| GHSA-5x7x-4c3c-qf5w Open WebUI: Server-side fetches reach blocked and internal hosts via unvalidated HTTP redirect targets | Medium | Also affects open-webui |
| GHSA-3cgp-3cqx-j8w2 Open WebUI: Any authenticated user can hang the server via message deletion in a cyclic chat tree | Medium | Also affects open-webui |
| GHSA-34r3-9m95-vq73 Open WebUI: Any authenticated user can reach the Azure platform channel via server-side web fetch | High | Also affects open-webui |
| GHSA-2724-6cpj-gf3v Open WebUI: Non-admin users can delete admin-owned external knowledge connections via knowledge base deletion | High | Also affects open-webui |
| GHSA-3pf7-q2g3-wj28 Open WebUI: Any authenticated user can inject chats into another user's folder via chat completions | Medium | Also affects open-webui |
MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.
Check your repos with MergeHarbor