CVE-2026-70491: open-webui: shared tool source leaks hardcoded API keys
GHSA-3r7g-q6cg-q2vx MEDIUM PoC AVAILABLE CISA: TRACK*A permission-model bug in open-webui let any user who was merely granted read access to a shared tool pull down that tool's full server-side Python source, even though the schema was explicitly designed to withhold it from non-writers. Tool source in this platform routinely embeds hard-coded API keys, credentials and internal service URLs, so a single read-only share — including a share to "everyone" — could hand a non-admin the keys to other systems, with no elevated permission and no user interaction required. The blast radius is narrow relative to open-webui's overall CVE volume (150 other CVEs in the package, 4 tracked downstream dependents), and both CISA's SSVC call (TRACK_STAR) and the EPSS score (0.26%, though ranked in the top 82% relative percentile) suggest this isn't being mass-exploited or urgently weaponized. Still, a public PoC exists and exploitation requires nothing beyond an ordinary account a tool owner already trusted, so treat it as a quiet-but-real secrets-exposure risk rather than noise. Upgrade to open-webui 0.11.0, then audit every tool that has ever been shared with a read grant (especially `user:*` public shares) and rotate any credentials that were hard-coded in their source.
What is the risk?
CVSS 6.5 (AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N) reflects a confidentiality-only flaw: no code execution, no data modification, no availability impact. Exploitability is trivial for anyone already holding a read grant — no privilege escalation or crafted payload needed, just calling an existing authenticated endpoint. What limits real-world risk is the precondition: an attacker must already be a recipient of a read-only tool share (or the tool must be shared publicly with `user:*`), so instances that don't share tools, or only share with users who already have write access, are unaffected. Not in CISA KEV, EPSS is low (0.26%), and SSVC lands at TRACK_STAR (lowest-urgency tier) — but a working PoC is public and the impact (credential exposure) can cascade well beyond the vulnerability itself if tool authors hard-coded secrets, which is common practice in this ecosystem.
How does the attack unfold?
What systems are affected?
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| Open WebUI | pip | <= 0.10.2 | 0.11.0 |
Do you use Open WebUI? You're affected.
How severe is it?
What is the attack surface?
What should I do?
1 step-
1) Upgrade open-webui to 0.11.0 or later — this is a full fix with no configuration change required (commits c05de13b4 + 310ae9130, PR #27005). 2) Before or immediately after patching, inventory every tool that has ever had a read-only or public (
user:*) access grant and treat any hard-coded credentials in that source as compromised — rotate them. 3) Going forward, enforce a policy that tool source never embeds secrets directly; use environment variables or a secrets manager referenced at runtime instead, so future permission bugs can't leak credentials via source disclosure. 4) Detection: review Resend/API/audit logs (if available) for unusual calls to/api/v1/tools/listor/api/v1/tools/id/{id}from non-admin accounts around the time tools were shared, and confirm no unexpected downstream API usage tied to keys that were embedded in shared tool source.
What does CISA's SSVC say?
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
How is it classified?
Which compliance frameworks are affected?
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2026-70491?
A permission-model bug in open-webui let any user who was merely granted read access to a shared tool pull down that tool's full server-side Python source, even though the schema was explicitly designed to withhold it from non-writers. Tool source in this platform routinely embeds hard-coded API keys, credentials and internal service URLs, so a single read-only share — including a share to "everyone" — could hand a non-admin the keys to other systems, with no elevated permission and no user interaction required. The blast radius is narrow relative to open-webui's overall CVE volume (150 other CVEs in the package, 4 tracked downstream dependents), and both CISA's SSVC call (TRACK_STAR) and the EPSS score (0.26%, though ranked in the top 82% relative percentile) suggest this isn't being mass-exploited or urgently weaponized. Still, a public PoC exists and exploitation requires nothing beyond an ordinary account a tool owner already trusted, so treat it as a quiet-but-real secrets-exposure risk rather than noise. Upgrade to open-webui 0.11.0, then audit every tool that has ever been shared with a read grant (especially `user:*` public shares) and rotate any credentials that were hard-coded in their source.
Is CVE-2026-70491 actively exploited?
Proof-of-concept exploit code is publicly available for CVE-2026-70491, increasing the risk of exploitation.
How to fix CVE-2026-70491?
1) Upgrade open-webui to 0.11.0 or later — this is a full fix with no configuration change required (commits c05de13b4 + 310ae9130, PR #27005). 2) Before or immediately after patching, inventory every tool that has ever had a read-only or public (`user:*`) access grant and treat any hard-coded credentials in that source as compromised — rotate them. 3) Going forward, enforce a policy that tool source never embeds secrets directly; use environment variables or a secrets manager referenced at runtime instead, so future permission bugs can't leak credentials via source disclosure. 4) Detection: review Resend/API/audit logs (if available) for unusual calls to `/api/v1/tools/list` or `/api/v1/tools/id/{id}` from non-admin accounts around the time tools were shared, and confirm no unexpected downstream API usage tied to keys that were embedded in shared tool source.
What systems are affected by CVE-2026-70491?
This vulnerability affects the following AI/ML architecture patterns: agent frameworks, plugin ecosystems.
What is the CVSS score for CVE-2026-70491?
CVE-2026-70491 has a CVSS v3.1 base score of 6.5 (MEDIUM). The EPSS exploitation probability is 0.27%.
What is the AI security impact?
Affected AI Architectures
MITRE ATLAS Techniques
AML.T0055 Unsecured Credentials AML.T0084 Discover AI Agent Configuration AML.T0084.001 Tool Definitions Compliance Controls Affected
What are the technical details?
Original Advisory
## Summary A workspace tool shared with a read grant returned its full Python source to the recipient. Any authenticated non-admin who could use a shared tool could also read its source, including any user on the instance when a tool was shared publicly. Source is meant to be a writer-only tier: the list response schema deliberately omits it and source export sits behind its own permission. The read endpoints delivered it anyway. ## Preconditions - Authentication enabled (`WEBUI_AUTH=true`, default) and plugins enabled (`ENABLE_PLUGINS=true`, default). - The attacker is an authenticated non-admin without the `workspace.tools` permission and without a write grant on the tool. - A tool is shared with a read grant to the attacker, to one of their groups, or to all users (`user:*`). Deployments that share no tools, or share them only with users who already hold write access, are not affected. ## Impact A non-admin obtains another user's server-side tool source. Tool source commonly embeds hard-coded API keys, credentials and internal service URLs, so the practical loss frequently extends past the code itself. The attack needs no special permission beyond an ordinary account that a tool was shared with, and no user interaction. Confidentiality only: it grants no ability to create, modify or execute tools, and no integrity or availability impact. ## Fix Fixed in 0.11.0 by commit `c05de13b4` (#27005) together with `310ae9130`. The per-id endpoint now drops the source for callers without write access, and the two list endpoints no longer load source at all. Function specs stay visible to read users, since the chat tool listing renders a tool's functions from them. Tool execution loads source server-side, so shared tools keep working. Upgrading to 0.11.0 fully resolves the issue with no configuration change. ## Root cause Affected components: `GET /api/v1/tools/`, `GET /api/v1/tools/list` and `GET /api/v1/tools/id/{id}` in `backend/open_webui/routers/tools.py`, and the response models in `backend/open_webui/models/tools.py`. Every build carrying the plugin routes is affected. `ToolResponse` deliberately omits the source and the specs, but its subclass `ToolUserResponse` permits extra fields, and each handler built its response by spreading a full dump of the tool model. The omitted fields were re-admitted as extras and serialised back to the caller, so the schema meant to enforce the writer-only tier enforced nothing at all. The listing path carried a second, independent defect: the flag that was supposed to keep source out of listings never changed the query it guarded. ## Proof of concept Against a default instance on 0.10.2, with an admin account and a second account of role `user`: 1. As the admin, create a tool whose source contains a marker secret and share it read-only with everyone: ``` POST /api/v1/tools/create {"id": "poctool", "name": "PoC Tool", "content": "API_KEY = \"TOOL_SRC_SECRET\"\nclass Tools:\n def hello(self) -> str: return 'hi'", "meta": {"description": "poc"}, "access_grants": [{"principal_type": "user", "principal_id": "*", "permission": "read"}]} ``` 2. As the non-admin, call any of the three read endpoints: ``` GET /api/v1/tools/list -> 200, item "poctool": write_access=false, content="API_KEY = \"TOOL_SRC_SECRET\" ..." ``` The same source is returned by `GET /api/v1/tools/` and `GET /api/v1/tools/id/poctool`. On 0.11.0 the identical run returns the item with no source for the non-admin, while the owner still receives it. ## Credits - bogdancherniy11-sudo — reported the disclosure across the three tool read endpoints.
Exploitation Scenario
An admin creates a useful internal tool (e.g., a ticketing or internal-API connector) whose source includes a hard-coded service API key, and shares it read-only with the whole organization so employees' agents can use it without needing write access. A curious or malicious employee with an ordinary account calls `GET /api/v1/tools/list` (or the per-tool detail endpoint) — an action fully within their granted permissions — and the vulnerable response includes the tool's raw Python source instead of just its name and function specs. The employee extracts the embedded API key and internal service URL from the source, then uses those credentials directly against the internal service, bypassing open-webui entirely and gaining access the platform never intended to grant them.
Weaknesses (CWE)
CWE-200 Exposure of Sensitive Information to an Unauthorized Actor
Primary
CWE-200 Exposure of Sensitive Information to an Unauthorized Actor CWE-200 — Exposure of Sensitive Information to an Unauthorized Actor: The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.
- [Architecture and Design] Compartmentalize the system to have "safe" areas where trust boundaries can be unambiguously drawn. Do not allow sensitive data to go outside of the trust boundary and always be careful when interfacing with a compartment outside of the safe area. Ensure that appropriate compartmentalization is built into the system design, and the compartmentalization allows for and reinforces privilege separation functionality. Architects and designers should rely on the principle of least privilege to decide the appropriate time to use privileges and the time to drop privileges.
Source: MITRE CWE corpus.
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N References
Timeline
Related Vulnerabilities
CVE-2026-44551 9.1 open-webui: LDAP auth bypass — full account takeover
Same package: open-webui CVE-2026-45672 8.8 open-webui: code exec gate bypass via API endpoint
Same package: open-webui CVE-2026-44552 8.7 open-webui: Redis cache poisoning enables cross-instance tool hijack
Same package: open-webui CVE-2025-64495 8.7 Open WebUI: XSS-to-RCE via malicious prompt injection
Same package: open-webui CVE-2026-45315 8.7 open-webui: stored XSS → JWT theft and admin takeover
Same package: open-webui