{"id":"CVE-2026-86431","summary":"commonmark before 2.9.1 XSS via AttributesExtension form feed bypass","details":"league/commonmark (thephpleague/commonmark) versions \u003e= 2.7.0 and \u003c 2.9.1 contain a cross-site scripting vulnerability in the AttributesExtension. Prefixing an attribute name with a single U+000C form feed byte (e.g. {\\x0Conclick=\"alert(1)\"}) bypasses the AttributesHelper::filterAttributes() 'on*' event-handler filter because PHP's trim() does not strip U+000C, causing the attribute to be written verbatim into the output where browsers parse it as a genuine event handler. The same prefix also defeats the allow_unsafe_links check, allowing javascript: URIs through href/src attributes even when allow_unsafe_links is false. Exploitation requires processing untrusted Markdown with the AttributesExtension enabled; the injected script executes when the rendered HTML is viewed. Fixed in 2.9.1.","aliases":["GHSA-f8fg-pg57-v4j8"],"modified":"2026-09-17T03:47:31.353438024Z","published":"2026-09-07T12:53:51.246Z","database_specific":{"unresolved_ranges":[{"extracted_events":[{"introduced":"2.7.0"},{"fixed":"2.9.1"}],"source":"AFFECTED_FIELD"},{"extracted_events":[{"introduced":"2.7.0"},{"fixed":"2.9.1"}],"source":"CPE_FIELD"}],"cna_assigner":"VulnCheck","cwe_ids":["CWE-79"],"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/86xxx/CVE-2026-86431.json"},"references":[{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/86xxx/CVE-2026-86431.json"},{"type":"ADVISORY","url":"https://github.com/thephpleague/commonmark/security/advisories/GHSA-f8fg-pg57-v4j8"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-86431"},{"type":"ADVISORY","url":"https://www.vulncheck.com/advisories/commonmark-before-2.9.1-xss-via-attributesextension-form-feed-bypass"},{"type":"FIX","url":"https://github.com/thephpleague/commonmark/commit/43207253ea5f14867c77c697cd3838c446cadcea"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/thephpleague/commonmark","events":[{"introduced":"0"},{"fixed":"43207253ea5f14867c77c697cd3838c446cadcea"}],"database_specific":{"source":"REFERENCES"}}],"versions":["2.6.0","2.5.0","2.4.0","2.3.0","2.2.0","2.1.0","2.0.2","2.0.1","2.0.0","2.0.0-rc2","2.0.0-rc1","2.0.0-beta3","2.0.0-beta2","2.0.0-beta1","0.18.1","0.17.4","0.17.2","0.17.0","0.16.0","0.15.7","0.15.6","0.15.5","0.15.4","0.15.3","0.15.2","0.15.1","0.15.0","0.14.0","0.13.4","0.13.3","0.13.2","0.13.1","0.13.0","0.12.0","0.11.3","0.11.2","0.11.1","0.11.0","0.10.0","0.9.0","0.8.0","0.7.1","0.7.0","0.6.1","0.6.0","0.5.1","0.5.0","0.4.0","0.3.0","0.2.1","0.2.0","0.1.2","0.1.1","0.1.0"],"database_specific":{"source":"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2026-86431.json"}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N"}]}