Summary
Open WebUI contains an authorization enforcement weakness that allows any authenticated user to overwrite messages in channels they do not belong to, including private and direct-message channels. The issue becomes risky when a chat completion request can reference a channel and message identifier without verifying that the caller has access to both resources.
Affected context
The vulnerability affects Open WebUI deployments using channel chat completion functionality in versions from 0.9.5 before 0.10.0. It occurs when pipeline output is processed through the channel emitter and the message update operation accepts a caller-supplied message identifier without confirming that the identified message belongs to an authorized channel.
Exploit preconditions
- Attack surface: Authenticated chat completion and channel messaging functionality
- Required access: A valid Open WebUI user account
- Target condition: A message exists in a channel, private channel, or direct-message conversation the user is not authorized to access
- Trigger point: Processing channel-prefixed completion requests that reference an existing message
- Why exploitation is possible: Authorization is not adequately bound to the requested message, channel, and caller before the database update occurs
Why this happens
The underlying issue is an object-level authorization failure mapped to CWE-862: Missing Authorization. The channel output path uses a caller-controlled message identifier when writing to the Messages table, but does not enforce a relationship between that message, the requested channel, and the authenticated user's membership or permissions. This creates an insecure direct object reference pattern in which resource ownership and access checks are separated from the update operation.
Potential impact
- An authenticated user may overwrite messages outside their authorized channels
- Private or direct-message content may be altered
- Conversation integrity and auditability could be reduced
- Users may be misled by unauthorized changes to channel history
- Modified messages can cause reputational, operational, or moderation impacts
General mitigation guidance
Mitigation generally focuses on enforcing authorization at the resource-operation boundary rather than trusting identifiers supplied by clients.
Common defensive patterns include:
- Verify channel membership and permissions before every message read or write
- Bind message ownership and channel relationships in the authorization query or transaction
- Treat message and channel identifiers as references only, not as proof of access
- Apply centralized, deny-by-default authorization checks consistently across API and pipeline paths
- Use least-privilege service permissions for database operations
- Record and review authorization failures and sensitive message updates
How teams detect issues like this
Organizations can assess for this class of issue through:
- Static analysis searches for database updates using client-supplied object identifiers without nearby authorization checks
- Code review of channel, message, and direct-message access-control paths
- Tests that attempt cross-channel reads and writes using authenticated accounts with different memberships
- Policy checks requiring authorization decisions to include both the caller and target resource
- Audit monitoring for message updates where the actor is not a member of the associated channel
- Automated application-security review tools that identify insecure direct object reference patterns

