rustsec-2026-0075
Vulnerability from osv_rustsec
Published
2026-03-04 12:00
Modified
2026-03-27 05:55
Summary
All-Zero Key Generation on Catastrophic RNG Failure
Details

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": [
    {
      "database_specific": {
        "categories": [],
        "cvss": "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",
        "informational": null
      },
      "ecosystem_specific": {
        "affected_functions": null,
        "affects": {
          "arch": [],
          "functions": [
            "libcrux_ed25519::generate_key_pair"
          ],
          "os": []
        }
      },
      "package": {
        "ecosystem": "crates.io",
        "name": "libcrux-ed25519",
        "purl": "pkg:cargo/libcrux-ed25519"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0.0.0-0"
            },
            {
              "fixed": "0.0.7"
            }
          ],
          "type": "SEMVER"
        }
      ],
      "versions": []
    }
  ],
  "aliases": [
    "GHSA-434v-x5qv-pmh6"
  ],
  "database_specific": {
    "license": "CC0-1.0"
  },
  "details": "The libcrux-ed25519 key generation samples Ed25519 secret keys from a\nprovided CSPRNG in a loop for up to 100 attempts until a non-zero key\nis found.  If a non-zero key could not be sampled within 100 attempts\nthe key generation function would silently continue with an all-zero buffer as\nthe secret key.\n\n## Impact\nThis bug only occurs in the event of a catastrophic failure of the\nCSPRNG, but would allow anyone to forge signatures under the resulting\nstatic signing key.\n\n## Mitigation\nInstead of silently continuing with an all-zero signing key, starting\nfrom version `0.0.7` key generation will error in the case of 100\nfailed attempts at sampling a valid key.",
  "id": "RUSTSEC-2026-0075",
  "modified": "2026-03-27T05:55:06Z",
  "published": "2026-03-04T12:00:00Z",
  "references": [
    {
      "type": "PACKAGE",
      "url": "https://crates.io/crates/libcrux-ed25519"
    },
    {
      "type": "ADVISORY",
      "url": "https://rustsec.org/advisories/RUSTSEC-2026-0075.html"
    },
    {
      "type": "WEB",
      "url": "https://github.com/cryspen/libcrux/pull/1349"
    }
  ],
  "related": [],
  "severity": [
    {
      "score": "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",
      "type": "CVSS_V4"
    }
  ],
  "summary": "All-Zero Key Generation on Catastrophic RNG Failure"
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.


Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…