CVE-2026-115515: @fastify/static vulnerable to route guard bypass via default index and extension resolution

Published Nov 19, 2026
·
Updated

@fastify/static is the Fastify plugin for serving static files. In versions before 10.1.8, the allowedPath guard receives only the requested pathname, but the underlying send step selects the file to serve afterwards, so a request for a directory resolves to its default index file and an extensionless request resolves through the configured extensions to a matching file. The selected file is streamed without being re-checked against allowedPath, so a guard that denies a specific file is bypassed by requesting its directory or extensionless form. An unauthenticated client can read files inside the static root that the application meant to keep private whenever the denied file is reachable as a directory index or an extension match. The issue is fixed in @fastify/static 10.1.8, and users should upgrade to 10.1.8 or later. As a workaround, also deny the directory and extensionless forms in allowedPath, or disable the index and extensions options.

Affected Software

1 affected component
npm/@fastify/static<10.1.8

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade @fastify/static to a version that resolves this vulnerability.

    Fixed in 10.1.8
  2. Configuration

    Disable the index and extensions options, or update allowedPath to also deny directory and extensionless forms.

    @fastify/static index and extensions = disabled

Event History

Nov 19, 2026
CVE Published
via MITRE·05:48 PM
Data Sourced
via MITRE·05:48 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·06:18 PM
DescriptionSeverityWeakness

Frequently Asked Questions

1

Which deployments are exposed to this bypass?

Deployments using @fastify/static before 10.1.8 are exposed if they use allowedPath to deny a file under the static root and that file can be reached through default index resolution or configured extension resolution. The issue requires the index or extensions behavior to provide an alternate request form for the denied file.

2

What does an attacker need to exploit the issue?

An attacker only needs network access to send HTTP requests; no authentication or user interaction is required. They must know or identify a denied file that is reachable by requesting its containing directory or an extensionless path.

3

How can we mitigate the issue before upgrading?

Update to @fastify/static 10.1.8 or later. If an immediate upgrade is not possible, deny the corresponding directory and extensionless request forms in allowedPath, or disable the index and extensions options.

4

How can we determine whether our current configuration is affected?

Review allowedPath rules for specific files that are intended to be private within the static root. Test whether requesting the parent directory returns that file as an index, or whether requesting the path without its extension resolves to the denied file through configured extensions.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203