Back to CVE records
High 8.7Published Mar 12, 2026

CVE-2026-32274Black: Arbitrary file writes from unsanitized user input in cache file name

Updated under an hour ago ()

Does this affect you?

It affects psf black and 6 other products. Add what you run to find out whether that includes you.

No exploitation reported and no EPSS estimate yet.

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
8.7 HIGH (v4.0, CNA)CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA: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
GitHub_M
NVD analysis
Modified
Record last updated
Aug 3, 2026
First seen by InfoSec Signals
Oct 9, 2026

Affected products

Affected products
psf black
psf:black (from the name)
from 24.3.0, < 26.3.1
CNA record
Red Hat Red Hat Ansible Automation Platform 2.5
redhat:ansible_automation_platform
from 1777393635 not affected
CISA ADP
from 1776319193 not affected
CISA ADP
Red Hat OpenShift Lightspeed
redhat:openshift_lightspeed
All versions
CISA ADP
2
CISA ADP
Red Hat Red Hat OpenShift Virtualization 4
redhat:container_native_virtualization
4
CISA ADP
python black
python:black
before 26.3.1
NVD

References

References

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.

Your cookie choices
We use essential cookies to run this site, and, only with your consent, an advertising cookie from Google to measure whether our ads lead to sign-ups and subscriptions. See our for details.