NewApp Monitoring is liveSign up free
AgentbeamBeta
AI agent vulnerability · Open WebUI

CVE-2024-7037: open-webui allows writing and deleting arbitrary files

mediumCVSS 4.0 5.5 · 3.0 6.5GHSA-54f4-v6v9-9q82

In open-webui 0.3.8 and earlier, the /api/pipelines/upload endpoint joins the uploaded file's filename to CACHE_DIR without sanitizing it. A caller can use path traversal to write or delete files outside that directory, which can lead to code execution. The advisory lists no patched version.

Published Oct 9, 2024 · Analysis Nov 1, 2026

What an attacker can do

The endpoint builds its target path by concatenating file.filename with CACHE_DIR. A filename containing ../ sequences or an absolute path moves the write outside the cache directory. The advisory describes this as arbitrary file write and delete (CWE-22). An attacker can overwrite files the Open WebUI process can write, or remove them.

Overwriting an application file, a Python module or a startup script can turn the write into remote code execution. Deleting files can break the service.

The CVSS vector requires high privileges (PR:H), so the caller must be an administrator account of the instance. It needs no user interaction and is reachable over the network. In practice the risk is a compromised or malicious admin, or an attacker who has stolen an admin token, moving from the web app to the host or container. Instances where several people hold admin rights, or where Open WebUI runs as root, carry the most risk.

Who is affected

The pip package open-webui, versions 0.3.8 and earlier. Docker deployments report the version in the web UI under settings, About. For pip installs:

pip show open-webui

open-webui

Ecosystem
PyPI
Affected
<= 0.3.8
Fixed in
No patched version yet
Check
pip show open-webui

How to fix it

No patched version is listed in the advisory data, and the sources I could read do not name one. Check the project's current releases and upgrade to the newest release; confirm that the /api/pipelines/upload handler sanitizes file.filename before relying on it.

Until then, limit admin accounts, restrict network access to the admin API, and run Open WebUI as an unprivileged user with a read-only filesystem except for its data directory. If you do not use pipelines, block /api/pipelines/upload at the reverse proxy. These are general mitigations, not advisory instructions.

How to tell if you were hit

Search reverse proxy and application logs for POST requests to /api/pipelines/upload, especially multipart filenames containing ../, ..%2f or a leading /. Look for files modified outside the cache directory around those requests, and for unexpected deletions. Review which accounts hold the admin role.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

In version v0.3.8 of open-webui/open-webui, the endpoint /api/pipelines/upload is vulnerable to arbitrary file write and delete due to unsanitized file.filename concatenation with CACHE_DIR. This vulnerability allows attackers to overwrite and delete system files, potentially leading to remote code execution.

Questions

Does CVE-2024-7037 need an admin account?

The CVSS vector sets PR:H, so high privileges are required. The caller needs an authorized account with admin rights on the instance.

Is there a fixed version of open-webui?

None is listed in the advisory. It marks 0.3.8 and earlier as vulnerable and gives no patched release.

Can this lead to remote code execution?

The advisory says it can potentially lead to it, by overwriting system files. It gives no specific exploit chain.

References

How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology

More Open WebUI vulnerabilities

All Open WebUI entries