{"id":2821,"cve":"CVE-2026-114134","cve_url":"https:\/\/www.cvedetails.com\/cve\/CVE-2026-114134\/","cwe":"CWE-829","cwe_number":829,"cwe_url":"https:\/\/cwe.mitre.org\/data\/definitions\/829","cvss_score":8.7,"published":"2026-11-05","owasp":"A08 Software and Data Integrity Failures","odc":"Checking","cdc":"Missing Check","category":"Input Validation and Sanitization","subcategory":"Insecure Parsing or Deserialization","scope":"Remote","impact":"Arbitrary Code Execution","summary":"Black Action allows unvalidated tool.black.required-version, enabling code injection.","permalink":"https:\/\/netpack.pt\/vaitp\/vulnerability\/CVE-2026-114134\/","description":"Black is the uncompromising Python code formatter. Prior to 26.10.1, the Black GitHub Action with use_pyproject: true accepts tool.black.required-version from pyproject.toml without validating that it is a released Black version specifier. An attacker who can submit a pull request can change that field to a direct reference to attacker-controlled code, causing the workflow to install and execute the code in the victim repository's GitHub Actions context. This issue is fixed in version 26.10.1.","solution":"Upgrade the Black GitHub Action to\u202fv26.10.1\u202for newer.","affected_component":"Black","fixed_by_upgrading":true,"vulnerable_code":"import subprocess\nimport toml\n\ndef install_black_from_pyproject(pyproject_path: str) -> None:\n    \"\"\"Read tool.black.required-version and install it.\"\"\"\n    data = toml.load(pyproject_path)\n    # VULNERABLE: directly trusts required-version string, allowing arbitrary package spec\n    spec = data[\"tool\"][\"black\"][\"required-version\"]\n    subprocess.run([\"python\", \"-m\", \"pip\", \"install\", spec], check=True)\n","patched_code":"import subprocess\nimport toml\n\ndef install_black_from_pyproject(pyproject_path: str) -> None:\n    \"\"\"Read tool.black.required-version and install it after validation.\"\"\"\n    data = toml.load(pyproject_path)\n    # FIX: validate that required-version is a proper Black version specifier\n    spec = data[\"tool\"][\"black\"][\"required-version\"]\n    if not spec.startswith((\"==\", \">=\", \"<=\", \"~=\", \"!=\")):\n        raise ValueError(\"Invalid Black version specifier\")\n    subprocess.run([\"python\", \"-m\", \"pip\", \"install\", f\"black{spec}\"], check=True)\n","payload_needed":true,"payload":null,"payload_status":"model_refused","published_fix":[{"repository":"psf\/black","commit_url":"https:\/\/github.com\/psf\/black\/commit\/ac1f71563aeccf73cf13ece00f231d9d6c66a514","commit_subject":"Action: validate required-version better (#5510)","units":[{"file":"action\/main.py","function":"read_version_specifier_from_pyproject"}]}],"references":null}