Vulnerability DatabaseCVE-2026-133250

CVE-2026-133250: 
JavaScript vulnerability analysis and mitigation

Overview

CVE-2026-133250 is a path-scoped middleware bypass vulnerability in @fastify/middie, the Express-compatible middleware layer for the Fastify web framework. It allows unauthenticated remote attackers to bypass authentication, authorization, or rate-limiting middleware by crafting HTTP requests that exploit a path-matching mismatch between middie and Fastify's router (find-my-way). All releases of @fastify/middie prior to version 9.3.8 are affected. The vulnerability was disclosed on November 20, 2026, and carries a CVSS v3.1 base score of 9.1 (Critical) (GitHub Advisory).

Technical details

The root cause is an interpretation conflict (CWE-436) combined with authentication bypass via an alternate path (CWE-288): @fastify/middie evaluates path-scoped middleware mounts against its own parsing of the raw request URL using path-to-regexp, while Fastify's router (find-my-way) independently resolves the route using different normalization rules. Three distinct request forms trigger the mismatch: (1) Empty parameter/wildcard segments — find-my-way accepts empty path segments for parameterized routes (e.g., /user/ matches /user/:id), but middie's path-to-regexp requires at least one character, so the middleware is skipped; (2) Asterisk-prefixed request targets — a request target like *admin is routed by find-my-way to /admin (stripping the leading *), while middie matches the literal target and finds no mount; (3) Percent-encoded literal % in mount paths — find-my-way keeps a literal % in a mount path encoded as %25, but middie decodes it an additional time, causing /100%25 to reach a /100% mount that middie skips. No special server configuration is required to trigger any of these vectors (GitHub Advisory).

Impact

Successful exploitation allows an unauthenticated network attacker to reach route handlers that are intended to be protected by middleware-enforced authentication, authorization, or rate-limiting controls. The high confidentiality and integrity impact (CVSS C:H/I:H) reflects that attackers can read sensitive data and perform unauthorized write or modification operations on protected resources. Availability is not directly impacted, but bypassing rate-limiting middleware could enable downstream abuse such as brute-force attacks or resource exhaustion (GitHub Advisory).

Exploitability

The GitHub Security Advisory includes concrete malicious request examples that serve as proof-of-concept steps, classified by Feedly with medium confidence as poc_steps. No exploit code or weaponized tooling has been publicly released, and there is no evidence of in-the-wild exploitation at the time of disclosure. The vulnerability requires no authentication, no user interaction, and no special configuration, making it trivially exploitable by any network-accessible attacker against a vulnerable Fastify application using path-scoped middleware. It is not currently listed in the CISA KEV catalog, and no EPSS score is available at this time (GitHub Advisory).

Exploitation steps

  1. Reconnaissance: Identify Fastify-based web applications using @fastify/middie for middleware (e.g., via HTTP response headers, npm package metadata, or open-source repository inspection). Confirm the application version is below 9.3.8.
  2. Identify protected routes: Map the application's route structure to find endpoints protected by path-scoped middleware (authentication, authorization, or rate-limiting). This can be done via API documentation, error responses, or fuzzing.
  3. Craft an empty-parameter bypass request: Send a request with an empty path segment to a parameterized route, e.g., GET /tenant//admin targeting a route defined as /tenant/:id/admin. The router dispatches to the handler while middie skips the protecting middleware.
  4. Craft an asterisk-prefix bypass request: Send a request whose target begins with *, e.g., GET *admin HTTP/1.1 with Host: target.com. find-my-way routes this to /admin while middie matches the literal *admin and finds no mount to enforce.
  5. Craft a percent-encoding bypass request: If the application mounts middleware on a path containing a literal % (e.g., /100%), send GET /100%25. The router matches the mount while middie's additional decoding causes it to skip the middleware.
  6. Access protected handler: With middleware bypassed, interact with the protected handler directly — reading sensitive data, performing unauthorized operations, or circumventing rate limits — as if fully authenticated (GitHub Advisory).

Indicators of compromise

  • Network: HTTP requests to parameterized routes with empty path segments (e.g., /user/, /tenant//admin, /files/); requests with asterisk-prefixed request targets (e.g., *admin); requests containing %25 in paths that correspond to routes with literal % in their mount definitions.
  • Logs: Access logs showing GET /user/ or GET /tenant//admin returning 200 OK responses (rather than 401/403) on routes expected to require authentication; repeated requests to protected endpoints from unauthenticated sessions.
  • Application Behavior: Successful responses to requests that should have been rejected by authentication or authorization middleware; absence of expected middleware-generated headers (e.g., WWW-Authenticate) on protected routes when accessed via crafted paths (GitHub Advisory).

Mitigation and workarounds

Primary fix: Upgrade @fastify/middie to version 9.3.8 or later. The patch aligns middie's path matching with find-my-way's routing logic: empty parameter and wildcard values are now permitted, request targets not starting with / (other than the asterisk-form) are rejected, and literal % in mount paths is matched as the router keeps it encoded.

Workaround (if immediate upgrade is not possible): Enforce authentication in a Fastify hook such as preHandler that runs after the router has resolved the request, and base the access decision on request.routeOptions.url (the matched route pattern) rather than request.url (the raw request path). This approach is immune to all three bypass vectors (GitHub Advisory).

Community reactions

The advisory was published by Fastify core maintainer mcollina (Matteo Collina) on November 20, 2026, with UlisesGascon credited as the remediation reviewer. The advisory references a related prior vulnerability (GHSA-hx87-8wv7-pjv8) involving the same class of middleware bypass via absolute-form request targets, and links to an upstream find-my-way fix (delvedor/find-my-way#471) that prevents routing of paths not starting with /. No broader media coverage or notable social media commentary has been identified at this time (GitHub Advisory).

Additional resources

  • GitHub Advisory — Official GHSA-gcf6-j9m3-p97x advisory with full technical details and patch guidance
  • Related Advisory — Prior middleware bypass via absolute-form request targets (same vulnerability class)
  • find-my-way Fix — Upstream router fix preventing routing of non-/-prefixed paths

Source: This report was generated using AI

Related JavaScript vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-133867CRITICAL9.1
  • JavaScript logoJavaScript
  • @fastify/express
NoYesNov 21, 2026
CVE-2026-133250CRITICAL9.1
  • JavaScript logoJavaScript
  • @fastify/middie
NoYesNov 21, 2026
CVE-2026-133120CRITICAL9.1
  • JavaScript logoJavaScript
  • @fastify/express
NoYesNov 21, 2026
CVE-2026-133312MEDIUM5.3
  • JavaScript logoJavaScript
  • @fastify/rate-limit
NoYesNov 21, 2026
CVE-2026-133273LOW3.7
  • JavaScript logoJavaScript
  • @fastify/swagger-ui
NoYesNov 21, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Additional Wiz resources

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management