commonmark 2.0.0 through 2.8.3 Denial of Service via Slug Collision
league/commonmark versions >= 2.0.0 and < 2.8.4 (patched in 2.9.0) contain a denial of service vulnerability in UniqueSlugNormalizer::normalize(), which restarts its numeric-suffix search from 1 on every slug collision, resulting in O(K^2) time complexity for K headings that collapse to the same base slug. The vulnerable path is reached when HeadingPermalinkExtension, FootnoteExtension, or TableOfContentsExtension is registered. An unauthenticated attacker can force many headings onto a single base slug (e.g., via empty ATX headings, identical heading text, or punctuation-only headings) in a small Markdown document, consuming excessive CPU and denying service.
CVE-2026-86434
Primary source · Revision 1
Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.
Security context
Source reference: cve:CVE-2026-86434
commonmark
Source reference: /containers/cna/affected/0/product
- Affected versions
- Not stated in this record
- Fixed versions
- Not stated in this record
- Prerequisites
- Not stated in this record
Structured affected-version data
Original package identities and version rules from this source.
[
{
"vendor": "thephpleague",
"product": "commonmark",
"versions": [
{
"status": "affected",
"version": "2.0.0",
"lessThan": "2.8.4",
"versionType": "semver"
},
{
"status": "unaffected",
"version": "2.8.4",
"versionType": "semver"
}
],
"packageURL": "pkg:composer/league/commonmark",
"defaultStatus": "unaffected"
}
]- Related CVEs
- CVE-2026-86434
Source reference:
/cveMetadata/cveId
Publisher severity
high
Source reference: /containers/cna/metrics
- Event
- #12951 · Revision 1
- Added to Heist Feed
- Publisher date