GHSA-Q3FF-CJ6V-RR5G
Grav's Clockwork profiler endpoint is unauthenticated: when the debugger is enabled, any visitor can read other users' session cookies, form submissions and the site's plugin configuration
Texto original en inglés · Ver en español
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N
Fuente: GitHub
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Divulgación | Publicada | GHSA-Q3FF-CJ6V-RR5G divulgada · CVSS 8.7 (GitHub) | |
| Divulgación | Modificada | Última actualización del registro | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Summary
When `system.debugger.enabled` is turned on, any unauthenticated visitor can read the stored profiler records of every other visitor's requests via `/__clockwork/...`. `InitializeProcessor::handleDebuggerRequest()` intercepts any path containing `/__clockwork/` during bootstrap and hands it to `Debugger::debuggerRequest()`, which performs no authentication of any kind: no user lookup, no IP restriction, and no Clockwork authenticator configured. The endpoint also supports anonymous pagination (`previous`/`next`) over the entire stored history.
With the shipped `censored: false` default, each record contains:
- the raw request cookies, including Grav's session cookie -- whose value *is* the PHP session id, so replaying it resumes that user's session, including an authenticated admin's;
- the full parsed request body. Clockwork's built-in password filter only inspects top-level keys, so Grav's own login form -- which posts `data[username]` / `data[password]` -- has its password stored in plaintext;
- the site's entire system and plugin configuration, dumped into every record's log, which includes any secrets an operator has saved in a plugin's settings (SMTP credentials, third-party API keys, licence keys).
The `Authorization` and `X-API-Token` request headers are stored in every record and are *not* masked even when `censored: true`.
Records persist as plaintext JSON under `cache/clockwork/<id>.json`. Those files are not directly fetchable under Grav's shipped web server configs; the `/__clockwork/` endpoint is the only route to them.
Condition
`debugger.enabled` ships as `false`, so this affects sites where an operator has turned the debugger on. Grav's documentation and admin help text described the debugger only as "a useful tool during development" and did not warn that enabling it publishes every visitor's request data to every other visitor. That has been corrected alongside this fix.
On Grav 2.0, setting `provider: debugbar` does not avoid the issue: since 2.0.4 Grav forces the Clockwork provider for any request that prefers a JSON response, so an attacker who sends `Accept: application/json` reaches the same store. On Grav 1.7 the `debugbar` provider is unaffected.
Impact
An attacker starting with zero access ends up able to read every recorded request body and configuration value, and to impersonate any recorded session, including an authenticated super-admin's. Trust boundary crossed: an unauthenticated visitor reaches a privileged sink.
Patches
The `/__clockwork/` endpoint now answers only requests originating from the server itself, or requests presenting the secret configured in the new `system.debugger.token` setting. Cookies and credential headers are stripped from stored records regardless of the `censored` setting.
Workarounds
Set `debugger.enabled: false`, or block `/__clockwork/` at the web server or CDN. Existing profiler data should be removed with `bin/grav clear`.
Credit
Reported by @zuwardo-zero.
Desglose de métricas
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
Packagistgetgrav/grav |
Corregida | 1.7.53.3, 2.0.22 | — | — |
1.7.53.32.0.22Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/getgrav/grav/security/advisories/GHSA-q3ff-cj6v-rr5gLas referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
