GitHub Advisoryadvisory · npm

GHSA-v2hh-gcrm-f6hx fast-uri vulnerable to host confusion via literal backslash authority delimiter

HIGH Published 2026-07-21 Modified 2026-07-21 Official page ↗
Aliases
CVE-2026-16221
Ecosystem
npm
Packages
fast-uri
Severity
High
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
Weaknesses
CWE-436
Reviewed
2026-07-21

Affected packages

• npm fast-uri: >= 2.3.1, < 2.4.3 → fixed in 2.4.3 • npm fast-uri: >= 3.0.0, < 3.1.4 → fixed in 3.1.4 • npm fast-uri: >= 4.0.0, < 4.1.1 → fixed in 4.1.1

Description

Impact `fast-uri` v4.1.0 and earlier do not treat a literal backslash (U+005C) as an authority delimiter. Node's native WHATWG `URL` (used by `fetch()`, `undici`, and Node's `http`/`https` clients) normalizes `\` to `/` for special schemes (`http`, `https`, `ws`, `wss`, `ftp`, `file`), so the two parsers extract different hosts from the same input string. For example, `http://evil.com\@allowed.com` is treated by `fast-uri` as host `allowed.com` with userinfo `evil.com\`, while Node's WHATWG URL parser and `fetch()` see host `evil.com` with path `/@allowed.com`. Applications that use `fast-uri` to enforce host-based policy (allowlists, denylists, loopback/SSRF filtering, redirect validation, outbound proxy routing) before passing the same URL into Node's URL or `fetch()` consumers see a policy/use desync and can be steered to an unintended destination, including cloud metadata endpoints, loopback, or internal hosts. Patches Upgrade to `fast-uri` v4.1.1, v3.1.4, or v2.4.3. Workarounds None. Upgrade to the patched version.

Related

Alias · CVE (1)

  • CVE-2026-16221 Impact: fast-uri versions from 2.3.1 through 4.1.0 (including the 3.x line up to 3.1.3 and the 2.x line up to 2.4.2) do not treat a literal… vulnerability

Weakness · CWE (1)

  • CWE-436 Interpretation Conflict weakness

References