VDB

CVE-2026-30838

CVE-2026-30838 PUBLISHED CVSS 5.1 MEDIUM

league/commonmark: DisallowedRawHtml extension bypass via whitespace in HTML tag names

Reported by github_m · Published March 7, 2026

league/commonmark is fixed in 2.8.1 (Packagist)

league/commonmark is a PHP Markdown parser. Prior to version 2.8.1, the DisallowedRawHtml extension can be bypassed by inserting a newline, tab, or other ASCII whitespace character between a disallowed HTML tag name and the closing >. For example, <script\n> would pass through unfiltered and be rendered as a valid HTML tag by browsers. This is a cross-site scripting (XSS) vector for any application that relies on this extension to sanitize untrusted user input. All applications using the DisallowedRawHtml extension to process untrusted markdown are affected. Applications that use a dedicated HTML sanitizer (such as HTML Purifier) on the rendered output are not affected. This issue has been patched in version 2.8.1.

Fixed versions

Upgrade to a fixed version or later. Language registries are listed first, then Linux distributions, then vendor products.

PackageEcosystemFixed in
league/commonmarkPackagist2.8.1

Risk scores

CVSS 4.0
5.1
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:N/VI:L/VA:N/SC:L/SI:L/SA:N

Affected products

VendorProductVersions
thephpleaguecommonmark< 2.8.1
thephpleaguecommonmark0
leaguecommonmark2.0.0

Timeline

  • Mar 6, 2026 CVE Published
  • Mar 7, 2026 PoC Published (2 in total, the first dated here)
  • Mar 8, 2026 EPSS Score (30 in total, the first dated here)
  • Mar 9, 2026 CVE Updated
  • Mar 17, 2026 Coalition ESS Score (2 in total, the first dated here)
  • Mar 23, 2026 Security Advisory

Query this with the API

The same record, from the CLI:

vulnetix vdb vuln CVE-2026-30838
vulnetix vdb fixes CVE-2026-30838

Or with curl, using the org id and key from your account page:

curl -s -H "Authorization: ApiKey ${VULNETIX_ORG_ID}:${VULNETIX_API_KEY}" \
  "https://api.vdb.vulnetix.com/v2/vuln/CVE-2026-30838/fixes/registry"

The Community plan is free and allows 50 queries a day. Get a free API key · API quickstart

Look up in the Resolve Platform →
$ Lookup Community · 50/day Open Lookup ›