GHSA-434v-x5qv-pmh6
high
libcrux has All-Zero Key Generation Upon Catastrophic RNG Failure
- Severity
- high CVSS:4.0 by GitHub
- Published
- Last changed
- Also known as
- RUSTSEC-2026-0075
Description
The libcrux-ed25519 key generation samples Ed25519 secret keys from a provided CSPRNG in a loop for up to 100 attempts until a non-zero key is found. If a non-zero key could not be sampled within 100 attempts the key generation function would silently continue with an all-zero buffer as the secret key.
Impact
This bug only occurs in the event of a catastrophic failure of the CSPRNG, but would allow anyone to forge signatures under the resulting static signing key.
Mitigation
Instead of silently continuing with an all-zero signing key, starting from version 0.0.7 key generation will error in the case of 100 failed attempts at sampling a valid key.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| libcrux-ed25519 (crates.io) | before 0.0.7, from 0.0.0-0 before 0.0.7 | GitHub Advisory Database, RustSec Advisory Database |
All scores
| GitHub | high CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N |
| RustSec Advisory Database | Not scored CVSS:4.0 | CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N |
Classification
References
Sources
| Source | Record | Licence |
|---|---|---|
| GitHub Advisory Database | GHSA-434v-x5qv-pmh6 changed 2026-03-27 | CC-BY-4.0 |
| RustSec Advisory Database | RUSTSEC-2026-0075 changed 2026-03-27 | CC0-1.0 |