Advisory

GHSA-v2hh-gcrm-f6hx

Also known as: CVE-2026-16221

Summary

fast-uri vulnerable to host confusion via literal backslash authority delimiter

Details

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.

Severity

High Basis: The source's own band: HIGH

Dates

Published
2026-07-21 22:08 UTC
Modified
2026-09-10 03:51 UTC

Affected packages and fixes

fast-uri

npm · All systems

Affected

  • introduced 2.3.1, fixed 2.4.3 (semver)

Fixed versions

2.4.3

Fix

fast-uri

npm · All systems

Affected

  • introduced 3.0.0, fixed 3.1.4 (semver)

Fixed versions

3.1.4

Fix

fast-uri

npm · All systems

Affected

  • introduced 4.0.0, fixed 4.1.1 (semver)

Fixed versions

4.1.1

Fix

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0

Sources & licences