---
title: "GHSA-qw65-cvwx-89v3: fast-uri vulnerable to authority injection via an unvalidated port in serialize"
description: "High severity. fast-uri vulnerable to authority injection via an unvalidated port in serialize. Affects fast-uri; fixed in 4.1.4."
url: https://inlinr.com/advisories/GHSA-qw65-cvwx-89v3
lang: en
---

[Packages](https://inlinr.com/packages) / [fast-uri](https://inlinr.com/packages/fast-uri) / [Security](https://inlinr.com/packages/fast-uri/security)

High Vulnerability GHSA-qw65-cvwx-89v3 CVE-2026-84292 Published 28 Sep 2026

# fast-uri vulnerable to authority injection via an unvalidated port in serialize

Your version 

Affected releases · [fast-uri](https://inlinr.com/packages/fast-uri)

- 4.x 4.0.0 – 4.1.3 Fixed in 4.1.4
- 3.x 3.0.0 – 3.1.6 Fixed in 3.1.7
- 2.x 2.0.0 – 2.4.5 Fixed in 2.4.6
- 1.x and older 0.0.1 – 1.0.1 No fix, no longer updated

On 4.x, the newest line:

```
npm install fast-uri@4.1.4
```

Every release on a timeline

4.x 

1. Affected

4.0.0 – 4.1.3  
6 releases
2. Fixed

4.1.4 – 4.2.3  
6 releases, latest

3.x 

1. Affected

3.0.0 – 3.1.6  
14 releases
2. Fixed

3.1.7 – 3.1.9  
3 releases

2.x 

1. Affected

2.0.0 – 2.4.5  
11 releases
2. Fixed

2.4.6 – 2.4.8  
3 releases

1.x 

1. Affected

1.0.0 – 1.0.1  
2 releases

0.x 

1. Affected

0.0.1 – 0.0.2  
2 releases

47 stable releases of fast-uri, oldest to newest, one row per major.

## What happens

Impact

`fast-uri` serializes the `port` component of a URI without validating it. When recomposing the authority, `fast-uri` escapes the userinfo and host components but concatenates the port verbatim, so a `port` value that is not a sequence of digits can inject authority delimiters. For example, serializing a component whose `port` is `@127.0.0.1:8124` produces `http://trusted.example:@127.0.0.1:8124/app`, demoting the intended host to userinfo and pointing the authority at an attacker-controlled host. Both `fast-uri` and Node's `URL` read the result back as the attacker's host with no error, so re-validating the built URI does not catch it.

This affects applications that build URIs from parts and assign untrusted data to the `port` component (for example a fixed host from configuration and a port taken from user input or a service record). The same path is reachable through `serialize()`, `normalize()`, and `equal()` in their object forms. A `port` obtained from `parse()` is always digits and is not affected.

Patches

This vulnerability has been patched in fast-uri `4.1.4`, `3.1.7`, and `2.4.6`. `recomposeAuthority` now rejects any port that is not `*DIGIT` per RFC 3986\. All users should upgrade.

Workarounds

If upgrading is not immediately possible, validate the `port` value against the RFC 3986 grammar (digits only) before passing a component to `serialize()`, `normalize()`, or `equal()`, and reject anything else, for example `if (!/^\d*$/.test(String(port))) throw new Error('invalid port')`.

## How it is exploited

Exploitable over the network, with no account and no action from a user.

- **Confidentiality**: none
- **Integrity**: high
- **Availability**: none

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

## References

- [Reference](https://github.com/fastify/fast-uri/security/advisories/GHSA-qw65-cvwx-89v3 "https://github.com/fastify/fast-uri/security/advisories/GHSA-qw65-cvwx-89v3")  
github.com/fastify/fast-uri/security/advisories…
- [NVD](https://nvd.nist.gov/vuln/detail/CVE-2026-84292 "https://nvd.nist.gov/vuln/detail/CVE-2026-84292")  
nvd.nist.gov/vuln/detail/CVE-2026-84292
- [Fix commit](https://github.com/fastify/fast-uri/commit/820e8478dd7da3d09f187bfaf35d50b71f67b8b4 "https://github.com/fastify/fast-uri/commit/820e8478dd7da3d09f187bfaf35d50b71f67b8b4")  
820e847
- [Reference](https://cna.openjsf.org/security-advisories.html "https://cna.openjsf.org/security-advisories.html")  
cna.openjsf.org/security-advisories.html
- [Package](https://github.com/fastify/fast-uri "https://github.com/fastify/fast-uri")  
github.com/fastify/fast-uri
- [Reference](https://github.com/fastify/fast-uri/releases/tag/v2.4.6 "https://github.com/fastify/fast-uri/releases/tag/v2.4.6")  
github.com/fastify/fast-uri/releases/tag/v2.4.6
- [Reference](https://github.com/fastify/fast-uri/releases/tag/v3.1.7 "https://github.com/fastify/fast-uri/releases/tag/v3.1.7")  
github.com/fastify/fast-uri/releases/tag/v3.1.7
- [Reference](https://github.com/fastify/fast-uri/releases/tag/v4.1.4 "https://github.com/fastify/fast-uri/releases/tag/v4.1.4")  
github.com/fastify/fast-uri/releases/tag/v4.1.4

A whole project to check? Paste its package.json in the [dependency check](https://inlinr.com/tools/dependency-check): every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.
