CVE-2023-31135 Dgraph Audit Log Encryption nonce reuse

Low 3.3 Published Updated

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.

PackageAffectedFixed in
github.com/dgraph-io/dgraph GoAll versions23.0.0
github.com/dgraph-io/dgraph GoAll versions23.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.

Sources

Also known as GHSA-92wq-q9pq-gw47.

Is CVE-2023-31135 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free