CVE-2026-32274Black is the uncompromising Python code formatter.
Updated under an hour ago ()
Does this affect you?
It affects python black. Add what you run to find out whether that includes you.
No exploitation reported and no EPSS estimate yet.
Do this next
Free account, 1 product
Black is the uncompromising Python code formatter. Starting in version 24.3.0 and prior to version 26.3.1, Black writes a cache file, the name of which is computed from various formatting options. The value of the --python-cell-magics option was placed in the filename without sanitization, which allowed an attacker who controls the value of this argument to write cache files to arbitrary file system locations. Fixed in Black 26.3.1.
- CVSS
- 7.5 HIGH (v3.1, NVD)CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
- Weakness (CWE)
- CWE-22
- Known exploited
- Not in CISA's KEV catalog
- EPSS (exploitation in the next 30 days)
- Not loaded for this CVE
- Assigned by
- Not given
- NVD analysis
- Modified
- Record last updated
- Aug 3, 2026
- First seen by InfoSec Signals
- Oct 9, 2026
Affected products
python black python:black | before 26.3.1 | NVD |
References
- https://access.redhat.com/errata/RHSA-2026:10184
- https://access.redhat.com/errata/RHSA-2026:13545
- https://access.redhat.com/errata/RHSA-2026:13553
- https://access.redhat.com/security/cve/CVE-2026-32274
- https://bugzilla.redhat.com/show_bug.cgi?id=2447111
- https://github.com/psf/black/commit/4937fe6cf241139ddbfc16b0bdbb5b422798909dpatch
- https://github.com/psf/black/commit/ed770ba4dd50c419148a0fca2b43937a7447e1f9
- https://github.com/psf/black/pull/4176
- https://github.com/psf/black/pull/5038issue-tracking, patch
- https://github.com/psf/black/releases/tag/26.3.1release-notes
- https://github.com/psf/black/security/advisories/GHSA-3936-cmfr-pm3mvendor-advisory
- https://github.com/pypa/advisory-database/tree/main/vulns/black/PYSEC-2026-2121.yaml
- https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-32274.json
The CVE record on cve.org NVD's entry
The CVE record is authoritative. Products marked “from the name” were identified from the CNA's free-text names, not a CPE, and are matched less certainly. This product uses the NVD API but is not endorsed or certified by the NVD.