🛡️ CVE-2026-32274 — black
Description
Black: Arbitrary file writes from unsanitized user input in cache file name ### Impact 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. ### Patches Fixed in Black 26.3.1. ### Workarounds Do not allow untrusted user input into the value of the `--python-cell-magics` option.
How this vulnerability can be exploited
This issue can be reached over the network, attack complexity is low, an attacker needs no privileges on the target. No user interaction is required. Rated impact: confidentiality none, integrity high, availability none.
Weakness class
CVE-2026-32274 is classified as CWE-22: Path Traversal. A file path built from user input is not confined to the intended directory, letting an attacker reach files elsewhere on the filesystem.
Affected software and timeline
Affected software: black (from 24.3.0 up to 26.3.1). Published on 12 March 2026 and last revised on 3 August 2026. No public exploit is currently recorded for this entry. A vendor advisory or fix has been published. Record sourced from OSV.
References
github.com (Web)
nvd.nist.gov (Advisory)
github.com (Web)
github.com (Web)
github.com (Web)
github.com (Web)
access.redhat.com (Web)
access.redhat.com (Web)
access.redhat.com (Web)
access.redhat.com (Web)
bugzilla.redhat.com (Web)
github.com (Package)
github.com (Web)
github.com (Web)
security.access.redhat.com (Web)
CVE-2026-32274 on other distributions
Each distribution ships its own build and its own fixed version. Pick the one you run:
Details
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
Affected Packages
| Software | From version | Fixed in |
|---|---|---|
| black | 24.3.0 | 26.3.1 |
References
Similar Threats
- High ROOT-APP-PYPI-CVE-2026-32274
- Unknown ECHO-c5b6-7968-60af
- Unknown MAL-2026-2870
- Unknown DEBIAN-CVE-2026-32274
- Unknown UBUNTU-CVE-2026-32274
Site Security Check
Is black part of your stack?
CVE-2026-32274 is rated CVSS 8.0 High. BotEraser scans your installation against known CVE records and tells you whether this vulnerability applies to the versions you actually run.
Scan My Site Free →No credit card required · Results in minutes
ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.