CVE-2026-86429
largeQuadratic Parsing DoS in league/commonmark SmartPunct/Attributes Extensions
The league/commonmark PHP Markdown parsing library (versions >= 1.5.0 and < 2.9.1) contains quadratic parsing complexity (CWE-407) in its SmartPunctExtension and AttributesExtension. The flaw is only triggered when one of these extensions is explicitly registered on a custom Environment — they are not enabled by default and are excluded from the standard CommonMark and GitHub-Flavored Markdown converters — and an unauthenticated attacker who can submit Markdown to such a deployment can trigger it with small crafted documents (e.g., text alternating with unpaired quotes, runs of block-level attribute blocks, or repeated class attributes). The attacker gains a denial of service: disproportionate CPU consumption degrades or stalls the rendering process, with no confidentiality or integrity impact (CVSS 4.0 8.7 High, availability-only). Affected parties are PHP applications and services that use the library in the affected range and have either extension explicitly enabled while accepting untrusted Markdown. There is currently no known exploitation, no public proof-of-concept, no entry in CISA KEV, and a low EPSS score of 0.3%.
What to do: Upgrade league/commonmark to 2.9.1 or later. If upgrading is not immediately possible, remove or unregister the SmartPunct and Attributes extensions from custom Environments, or rate-limit/CPU-limit rendering of untrusted Markdown. Audit composer dependency trees for versions >= 1.5.0 and < 2.9.1 and review Environment configuration for SmartPunctExtension or AttributesExtension usage.
| thephpleague commonmark (league/commonmark) | >= 1.5.0 and < 2.9.1 (fixed in 2.9.1; only exploitable when SmartPunctExtension or AttributesExtension is explicitly registered) |
Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.
The league/commonmark (thephpleague/commonmark) library in versions >= 1.5.0 and < 2.9.1 contains quadratic parsing complexity in its SmartPunctExtension and AttributesExtension. When either extension is explicitly registered on the Environment (they are not enabled by default and are excluded from the standard CommonMark and GitHub-Flavored Markdown converters), an unauthenticated attacker can submit small, specially crafted Markdown documents — such as text alternating with unpaired quotes, contiguous runs of block-level attribute blocks, or repeated class attributes — to trigger disproportionate CPU consumption and cause a denial of service. Fixed in 2.9.1.
- Vendors
- thephpleague
- Products
- commonmark
- Weakness
- CWE-407
- Vector
- CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
In the news0 stories
No ingested article mentions this CVE yet.