All reports
Medium

@fastify/static vulnerable to Authorization Bypass via Non-Canonical URL Paths

Affected versions

Affected versions
<= 10.1.1
Fixed version
10.1.2
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported

Exploitation

CVE-2026-7120

Probability of exploitation in the next 30 days: 0.37%

FIRST EPSS · 2026-11-23

Description

Impact

@fastify/static evaluates the allowedPath callback before normalizing dot segments and duplicate slashes in the pathname used for file resolution. Non-canonical pathnames such as //file, /./file, or /public/../private/file bypass allowedPath filtering while resolving to the intended file on disk.

Applications that use allowedPath as a security boundary to restrict access to specific static files or path subtrees may unintentionally expose files that were intended to be denied.

Patches

Upgrade to @fastify/static >= 10.1.2.

Workarounds

None. Upgrade to the patched version.

Links

Credits

  • yuki-matsuhashi
  • mcollina
  • UlisesGascon