CVE-2024-31580 json
PyTorch heap buffer overflow vulnerability
published 2024-04-17 2 y ago modified 2026-09-08 2 mo ago also BIT-pytorch-2024-31580 , EUVD-2024-1105 , GHSA-5pcm-hx3q-hm94 , PYSEC-2024-252 , PYSEC-2024-328
- cvss
- 4.0
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.2%
- EPSS 0.2% chance of exploitation in 30 days, percentile 13%
- public exploits
- 0
- none known
Summary
PyTorch before v2.2.0 was discovered to contain a heap buffer overflow vulnerability in the component /runtime/vararg_functions.cpp. This vulnerability allows attackers to cause a Denial of Service (DoS) via a crafted input.
Patch / fix
- pypi torch 2.2.0
- bitnami pytorch 2.2.1
- pypi torch-npu 2.2.0
- pytorch pytorch 2.2.0
- pytorch Debian 14, Debian 13 2.4.1-1
debian advisories DEBIAN-CVE-2024-31580
CISA SSVC
- Exploitation
- none
- Automatable
- yes
- Technical impact
- partial
- Assessed
- 2 y ago
Exploit prediction
0.22% chance of exploitation in the next 30 days, higher than 13% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CISA ADP | 3.1 | 4.0 | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| GitHub | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| CNA | 3.1 | 4.0 | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
| OSV | 3.1 | 4.0 | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| pypi | torch | <2.2.0 |
2.2.0 |
| bitnami | pytorch | <2.2.1 |
2.2.1 |
| pypi | torch-npu | <2.2.0 |
2.2.0 |
Affected products
- pytorch pytorch
Classification
- Weakness
-
- CWE-122 Heap-based Buffer Overflow
References
-
github.com
/pytorch/pytorch/commit/b5c3a17c2c207ebefcb85043f0cf94be9b2fef81
web, patch
-
gist.github.com
/1047524396/038c78f2f007345e6f497698ace2aa3d
web, third-party-advisory, advisory
-
nvd.nist.gov
/vuln/detail/CVE-2024-31580
advisory, web
-
github.com
/pypa/advisory-database/tree/main/vulns/torch/PYSEC-2024-252.yaml
web
-
github.com
/pytorch/pytorch
package
-
security.snyk.io
/vuln/SNYK-PYTHON-TORCH-6649934
web
-
github.com
/advisories/GHSA-5pcm-hx3q-hm94
advisory
Sources
- CVE List CVE-2024-31580
- GitHub Advisory GHSA-5pcm-hx3q-hm94
- NVD CVE-2024-31580
- OSV BIT-pytorch-2024-31580
- OSV PYSEC-2024-252
- OSV PYSEC-2024-328
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.