The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • 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
    • Singularity Identity
      Identity Threat Detection and Response
    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
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • 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
      DFIR, Breach Readiness, & Compromise Assessments
    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
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • 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-2025-22872

CVE-2025-22872: HTML Tokenizer XSS Vulnerability

CVE-2025-22872 is an XSS flaw in HTML tokenizer where unquoted attribute values ending with solidus are misinterpreted as self-closing tags. This article covers technical details, affected versions, impact, and mitigation.

Updated: January 22, 2026

CVE-2025-22872 Overview

CVE-2025-22872 is an Input Validation Error vulnerability in the Go golang.org/x/net/html tokenizer package. The tokenizer incorrectly interprets tags with unquoted attribute values that end with a solidus character (/) as self-closing. This parsing inconsistency affects both direct Tokenizer usage and the Parse functions, potentially leading to DOM construction errors where content is placed in the wrong scope, particularly when processing foreign content within <math> or <svg> contexts.

Critical Impact

Applications using the Go HTML tokenizer to process untrusted HTML content containing foreign elements may experience incorrect DOM tree construction, potentially enabling XSS attacks or content injection in security-sensitive parsing scenarios.

Affected Products

  • Go golang.org/x/net/html package (versions prior to the security patch)
  • Applications using the Go HTML tokenizer for parsing untrusted content
  • Systems with NetApp products utilizing affected Go components

Discovery Timeline

  • April 16, 2025 - CVE-2025-22872 published to NVD
  • May 16, 2025 - Last updated in NVD database

Technical Details for CVE-2025-22872

Vulnerability Analysis

This vulnerability stems from a parsing ambiguity in how the Go HTML tokenizer handles attribute values. When an HTML tag contains an unquoted attribute value that ends with a forward slash (/), the tokenizer misinterprets the trailing slash as indicating a self-closing tag rather than being part of the attribute value itself.

This behavior creates a deviation from the HTML5 parsing specification. The impact is twofold: when using the Tokenizer directly, affected tags are incorrectly flagged as self-closing; when using the higher-level Parse functions, the DOM tree construction becomes corrupted. The vulnerability is particularly pronounced when parsing foreign content namespaces such as SVG and MathML, where self-closing tag semantics differ from standard HTML.

The attack requires network access and involves high complexity, as exploitation depends on specific HTML structures being processed through the vulnerable tokenizer in a security-sensitive context.

Root Cause

The root cause lies in the tokenizer's attribute parsing logic, which fails to correctly distinguish between a solidus character that is part of an unquoted attribute value versus one that indicates a self-closing tag. The HTML5 specification has specific rules for handling unquoted attribute values, and this implementation does not correctly account for all edge cases involving the solidus character.

Attack Vector

The attack vector is network-based, requiring an attacker to supply maliciously crafted HTML content to an application using the vulnerable tokenizer. The crafted HTML would include tags with unquoted attribute values ending in / within foreign content contexts like SVG or MathML. When this content is parsed, the incorrect DOM construction could allow attacker-controlled content to escape its intended scope, potentially leading to Cross-Site Scripting (XSS) if the parsed output is rendered in a browser context.

For example, content that should be contained within an SVG element might be placed outside of it due to the parsing error, allowing HTML content to execute in unexpected contexts.

Detection Methods for CVE-2025-22872

Indicators of Compromise

  • Unexpected HTML content appearing outside of <svg> or <math> elements in rendered pages
  • Application logs showing parsing anomalies or DOM construction warnings
  • User reports of visual rendering inconsistencies in pages containing SVG or MathML content

Detection Strategies

  • Review application dependencies for the golang.org/x/net/html package and verify the installed version
  • Implement automated scanning for Go module dependencies using go list -m all to identify vulnerable versions
  • Monitor Content Security Policy (CSP) violation reports that may indicate XSS attempts exploiting this vulnerability
  • Audit code paths that process untrusted HTML input, particularly those handling SVG or MathML content

Monitoring Recommendations

  • Enable detailed logging for HTML parsing operations in production environments
  • Implement input validation metrics to track malformed HTML patterns being submitted to your applications
  • Set up alerts for anomalous parsing behavior or increased error rates in HTML processing pipelines

How to Mitigate CVE-2025-22872

Immediate Actions Required

  • Update the golang.org/x/net/html package to the latest patched version immediately
  • Audit all applications using the Go HTML tokenizer for potential exposure to untrusted HTML input
  • Implement additional input sanitization for HTML content containing foreign elements
  • Consider using Content Security Policy headers to mitigate potential XSS exploitation

Patch Information

The Go security team has released a fix for this vulnerability. The patch is available through the standard Go module update process. For detailed information about the fix, refer to the Go.dev Change Log Entry and the Go.dev Vulnerability Report. NetApp has also published a security advisory for affected products.

To update to the patched version, run:

bash
go get -u golang.org/x/net/html

Workarounds

  • Sanitize or reject HTML input containing unquoted attribute values with trailing solidus characters before processing
  • Avoid processing untrusted HTML content containing <svg> or <math> foreign elements until the patch is applied
  • Implement output encoding and Content Security Policy headers to reduce XSS impact if exploitation occurs
  • Consider using alternative HTML parsing libraries with independent implementations as a temporary measure
bash
# Update Go dependencies to latest patched versions
go get -u golang.org/x/net@latest
go mod tidy
go mod verify

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

  • Vulnerability Details
  • TypeXSS

  • Vendor/TechN/A

  • SeverityMEDIUM

  • CVSS Score6.5

  • EPSS Probability0.03%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:L/A:L
  • Impact Assessment
  • ConfidentialityHigh
  • IntegrityNone
  • AvailabilityLow
  • Technical References
  • Go.dev Change Log Entry

  • Go.dev Issue Tracker Update

  • Google Group Announcement

  • Go.dev Vulnerability Report

  • NetApp Security Advisory
  • Latest CVEs
  • CVE-2025-70797: LimeSurvey XSS Vulnerability

  • CVE-2025-30650: Juniper Junos OS Auth Bypass Vulnerability

  • CVE-2026-35471: Goshs Path Traversal Vulnerability

  • CVE-2026-35393: Goshs Path Traversal Vulnerability
Default Legacy - Prefooter | 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
  • 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

English