Input validation error in black - CVE-2026-31900

 

Input validation error in black - CVE-2026-31900

Published: November 25, 2026


Vulnerability identifier: #VU170301
CSH Severity: High
CVSS v4: 9.3 [CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N]
CVE-ID: CVE-2026-31900
CWE-ID: CWE-20
Exploitation vector: Remote access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a remote attacker to execute arbitrary code in the Black GitHub Action and potentially access secrets or use permissions available to the workflow.

The vulnerability exists due to improper version validation in the Black GitHub Action when it reads the formatter version from repository configuration. A remote attacker can submit a pull request with untrusted dependency metadata to cause the action to run code from an untrusted source.


Affected software

black

How to mitigate CVE-2026-31900

Install security update from vendor's website.

black - update to 26.3.0

External References