CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-70491

CVE-2026-70491: Source Code Disclosure in Open WebUI Custom Tools

Alon Barad
Alon Barad
Software Engineer

Aug 5, 2026·5 min read·28 visits

Executive Summary (TL;DR)

Open WebUI versions <= 0.10.2 fail to strip sensitive tool source code during serialization due to a permissive Pydantic schema subclass and a non-functional database column defer flag, exposing credentials to unprivileged users.

An information disclosure vulnerability in Open WebUI versions 0.10.2 and earlier allows authenticated non-admin users with read-only access (or any authenticated user when a tool is shared publicly) to retrieve the raw Python source code of custom workspace tools. Because these server-side tools commonly contain hardcoded API tokens, credentials, and proprietary logic, the exposure of raw tool source code severely compromises confidentiality and can facilitate wider infrastructure compromise.

Vulnerability Overview

Open WebUI is an extensible, self-hosted AI user interface that allows users to create and execute custom server-side "tools" written in Python. These tools extend the functional capabilities of the underlying large language models. Because these tools run directly on the server, authors frequently hardcode sensitive parameters such as external service API keys, database credentials, internal service endpoints, and proprietary algorithms into the Python code.

The system is designed to enforce a strict boundary between users who can edit a tool and users who can only use or execute a tool. Standard users who have been granted read-only access to a shared tool are intended to view only the tool's functional interface specification (its schemas and parameter inputs), not the underlying backend Python source code.

Due to serialization flaws and defective database fetching mechanisms, Open WebUI versions 0.10.2 and earlier fail to enforce this write-only boundary. An authenticated user possessing minimal read access can query the tool API endpoints to retrieve the complete, plain-text Python source code, leading to an unauthorized exposure of sensitive credentials and system logic (CWE-200).

Root Cause Analysis

The root cause of this vulnerability lies in the combination of permissive response model schema configurations and an inactive database optimization flag. Inside backend/open_webui/routers/tools.py and backend/open_webui/models/tools.py, Open WebUI defines several Pydantic models for data validation and serialization.

While the base ToolResponse model does not include the sensitive content field (which stores the Python code), the subclass model ToolUserResponse (and its derivative ToolAccessResponse) was configured with a permissive configuration rule, effectively allowing extra fields during parsing:

model_config = ConfigDict(extra='allow')

When FastAPI processes a response, it dumps the database object and unpacks the dictionary into the response model constructor. Because the subclass explicitly allowed extra fields, the unpacked 'content' key—containing the full source code—was accepted and serialized into the final HTTP response.

Furthermore, the database query layer in Tools.get_tools featured a programmatic defect. A defer_content flag was intended to instruct the SQLAlchemy ORM to omit the content column during SELECT queries. However, this flag was a complete 'no-op' and did not modify the SQL execution plan. As a result, the backend always retrieved the raw source code from the database into the execution context, enabling the permissive serialization schemas to expose it.

Code Analysis

The vulnerability was addressed in commit c05de13b4fca1ac8a17153782b46b3d0aacf491c by restructuring how database records are serialized and validating write privileges explicitly before constructing response payloads.

Prior to the patch, the get_tools_by_id endpoint constructed the response object directly from the database model dump without evaluating whether the user should receive the raw source:

# VULNERABLE APPROACH
return ToolAccessResponse(
    **tools.model_dump(),
    write_access=(
        (user.role == 'admin' and BYPASS_ADMIN_ACCESS_CONTROL)
        or user.id == tools.user_id
        or await AccessGrants.has_access(
            user_id=user.id,
            resource_type='tool',
            resource_id=tools.id,
            permission='write',
            db=db,
        )
    ),
)

Because ToolAccessResponse allows extra fields via inheritance, the unstripped database dump passed the sensitive content field straight through to the client.

The patched code implements programmatic stripping of the content key when write_access is false, overriding the passive Pydantic model structure:

