Join the Cyber Forum: Threat Intel on May 12, 2026 to learn how AI is reshaping threat defense.Join the Virtual Cyber Forum: Threat IntelRegister Now
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
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • 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-22150

CVE-2025-22150: Undici HTTP Client Info Disclosure Flaw

CVE-2025-22150 is an information disclosure vulnerability in Undici HTTP/1.1 client affecting multipart/form-data requests. Attackers can predict boundary values to tamper with backend API requests. This article covers technical details, affected versions, impact, and mitigation steps.

Updated: January 22, 2026

CVE-2025-22150 Overview

A vulnerability has been identified in Undici, a popular HTTP/1.1 client for Node.js, where the use of Math.random() for generating multipart/form-data boundaries introduces a security weakness. Since Math.random() produces predictable output when several generated values are known, attackers who can collect boundary values from multipart requests may be able to predict future boundaries. This could allow request tampering against backend APIs if an application sends multipart requests to attacker-controlled servers.

Critical Impact

Attackers can potentially predict multipart form-data boundaries and tamper with HTTP requests to backend APIs, compromising data integrity and confidentiality.

Affected Products

  • Undici versions 4.5.0 through 5.28.4
  • Undici versions 6.0.0 through 6.21.0
  • Undici versions 7.0.0 through 7.2.2

Discovery Timeline

  • 2025-01-21 - CVE CVE-2025-22150 published to NVD
  • 2025-01-21 - Last updated in NVD database

Technical Details for CVE-2025-22150

Vulnerability Analysis

This vulnerability stems from Undici's use of Math.random() for generating boundary strings in multipart/form-data HTTP requests. The JavaScript Math.random() function is not cryptographically secure—it uses a pseudorandom number generator (PRNG) whose internal state can be reconstructed if an attacker observes enough output values.

In scenarios where an application sends multipart requests to external servers (including potentially attacker-controlled endpoints), the boundary values become observable. An attacker collecting multiple boundary strings can reverse-engineer the PRNG state and predict future boundary values. With knowledge of upcoming boundaries, the attacker could craft malicious payloads that exploit the predictable boundary to inject or modify data in requests destined for legitimate backend APIs.

The attack requires specific conditions: the victim application must send multipart requests to attacker-controlled infrastructure, and the attacker must collect sufficient boundary values to predict the PRNG state. Despite these prerequisites, the potential for request tampering affecting data integrity and confidentiality makes this a significant concern for applications using affected Undici versions.

Root Cause

The root cause is classified as CWE-330: Use of Insufficiently Random Values. The vulnerable code in lib/web/fetch/body.js used Math.random() directly for boundary generation, which provides only pseudorandom values unsuitable for security-sensitive operations. Cryptographic contexts require the use of cryptographically secure random number generators (CSPRNGs) such as Node.js's crypto.randomInt().

Attack Vector

The attack vector is network-based and requires user interaction. An attacker must first establish a mechanism to receive multipart requests from the target application—typically by tricking the application or its users into sending requests to attacker-controlled servers. Once boundary values are collected, the attacker analyzes them to predict the PRNG state. With this knowledge, the attacker can predict boundaries in subsequent requests and potentially tamper with legitimate API communications.

The attack complexity is high due to the requirement of collecting multiple random values and successfully predicting the PRNG state, but sophisticated attackers with access to boundary values can execute this attack.

javascript
// Security patch in lib/web/fetch/body.js - Backport of c2d78cd
// Source: https://github.com/nodejs/undici/commit/711e20772764c29f6622ddc937c63b6eefdf07d0

 const { File: UndiciFile } = require('./file')
 const { parseMIMEType, serializeAMimeType } = require('./dataURL')
 
+let random
+try {
+  const crypto = require('node:crypto')
+  random = (max) => crypto.randomInt(0, max)
+} catch {
+  random = (max) => Math.floor(Math.random(max))
+}
+
 let ReadableStream = globalThis.ReadableStream
 
 /** @type {globalThis['File']} */

Detection Methods for CVE-2025-22150

Indicators of Compromise

  • Unusual patterns of multipart/form-data requests from application servers to external or unknown endpoints
  • High volumes of outbound HTTP requests containing multipart boundaries to suspicious destinations
  • Evidence of data exfiltration or request interception in backend API logs

Detection Strategies

  • Audit application dependencies to identify Undici versions between 4.5.0 and the patched releases (5.28.5, 6.21.1, 7.2.3)
  • Monitor network traffic for multipart requests to untrusted or attacker-controlled domains
  • Implement Software Composition Analysis (SCA) tools to flag vulnerable Undici versions in your codebase

Monitoring Recommendations

  • Enable logging for all outbound HTTP requests from Node.js applications, particularly those containing multipart/form-data content
  • Implement egress filtering to restrict applications from making requests to unknown external servers
  • Use application-level monitoring to detect unexpected HTTP client behavior patterns

How to Mitigate CVE-2025-22150

Immediate Actions Required

  • Upgrade Undici to patched versions: 5.28.5, 6.21.1, or 7.2.3 depending on your major version
  • Audit your application to identify any code paths that send multipart requests to external or user-controlled URLs
  • Implement network egress controls to prevent applications from communicating with untrusted servers

Patch Information

The vulnerability has been fixed in Undici versions 5.28.5, 6.21.1, and 7.2.3. The patch replaces the insecure Math.random() call with crypto.randomInt() from Node.js's cryptographic module, ensuring cryptographically secure boundary generation. The fix includes a fallback to Math.random() only in environments where the crypto module is unavailable.

For detailed patch information, see the GitHub Security Advisory and the HackerOne Vulnerability Report.

Workarounds

  • Avoid sending multipart/form-data requests to attacker-controlled or untrusted servers
  • Implement strict URL allowlisting for any outbound HTTP requests from your application
  • Consider implementing a proxy layer that validates and controls outbound request destinations
bash
# Upgrade Undici to patched version
npm update undici

# Or install specific patched versions
npm install undici@5.28.5
npm install undici@6.21.1
npm install undici@7.2.3

# Verify installed version
npm list undici

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

  • Vulnerability Details
  • TypeInformation Disclosure

  • Vendor/TechUndici

  • SeverityMEDIUM

  • CVSS Score6.8

  • EPSS Probability0.13%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N
  • Impact Assessment
  • ConfidentialityHigh
  • IntegrityHigh
  • AvailabilityNone
  • CWE References
  • CWE-330
  • Technical References
  • Security Evaluators Blog Post

  • GitHub Node.js Code Line

  • GitHub Node.js Commit Update

  • GitHub Node.js Commit Changes

  • GitHub Node.js Commit Modification

  • GitHub Security Advisory

  • HackerOne Vulnerability Report
  • Related CVEs
  • CVE-2026-2581: Undici Deduplication DoS Vulnerability

  • CVE-2026-2229: Undici WebSocket Client DoS Vulnerability

  • CVE-2026-1528: undici WebSocket DoS Vulnerability

  • CVE-2026-1527: HTTP Header Injection 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