A Leader in the 2025 Gartner® Magic Quadrant™ for Endpoint Protection Platforms. Five years running.A Leader in the Gartner® Magic Quadrant™Read the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI Security Portfolio
      Leading the Way in AI-Powered Security Solutions
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly ingest data from on-prem, cloud or hybrid environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Identity Security
    • Singularity Identity
      Identity Threat Detection and Response
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-class Expertise and Threat Intelligence.
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      Digital Forensics, IRR & Breach Readiness
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive solutions for seamless security operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • Partner Locator
      Your go-to source for our top partners in your region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2024-45801

CVE-2024-45801: DOMPurify XSS Bypass Vulnerability

CVE-2024-45801 is an XSS bypass vulnerability in Cure53 DOMPurify that allows malicious HTML to evade depth checking through nesting techniques and Prototype Pollution. This article covers technical details, affected versions, and patches.

Published: January 28, 2026

CVE-2024-45801 Overview

CVE-2024-45801 is a Cross-Site Scripting (XSS) sanitizer bypass vulnerability affecting DOMPurify, a widely-used DOM-only, high-performance XSS sanitizer library for HTML, MathML, and SVG content. The vulnerability enables attackers to bypass DOMPurify's depth checking mechanism through specially crafted malicious HTML using advanced nesting techniques. Additionally, the flaw can be exploited via Prototype Pollution to weaken the depth check, rendering the sanitizer ineffective against XSS attacks.

DOMPurify is extensively used in web applications to sanitize user-supplied HTML content before rendering, making this bypass vulnerability particularly concerning for applications relying on it as a primary defense against XSS attacks.

Critical Impact

Attackers can inject and execute arbitrary JavaScript code in victims' browsers by bypassing DOMPurify's sanitization, potentially leading to session hijacking, credential theft, and malicious actions performed on behalf of authenticated users.

Affected Products

  • Cure53 DOMPurify versions prior to 2.5.4
  • Cure53 DOMPurify versions prior to 3.1.3

Discovery Timeline

  • 2024-09-16 - CVE-2024-45801 published to NVD
  • 2025-09-22 - Last updated in NVD database

Technical Details for CVE-2024-45801

Vulnerability Analysis

This vulnerability exploits weaknesses in DOMPurify's depth tracking mechanism, which was implemented to prevent deeply nested HTML structures that could potentially bypass sanitization. The attack leverages two distinct techniques: special HTML nesting patterns that evade the depth checker, and Prototype Pollution to manipulate the depth checking logic itself.

The vulnerability falls under CWE-1333 (Inefficient Regular Expression Complexity) and CWE-1321 (Improperly Controlled Modification of Object Prototype Attributes). When successfully exploited, malicious HTML content passes through the sanitizer unaltered, enabling the execution of arbitrary JavaScript in the context of the vulnerable application.

The network-accessible nature of this vulnerability means any web application using affected DOMPurify versions to sanitize user-controlled HTML input is potentially vulnerable. User interaction is required for exploitation, typically involving a victim viewing a page containing attacker-supplied content that has been "sanitized" by the vulnerable DOMPurify instance.

Root Cause

The root cause lies in the insufficient hardening of DOMPurify's depth tracking code against Prototype Pollution attacks. The depth checking mechanism could be manipulated through JavaScript's prototype chain, allowing attackers to influence the sanitization logic. Additionally, the nesting depth validation had gaps that could be exploited through carefully constructed HTML structures.

The vulnerability specifically relates to how numeric values were validated in the depth checking code. The Number.isNaN function was not properly protected (unapplied) against prototype pollution, allowing attackers to potentially manipulate the behavior of numeric checks used in depth validation.

Attack Vector

The attack vector is network-based and requires user interaction. An attacker crafts malicious HTML that exploits either the nesting technique bypass or Prototype Pollution weakness:

  1. Nesting Technique Bypass: The attacker creates deeply nested HTML structures using specific element combinations that evade the depth checker while still containing executable JavaScript payloads.

  2. Prototype Pollution Attack: The attacker first pollutes JavaScript prototypes (e.g., through gadgets in the application or via other vulnerabilities) to weaken the depth check validation, then submits malicious HTML that would normally be caught by a functioning depth checker.

