{"id":"CVE-2024-7034","details":"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.","aliases":["GHSA-crh6-pj8c-xrhc"],"modified":"2026-04-10T05:19:31.350988Z","published":"2025-03-20T10:15:35.117Z","references":[{"type":"EVIDENCE","url":"https://huntr.com/bounties/711beada-10fe-4567-9278-80a689da8613"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/open-webui/open-webui","events":[{"introduced":"0"},{"last_affected":"9bcd4ce5c0a01af68c0d2aa44554a68bb741c61b"}],"database_specific":{"versions":[{"introduced":"0"},{"last_affected":"0.3.8"}]}}],"versions":["v0.1.102","v0.1.103","v0.1.104","v0.1.105","v0.1.106","v0.1.107","v0.1.108","v0.1.109","v0.1.110","v0.1.111","v0.1.112","v0.1.113","v0.1.114","v0.1.115","v0.1.116","v0.1.117","v0.1.118","v0.1.119","v0.1.120","v0.1.121","v0.1.122","v0.1.123","v0.1.124","v0.1.125","v0.2.0","v0.2.1","v0.2.2","v0.2.3","v0.2.4","v0.2.5","v0.3.0","v0.3.1","v0.3.2","v0.3.3","v0.3.4","v0.3.5","v0.3.6","v0.3.7","v0.3.8"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2024-7034.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H"}]}