CVE-2026-15074: @fastify/static vulnerable to route guard bypass via path traversal
Impact @fastify/static is vulnerable to a bypass of route-based middleware and guards via non-leading .. and %2E%2E path segments. find-my-way does not normalize .. when matching routes, so a request such as /foo/../deep/secret.txt matches the static plugin's catch-all instead of the guarded /deep/. The getPathnameForSend helper introduced by the fix for GHSA-x428-ghpx-8j92 only guards against the %2F variant; ..
Published Jul 24, 2026
Affected packages
@fastify/static
- Ecosystem
- npm
- Affected
- <= 10.1.0
- Fixed in
- 10.1.1
- Check
npm ls @fastify/static
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Impact
@fastify/static is vulnerable to a bypass of route-based middleware and guards via non-leading .. and %2E%2E path segments. find-my-way does not normalize .. when matching routes, so a request such as /foo/../deep/secret.txt matches the static plugin's catch-all instead of the guarded /deep/*. The getPathnameForSend helper introduced by the fix for GHSA-x428-ghpx-8j92 only guards against the %2F variant; .. and %2E%2E survive the decodeURI + encodeURI round-trip and are then collapsed away by @fastify/send's path.normalize before its own traversal guard runs.
Applications that rely on route-based middleware or guards to protect files served by @fastify/static can be bypassed with non-leading dot-dot path segments.
Patches
Upgrade to @fastify/static 10.1.1.
Workarounds
Do not use route-based middlewares or guards to protect files served by @fastify/static.
Credited to imssm99, mcollina, UlisesGascon.
References
- https://github.com/fastify/fastify-static/security/advisories/GHSA-83w8-p2f5-377r
- https://nvd.nist.gov/vuln/detail/CVE-2026-15074
- https://github.com/fastify/fastify-static/commit/db4276f846ba56b21f93768cd6636ee5e2fc58b1
- https://cna.openjsf.org/security-advisories.html
- https://github.com/fastify/fastify-static/releases/tag/v10.1.1
- https://github.com/advisories/GHSA-83w8-p2f5-377r
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
More npm vulnerabilities
All npm entriesCVE-2026-7120
@fastify/static vulnerable to Authorization Bypass via Non-Canonical URL Paths
medium5.3Jul 24, 2026CVE-2026-6410
@fastify/static vulnerable to path traversal in directory listing
medium5.3Apr 16, 2026CVE-2026-6414
@fastify/static vulnerable to route guard bypass via encoded path separators
medium5.9Apr 16, 2026
