Skip to main content

league/commonmark CVE-2026-86435

| EUVDEUVD-2026-72393 HIGH
Inefficient Algorithmic Complexity (CWE-407)
2026-09-07 VulnCheck GHSA-2cmp-7fm4-4v9w
8.7
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Send ~10 KB crafted Markdown via HTTP
  2. Delivery
    FootnoteExtension processes duplicate definitions without dedup
  3. Exploit
    O(N²) FootnoteBackref nodes allocated
  4. Execution
    ~440 MB memory consumed in PHP worker
  5. Persist
    PHP-FPM worker OOM-killed
  6. Impact
    Denial of service

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V2 - Validation and Business Logic Algorithmic complexity limits
Exploitation Conditions

The FootnoteExtension must be registered on the league/commonmark Environment - this is opt-in configuration but is described by the vendor as a commonly enabled GFM-style feature, making it present in a significant fraction of real deployments. No authentication is required; the attack is triggered by the content of the Markdown document alone. No non-default PHP configuration is needed beyond the FootnoteExtension being active. The amplification is deterministic: any document with duplicate [^label]: definition blocks combined with repeated references to the same label triggers the O(N²) behavior. Exploitation is limited to availability - no confidentiality or integrity impact is possible via this vector. Deployments that parse only trusted content (e.g., CMS editors used by authenticated authors) face negligible real-world risk despite the zero-privilege CVSS vector.

Impact

The CVSS 4.0 score of 8.7 (AV:N/AC:L/AT:N/PR:N/UI:N/VA:H) is well-calibrated: the attack is network-reachable, requires zero authentication or user interaction, and produces high availability impact. The EPSS score is not provided in the source data. KEV status is negative and no public exploit code has been identified, meaning exploitation probability from opportunistic actors is currently lower than the severity score implies - however, the attack is conceptually trivial: an attacker needs only to construct a Markdown document with repeated footnote definitions. The critical limiting factor is that the FootnoteExtension must be registered on the commonmark Environment; this is opt-in but described by the vendor as a commonly enabled GFM-style feature. The amplification ratio (~10 KB → ~440 MB peak memory) is severe enough to constitute a practical single-request OOM attack against a default PHP-FPM worker configuration. No confidentiality or integrity impact is present. Real-world risk is medium-to-high for applications that accept arbitrary Markdown from untrusted users with the Footnote extension enabled; negligible for deployments that parse only trusted author-controlled content.

Exploit ScenarioDerived

An attacker submitting Markdown to a public forum, comment system, or documentation platform built on league/commonmark with the FootnoteExtension enabled sends a single ~10 KB POST body containing a footnote label referenced and defined N times (e.g., 150 references and 150 duplicate definitions of [^a]:). The server's commonmark renderer generates 22,500 FootnoteBackref nodes, consuming ~440 MB of memory and ~3 seconds of CPU, OOM-killing the PHP-FPM worker and returning a 500 error. Repeating the request across a pool of workers can take down the entire application with minimal attacker bandwidth.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Sep 07, 2026

Quadratic-blowup denial of service in league/commonmark's Footnote extension allows remote unauthenticated attackers to exhaust PHP server resources by crafting documents with duplicate footnote definitions. The GatherFootnotesListener and NumberFootnotesListener classes append the full backref list for every duplicate definition without deduplication, producing O(N²) FootnoteBackref nodes - a ~10 KB crafted document expands into ~62 MB of HTML output, ~440 MB of peak memory, and ~3 seconds of CPU time, sufficient to OOM-kill a default 128 MB PHP worker. All library releases from 1.5.0 (May 2020) through 2.8.x are affected; no public exploit identified at time of analysis, but the amplification ratio is deterministic and trivially reproducible.

RemediationAI

Upgrade to league/commonmark 2.9.0 or later via Composer (composer require league/commonmark:^2.9.0); the fix is delivered in commit 66028124a17ba193da7b11cc3dfda92df21bfbf4 referenced in GHSA-jfm3-95jq-q3rf. No in-library configuration switch caps footnote processing, so there is no safe non-upgrade workaround within the library itself. For integrators unable to upgrade immediately, the vendor recommends either (a) removing FootnoteExtension from the registered Environment for any pipeline that processes untrusted input - this eliminates the vulnerable code path entirely with no functional trade-off if footnotes are non-essential - or (b) enforcing an aggressive input-size cap before conversion; the vendor explicitly warns this is a weak control because the ~10 KB blowup payload is well within typical HTTP body limits and any effective cap must be extremely small (sub-kilobyte), which will break legitimate large documents. Upgrading to 2.9.0 is the only reliable remediation.

Affected VersionsENISA

commonmark 1.5.0 <2.8.4

Affected Packages

euvd commonmark fix: 2.8.4

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

