3.3low
Dgraph Audit Log Encryption nonce reuse
- Severity
- 3.3low CVSS:3.1 by GitHub_M
- Exploit likelihood
- 0.15% (higher than 4% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-92wq-q9pq-gw47
Description
Dgraph is an open source distributed GraphQL database. Existing Dgraph audit logs are vulnerable to brute force attacks due to nonce collisions. The first 12 bytes come from a baseIv which is initialized when an audit log is created. The last 4 bytes come from the length of the log line being encrypted. This is problematic because two log lines will often have the same length, so due to these collisions we are reusing the same nonce many times. All audit logs generated by versions of Dgraph <v23.0.0 are affected. Attackers must have access to the system the logs are stored on. Dgraph users should upgrade to v23.0.0. Users unable to upgrade should store existing audit logs in a secure location and for extra security, encrypt using an external tool like `gpg`.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| dgraph-io dgraph | < 23.0.0 | CVE List |
| github.com/dgraph-io/dgraph (Go) | before 23.0.0 | GitHub Advisory Database |
| dgraph dgraph | before 23.0.0 | NVD |
All scores
| GitHub_M | 3.3low CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N |
| GitHub | 5.5medium CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N |
| NVD | 5.5medium CVSS:3.1 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N |
Classification
SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.
What each source says
CVE List
Dgraph is an open source distributed GraphQL database. Existing Dgraph audit logs are vulnerable to brute force attacks due to nonce collisions. The first 12 bytes come from a baseIv which is initialized when an audit log is created. The last 4 bytes come from the length of the log line being encrypted. This is problematic because two log lines will often have the same length, so due to these collisions we are reusing the same nonce many times. All audit logs generated by versions of Dgraph <v23.0.0 are affected. Attackers must have access to the system the logs are stored on. Dgraph users should upgrade to v23.0.0. Users unable to upgrade should store existing audit logs in a secure location and for extra security, encrypt using an external tool like `gpg`.
GitHub Advisory Database
Impact
Existing Dgraph audit logs are vulnerable to brute force attacks due to nonce collisions. All audit logs generated by versions of Dgraph <v23.0.0 are affected.
Patches
This issue was patched in https://github.com/dgraph-io/dgraph/pull/8323. Dgraph users should upgrade to v23.0.0.
Workarounds
Store existing audit logs in a secure location. For extra security, encrypt using a tool like gpg.
References
See https://github.com/dgraph-io/dgraph/pull/8323 for more context on the vulnerability.
NVD (es)
Dgraph es una base de datos GraphQL distribuida de código abierto. Los registros de auditoría de Dgraph existentes son vulnerables a ataques de fuerza bruta debido a colisiones de nonce. Los primeros 12 bytes provienen de un baseIv que se inicializa cuando se crea un registro de auditoría. Los últimos 4 bytes provienen de la longitud de la línea de registro que se está cifrando. Esto es problemático porque dos líneas de registro a menudo tendrán la misma longitud, por lo que debido a estas colisiones estamos reutilizando el mismo nonce muchas veces. Todos los registros de auditoría generados por versiones de Dgraph anterior a v23.0.0 están afectados. Los atacantes deben tener acceso al sistema donde se almacenan los registros. Los usuarios de Dgraph deben actualizar a v23.0.0. Los usuarios que no puedan actualizar deben almacenar los registros de auditoría existentes en una ubicación segura y, para mayor seguridad, cifrarlos utilizando una herramienta externa como 'gpg'.
References
| https://github.com/dgraph-io/dgraph/security/advisories/GHSA-92wq-q9pq-gw47 | vendor-advisory, web | |
| https://github.com/dgraph-io/dgraph/pull/8323 | issue-tracking, patch, web | |
| https://en.wikipedia.org/wiki/Cryptographic_nonce | technical-description, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2023-31135 | advisory | |
| https://github.com/dgraph-io/dgraph | package | |
| https://github.com/dgraph-io/dgraph/releases/tag/v23.0.0 | web | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2023-31135 changed 2025-01-22 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-92wq-q9pq-gw47 changed 2023-11-08 | CC-BY-4.0 |
| NVD | CVE-2023-31135 changed 2026-10-23 | Public domain |