BuzzPHP
LightDarkSystem

league/commonmark: Denial of service via distinctly-named attributes in the Attributes extension

High severity. Published 1 September 2026. Update league/commonmark to 2.10.0 or later: composer update league/commonmark.

Which versions are affected?

PackageAffected versionsFixed in
league/commonmark (opens in a new tab)>= 1.5.0, < 2.10.02.10.0

What should you do?

Update every affected package you use to its fixed version, then check that nothing else in your project matches an advisory. To see which version you run, and whether anything is still affected:

composer show league/commonmark
composer audit

Advisory details

SeverityHighCVSS 7.5
Published
Updated
GHSAGHSA-8rr7-cvq3-gmfh (opens in a new tab)
WeaknessCWE-407, CWE-1050

What the advisory says

Impact

AttributesExtension ships with the library but must be explicitly registered on the Environment; it is not included in CommonMarkConverter, GithubFlavoredMarkdownConverter, or GithubFlavoredMarkdownExtension. Applications that do not register AttributesExtension are not affected by this advisory.

Two paths in the extension re-process every attribute a node has already collected each time another attribute is applied to it. When the attributes carry distinct names, the collected set grows by one on every step and is walked again in full, so a run of n attributes costs O(n²).

1. Attribute nodes resolving to a common target (affected from 1.5.0).

Source: GHSA-8rr7-cvq3-gmfh (opens in a new tab) in the GitHub Advisory Database (CC BY 4.0). Data from GitHub (opens in a new tab) as of .

Other recent advisories for this package

All Composer security advisories