synced JUST NOW
01 Record

CVE-2024-21503

Versions of the package black before 24.3.0 are vulnerable to Regular Expression Denial of Service (ReDoS) via the lines_with_leading_tabs_expanded function in the strings.py file. An attacker could

MediumPUBLISHEDCNA: snyk
CNA base score5.3 CVSS v3.xCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L/E:P

02 Description

Versions of the package black before 24.3.0 are vulnerable to Regular Expression Denial of Service (ReDoS) via the lines_with_leading_tabs_expanded function in the strings.py file. An attacker could

03 Exploitation and scoring

Exploitation
Public exploit code exists. CISA's assessment records a public proof of concept. That is not a report of exploitation in the wild.
SSVC decision
  • ExploitationpocPublic proof-of-concept exploit code exists. Not a report of exploitation in the wild.
  • AutomatableyesAn attacker can reliably automate reconnaissance through exploitation, so this scales.
  • Technical ImpactpartialSuccessful exploitation gives limited control of the vulnerable component.
CISA publishes the decision points, not a final SSVC decision. The decision also depends on mission and well-being impact, which is a property of your deployment rather than of the vulnerability.
EPSS probability
0.97% probability of exploitation activity in the next 30 days.
EPSS percentile
Equal to or higher than the score of 61.7% of scored records. A rank, not a probability.
NVD base score
5.3 (CVSS v3.x), scored by the NVD independently of the CNA.
NVD CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
NVD analysis status
Deferred. NVD last modified this record on 2026-06-17.
Red Hat severity
Moderate. Red Hat's rating for its own products, not a CVSS rating.

Exploit-prediction scores from FIRST. Independent scoring and analysis status from the NVD. Vendor severity from Red Hat. Exploitation assessment and catalog membership from CISA.

04 Metadata

Published
2024-03-19 05:00Z2 YR AGO
Last updated
2024-08-01 22:20Z2 YR AGO
Reserved
2023-12-22
Assigning CNA
snyk
Record state
PUBLISHED
Severity
Medium (CVSS 5.3)
CNA CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L/E:P
Weaknesses
  • CWE-75Failure to Sanitize Special Elements into a Different Plane (Special Element Injection)Class
  • CWE-1333Inefficient Regular Expression ComplexityBase
Data version
5.1
Document digest
5f7eb2dc0565e9f9c5ce8861b19c7ca27ab9a0f9a95c8030c7965bef787dcfb8

05 Affected products

VendorProductVersionsPlatforms
n/ablack0 to < 24.3.0—
python_software_foundationblack0 to < 24.3.0—

06 References

07 Fixed in

Debian 12

  • black
    No fix yet

Source: Debian Security Tracker, the Debian security team. Received through OSV.dev. Reformatted by exploit.cc.

Debian 13

  • black
    Fixed in 24.4.0-1

Source: Debian Security Tracker, the Debian security team. Received through OSV.dev. Reformatted by exploit.cc.

Debian 14

  • black
    Fixed in 24.4.0-1

Source: Debian Security Tracker, the Debian security team. Received through OSV.dev. Reformatted by exploit.cc.

Ubuntu 20.04 LTS

  • black
    No fix yet

Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.

Ubuntu 22.04 LTS

  • black
    No fix yet

Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.

Ubuntu 24.04 LTS

  • black
    No fix yet

Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.

Ubuntu 25.10

  • black
    No fix yet

Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.

Ubuntu 26.04 LTS

  • black
    No fix yet

Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.

Ubuntu 26.10

  • black
    No fix yet

Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.

A release or ecosystem missing from this list has no record here. It may be unaffected or not covered by the source. Source notices and licences.