rustsec-2026-0207
Vulnerability from osv_rustsec
Published
2026-04-22 12:00
Modified
2026-07-17 11:34
Summary
Incorrect Output of Incremental Portable SHAKE API on Multiple Squeeze Calls
Details

The incremental squeeze functions in the portable SHAKE XOF API, when attempting to squeeze an output using multiple calls to squeeze, rather than squeezing the full output at once, could output incorrect values. Internally, output blocks that were not completely squeezed were not buffered for the next call to squeeze, which would consequently drop bytes of the correct squeeze output if the preceding call requested an output of length in bytes not cleanly divisible by RATE (168 for SHAKE128, 136 for SHAKE256).

Impact

This bug impacts users that rely on this XOF API to squeeze output in multiple calls where any of the calls request an output length that is not divisible by RATE. It does not impact the use of libcrux-sha3 in libcrux-ml-kem or libcrux-ml-dsa.

Mitigation

Starting from version 0.0.10 the squeeze functions correctly output all squeezed bytes independent of the number of squeeze calls and the output lengths requested in each call.


{
  "affected": [
    {
      "database_specific": {
        "categories": [],
        "cvss": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N",
        "informational": null
      },
      "ecosystem_specific": {
        "affected_functions": null,
        "affects": {
          "arch": [],
          "functions": [
            "libcrux_sha3::portable::incremental::Shake128Xof::squeeze",
            "libcrux_sha3::portable::incremental::Shake256Xof::squeeze"
          ],
          "os": []
        }
      },
      "package": {
        "ecosystem": "crates.io",
        "name": "libcrux-sha3",
        "purl": "pkg:cargo/libcrux-sha3"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0.0.0-0"
            },
            {
              "fixed": "0.0.10"
            }
          ],
          "type": "SEMVER"
        }
      ],
      "versions": []
    }
  ],
  "aliases": [],
  "database_specific": {
    "license": "CC0-1.0"
  },
  "details": "The incremental squeeze functions in the portable SHAKE XOF API, when\nattempting to squeeze an output using multiple calls to `squeeze`,\nrather than squeezing the full output at once, could output incorrect\nvalues. Internally, output blocks that were not completely squeezed\nwere not buffered for the next call to `squeeze`, which would\nconsequently drop bytes of the correct squeeze output if the preceding\ncall requested an output of length in bytes not cleanly divisible by\n`RATE` (168 for SHAKE128, 136 for SHAKE256).\n\n## Impact\nThis bug impacts users that rely on this XOF API to squeeze output in\nmultiple calls where any of the calls request an output length that is\nnot divisible by `RATE`. It does not impact the use of libcrux-sha3 in\nlibcrux-ml-kem or libcrux-ml-dsa.\n\n## Mitigation\nStarting from version `0.0.10` the squeeze functions correctly output\nall squeezed bytes independent of the number of `squeeze` calls and\nthe output lengths requested in each call.",
  "id": "RUSTSEC-2026-0207",
  "modified": "2026-07-17T11:34:24Z",
  "published": "2026-04-22T12:00:00Z",
  "references": [
    {
      "type": "PACKAGE",
      "url": "https://crates.io/crates/libcrux-sha3"
    },
    {
      "type": "ADVISORY",
      "url": "https://rustsec.org/advisories/RUSTSEC-2026-0207.html"
    },
    {
      "type": "WEB",
      "url": "https://github.com/celabshq/libcrux/pull/1389"
    }
  ],
  "related": [],
  "severity": [
    {
      "score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N",
      "type": "CVSS_V4"
    }
  ],
  "summary": "Incorrect Output of Incremental Portable SHAKE API on Multiple Squeeze Calls"
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

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…

Loading…