@fastify/middie vulnerable to path-scoped middleware bypass via duplicate-slash mount path
Summary
| CVE | CVE-2026-132133 |
|---|---|
| State | PUBLISHED |
| Assigner | openjs |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-11-19 12:18:40 UTC |
| Updated | 2026-11-19 12:18:40 UTC |
| Description | @fastify/middie is the middleware engine that adds Express and Connect style middleware support to Fastify. In versions up to and including 9.3.6, middie builds the match regular expression for each path-scoped middleware from its mount path without collapsing duplicate slashes, even when the application enables the ignoreDuplicateSlashes router option. Under that option Fastify's router collapses duplicate slashes in both the registered route and the request path, so a mount path containing a doubled slash is served by the router at its single-slash form while the middleware's compiled match still requires the doubled slash and never matches. A path-scoped middleware such as authentication, authorization, or rate limiting is therefore skipped while the router dispatches the request to the protected handler, without any authentication required. Applications are affected when they enable ignoreDuplicateSlashes and a middleware mount path reaches middie with a duplicate slash, most commonly when a plugin prefix that ends with a slash is joined to a mount path that starts with one. The issue is fixed in @fastify/middie 9.3.7, and users should upgrade to 9.3.7 or later. As a workaround, enforce authorization in a Fastify hook such as preHandler that runs after routing, and avoid mount paths and plugin prefixes that introduce duplicate slashes. |
Risk And Classification
Primary CVSS: v3.1 4.8 MEDIUM from ce714d77-add3-4f53-aff5-83d477b104bb
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N
Problem Types: CWE-436 | CWE-436 CWE-436: Interpretation Conflict
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | ce714d77-add3-4f53-aff5-83d477b104bb | Secondary | 4.8 | MEDIUM | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N |
| 3.1 | CNA | CVSS | 4.8 | MEDIUM | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N |
CVSS v3.1 Breakdown
Attack Vector
NetworkAttack Complexity
HighPrivileges Required
NoneUser Interaction
NoneScope
UnchangedConfidentiality
LowIntegrity
LowAvailability
NoneCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:N
Vendor Declared Affected Products
| Source | Vendor | Product | Version | Platforms |
|---|---|---|---|---|
| CNA | @fastifymiddie | @fastify/middie | affected 9.3.7 semver | Not specified |
| CNA | @fastifymiddie | @fastify/middie | unaffected 9.3.7 semver | Not specified |
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| cna.openjsf.org/security-advisories.html | ce714d77-add3-4f53-aff5-83d477b104bb | cna.openjsf.org | |
| github.com/fastify/middie/security/advisories/GHSA-56jq-34pf-p873 | ce714d77-add3-4f53-aff5-83d477b104bb | github.com | |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
Vendor Comments And Credit
Discovery Credit
CNA: superbot-helper (en)
CNA: mcollina (en)
CNA: UlisesGascon (en)
There are currently no legacy QID mappings associated with this CVE.