GHSA-97VV-H72Q-2GVR
Authentication/Authorization Bypass: server$() RPC Dispatch Runs Before (and Bypasses) Layout onRequest Middleware
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Remediación | Parche 1.20.2 | @builder.io/qwik-city · -7 d desde divulgación | |
| Divulgación | Publicada | GHSA-97VV-H72Q-2GVR divulgada | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Description
In `@builder.io/qwik-city` 1.20.0, `server$()` RPC calls are dispatched before middleware exported by the matched page route’s `layout.tsx` or `index.tsx`. When `runServerFunction` recognizes a valid RPC request, it invokes the selected server function and terminates the remaining handler chain. Consequently, route-level `onRequest` and method-specific handlers do not authorize that call.
This is documented behavior rather than an established framework vulnerability. Qwik City describes each `server$()` function as an HTTP endpoint, explicitly states that layout middleware does not run for `server$()` requests, and recommends server plugins for middleware that must cover both page and RPC traffic. Sensitive functions must therefore perform their own authorization or be protected by appropriate server-plugin middleware.
Applications may become exposed when developers incorrectly treat layout middleware as the sole authorization boundary for a sensitive `server$()` function and omit both supported authorization mechanisms. The RPC dispatcher also does not bind a target function to the route whose code references it, so placing the dispatcher after the middleware for the receiving URL would not necessarily apply the layout associated with that function.
Impact
In an application that relies exclusively on layout middleware to protect a sensitive `server$()` function, a remote caller capable of constructing a valid RPC request may invoke the function without the expected layout check.
The consequences depend entirely on the affected application and the invoked function. A function without another authorization check could disclose sensitive information or perform state-changing operations using the application’s server-side privileges. Authorization inside the function, server-plugin middleware, and ordinary input validation limit or prevent this impact.
The supplied verification establishes the handler order but does not demonstrate an end-to-end unauthorized invocation, data disclosure, or state change. It therefore does not support characterizing the behavior as a general Qwik City authentication bypass or assigning it a framework-level High severity/CVSS 8.2 rating.
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
npm@builder.io/qwik-city |
Corregida | 1.20.2 | -7 d | 1.20.4 no afectada |
1.20.2Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/QwikDev/qwik/security/advisories/GHSA-97vv-h72q-2gvrLas referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
