CVE-2024-7034: open-webui: path traversal allows arbitrary file write/RCE
GHSA-crh6-pj8c-xrhc MEDIUM CISA: TRACK*Any user with upload privileges on open-webui <= 0.3.8 can overwrite arbitrary files on the host system via crafted filenames in the /models/upload endpoint, potentially achieving remote code execution. Upgrade immediately or disable the upload endpoint if no patch is available. Treat any open-webui instance with multiple users or internet exposure as compromised until patched.
Risk Assessment
CVSS 6.5 understates operational risk. While PR:H limits mass exploitation, open-webui is typically deployed with multiple trusted users (data scientists, ML engineers) who have upload access — making the 'high privilege' bar effectively low in practice. The integrity and availability impact is HIGH, and file overwrite primitives routinely escalate to RCE via cron jobs, SSH authorized_keys, or application config. Internet-exposed open-webui instances are particularly at risk. EPSS of ~3% indicates limited active exploitation currently, but path traversal exploits are well within script-kiddie capability.
Affected Systems
| Package | Ecosystem | Vulnerable Range | Patched |
|---|---|---|---|
| open-webui | pip | <= 0.3.8 | No patch |
Do you use open-webui? You're affected.
Severity & Risk
Attack Surface
Recommended Action
5 steps-
PATCH
Upgrade open-webui to a version > 0.3.8 — verify the specific patched version in the release notes before deploying.
-
WORKAROUND (if unpatched): Block or restrict access to the /models/upload endpoint at the reverse proxy layer (Nginx/Caddy rule: deny POST to /models/upload from non-admin IPs).
-
HARDEN
Enforce filename sanitization at the OS level using a restricted upload directory with no symlinks and a chroot/container boundary.
-
DETECT
Alert on file writes outside UPLOAD_DIR using auditd rules (auditctl -w /etc -p wa) or EDR file integrity monitoring.
-
AUDIT
Review existing uploaded files for path traversal payloads (filenames containing ../ or absolute paths in the uploads table/directory).
CISA SSVC Assessment
Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.
Classification
Compliance Impact
This CVE is relevant to:
Frequently Asked Questions
What is CVE-2024-7034?
Any user with upload privileges on open-webui <= 0.3.8 can overwrite arbitrary files on the host system via crafted filenames in the /models/upload endpoint, potentially achieving remote code execution. Upgrade immediately or disable the upload endpoint if no patch is available. Treat any open-webui instance with multiple users or internet exposure as compromised until patched.
Is CVE-2024-7034 actively exploited?
No confirmed active exploitation of CVE-2024-7034 has been reported, but organizations should still patch proactively.
How to fix CVE-2024-7034?
1. PATCH: Upgrade open-webui to a version > 0.3.8 — verify the specific patched version in the release notes before deploying. 2. WORKAROUND (if unpatched): Block or restrict access to the /models/upload endpoint at the reverse proxy layer (Nginx/Caddy rule: deny POST to /models/upload from non-admin IPs). 3. HARDEN: Enforce filename sanitization at the OS level using a restricted upload directory with no symlinks and a chroot/container boundary. 4. DETECT: Alert on file writes outside UPLOAD_DIR using auditd rules (auditctl -w /etc -p wa) or EDR file integrity monitoring. 5. AUDIT: Review existing uploaded files for path traversal payloads (filenames containing ../ or absolute paths in the uploads table/directory).
What systems are affected by CVE-2024-7034?
This vulnerability affects the following AI/ML architecture patterns: model serving, local LLM deployments, ML workstations and research infrastructure, shared GPU inference clusters, open-webui + Ollama stacks.
What is the CVSS score for CVE-2024-7034?
CVE-2024-7034 has a CVSS v3.1 base score of 6.5 (MEDIUM). The EPSS exploitation probability is 6.73%.
Technical Details
NVD Description
In open-webui version 0.3.8, the endpoint `/models/upload` is vulnerable to arbitrary file write due to improper handling of user-supplied filenames. The vulnerability arises from the usage of `file_path = f"{UPLOAD_DIR}/{file.filename}"` without proper input validation or sanitization. An attacker can exploit this by manipulating the `file.filename` parameter to include directory traversal sequences, causing the resulting `file_path` to escape the intended `UPLOAD_DIR` and potentially overwrite arbitrary files on the system. This can lead to unauthorized modifications of system binaries, configuration files, or sensitive data, potentially enabling remote command execution.
Exploitation Scenario
An attacker with a legitimate open-webui account (e.g., a researcher or developer) crafts a multipart POST to /api/models/upload with Content-Disposition: form-data; name='file'; filename='../../.ssh/authorized_keys'. The server constructs the path as {UPLOAD_DIR}/../../.ssh/authorized_keys and writes attacker-controlled content, adding their public SSH key. Alternatively, the attacker targets /etc/cron.d/backdoor to establish persistence or overwrites a Python package in site-packages to inject malicious code into the model serving stack. In a shared GPU cluster deployment, this single exploit compromises the entire model inference infrastructure for all teams.
Weaknesses (CWE)
CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:H/UI:N/S:U/C:N/I:H/A:H References
Timeline
Related Vulnerabilities
CVE-2026-44551 9.1 open-webui: LDAP auth bypass — full account takeover
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-2025-65958 8.5 open-webui: SSRF allows internal network access
Same package: open-webui CVE-2024-7990 8.4 open-webui: Stored XSS enables admin session hijack
Same package: open-webui
AI Threat Alert