Skip to main content
VulnerabilityPublished Updated

CVE-2026-40347: Semgrep · python-multipart affected by Denial of Service via large multipart preamble or epilogue data

Affects semgrepSource GCVE Database

0
Compare
Authoritative record:CVE-2026-40347· Medium 5.3

Not known to be exploited · CVSS 5.3 Medium : upgrade to 1.165.0 or 1.159.0 when convenient.

Data as of 19 Nov 2026, 19:38 UTC

CVSS 3.1 base score
5.3Medium
How severe the flaw is on the 0–10 CVSS scale.
Patch
Available – fixed in 1.165.0, 1.159.0
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L

Exploitation evidence

  1. Disclosed: evidence found.

    CVE published 17 Apr 2026

  2. Detectable: no evidence on record.

    No public nuclei template indexed

  3. Weaponized: no evidence on record.

    No public exploit code indexed in Metasploit or Exploit-DB

  4. Exploited in the wild: no evidence on record.

    Not in CISA KEV and no source reports exploitation

  5. Observed by OffSeq Mirage: no evidence on record.

    No attack traffic recorded by OffSeq Mirage sensors

A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 18 Nov 2026.

What to do

Upgrade semgrep to 1.165.0 or 1.159.0.

Affected software

ProductAffectedFixed in
Homebrewsemgreppkg:brew/semgrepOther threatsAffected
  • >=1.137.0 <1.159.0
  • >=1.164.0 <1.165.0
Fixed in
  • 1.159.0
  • 1.165.0

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

AI-suggested

Upgrade semgrep to version 1.159.0 or later (including 1.165.0 and beyond), which includes fixes that optimize parsing by skipping ahead when processing leading CR/LF data and immediately discarding epilogue data after the closing boundary. Applying these updates mitigates the denial of service risk.

Description

A denial of service vulnerability in python-multipart affects semgrep when parsing crafted multipart/form-data requests with large preamble or epilogue sections. The parser inefficiently handles leading CR/LF bytes before the first boundary and processes trailing epilogue data after the closing boundary, causing excessive CPU consumption. This can degrade availability by delaying legitimate requests but does not typically cause a complete denial of service. The issue is fixed in semgrep versions 1.159.0 and 1.165.0 and later.

References

Community reviews

Loading reviews…