GHSA-2XCM-7H22-3M66
Update and delete by query evaluate filters without read permissions, leaking hidden field values
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
Fuente: GitHub
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Remediación | Parche 12.4.0 | directus · -27 d desde divulgación | |
| Divulgación | Publicada | GHSA-2XCM-7H22-3M66 divulgada · CVSS 6.5 (GitHub) | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Summary
Update-by-query and delete-by-query requests resolved their target items with a read that skipped permission checks. The request's `filter` was therefore evaluated against every row and every field in the collection, including fields and rows the user is not allowed to read. Because the response lists which items were updated or deleted, a user with update or delete permission on a collection could use it as a boolean oracle to recover the values of fields hidden from them by their read permissions.
Details
`ItemsService.getKeysByQuery`, used by `updateByQuery` and `deleteByQuery`, read the matching primary keys through a new `ItemsService` created without the caller's accountability. Without accountability the permission layer applies no field or row restrictions, so a filter on a field the user cannot read was accepted and evaluated normally. The subsequent `updateMany` / `deleteMany` only checks update or delete permission on the resolved keys, not whether the user could have read the fields used to find them.
The affected path is reachable wherever a query is passed to an update or delete, including the REST `PATCH` and `DELETE` endpoints for items and system collections (`{ "query": { "filter": ... }, "data": ... }`), the WebSocket `items` handler, and the MCP item tools.
A probe such as the following reveals whether a hidden `salary` field of item `1` is greater than a given value, depending on whether item `1` appears in the response:
PATCH /items/employees
{
"query": { "filter": { "_and": [{ "id": { "_eq": 1 } }, { "salary": { "_gt": 100000 } }] } },
"data": { "name": "unchanged" }
}Repeating this with range operators or `_starts_with` recovers the full value.
Impact
An authenticated user with update or delete permission on a collection can recover the values of fields in that collection that their read permissions hide from them. Each probe performs a real update or delete on the matched items, but only one the user was already permitted to make, so the impact is limited to confidentiality.
Workarounds
Until upgrading, avoid granting update or delete permission on collections that contain fields hidden from the same role by its read permissions.
Desglose de métricas
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
npmdirectus |
Corregida | 12.4.0 | -27 d | 12.6.1 no afectada |
12.4.0Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/directus/directus/security/advisories/GHSA-2xcm-7h22-3m66Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
