Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. undici
  4. ›
  5. CVE-2026-1527

CVE-2026-1527: Undici has CRLF Injection in undici via `upgrade` option

March 13, 2026

When an application passes user-controlled input to the upgrade option of client.request(), an attacker can inject CRLF sequences (\r\n) to:

  1. Inject arbitrary HTTP headers
  2. Terminate the HTTP request prematurely and smuggle raw data to non-HTTP services (Redis, Memcached, Elasticsearch)

The vulnerability exists because undici writes the upgrade value directly to the socket without validating for invalid header characters:

// lib/dispatcher/client-h1.js:1121
if (upgrade) {
header += `connection: upgrade\r\nupgrade: ${upgrade}\r\n`
}

References

  • cna.openjsf.org/security-advisories.html
  • github.com/advisories/GHSA-4992-7rv2-5pvq
  • github.com/nodejs/undici
  • github.com/nodejs/undici/security/advisories/GHSA-4992-7rv2-5pvq
  • hackerone.com/reports/3487198
  • nvd.nist.gov/vuln/detail/CVE-2026-1527

Code Behaviors & Features

Detect and mitigate CVE-2026-1527 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Dependency Scanning using SBOM also detects vulnerabilities from proprietary advisories that this site does not include. Learn more about Dependency Scanning using SBOM →

Affected versions

All versions before 6.24.0, all versions starting from 7.0.0 before 7.24.0

Fixed versions

  • 6.24.0
  • 7.24.0

Solution

Upgrade to versions 6.24.0, 7.24.0 or above.

Impact 4.6 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:N

Learn more about CVSS

Weakness

  • CWE-93: Improper Neutralization of CRLF Sequences ('CRLF Injection')

Source file

npm/undici/CVE-2026-1527.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sun, 08 Nov 2026 00:15:55 +0000.