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

CVE-2026-11525: undici vulnerable to Set-Cookie SameSite attribute downgrade via permissive substring matching

June 19, 2026

When undici parses a Set-Cookie header, it accepts any SameSite attribute value that contains Strict, Lax, or None as a substring, rather than the case-insensitive exact match specified by RFC 6265. Non-spec values are silently mapped to one of the three standard tokens:

  • SameSite=NoneOfYourBusiness is parsed as None, the most permissive setting.
  • SameSite=StrictLax is parsed as Lax, a downgrade from Strict.

Affected applications are those that consume Set-Cookie headers from server responses (for example via undici’s fetch or proxy code paths) and then forward or rely on the parsed sameSite attribute. A malicious or non-compliant server can coerce the consumer’s view of a cookie’s SameSite policy to a weaker value, silently degrading the SameSite enforcement the cookie is supposed to provide.

This was introduced in undici 5.15.0 when the cookies feature was added.

References

  • cna.openjsf.org/security-advisories.html
  • github.com/advisories/GHSA-g8m3-5g58-fq7m
  • github.com/nodejs/undici/security/advisories/GHSA-g8m3-5g58-fq7m
  • nvd.nist.gov/vuln/detail/CVE-2026-11525

Code Behaviors & Features

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

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 6.27.0, all versions starting from 7.0.0 before 7.28.0, all versions starting from 8.0.0 before 8.5.0

Fixed versions

  • 6.27.0
  • 7.28.0
  • 8.5.0

Solution

Upgrade to versions 6.27.0, 7.28.0, 8.5.0 or above.

Impact 3.7 LOW

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

Learn more about CVSS

Weakness

  • CWE-183: Permissive List of Allowed Inputs

Source file

npm/undici/CVE-2026-11525.yml

Spotted a mistake? Edit the file on GitLab.

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

Page generated Sat, 20 Jun 2026 12:17:17 +0000.