CVE-2025-4432: Ring: some aes functions may panic when overflow checking is enabled in ring
ring::aead::quic::HeaderProtectionKey::newmask() may panic when overflow checking is enabled. In the QUIC protocol, an attacker can induce this panic by sending a specially-crafted packet. Even unintentionally it is likely to occur in 1 out of every 232 packets sent and/or received.
On 64-bit targets operations using ring::aead::{AES128GCM, AES256GCM} may panic when overflow checking is enabled, when encrypting/decrypting approximately 68,719,476,700 bytes (about 64 gigabytes) of data in a single chunk. Protocols like TLS and SSH are not affected by this because those protocols break large amounts of data into small chunks. Similarly, most applications will not attempt to encrypt/decrypt 64GB of data in one chunk.
Overflow checking is not enabled in release mode by default, but RUSTFLAGS="-C overflow-checks" or overflow-checks = true in the Cargo.toml profile can override this. Overflow checking is usually enabled by default in debug mode.
Other sources
A flaw was found in Rust's Ring package. A panic may be triggered when overflow checking is enabled. In the QUIC protocol, this flaw allows an attacker to induce this panic by sending a specially crafted packet. It will likely occur unintentionally in 1 out of every 232 packets sent or received.
— GitHub
Ring: some aes functions may panic when overflow checking is enabled in ring
— Microsoft
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
rust/ringto a version that resolves this vulnerability.Fixed in 0.17.13 - Upgrade
Upgrade
rust/ringto a version that resolves this vulnerability.Fixed in 0.17.12 - Configuration
Disable overflow checking so the panic condition in ring does not occur (overflow checking is overridden by RUSTFLAGS="-C overflow-checks" or overflow-checks=true in Cargo.toml profile).
Rust (compiler) / Cargo profiles overflow-checks (via -C overflow-checks or overflow-checks=true) = disable (do not set RUSTFLAGS="-C overflow-checks" and set overflow-checks=false) - Configuration
Ensure overflow checking is not enabled for the target build (overflow checking is usually enabled by default in debug mode).
Rust (compiler) / Cargo profiles overflow-checks (debug mode) = disable for affected builds - Compensating control
For QUIC deployments, reduce exposure by ensuring the application processes QUIC traffic in a way that prevents the specially-crafted packets from being able to trigger ring panics (e.g., deploy network-level filtering/inspection to block maliciously crafted QUIC packets).
Event History
Frequently Asked Questions
What is the severity of CVE-2025-4432?
CVE-2025-4432 has a moderate severity as it can lead to a denial of service through a panic in the QUIC protocol.
How do I fix CVE-2025-4432?
To fix CVE-2025-4432, upgrade the Rust Ring library to version 0.17.13 or later.
What causes the panic in CVE-2025-4432?
The panic in CVE-2025-4432 is caused by overflow checking in the `ring::aead::quic::HeaderProtectionKey::new_mask()` function when processing specially-crafted QUIC packets.
Who is affected by CVE-2025-4432?
CVE-2025-4432 affects users of the Rust Ring library that utilize QUIC protocol implementations.
Is CVE-2025-4432 being actively exploited?
Currently, there have been no reported active exploits for CVE-2025-4432, but potential exploitation could occur given the nature of the vulnerability.