Vulnerability MediumRUSTSEC-2025-0144 · ml-dsa
RUSTSEC-2025-0144: Timing side-channel in ML-DSA decomposition
Short answerA security vulnerability in the ml-dsa crate: Timing side-channel in ML-DSA decomposition. Medium severity (CVSS 6.4). Fixed in 0.1.0-rc.3: update to a fixed version.
| Crate | ml-dsa |
|---|---|
| Type | Vulnerability (crypto-failure) |
| Affected versions | Before 0.1.0-rc.3. |
| Fixed in | 0.1.0-rc.3 |
| Severity | Medium, CVSS 6.4 CVSS:3.1/AV:A/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N |
| Published | 2025-12-12 |
| Last changed | 2026-10-12 |
| Also known as | CVE-2026-22705, GHSA-hcp2-x6j4-29j7 |
What to do
- See which version you have:
cargo tree -i ml-dsa(it also shows which of your dependencies pulls it in). - Update within your version requirement:
cargo update -p ml-dsa. If the fix is a newer major or minor than your requirement allows, raise it in Cargo.toml (for exampleml-dsa = "0.1.0-rc.3") or update the dependency that pulls it in. - Check again with
cargo audit, or paste your Cargo.lock into our Cargo.toml checker.
Details from the advisory
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()wherecs2is derived from secret key components2Hint::new()callshigh_bits()on values derived from secret key componentt0
**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.
References
- Package: crates.io/crates/ml-dsa
- Advisory: rustsec.org/advisories/RUSTSEC-2025-0144.html
- Web: github.com/RustCrypto/signatures/pull/1144
From the RustSec Advisory Database (CC0-1.0) via the OSV export, downloaded Oct 24, 2026. Severity score computed from the published CVSS vector.
Other advisories for ml-dsa
Up next
Same crateml-dsa: security historyEvery advisory for this crate, and whether it is safe to use today.Read it next →Did this answer your question?