CVE-2024-0397: Memory race condition in ssl.SSLContext certificate store methods
Vulnerability summary
CVE-2024-0397 is a high (CVSS 7.4) vulnerability in python software foundation cpython. EPSS estimates a 0.81% chance of exploitation in the next 30 days, higher than 56.9% of scored vulnerabilities.
Severe, CVSS 7.4 (CVE.org); no exploitation reported by the 5 checked sources; EPSS 1% (FIRST, 03-11-2026)
Source freshness unavailable
How is this decided?Advisory lineage
Upstream 0 · Downstream 22 · Related 19Timeline
- 17-06-2024PublishedVulnerability first disclosed.
- 03-11-2025Last modifiedVulnerability information updated.
Description
A defect was discovered in the Python “ssl” module where there is a memory race condition with the ssl.SSLContext methods “cert_store_stats()” and “get_ca_certs()”. The race condition can be triggered if the methods are called at the same time as certificates are loaded into the SSLContext, such as during the TLS handshake with a certificate directory configured. This issue is fixed in CPython 3.10.14, 3.11.9, 3.12.3, and 3.13.0a5.
CVSS metrics
5 scores · 5 sources · 1 version- OSV · UbuntuEcosystem advisory · calculated7.4HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:H
- OSV · DebianEcosystem advisory · calculated7.4HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:H
- OSV · ChainguardEcosystem advisory · calculated7.4HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:H
- NVDNIST7.4HighCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:N/A:H
EPSS trend
Probability
0.81%
Chance of exploitation in the next 30 days
Percentile
57%
Versus all other CVEs
30-day change
No change 0.00 pp
From 0.81% on 04-10-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Known conditions: network-reachable, no authentication, no user interaction (CVSS vector). Other conditions: not stated in public data.
Ubuntu8 products
- python2.7All versions (No fix recorded)
- python3.10< 3.10.12-1~22.04.5
- python3.11All versions (No fix recorded)
- python3.4All versions (No fix recorded)
- python3.6All versions (No fix recorded)
Opensuse3 products
- python310&distro=openSUSE Tumbleweed< 3.10.14-2.1
- python38&distro=openSUSE Tumbleweed< 3.8.19-3.1
- python39&distro=openSUSE Tumbleweed< 3.9.19-2.1
Debian2 products
- pypy3All versions (No fix recorded) | < 7.3.16+dfsg-1
- python3.11< 3.11.2-6+deb12u3
Chainguard1 product
- python-3.9< 3.9.19-r2
Python software foundation1 product
- cpython< 3.8.20 | ≥ 3.9.0, < 3.9.20 | ≥ 3.10.0, < 3.10.14 | ≥ 3.11.0, < 3.11.9 | ≥ 3.12.0, < 3.12.3 | ≥ 3.13.0a1, < 3.13.0a5
5 vendors · 15 products
References
20 links- mail.python.org/archives/list/security-announce@python.org/thread/BMAK5BCGKYWNJOACVUSLUF6SFGBIM4VP/Vendor AdvisoryREPORTAdvisory
Show all 20 references
- github.com/python/cpythonPACKAGE