CVE-2026-34446: ONNX Arbitrary File Read Vulnerability
MODERATECVE-2026-34446 is a MODERATE (CVSS 4.7) arbitrary file read vulnerability (CWE-61: UNIX Symbolic Link (Symlink) Following) affecting ONNX libraries in the PyPI ecosystem. The issue involves arbitrary file read via externaldata hardlink bypass in onnx load. Remediation is available by upgrading affected packages to version 1.21.0.
CVE-2026-34446 at a Glance
Security Impact
CVSS: 4.7
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N).
How to Fix CVE-2026-34446
To remediate this vulnerability, upgrade all affected ONNX dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
pip install onnx>=1.21.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
pip show onnx
How to Check if You Are Affected
To determine whether your Python environment is affected by CVE-2026-34446, inspect your installed packages using pip:
pip show onnx
Analyze the terminal output to locate any version of ONNX in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.21.0), your application is affected.
Note: The pip show onnx command checks currently installed packages in your active Python environment.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-61: UNIX Symbolic Link (Symlink) Following, where the product, when opening a file or directory, does not sufficiently account for when the file is a symbolic link that resolves to a target outside of the intended control sphere. this could allow an attacker to cause the product to operate on unauthorized files. In ONNX, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2026-34446 Affected ONNX Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
onnx
|
PyPI |
< 1.21.0
|
1.21.0
|
References
Frequently Asked Questions
What is CVE-2026-34446?
Which ONNX versions are affected?
What version fixes CVE-2026-34446?
Is onnx affected?
What is the CVSS score of CVE-2026-34446?
What CWE is associated with CVE-2026-34446?
How can I check PyPI dependencies for CVE-2026-34446?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-cmw6-hcpp-c6jp",
"modified" : "2026-04-01T21:13:37Z",
"published" : "2026-04-01T21:13:37Z",
"aliases" : [ "CVE-2026-34446" ],
"summary" : "ONNX: Arbitrary File Read via ExternalData Hardlink Bypass in ONNX load",
"details" : "### Summary\nThe issue is in `onnx.load` — the code checks for symlinks to prevent path traversal, but completely misses hardlinks, which is the problem, since a hardlink looks exactly like a regular file on the filesystem.\n\n### The Real Problem\nThe validator in `onnx/checker.cc` only calls `is_symlink()` and never checks the inode or `st_nlink`, so a hardlink walks right through every security check without any issues.\n\n### Impact\nEspecially dangerous in AI supply chain scenarios like HuggingFace — a single malicious model is enough to silently steal secrets from the victim's machine without them noticing anything.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "PyPI",
"name" : "onnx"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "1.21.0"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 1.20.1"
}
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/onnx/onnx/security/advisories/GHSA-cmw6-hcpp-c6jp"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-34446"
}, {
"type" : "WEB",
"url" : "https://github.com/onnx/onnx/commit/4755f8053928dce18a61db8fec71b69c74f786cb"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/onnx/onnx"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-22", "CWE-61" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2026-04-01T21:13:37Z",
"nvd_published_at" : "2026-04-01T18:16:30Z"
}
}