
Cloud Vulnerability DB
A community-led vulnerabilities database
CVE-2026-133867 is a critical authentication bypass vulnerability in the @fastify/express npm package, caused by improper handling of RegExp mount paths under parameterized Fastify plugin prefixes. When Express middleware is mounted using a RegExp (e.g., app.use(/^\/private/, authMiddleware)) inside a plugin registered with a parameterized prefix (e.g., /tenant/:tenantId), the Express matcher treats the prefix as literal text, causing it to silently skip the middleware while Fastify still executes the route handler. This allows unauthenticated clients to access routes that should be protected. Affected versions are @fastify/express >= 4.0.7 and < 4.0.10; version 4.0.10 contains the fix. The vulnerability was disclosed on November 20, 2026, with a CVSS v3.1 base score of 9.1 (Critical) (GitHub Advisory).
The root cause is an interpretation conflict (CWE-436) combined with improper authentication enforcement (CWE-287): @fastify/express fails to rewrite RegExp-based Express mount paths to account for resolved parameterized Fastify plugin prefixes. When the Express router matcher is constructed, the parameterized segment (e.g., :tenantId) is embedded as a literal string rather than being treated as a wildcard, so the RegExp never matches real incoming URLs containing concrete tenant values (e.g., /tenant/acme/private/resource). As a result, Express silently skips the middleware, while Fastify's own router correctly resolves and dispatches the request to the route handler — effectively bypassing any authentication or authorization logic placed in the RegExp-mounted middleware. No special configuration beyond a parameterized prefix and a RegExp mount is required to trigger the bypass; default router settings are sufficient (GitHub Advisory).
Successful exploitation allows unauthenticated network attackers to access routes that are intended to be protected by Express middleware-based authentication or authorization, resulting in high confidentiality and integrity impact. Sensitive data exposed behind the protected routes can be read or manipulated without any credentials. Availability is not directly impacted, but the bypass could enable further actions such as unauthorized data modification, privilege escalation within the application, or access to multi-tenant data belonging to other users (GitHub Advisory).
A proof-of-concept exploit configuration is described in the GitHub Security Advisory, providing sufficient detail to reproduce the bypass without additional research, though no runnable exploit code has been published. The vulnerability requires no authentication, no user interaction, and no special privileges — only knowledge of a parameterized route prefix and a protected path. There is no evidence of active in-the-wild exploitation at this time, and the CVE status remains Reserved. No EPSS score or CISA KEV catalog entry is currently available for this CVE (GitHub Advisory).
@fastify/express versions >= 4.0.7 and < 4.0.10 that registers a Fastify plugin under a parameterized prefix (e.g., /tenant/:tenantId) and uses RegExp-mounted Express middleware for authentication (e.g., app.use(/^\/private/, authMiddleware))./tenant/acme/private/resource.GET /tenant/acme/private/resource) without any authentication token or credentials.:tenantId rather than the resolved value acme, the RegExp mount never matches the real URL, the authMiddleware is silently skipped, and Fastify dispatches the request to the route handler — returning protected data or performing privileged actions without authentication (GitHub Advisory)./tenant/<value>/private/...) that would normally require authentication tokens or session cookies; absence of Authorization or Cookie headers in requests to protected endpoints.2xx responses to protected paths for requests lacking authentication headers; absence of authentication middleware log entries for requests that reach route handlers under parameterized prefixes.Upgrade @fastify/express to version 4.0.10 or later, which correctly rewrites RegExp mount paths to account for parameterized plugin prefixes. If an immediate upgrade is not possible, two workarounds are available: (1) enforce authentication using a Fastify hook such as preHandler that runs after the router resolves the request, ensuring authentication logic is not dependent on Express middleware matching; or (2) avoid RegExp mount paths under parameterized plugin prefixes by using string-based mount paths or restructuring the application to move route parameters out of the plugin prefix (GitHub Advisory).
The advisory was published by mcollina (a core Fastify maintainer) on November 20, 2026, with remediation review credited to UlisesGascon and the vulnerability reported by kleju13. The advisory notes AI assistance was used in its preparation. No significant broader media coverage or notable external researcher commentary has been identified at this time (GitHub Advisory).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."