Read the docs

@fastify/swagger-ui authentication bypass via unprotected /static route

Priority LOW 18CWE-288Published · Updated

Key facts

Attack vector
Network
Privileges required
None
User interaction
None
Attack complexity
High
Impact type
Security bypass
Confidentiality · integrity · availability
Low · None · None
Fix status
Fixed

Attack profile from CVSS 3.1 · CNA. Fix status from CNA. Impact type from CWE-288.

Summary

In @fastify/swagger-ui versions 2.1.0 through 6.1.4, the authentication hooks an application registers to protect its Swagger UI documentation apply to every route the plugin adds except the bundled static asset instance. When the option that serves bundled UI files from a local directory is enabled, that instance exposes every file in the directory without credentials. A specification file meant to stay behind the documentation login can therefore be read by an unauthenticated client who knows or guesses its name, with read-only access limited to files in that directory. CWE-288 covers the flaw, and CVSS 3.1 rates it 3.7 (LOW).

Written with Claude Haiku 5.5 from the sources below · 2026-11-21

Description from the CNA

@fastify/swagger-ui is the plugin that serves Swagger UI documentation for Fastify applications. In versions 2.1.0 through 6.1.4, the authentication hooks that applications register to protect the documentation are applied to every route the plugin adds except the bundled static asset instance. When the option that serves bundled UI files from a local directory is enabled, that instance exposes every file in the directory without credentials, so a specification file an operator meant to keep behind the documentation login becomes reachable by an unauthenticated client who knows or guesses its name. Access is read-only and limited to files in that directory. The issue is fixed in @fastify/swagger-ui 6.1.5, which applies the same authentication hooks to the static asset route, and users should upgrade to 6.1.5 or later.

Why it matters now

Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.00337 19th percentileScored 2026-11-30
Fix Fixed @fastify/swagger-ui (@fastify/swagger-ui): 6.1.5

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
None
Automatable
No
Technical impact
Partial

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
@fastify/swagger-ui@fastify/swagger-ui2.1.0 to before 6.1.56.1.5Patch availableCNA
  • @fastify/swagger-ui Vendor@fastify/swagger-ui Affected 2.1.0 to before 6.1.5 Fixed in 6.1.5 Patch available CNA

Remediation

Upgrade @fastify/swagger-ui to 6.1.5, which applies the same authentication hooks to the static asset route.

Written with Claude Haiku 5.5 from the sources below · 2026-11-21

  • Fix · CNA @fastify/swagger-ui (@fastify/swagger-ui) Fixed in 6.1.5

Timeline

  1. 2026-11-21 Threatist record created from CVE-2026-133273
  2. 2026-11-23 CISA SSVC decision points changed

References

Sources

This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences