CVE-2023-31135 Dgraph Audit Log Encryption nonce reuse
Attackers with log access can brute-force decrypt Dgraph audit logs due to nonce reuse in encryption.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- Available
What is CVE-2023-31135?
CVE-2023-31135 is a low-severity vulnerability in dgraph-io dgraph, published on 17 May 2023. It can only be exploited from the same machine or local network, with no action from the victim.
Official 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`.
Weakness: CWE-326
Which versions are affected by CVE-2023-31135?
2 open source packages ship an affected version, including github.com/dgraph-io/dgraph. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
github.com/dgraph-io/dgraph Go | All versions | 23.0.0 |
github.com/dgraph-io/dgraph Go | All versions | 23.0.0 |
Products include Dgraph Dgraph.
How do I fix CVE-2023-31135?
Upgrade github.com/dgraph-io/dgraph to 23.0.0 or later.
Is CVE-2023-31135 being exploited?
There is no known exploitation of CVE-2023-31135 in the wild and no public exploit code.
Other vulnerabilities in dgraph-io dgraph
- CVE-2026-34976 Dgraph Affected by Pre-Auth Database Overwrite + SSRF + File Read via restoreTenant Missing Authorization
- CVE-2026-41492 Unauthenticated Admin Token Disclosure Leading to Authentication Bypass via /debug/vars in Dgraph
- CVE-2026-40173 Dgraph: Unauthenticated pprof endpoint leaks admin auth token
- CVE-2026-41327 Dgraph: Pre-Auth Full Database Exfiltration via DQL Injection in Upsert Condition Field
- CVE-2026-41328 Dgraph: Pre-Auth Full Database Exfiltration via DQL Injection in NQuad Lang Field
Sources
Also known as GHSA-92wq-q9pq-gw47.