league/commonmark (cpe:2.3:a:thephpleague:commonmark) is a PHP CommonMark specification-compliant Markdown parser maintained by The PHP League and widely used in Laravel and similar PHP frameworks. The Footnote extension - introduced in 1.5.0 - registers GatherFootnotesListener and NumberFootnotesListener to collect backref nodes for rendered footnote links. The root cause (CWE-407: Inefficient Algorithmic Complexity) is that neither listener deduplicates footnote label definitions: for a document supplying N copies of [^label]: definitions and N references to that label, the library generates N × N FootnoteBackref nodes rather than N, making output size, parse time, and peak memory all O(N²). This is a pure algorithmic amplification with no input-validation bypass required - the blowup is intrinsic to the data structure construction logic.

Know when Commonmark gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 8.7 HIGH
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
vuln.today AI 7.5 HIGH

Network-reachable with no auth or interaction; scope unchanged (single PHP worker); availability-only impact via OOM exhaustion.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch available
Sep 07, 2026 - 14:02 EUVD
CVE Published
Sep 07, 2026 - 12:53 cve.org
HIGH 8.7

DescriptionCVE.org

commonmark versions from 1.5.0 before 2.8.4 contain a denial of service vulnerability in the Footnote extension that fails to deduplicate footnote definitions. Attackers can craft documents with duplicate footnote definitions and references to create quadratic output expansion, consuming excessive memory and CPU to exhaust server resources.

Technical POC Analysis

CWE-407: inefficient algorithmic complexity; a quadratic amplification in league/commonmark's Footnote extension.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

Organizations using the PHP library league/commonmark for markdown rendering (versions 1.5.0-2.8.x with Footnote extension enabled) are at risk of unexpected service disruptions. Remote unauthenticated attackers can craft specially crafted documents to exhaust server memory and CPU with minimal computational effort, triggering denial-of-service that could block legitimate users. No public exploit identified at time of analysis, but the vulnerability is deterministic and trivially reproducible, presenting material risk to customer-facing applications with no vendor patch currently available.

Business Impact: High
Compensating Controls

No vendor-released patch identified at time of analysis. Interim mitigations: (1) disable the Footnote extension if not operationally required; (2) implement input validation to detect and reject documents with duplicate footnote definitions exceeding safe thresholds; (3) enforce per-request memory limits via PHP memory_limit or container resource caps and execution timeouts; (4) implement rate limiting on endpoints accepting user-supplied markdown; (5) consider architectural isolation with a separate markdown processing service running with resource quotas to prevent cascade failure.

Threat Intelligence Overview

EPSS Score
0.3%
Top 80% exploitable
Prevalence
High
popular PHP Markdown library, core dependency of Laravel and many frameworks
Social Media
1
Sightings
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

44
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +44
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

CVE-2019-10010 MEDIUM POC
6.1 Mar 24

Cross-site scripting (XSS) vulnerability in the PHP League CommonMark library before 0.18.3 allows remote attackers to i

CVE-2018-20583 MEDIUM POC
6.1 Dec 30

Cross-site scripting (XSS) vulnerability in the PHP League CommonMark library versions 0.15.6 through 0.18.x before 0.18

CVE-2026-86434 HIGH
8.7 Sep 07

Quadratic CPU exhaustion in league/commonmark 2.0.0-2.8.3 allows unauthenticated remote attackers to deny service by sub

CVE-2026-86433 HIGH
8.7 Sep 07

Quadratic-time algorithmic complexity in league/commonmark's Attributes extension exposes PHP applications to remote den

CVE-2026-86429 HIGH
8.7 Sep 07

Quadratic parsing complexity in league/commonmark (thephpleague/commonmark, versions ≥1.5.0 and <2.9.1) allows unauthent

CVE-2026-86430 HIGH
8.7 Sep 07

Three independent super-linear parsing paths in league/commonmark before 2.9.1 allow unauthenticated remote attackers to

CVE-2026-86428 HIGH
8.7 Sep 07

Quadratic CPU exhaustion in league/commonmark's optional AttributesExtension (versions 1.5.0 through 2.9.2) allows unaut

CVE-2026-105830 HIGH
8.7 Oct 08

Quadratic-time denial of service in league/commonmark 2.0.0 through 2.10.1 lets unauthenticated remote attackers exhaust

CVE-2026-86432 MEDIUM
6.9 Sep 07

Quadratic memory and output amplification in league/commonmark's XmlRenderer affects all 2.x releases from 2.0.0 through

CVE-2026-86431 MEDIUM
6.9 Sep 07

Cross-site scripting in league/commonmark 2.7.0-2.9.0 allows unauthenticated attackers to inject arbitrary JavaScript in

CVE-2026-30838 MEDIUM
6.1 Mar 07

The DisallowedRawHtml extension in PHP Commonmark (league/commonmark) versions prior to 2.8.1 can be bypassed by injecti

CVE-2026-105829 MEDIUM
5.3 Oct 08

Stored cross-site scripting in league/commonmark from 1.3.0 through 2.10.1 lets any user who can post Markdown bypass th

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy