Origin Validation Error Affecting undici package, versions >=7.0.0 <7.30.4>=8.0.0 <8.14.1


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-JS-UNDICI-23775816
  • published5 Dec 2026
  • disclosed5 Dec 2026
  • creditAndrew Stellman

Introduced: 5 Dec 2026

NewCVE-2026-139823  (opens in a new tab)
CWE-346  (opens in a new tab)

How to fix?

Upgrade undici to version 7.30.4, 8.14.1 or higher.

Overview

undici is an An HTTP/1.1 client, written from scratch for Node.js

Affected versions of this package are vulnerable to Origin Validation Error via the cache interceptor (interceptors.cache()), which builds its cache key from the request's origin, method, and path, but forwards an explicit Host header to the server as the target authority. When an application sends requests for multiple virtual hosts to a single origin by varying the Host header, a cacheable response for one host is stored under the shared origin key and served to a subsequent request for a different host without that request reaching the server. This can disclose one host's response to callers of another, and allows a caller who controls the Host header to influence the cached response that other requests to the same origin and path receive.

Note: This is only exploitable when the cache interceptor is in use and requests are sent with a Host header naming a different authority than the request origin; responses that include a Vary: Host header are not affected.

Workaround

Do not compose interceptors.cache() on dispatchers that send requests with an explicit Host header for a different host, use a separate dispatcher and cache store per host, or have the server send Vary: Host on responses that differ by host.

CVSS Base Scores

version 4.0
version 3.1