{"id":"CVE-2026-2880","aliases":["CVE-2026-2880","GHSA-8p85-9qpw-fwgw"],"related":[],"kind":"vulnerability","state":"published","title":"@fastify/middie has an improper path normalization vulnerability","summary":"A vulnerability in @fastify/middie versions < 9.2.0 can result in authentication/authorization bypass when using path-scoped middleware (for example, app.use('/secret', auth)).\n\nWhen Fastify router normalization options are enabled (such as ignoreDuplicateSlashes, useSemicolonDelimiter, and related trailing-slash behavior), crafted request paths may bypass middleware checks while still being routed to protected handlers.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"A vulnerability in @fastify/middie versions < 9.2.0 can result in authentication/authorization bypass when using path-scoped middleware (for example, app.use('/secret', auth)).\n\nWhen Fastify router normalization options are enabled (such as ignoreDuplicateSlashes, useSemicolonDelimiter, and related trailing-slash behavior), crafted request paths may bypass middleware checks while still being routed to protected handlers.","source":"cvelist"},{"lang":"en","text":"## Summary\nA path normalization inconsistency in `@fastify/middie` can result in authentication/authorization bypass when using path-scoped middleware (for example, `app.use('/secret', auth)`).\n\nWhen Fastify router normalization options are enabled (such as `ignoreDuplicateSlashes`, `useSemicolonDelimiter`, and related trailing-slash behavior), crafted request paths may bypass middleware checks while still being routed to protected handlers.\n\n## Impact\nAn unauthenticated remote attacker can access endpoints intended to be protected by middleware-based auth/authorization controls by sending specially crafted URL paths (for example, `//secret` or `/secret;foo=bar`), depending on router option configuration.\n\nThis may lead to unauthorized access to protected functionality and data exposure.\n\n## Affected versions\n- Confirmed affected: `@fastify/middie@9.1.0`\n- All versions prior to the patch are affected.\n\n## Patched versions\n- Fixed in: *9.2.0*\n\n## Details\nThe issue is caused by canonicalization drift between:\n1. `@fastify/middie` path matching for `app.use('/prefix', ...)`, and\n2. Fastify/find-my-way route lookup normalization.\n\nBecause middleware and router did not always evaluate the same normalized path, auth middleware could be skipped while route resolution still succeeded.\n\n## Workarounds\nUntil patched version is deployed:\n- Avoid relying solely on path-scoped middie guards for auth/authorization.\n- Enforce auth at route-level handlers/hooks after router normalization.\n- Disable risky normalization combinations only if operationally feasible.\n\n## Resources\n- Fluid Attacks Disclosure Policy: https://fluidattacks.com/advisories/policy\n- Fluid Attacks advisory URL: https://fluidattacks.com/advisories/jimenez\n\n## Credits\n- **Cristian Vargas** (Fluid Attacks Research Team) — discovery and report.\n- **Oscar Uribe** (Fluid Attacks) — coordination and disclosure.","format":"markdown","source":"ghsa"},{"lang":"es","text":"Una vulnerabilidad en las versiones de @fastify/middie anteriores a la 9.2.0 puede resultar en una omisión de autenticación/autorización al usar middleware con ámbito de ruta (por ejemplo, app.use('/secret', auth)).\n\nCuando las opciones de normalización del router de Fastify están habilitadas (como ignoreDuplicateSlashes, useSemicolonDelimiter y el comportamiento relacionado con las barras finales), las rutas de solicitud manipuladas pueden omitir las comprobaciones del middleware mientras siguen siendo enrutadas a manejadores protegidos.","source":"nvd"}],"published":"2026-02-27T18:25:37.428Z","modified":"2026-06-17T10:31:56.523Z","severity":{"scorer":"openjs","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N","score":8.2,"rating":"HIGH"},"severities":[{"scorer":"openjs","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N","score":8.2,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N","rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N","score":9.1,"rating":"CRITICAL"}],"cwes":["CWE-20"],"affected":[{"ranges":[{"type":"semver","introduced":"0.0.0","fixed":"9.2.0","status":"affected"}],"vendor":"@fastify/middie","product":"@fastify/middie","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"9.2.0"}],"ecosystem":"npm","package":"@fastify/middie","purl":"pkg:npm/%40fastify/middie","source":"ghsa"},{"ranges":[{"status":"affected","fixed":"9.2.0"}],"vendor":"fastify","product":"fastify/middie","cpe":"cpe:2.3:a:fastify:fastify\\/middie:*:*:*:*:*:node.js:*:*","source":"nvd"}],"references":[{"url":"https://github.com/fastify/middie/security/advisories/GHSA-8p85-9qpw-fwgw","tags":["mitigation","vendor-advisory","web"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-2880","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/fastify/middie/commit/140e0dd0359d890fec7e6ea1dcc5134d6bd554d4","tags":["web"],"sources":["ghsa"]},{"url":"https://fluidattacks.com/advisories/jimenez","tags":["web"],"sources":["ghsa"]},{"url":"https://fluidattacks.com/advisories/policy","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/fastify/middie","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/fastify/middie/releases/tag/v9.2.0","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"openjs","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-02-27T18:55:36.300Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-2880","url":"https://www.cve.org/CVERecord?id=CVE-2026-2880","licence":"CVE Terms of Use","modified":"2026-02-27T18:56:02.979Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-8p85-9qpw-fwgw","url":"https://github.com/advisories/GHSA-8p85-9qpw-fwgw","licence":"CC-BY-4.0","modified":"2026-02-28T06:56:21.047Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-2880","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-2880","licence":"Public domain","modified":"2026-06-17T10:31:56.523Z"}],"updatedAt":"2026-11-25T22:59:15.036Z","epss":{"score":0.00423,"percentile":0.38583,"date":"2026-12-02T12:00:21.000Z"}}