Track vulnerabilities like this one. Sign up free to get alerted when software you use is affected.
5.3

CVE-2026-7120: Fastify static may serve restricted files via odd URLs

CVE-2026-7120 · published 3 months ago
Summary

The Fastify static file plugin (versions up to 10.1.1) checks its allow‑list before cleaning up unusual parts of a URL. An attacker could use specially crafted paths to get files that were meant to be blocked. Upgrade to version 10.1.2 or later to fix the issue.

What to do
  • Update fastify static to version 10.1.2.
  • Update @fastify/static @fastify/static to version 10.1.2 or later.
  • Update fastify fastify-static to version 10.1.2 or later.
Affected software
Ecosystem VendorProductAffected versions
– @fastify/static @fastify/static < 10.1.2
npm fastify static <= 10.1.1
Fix: upgrade to 10.1.2
– fastify fastify-static < 10.1.2
cpe:2.3:a:fastify:fastify-static:*:*:*:*:*:*:*:*
Original advisory text
@fastify/static vulnerable to Authorization Bypass via Non-Canonical URL Paths
@fastify/static evaluates the allowedPath callback before normalizing dot segments and duplicate path separators in the pathname used for file resolution. Versions up to and including 10.1.1 are affected. An unauthenticated attacker can bypass allowedPath restrictions by requesting equivalent non-canonical pathnames, causing files that were intended to be denied to be served anyway. The bypass does not allow access outside the configured static root by itself, it defeats path-based filtering only. The issue is patched in @fastify/static 10.1.2.
Fix within
Internet-facing 14 days
Internal 60 days
  • Not known to be exploited
  • Can be exploited automatically
  • Gives an attacker partial control
Severity
5.3 Medium
Exploitation
<1% chance of attack within 30 days
Type
CWE-180Incorrect Behavior Order: Validate Before Canonicalize
Timeline
Published23 Jul 2026
Updated4 Nov 2026
First seen23 Jul 2026
Sources
CVE-2026-7120 · NVD
CVE-2026-7120 · MITRE
CVE-2026-7120 · OSV
Track software like this
Free during beta