Description
In ONNX before 1.21.0, the 'save_external_data' function builds the external-data file path from the model's external_data location field and opens it for writing without 'O_NOFOLLOW/O_EXCL', after a non-atomic 'os.path.isfile()' check. A local attacker with write access to the directory where a victim serializes external data can deterministically pre-plant a symlink that is being followed, causing the victim's write to append to any file the victim can write, e.g. ~/.ssh/authorized_keys, cron files, or application configs. Fixed in 1.21.0.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| ONNX | ONNX | < 1.21.0 | 1.21.0 |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | onnx | No fix yet | — |
| Debian 13 | onnx | No fix yet | — |
| Debian 12 | onnx | No fix yet | — |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | onnx | No fix yet | — |
| Ubuntu 26.04 LTS | onnx | No fix yet | — |
| Ubuntu 22.04 LTS | onnx | No fix yet | — |
Show 1 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Pro 24.04 LTS | onnx | No fix yet | — |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| PyPI | onnx | < 1.21.0 | 1.21.0 | GHSA-q56x-g2fj-4rj6 |
Advisories 1
- VA-26-233-01 ONNX symlink-following and path-traversal arbitrary file write CISA ICS & IT advisories · Aug 21, 2026