CVE-2026-0540

Source
https://cve.org/CVERecord?id=CVE-2026-0540
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-0540.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-0540
Aliases
Downstream
Related
Published
2026-03-03T18:16:24.457Z
Modified
2026-03-13T03:57:03.518888Z
Severity
  • 5.1 (Medium) CVSS_V4 - CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X CVSS Calculator
Summary
[none]
Details

DOMPurify 3.1.3 through 3.3.1 and 2.5.3 through 2.5.8, fixed in commit 729097f, contain a cross-site scripting vulnerability that allows attackers to bypass attribute sanitization by exploiting five missing rawtext elements (noscript, xmp, noembed, noframes, iframe) in the SAFEFORXML regex. Attackers can include payloads like </noscript><img src=x onerror=alert(1)> in attribute values to execute JavaScript when sanitized output is placed inside these unprotected rawtext contexts.

References

Affected packages

Git / github.com/cure53/dompurify

Affected ranges

Type
GIT
Repo
https://github.com/cure53/dompurify
Events
Database specific
{
    "versions": [
        {
            "introduced": "2.5.3"
        },
        {
            "last_affected": "2.5.8"
        },
        {
            "introduced": "3.1.3"
        },
        {
            "last_affected": "3.3.1"
        }
    ]
}

Affected versions

2.*
2.5.3
2.5.4
2.5.5
2.5.6
2.5.7
2.5.8
3.*
3.1.3
3.2.3

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-0540.json"