cve.bz

CVE-2026-32274 python black: Path traversal

8.7 highEPSS 0.7%Fix available

High (8.7) in python black. EPSS 0.7% estimated probability of exploitation activity in the next 30 days. Fixed in black 26.3.1.

On this page
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.

Severity

CVSS 4.0

8.7 high
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

CVSS 3.1

7.5 high
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
EPSS
0.7% (unchanged from 0.7% a week ago; 0.7% 30 days ago) estimated probability of exploitation activity in the next 30 days; 54th percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: yes · Technical impact: partial, assessed 2026-03-13. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-22 Improper Limitation of a Pathname to a Restricted Directory (Path traversal)
OWASP Top 10
A01:2025 Broken Access Control
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2026-32274 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-32274?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-32274?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-32274 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the NVD's CPE matches.

ProductAffected
python:blackbefore 26.3.1

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-3936-cmfr-pm3mPyPIblack>=24.3.0 <26.3.126.3.1
PYSEC-2026-2121PyPIblack<26.3.126.3.1

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian12blackno fix listedDEBIAN-CVE-2026-32274
Debian13black25.1.0-3+deb13u1DEBIAN-CVE-2026-32274
Debian14black26.3.1-1DEBIAN-CVE-2026-32274
Ubuntu20.04:LTS, 22.04:LTS, 24.04:LTS and 3 moreblackno fix listedUBUNTU-CVE-2026-32274
SUSELinux Enterprise Server 16.0, Linux Enterprise Server for SAP applications 16.0python-black25.1.0-160000.3.1SUSE-SU-2026:20928-1
openSUSELeap 15.6python-black24.3.0-150400.9.11.1SUSE-SU-2026:0900-1
openSUSELeap 16.0python-black25.1.0-160000.3.1openSUSE-SU-2026:20417-1
openSUSETumbleweedansible-lint26.9.0-1.1openSUSE-SU-2026:11856-1
openSUSETumbleweedpython-black26.3.1-1.1openSUSE-SU-2026:10372-1

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; SUSE security data, CC BY 4.0. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · SUSE · openSUSE.

Red Hat

Red Hat rates this Important.

Red Hat's mitigation

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.

ProductPackageStateAdvisory
Red Hat Ansible Automation Platform 2.5ansible-automation-platform-25/hub-rhel8:1777393635Fixed 2026-05-04RHSA-2026:13553
Red Hat Ansible Automation Platform 2.5ansible-automation-platform-25/lightspeed-rhel8:1777403872Fixed 2026-05-04RHSA-2026:13553
Red Hat Ansible Automation Platform 2.6ansible-automation-platform-26/ansible-dev-tools-rhel9:1777390240Fixed 2026-05-04RHSA-2026:13545
Red Hat Ansible Automation Platform 2.6ansible-automation-platform-26/ee-minimal-rhel9:1777387537Fixed 2026-05-04RHSA-2026:13545
Red Hat Ansible Automation Platform 2.6ansible-automation-platform-26/hub-rhel9:1777299023Fixed 2026-05-04RHSA-2026:13545
Red Hat Ansible Automation Platform 2.6ansible-automation-platform-26/lightspeed-rhel9:1777387242Fixed 2026-05-04RHSA-2026:13545
Red Hat Ansible Automation Platform 2.6ansible-automation-platform-26/platform-resource-runner-rhel9:1777390333Fixed 2026-05-04RHSA-2026:13545
Red Hat OpenShift AI 2.25rhoai/odh-workbench-jupyter-datascience-cpu-py312-rhel9:1776319193Fixed 2026-04-23RHSA-2026:10184
Red Hat OpenShift AI 2.25rhoai/odh-workbench-jupyter-pytorch-cuda-py312-rhel9:1776319179Fixed 2026-04-23RHSA-2026:10184
Red Hat OpenShift AI 2.25rhoai/odh-workbench-jupyter-pytorch-llmcompressor-cuda-py312-rhel9:1776319185Fixed 2026-04-23RHSA-2026:10184
OpenShift Lightspeedopenshift-lightspeed-tech-preview/lightspeed-rag-tool-rhel9Affected
Red Hat Ansible Automation Platform 2ansible-automation-platform-24/lightspeed-rhel8Not affected
Red Hat Ansible Automation Platform 2ansible-automation-platform-26/ee-supported-rhel9Not affected
Red Hat Ansible Automation Platform Ansible Core 2ansible-automation-platform/ee-minimal-rhel8Affected
Red Hat Ansible Automation Platform Ansible Core 2ansible-automation-platform/ee-minimal-rhel9Affected
Red Hat Ansible Automation Platform Ansible Core 2ansible-automation-platform-tech-preview/ee-minimal-rhel8Affected
Red Hat Ansible Automation Platform Ansible Core 2ansible-automation-platform-tech-preview/ee-minimal-rhel9Affected
Red Hat OpenShift AI (RHOAI)rhoai/odh-kserve-agent-rhel9Not affected
Red Hat OpenShift AI (RHOAI)rhoai/odh-kserve-controller-rhel9Not affected
Red Hat OpenShift AI (RHOAI)rhoai/odh-kserve-router-rhel9Not affected
16 more in the JSON and on Red Hat's page.

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2026-32274.

Attack patterns (CAPEC)

  • CAPEC-64 Using Slashes and URL Encoding Combined to Bypass Validation Logic Likelihood: High · Severity: High
  • CAPEC-76 Manipulating Web Input to File System Calls Likelihood: High · Severity: Very High
  • CAPEC-78 Using Escaped Slashes in Alternate Encoding Likelihood: High · Severity: High
  • CAPEC-79 Using Slashes in Alternate Encoding Likelihood: High · Severity: High
  • CAPEC-126 Path Traversal Likelihood: High · Severity: Very High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON