Dompurify · Dompurify · CVE-2024-47875
**Name of the Vulnerable Software and Affected Versions**
DOMPurify versions prior to 2.5.0
DOMPurify versions prior to 3.1.3
**Description**
The issue is related to insufficient input validation in the DOMPurify JavaScript library, which can lead to a cross-site scripting (XSS) attack. This vulnerability allows a remote attacker to perform a cross-site scripting attack. DOMPurify is a DOM-only, super-fast, uber-tolerant XSS sanitizer for HTML, MathML, and SVG, and it was vulnerable to nesting-based mXSS.
**Recommendations**
For DOMPurify versions prior to 2.5.0, update to version 2.5.0 or later to fix the vulnerability.
For DOMPurify versions prior to 3.1.3, update to version 3.1.3 or later to fix the vulnerability.
As a temporary workaround, consider restricting the use of the DOMPurify library until a patch is applied.