RUSTSEC-2025-0144

Source
https://rustsec.org/advisories/RUSTSEC-2025-0144
Import Source
https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2025-0144.json
JSON Data
https://api.osv.dev/v1/vulns/RUSTSEC-2025-0144
Aliases
Published
2025-12-12T12:00:00Z
Modified
2026-01-27T22:41:06.279630Z
Severity
  • 6.4 (Medium) CVSS_V3 - CVSS:3.1/AV:A/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N CVSS Calculator
Summary
Timing side-channel in ML-DSA decomposition
Details

Summary

A timing side-channel was discovered in the Decompose algorithm which is used during ML-DSA signing to generate hints for the signature.

Details

The analysis was performed using a constant-time analyzer that examines compiled assembly code for instructions with data-dependent timing behavior. The analyzer flags:

  • UDIV/SDIV instructions: Hardware division instructions have early termination optimizations where execution time depends on operand values.

The decompose function used a hardware division instruction to compute r1.0 / TwoGamma2::U32. This function is called during signing through high_bits() and low_bits(), which process values derived from secret key components:

  • (&w - &cs2).low_bits() where cs2 is derived from secret key component s2
  • Hint::new() calls high_bits() on values derived from secret key component t0

Original Code:

fn decompose<TwoGamma2: Unsigned>(self) -> (Elem, Elem) {
    // ...
    let mut r1 = r_plus - r0;
    r1.0 /= TwoGamma2::U32;  // Variable-time division on secret-derived data
    (r1, r0)
}

Impact

The dividend (r1.0) is derived from secret key material. An attacker with precise timing measurements could extract information about the signing key by observing timing variations in the division operation.

Mitigation

Integer division was replaced with a constant-time Barrett reduction.

Database specific
{
    "license": "CC-BY-4.0"
}
References

Affected packages

crates.io / ml-dsa

Package

Affected ranges

Type
SEMVER
Events
Introduced
0.0.0-0
Fixed
0.1.0-rc.3

Ecosystem specific

{
    "affects": {
        "functions": [],
        "os": [],
        "arch": []
    },
    "affected_functions": null
}

Database specific

source
"https://github.com/rustsec/advisory-db/blob/osv/crates/RUSTSEC-2025-0144.json"
categories
[
    "crypto-failure"
]
cvss
"CVSS:3.1/AV:A/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N"
informational
null