MediumGHSA-r99w-jh2x-3mg9CVE-2026-128077

Nuxt: Incomplete fix for GHSA-9v7c-q64q-vv33: a leading `//` in the request path bypasses `server/middleware` path checks and server route rules on page routes

Published 13 Nov 2026 · Updated 13 Nov 2026

Is your project on an affected @nuxt/nitro-server?

Private repo? Upload its lockfile instead, or connect GitHub to check every repo.

Look after several JavaScript apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie

Affected package

Affected
>=4.6.0 <4.6.4
Fixed in
4.6.4
Update to the fixed version for your release line, for example:npm install @nuxt/nitro-server@4.6.4

Details

Summary

Since 4.6.0, Nuxt parses a request path that starts with // as a URL with a host before rendering a page, so //x/admin renders the page at /admin. Nitro's routing, Nitro's route rules and server/middleware see the path as //x/admin, so server-side checks keyed on /admin do not apply. The fix for GHSA-9v7c-q64q-vv33 in 4.6.3 covered dot segments but not this form.

Impact

An unauthenticated attacker can bypass server-side controls that match on the request path of a page route.

A route-scoped server handler is skipped:

// nuxt.config.ts
export default defineNuxtConfig({
  serverHandlers: [{ route: '/admin', middleware: true, handler: '~~/server/admin-guard.ts' }],
})
// server/admin-guard.ts
export default defineEventHandler((event) => {
  if (!isAuthenticated(event)) {
    throw createError({ statusCode: 401 })
  }
})

With this handler, /admin returns 401, but //x/admin and ///x/admin render app/pages/admin.vue along with the data it fetches during server rendering. server/middleware that checks event.path.startsWith('/admin') is skipped in the same way.

Server-side redirect and headers route rules are also skipped, so '/admin/**': { redirect: '/login' } does not redirect //x/admin/secret, and per-route security headers such as Content-Security-Policy are not sent.

Browsers send a path such as //x/admin as written, so a plain link is enough to reach the page.

Not affected:

  • API handlers in server/api and server/routes, which Nitro does not match for these paths.
  • appMiddleware route rules and middleware declared with definePageMeta, which are matched against the resolved route.
  • Nuxt 3.x and 4.0.0 to 4.5.x, which pass the path to the page router unchanged, so these requests 404.

Patches

Fixed in @nuxt/nitro-server@4.6.4, which nuxt@4.6.4 depends on. The renderer now uses the request path exactly as Nitro matched it, so a path starting with // no longer resolves to a different page.

Workarounds

Reject request paths that start with // in a server middleware:

// server/middleware/double-slash.ts
export default defineEventHandler((event) => {
  if (event.path.startsWith('//')) {
    throw createError({ statusCode: 404 })
  }
})

A reverse proxy or CDN that merges repeated slashes before forwarding the request also removes the mismatch.

Credits

Nuxt thanks @kq5y for reporting this issue.

Is GHSA-r99w-jh2x-3mg9 in any of your client repos?

Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected @nuxt/nitro-server, and gives you the command that fixes it.

More advisories for @nuxt/nitro-server

  • LowCVE-2026-128076Nuxt: Colliding island props can share one `/__nuxt_island` path (incomplete fix for CVE-2026-46342) · 16 Nov 2026
  • MediumCVE-2026-128071Nuxt: Incomplete fix for GHSA-6gq8-jgmh-3ffp: an encoded slash (`%2F`) in the request path bypasses route rules on catch-all page routes · 16 Nov 2026
  • MediumCVE-2026-119200Nuxt: Dot segments in the request path bypass `server/middleware` path checks and server route rules on page routes · 30 Oct 2026
  • MediumCVE-2026-114132Nuxt: Server-side route rules (`redirect`, `headers`, `proxy`, `ssr`) are skipped for case-variant paths when routing is case-insensitive · 22 Oct 2026
  • MediumCVE-2026-47200Nuxt's route middleware is not enforced when rendering `.server.vue` pages via `/__nuxt_island/page_*` · 29 May 2026
  • LowCVE-2026-46342Nuxt: `__nuxt_island` endpoint does not bind responses to request props, enabling shared-cache poisoning · 19 May 2026
@nuxt/nitro-server security overview

References

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.