Średnia

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

  • Ujawniono: 13.11.2026
  • Aktualizacja: 13.11.2026 21:17

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:

ts
// nuxt.config.ts
export default defineNuxtConfig({
  serverHandlers: [{ route: '/admin', middleware: true, handler: '~~/server/admin-guard.ts' }],
})
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:

ts
// 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.

Czego dotyczy

Kliknij technologię, aby zobaczyć wszystkie dotyczące jej podatności.

PlatformaPaczkaPodatne wersjePoprawka w wersji
Paczka npm @nuxt/nitro-server >= 4.6.0, < 4.6.4 4.6.4

Odnośniki

Ocena CVSS 6.5/10
Wektor CVSS
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N
Słabość (CWE)
CWE-436, CWE-863
Platforma
npm
Paczka
@nuxt/nitro-server
Ujawniono
13.11.2026
Aktualizacja
13.11.2026 21:17

Źródła i licencje

OSV / GitHub Advisory Database - GHSA-r99w-jh2x-3mg9 - CC BY 4.0

Historia podatności: @nuxt/nitro-server

Wszystkie opisane podatności tej paczki (Paczka npm), od najnowszej. Widać, czy to jednorazowa wpadka, czy paczka, której trzeba pilnować.

Wszystkich wpisów
7
Pierwsza → ostatnia
05.2026 11.2026
Bez poprawki
0
Wykorzystywana w atakach
0

Rozkład istotności

  • Średnia 5
  • Niska 2

Ujawnienia w latach

  1. 2026: 7
  1. 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 ten wpis
    Średnia · 6.5 CVE-2026-128077 >= 4.6.0, < 4.6.4 4.6.4
  2. Średnia · 5.3 CVE-2026-47200 >= 3.20.0, < 3.21.6, >= 4.2.0, < 4.4.6 3.21.6, 4.4.6
  3. Niska · 5.4 CVE-2026-46342 >= 3.20.0, < 3.21.6, >= 4.2.0, < 4.4.6 3.21.6, 4.4.6

Dowiedz się, które podatności dotyczą Twojej aplikacji

Po podłączeniu integracji DockRay i włączeniu raportowania oprogramowania DockRay porównuje zgłoszone wersje komponentów ze znanymi podatnościami i powiadamia o potwierdzonych dopasowaniach. Zakres zależy od obsługiwanej technologii i dostępnych biuletynów.

Podłącz swoją aplikację
Newsletter DockRay

Bezpieczeństwo aplikacji w Twojej skrzynce

Najważniejsze podatności, konkretne zalecenia i praktyczne wskazówki dla Twoich aplikacji. Wybierz technologie i śledź to, co ma znaczenie dla Twojego projektu.

  • Codzienne zestawienie nowych podatności, także krytycznych.
  • Powiadomienia o ważnych aktualizacjach.
  • Praktyczne porady o bezpieczeństwie i monitoringu aplikacji.

Pozostaw puste, aby otrzymywać informacje o wszystkich technologiach.

Zapis jest bezpłatny. Wypiszesz się jednym kliknięciem w wiadomości.