8.8high
Arbitrary File Overwrite in download_model_with_test_data in onnx/onnx
- Severity
- 8.8high CVSS:3.0 by @huntr_ai
- Exploit likelihood
- 1.17% (higher than 68% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- @huntr_ai
- Also known as
- GHSA-6rq9-53c3-f7vjPYSEC-2025-148
Description
A vulnerability in the `download_model_with_test_data` function of the onnx/onnx framework, version 1.16.0, allows for arbitrary file overwrite due to inadequate prevention of path traversal attacks in malicious tar files. This vulnerability enables attackers to overwrite any file on the system, potentially leading to remote code execution, deletion of system, personal, or application files, thus impacting the integrity and availability of the system. The issue arises from the function's handling of tar file extraction without performing security checks on the paths within the tar file, as demonstrated by the ability to overwrite the `/home/kali/.ssh/authorized_keys` file by specifying an absolute path in the malicious tar file.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| onnx onnx/onnx | from unspecified up to latest | CVE List |
| linuxfoundation onnx | from 1.16.0 before *, 1.16.0 | CVE List, NVD |
| onnx (PyPI) | before 1.16.2, up to 1.17.0 | GitHub Advisory Database, PyPA Advisory Database |
All scores
| @huntr_ai | 8.8high CVSS:3.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H |
| GitHub | 8.8high CVSS:3.0 | CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H |
| NVD | 8.8high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H |
| PyPA Advisory Database | 8.8high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H |
Classification
SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total.
What each source says
CVE List
A vulnerability in the `download_model_with_test_data` function of the onnx/onnx framework, version 1.16.0, allows for arbitrary file overwrite due to inadequate prevention of path traversal attacks in malicious tar files. This vulnerability enables attackers to overwrite any file on the system, potentially leading to remote code execution, deletion of system, personal, or application files, thus impacting the integrity and availability of the system. The issue arises from the function's handling of tar file extraction without performing security checks on the paths within the tar file, as demonstrated by the ability to overwrite the `/home/kali/.ssh/authorized_keys` file by specifying an absolute path in the malicious tar file.
GitHub Advisory Database
A vulnerability in the download_model_with_test_data function of the onnx/onnx framework, versions before 1.16.2, allow for arbitrary file overwrite due to inadequate prevention of path traversal attacks in malicious tar files. This vulnerability enables attackers to overwrite any file on the system, potentially leading to remote code execution, deletion of system, personal, or application files, thus impacting the integrity and availability of the system. The issue arises from the function's handling of tar file extraction without performing security checks on the paths within the tar file, as demonstrated by the ability to overwrite the /home/kali/.ssh/authorized_keys file by specifying an absolute path in the malicious tar file.
NVD (es)
Una vulnerabilidad en la función `download_model_with_test_data` del framework onnx/onnx, versión 1.16.0, permite la sobrescritura arbitraria de archivos debido a una prevención inadecuada de ataques de path traversal en archivos tar maliciosos. Esta vulnerabilidad permite a los atacantes sobrescribir cualquier archivo en el sistema, lo que podría provocar la ejecución remota de código y la eliminación de archivos del sistema, personales o de aplicaciones, lo que afecta la integridad y disponibilidad del sistema. El problema surge del manejo de la función de extracción de archivos tar sin realizar controles de seguridad en las rutas dentro del archivo tar, como lo demuestra la capacidad de sobrescribir el archivo `/home/kali/.ssh/authorized_keys` especificando una ruta absoluta en el archivo tar. archivo tar malicioso.
PyPA Advisory Database
Path Traversal vulnerability in onnx.external_data_helper.save_external_data in ONNX 1.17.0 allows attackers to overwrite arbitrary files by supplying crafted external_data.location paths containing traversal sequences, bypassing intended directory restrictions.
References
Related
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2024-5187 changed 2024-08-01 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-6rq9-53c3-f7vj changed 2026-06-06 | CC-BY-4.0 |
| NVD | CVE-2024-5187 changed 2026-06-17 | Public domain |
| PyPA Advisory Database | PYSEC-2025-148 changed 2026-05-21 | CC-BY-4.0 |