# PATCHED APPROACH
write_access = (
    (user.role == 'admin' and BYPASS_ADMIN_ACCESS_CONTROL)
    or user.id == tools.user_id
    or await AccessGrants.has_access(
        user_id=user.id,
        resource_type='tool',
        resource_id=tools.id,
        permission='write',
        db=db,
    )
)
data = tools.model_dump()
if not write_access:
    # extra='allow' re-admits content from model_dump; source is writer-only
    data.pop('content', None)
return ToolAccessResponse(**data, write_access=write_access)

Additionally, related fixes in Tools.get_tools repaired the defer_content parameter, ensuring that the database itself does not return the code column for standard index queries, providing a defense-in-depth barrier.

Exploitation Methodology

An authenticated attacker with a low-privilege user account can exploit this flaw using standard HTTP client tools. The only prerequisite is that the target tool must either be shared globally (assigned to the principal * with a read permission) or explicitly shared with the attacker's user identifier.

First, the attacker logs in to acquire a valid JSON Web Token (JWT). To retrieve the full Python source code of all available tools, the attacker sends a standard GET request to the tool listing endpoint:

GET /api/v1/tools/list HTTP/1.1
Host: target.openwebui.internal:8080
Authorization: Bearer <USER_JWT_TOKEN>
Accept: application/json

