CVE-2024-9979
Pyo3: risk of use-after-free in `borrowed` reads from python weak references
- Published
- Updated
- Reserved
- Assigned by
- redhat
Description
A flaw was found in PyO3. This vulnerability causes a use-after-free issue, potentially leading to memory corruption or crashes via unsound borrowing from weak Python references.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| redhatCNA (assigner) | 3.1 | Medium5.3 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L |
| NVDNVD · Deferred | 3.1 | Medium5.3 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L |
- EPSS (exploitation in 30 days)
- 0.21% · top 89% of all CVEs (6 Nov 2026)
- CISA SSVC
- Exploitation: none · Automatable: no · Technical impact: partial
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 5.3.
Weakness
Affected products
pyo3
- affected 0.22.0 – < 0.22.4
Red Hat · Red Hat Ansible Automation Platform 2
All versions: unaffected
Red Hat · Red Hat Ansible Automation Platform 2
All versions: unaffected
Red Hat · Red Hat Enterprise Linux 10
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: unaffected
Red Hat · Red Hat Enterprise Linux 8
All versions: unaffected
Red Hat · Red Hat Enterprise Linux 9
All versions: unaffected
Red Hat · Red Hat Enterprise Linux 9
All versions: unaffected
Affected packages
From reviewed advisories of the GitHub Advisory Database.
- crates.iopyo3GHSA-6jgw-rgmm-7cv6 (opens in a new tab)
What to do
Workaround: Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.
References (5)
- https://access.redhat.com/security/cve/CVE-2024-9979 (opens in a new tab)vdb-entryx_refsource_REDHAT
- RHBZ#2318646 (opens in a new tab)issue-trackingx_refsource_REDHAT
- https://crates.io/crates/pyo3 (opens in a new tab)
- https://github.com/PyO3/pyo3/pull/4590 (opens in a new tab)
- https://rustsec.org/advisories/RUSTSEC-2024-0378.html (opens in a new tab)
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-6jgw-rgmm-7cv6 (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://trackcve.app/cve/CVE-2024-9979)Record last updated .