Fastify Middie auth bypass in path-scoped middleware
Affects @fastify/middie releases up to and including 9.3.7 when requests use an empty parameter or wildcard value, a target starting with *, or a literal % in a mount path. Fixed in 9.3.8. CVSS rates it critical.
- Exploited
- No known exploitation
- Fix
- Fixed in 9.3.8
- Who is exposed
- Default setups
Summary
The @fastify/middie middleware engine for the Fastify web framework can be tricked into skipping path-scoped middleware, so a remote attacker without logging in can reach handlers that authentication, authorization, or rate-limiting middleware was meant to protect. The flaw is triggered by empty parameter or wildcard values, request targets that do not begin with a slash, and literal percent characters in a mount path.
Written by a model
Original description
@fastify/middie is the middleware engine for the Fastify web framework. In versions up to and including 9.3.7, middie matches path-scoped middleware against its own reading of the request path, which can differ from the path Fastify's router uses to dispatch the request. When the two disagree, the router can route a request to a handler covered by a middleware mount while middie skips that middleware, so an unauthenticated client reaches a handler that an authentication, authorization, or rate-limiting middleware was meant to protect, with no special configuration required. The mismatch is triggered by empty parameter or wildcard values, request targets that do not begin with a slash, and literal percent characters in a mount path. The issue is fixed in @fastify/middie 9.3.8, and users should upgrade to 9.3.8 or later.
Who should check
Teams running @fastify/middie 9.3.7 or earlier, such as Fastify apps using middleware for authentication, authorization or rate limiting on path-scoped routes.
“All releases up to 9.3.7 are affected.”
What to do
Check every install: default setups are affected.
Upgrade to a fixed version: 9.3.8.
Check your systems with an agent
Paste this into a coding or ops agent. It checks your systems read-only and reports a table per asset.
Check whether my systems are affected by CVE-2026-133250 (@fastify/middie vulnerable to path-scoped middleware bypass via request path matching mismatches), using the cve.now data below.
Rules: work read-only. Do not run exploit code, proof-of-concept scripts or scanners that send attack payloads, and do not change any configuration, package, image or deployment. Report findings only.
What cve.now has for CVE-2026-133250 (entry last updated 2026-11-21):
Affected:
- npm package @fastify/middie: fixed in 9.3.8
Fixed versions: 9.3.8.
Conditions (all must be true for the bug to be hit):
- Affected @fastify/middie releases up to and including 9.3.7. (source: https://github.com/fastify/middie/security/advisories/GHSA-gcf6-j9m3-p97x)
- The request uses an empty parameter or wildcard value, a target starting with *, or a literal % in a mount path. (source: https://github.com/fastify/middie/security/advisories/GHSA-gcf6-j9m3-p97x)
Setup: the bug is reachable in a default setup; no special feature or setting is needed.
Attacker needs: network access, no login, no user action.
CISA KEV: CVE-2026-133250 is not listed as of cve.now's last read.
This KEV status is for CVE-2026-133250 only. If you also check another CVE, look up its own KEV status; never assume it from this one.
How to check:
- Packages (npm): find every lockfile in each project and run the stack.check operation of the cve.now MCP server (execute) on each one. Compare the resolved versions, not the ranges a manifest declares, with the affected versions above. Include transitive dependencies.
Verify against the linked advisories before concluding, and cite the date you read each one:
- https://github.com/fastify/middie/security/advisories/GHSA-gcf6-j9m3-p97x
- https://cna.openjsf.org/security-advisories.html
Do not conclude an asset is unaffected unless you checked it and the evidence covers both its version and the conditions above. If you could not check something, mark it unknown and say what is missing.
Report a table with one row per asset and these columns: Asset | Version or build | Status (affected, fixed, not applicable, unknown) | Compensating controls | Exposure (internet-facing, internal, none) | Evidence | Next action.
Entry: https://cve.now/CVE-2026-133250
For follow-up questions, use the cve.now MCP server at https://mcp.cve.now/mcp (no authentication), for example execute with name cve.get and arguments {"id": "CVE-2026-133250"}.Affected versions
cve.now Index
- Exploitation?/40Unknown. No CISA SSVC exploitation rating yet
- Exposure22/25Default setups, reachable over the network without a login
- Reach16/20@fastify/middie: 2.8M downloads a week
- Severity9.1/10CVSS 9.1
- No patch0/5No signal
What would change the score
- Would score about 87 if added to CISA KEV
- Would score about 82 if CISA's SSVC rates exploitation active
Impact
Timeline
- CVE published
- First seen by cve.now
- Posted on X by cve.now
Evidence 4
| Kind | Source |
|---|---|
| Vendor advisory 1Establishes: Affected and fixed versions. | |
| Advisory | GitHub · fastify/middie · Advisory GHSA-gcf6-j9m3-p97x |
| CVE record 2Establishes: The identifier and description. | |
| Record | CVE List · CVE-2026-133250 |
| Record | NVD · CVE-2026-133250 |
| Other links 1 | |
| Link | cna.openjsf.org · security-advisories.html |
Questions about CVE-2026-133250
Is CVE-2026-133250 being exploited?
It is not in CISA's Known Exploited Vulnerabilities catalog, and CISA's SSVC assessment does not mark exploitation as active. That does not mean it has not been attacked: vendors and researchers can report attacks before CISA lists them. No public exploit code is tracked.
Source: cve.now feed data
What does this mean?
Path-scoped middleware can be skipped for certain request paths, so an unauthenticated client can reach a handler that an authentication, authorization or rate-limiting middleware was meant to protect.
Source: github.com
Which versions are affected by CVE-2026-133250?
@fastify/middie (npm): before 9.3.8.
Source: cve.now feed data
Am I affected, and how do I check?
All @fastify/middie releases up to and including 9.3.7 are affected. The mismatch is triggered by requests with an empty parameter or wildcard value, a target starting with *, or a literal % in a mount path. Check the installed @fastify/middie version in the project's dependencies to see whether it falls in that range.
Source: github.com
How do I fix CVE-2026-133250?
Upgrade @fastify/middie to 9.3.8, the listed fixed version.
Source: github.com
Related
- CVE-2026-112712@fastify/middie vulnerable to path-scoped middleware bypass via scope prefix mismatch
- CVE-2026-85184@fastify/middie vulnerable to path-scoped middleware bypass via absolute-form request target
- CVE-2026-14198@fastify/middie vulnerable to authorization bypass via encoded slash in path parameter values
- CVE-2026-6270@fastify/middie vulnerable to middleware authentication bypass in child plugin scopes
- CVE-2026-22031Fastify Middie Middleware Path Bypass
- CVE-2026-2880@fastify/middie has an improper path normalization vulnerability
No corrections so far. Something wrong on this page? Report an error.