Despite the attacker lacking write privileges (resulting in `

Impact Assessment

The CVSS Base Score is evaluated at 6.5 (Medium), with a vector of CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N. Although the score is categorized as medium because it requires standard authenticated user credentials and does not directly permit data modification or service disruption, the practical operational severity is high.

In real-world configurations, server-side tools are key points of integration with corporate infrastructure. Exposing the Python source code allows standard users to extract API keys for critical language models, database connection strings, internal microservice tokens, and proprietary IP.

If the deployment uses custom scripts to interact with internal networks, attackers can utilize the discovered endpoints and parameters to map out the private corporate architecture. This exposure corresponds to MITRE ATT&CK techniques T1005 (Data from Local System) and T1552 (Unsecured Credentials), serving as a crucial initial foothold for lateral movement.

Remediation & Mitigation

The primary remediation for this vulnerability is to upgrade Open WebUI to version 0.11.0 or newer. This release implements programmatic pruning of sensitive fields and stabilizes DB-level column deferrals.

For environments where patching is delayed, administrators must apply alternative control measures. If custom Python scripts are not vital to daily operations, disable tool compilation entirely by setting the following environment variable:

ENABLE_PLUGINS=false

Additionally, audit existing workspace tool permissions. Ensure that tools carrying confidential credentials or proprietary operations are not shared with the general wildcard user (*).

To identify potential exploitation attempts, security teams should review web server access logs for anomalous, high-frequency requests targeting the endpoints GET /api/v1/tools/, GET /api/v1/tools/list, and GET /api/v1/tools/id/<id> from non-administrative source IPs.

Official Patches

Open WebUIVulnerability Advisory and Mitigation Information
Open WebUIOfficial Fix Pull Request

Fix Analysis (1)

Technical Appendix

CVSS Score
6.5/ 10
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N

Affected Systems

Open WebUIopen-webui PyPI Package

Affected Versions Detail

Product
Affected Versions
Fixed Version
Open WebUI
Open WebUI
<= 0.10.20.11.0
AttributeDetail
CWE IDCWE-200
Attack VectorNetwork (AV:N)
CVSS v3.16.5
EPSS ScoreNot Available
ImpactHigh Confidentiality Loss
Exploit StatusPoC Available
CISA KEV StatusNot Listed

MITRE ATT&CK Mapping

T1005Data from Local System
Collection
T1552Unsecured Credentials
Credential Access
CWE-200
Exposure of Sensitive Information to an Unauthorized Actor

The product exposes sensitive information to an actor that is not authorized to have access to that information.

Known Exploits & Detection

GitHub Security AdvisoryThe official security advisory notes the presence of a functional Proof of Concept demonstrating credentials harvesting from shared tools.

Vulnerability Timeline

Vulnerability disclosed and fixed in version 0.11.0
2026-02-10

References & Sources

  • [1]GHSA-3r7g-q6cg-q2vx Security Advisory
  • [2]Fix Tool Serialization Code Change
  • [3]Open WebUI v0.11.0 Release Notes

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•2 minutes ago•CVE-2026-105743
4.0

CVE-2026-105743: Server-Side Request Forgery Guard Bypass in Docling Document Conversion Engine

An SSRF guard bypass vulnerability in the Docling document conversion engine allows unauthenticated attackers to bypass internal IP access controls. The vulnerability exists due to a DNS rebinding Time-of-Check Time-of-Use (TOCTOU) condition, URL authority parsing inconsistencies, and unvalidated network requests triggered during headless browser page rendering.

Amit Schendel
Amit Schendel
0 views•6 min read
•about 1 hour ago•CVE-2026-105742
3.7

CVE-2026-105742: Sensitive Custom Header Leakage in Docling Image Resource Loader

A technical analysis of CVE-2026-105742 (GHSA-p3fw-7699-7926), a sensitive information disclosure vulnerability in the Docling document processing library. Vulnerable versions of Docling indiscriminately forward custom HTTP headers, such as authentication tokens, to arbitrary third-party origins and during cross-origin redirects while fetching remote image assets from untrusted HTML and EPUB documents.

Alon Barad
Alon Barad
3 views•6 min read
•about 2 hours ago•CVE-2026-106121
4.9

CVE-2026-106121: Denial of Service via Infinite Loop in RabbitMQ Java Client JSON Parser

CVE-2026-106121 is a Denial of Service (DoS) vulnerability in the RabbitMQ Java Client library (amqp-client) affecting versions prior to 5.37.0. The vulnerability resides in the legacy, custom JSON-RPC parsing class com.rabbitmq.tools.json.JSONReader. When parsing malformed or truncated payloads ending within a quoted string or single-line comment, the parser's scanner enters an infinite loop. This occurs because the loop lacks an exit condition for the end-of-input sentinel character returned by the iterator, leading to either CPU exhaustion or a JVM crash from an OutOfMemoryError.

Amit Schendel
Amit Schendel
5 views•6 min read
•about 4 hours ago•CVE-2026-105646
4.9

CVE-2026-105646: Regular Expression Denial of Service in Ghost CMS Import Handlers

An authenticated Regular Expression Denial of Service (ReDoS) vulnerability in TryGhost Ghost (CMS) versions 4.0.0 through 6.66.x. An attacker with administrator privileges can upload crafted content import archives containing pathological directory names or migration patterns, triggering exponential backtracking in the Node.js V8 engine.

Alon Barad
Alon Barad
8 views•6 min read
•about 5 hours ago•CVE-2026-105645
4.9

CVE-2026-105645: Regular Expression Denial of Service (ReDoS) in Ghost CMS

CVE-2026-105645 is a regular expression denial of service (ReDoS) vulnerability affecting Ghost, an open-source Node.js content management system. The vulnerability exists within directory import handlers and the external media inliner, allowing authenticated administrators to trigger catastrophic backtracking in the V8 JavaScript engine, resulting in infinite loops, 100% CPU utilization, and total denial of service.

Amit Schendel
Amit Schendel
8 views•6 min read
•about 6 hours ago•CVE-2026-105644
6.8

CVE-2026-105644: Stored Cross-Site Scripting via Malicious SVG Content Import in Ghost CMS

A Stored Cross-Site Scripting (XSS) and Unrestricted Upload of File with Dangerous Type vulnerability in Ghost CMS (versions 4.0.0 to 6.66.x) allows remote attackers to execute arbitrary JavaScript in the context of an administrator's session. The flaw lies in the content import subsystem, which extracted and stored SVG files without sanitization or binary verification.

Amit Schendel
Amit Schendel
7 views•6 min read