The patched code hardens the depth tracking by wrapping Number.isNaN with the unapply function to prevent prototype pollution from affecting its behavior:

javascript
// Security patch - Hardening depth tracking against prototype pollution
const objectHasOwnProperty = unapply(Object.prototype.hasOwnProperty);
const regExpTest = unapply(RegExp.prototype.test);
const typeErrorCreate = unconstruct(TypeError);
+const numberIsNaN = unapply(Number.isNaN);

/**
 * Creates a new function that calls the given function with a specified thisArg and arguments.

Source: DOMPurify Security Commit

The fix was also merged into the 2.x branch:

javascript
// Security patch for 2.x branch
var stringTrim = unapply(String.prototype.trim);
var regExpTest = unapply(RegExp.prototype.test);
var typeErrorCreate = unconstruct(TypeError);
+var numberIsNaN = unapply(Number.isNaN);
function unapply(func) {
  return function (thisArg) {
    for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {

Source: DOMPurify 2.x Security Commit

Detection Methods for CVE-2024-45801

Indicators of Compromise

  • Unusual JavaScript execution events following user-submitted HTML content rendering
  • Web application firewall (WAF) logs showing deeply nested HTML structures or prototype pollution patterns
  • Client-side errors related to unexpected DOM modifications or script execution
  • Reports of suspicious behavior from users after interacting with user-generated content

Detection Strategies

  • Implement Content Security Policy (CSP) headers with strict script-src directives to detect and block unauthorized script execution
  • Monitor application logs for patterns indicative of XSS attempts, including unusual HTML structures with excessive nesting
  • Deploy client-side monitoring to detect prototype pollution attempts targeting built-in JavaScript objects
  • Use SentinelOne Singularity XDR to identify anomalous browser behavior and potential XSS exploitation patterns

Monitoring Recommendations

  • Enable verbose logging for content sanitization operations to track potential bypass attempts
  • Monitor for client-side JavaScript errors that may indicate exploitation attempts or DOM manipulation
  • Implement real-time alerting for CSP violation reports indicating blocked script execution
  • Track DOMPurify version deployments across your application portfolio using software composition analysis (SCA) tools

How to Mitigate CVE-2024-45801

Immediate Actions Required

  • Upgrade DOMPurify to version 2.5.4 or later for the 2.x branch, or version 3.1.3 or later for the 3.x branch
  • Audit all applications using DOMPurify and prioritize updates for internet-facing applications that process user-submitted HTML
  • Implement additional defense-in-depth measures such as strict Content Security Policy headers
  • Review application code for potential Prototype Pollution vulnerabilities that could compound this issue

Patch Information

Cure53 has released security patches addressing this vulnerability in DOMPurify versions 2.5.4 and 3.1.3. The patches harden the depth tracking code against prototype pollution by using the unapply pattern on Number.isNaN and other critical functions.

The security commits are available for review:

  • Version 3.x patch
  • Version 2.x patch

For detailed information about this vulnerability, see the GitHub Security Advisory.

Workarounds

  • There are no known workarounds for this vulnerability; upgrading to a patched version is the only remediation
  • As a temporary defense-in-depth measure, implement strict Content Security Policy headers to limit script execution
  • Consider server-side HTML sanitization as an additional layer while planning the upgrade
  • Limit or disable user-submitted HTML features until the patch can be deployed
bash
# Update DOMPurify via npm
npm update dompurify@latest

# Or install specific patched versions
npm install [email protected]  # For 3.x users
npm install [email protected]  # For 2.x users

# Verify installed version
npm list dompurify

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeXSS

  • Vendor/TechDompurify

  • SeverityMEDIUM

  • CVSS Score6.1

  • EPSS Probability0.06%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityLow
  • AvailabilityNone
  • CWE References
  • CWE-1333

  • CWE-1321
  • Technical References
  • GitHub Security Advisory
  • Vendor Resources
  • GitHub Commit Update

  • GitHub Commit Update
  • Related CVEs
  • CVE-2025-26791

  • CVE-2024-47875
Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • English
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use