CVE-2026-14198: @fastify/middie vulnerable to authorization bypass via encoded slash in path parameter values

Published Jul 1, 2026
·
Updated

@fastify/middie versions 9.1.0 through 9.3.2 decode the encoded slash %2F inside path parameter values before matching middleware paths, while Fastify's underlying router preserves the encoding during route lookup. The two layers disagree on the canonical request path, so the middleware fails to match a URL that the route handler does match. When middleware is used for authentication, authorization, rate limiting, or auditing on parameterized paths, an attacker can reach the protected handler by sending a single crafted URL with an encoded slash in the parameter position. The bypass is HTTP method agnostic and requires no authentication or special preconditions. Patches: upgrade to @fastify/middie 9.3.3. Workarounds: avoid parameterized middleware paths for security decisions, or enforce authentication at the route handler or via a Fastify hook that runs after the router has resolved the request.

Affected Software

2 affected components
npm/@fastify/middie>=9.1.0<=9.3.2
fastify Fastify\/middie Node.js>=9.1.0<9.3.3

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade @fastify/middie to a version that resolves this vulnerability.

    Fixed in 9.3.3
  2. Configuration

    Avoid using @fastify/middie middleware on parameterized paths when making authentication/authorization/rate limiting/auditing security decisions.

    @fastify/middie (middleware path usage) parameterized middleware paths for security decisions = avoid
  3. Compensating control

    If you must use middleware for authorization/authentication, enforce those controls at the Fastify route handler or via a Fastify hook that runs after the router has resolved the request (so checks occur after route lookup rather than before middleware path matching).

Event History

Jul 1, 2026
CVE Published
via MITRE·11:29 AM
Data Sourced
via MITRE·11:29 AM
DescriptionSeverityWeakness
Data Sourced
via NVD·12:16 PM
DescriptionSeverityWeaknessAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-14198?

CVE-2026-14198 has a critical severity rating of 9.1.

2

How does CVE-2026-14198 affect @fastify/middie?

CVE-2026-14198 allows for an authorization bypass due to the inconsistent handling of encoded slashes in path parameter values.

3

Which versions of @fastify/middie are affected by CVE-2026-14198?

CVE-2026-14198 affects @fastify/middie versions 9.1.0 through 9.3.2.

4

How can I fix CVE-2026-14198?

To fix CVE-2026-14198, upgrade @fastify/middie to a version above 9.3.2 where the issue has been resolved.

5

What types of impact does CVE-2026-14198 have on an application?

CVE-2026-14198 can potentially lead to unauthorized access to resources due to bypassed authentication checks.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203