Panic Risk in AES Functions of Ring Package: RUSTSEC-2025-0009

ring Updated 02 Oct 2025

Summary

06/03/2025
N/A
Yes i
Unrated
Not published

RUSTSEC-2025-0009: Some AES functions may panic when overflow checking is enabled. Affects ring versions >= 0.0.0-0, < 0.17.12. Fixed in 0.17.12. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

The Ring package is a widely used cryptographic library in Rust, providing secure implementations of various cryptographic algorithms, including AES (Advanced Encryption Standard). It is designed for high performance and security, making it suitable for applications that require encryption, such as TLS and SSH. However, certain functions within the Ring package may panic under specific conditions, particularly when overflow checking is enabled, which can lead to denial-of-service vulnerabilities.

Vulnerability Detail

The vulnerability arises from the ring::aead::quic::HeaderProtectionKey::new_mask() function, which may panic when overflow checking is enabled. An attacker can exploit this by sending specially-crafted packets in the QUIC protocol, potentially causing a panic in the application. This situation can occur unintentionally in approximately 1 out of every 2^32 packets sent or received. On 64-bit systems, operations involving ring::aead::{AES_128_GCM, AES_256_GCM} may also panic when processing around 68.7 billion bytes of data in a single chunk. While protocols like TLS and SSH are not affected due to their chunking of data, applications that attempt to encrypt or decrypt large amounts of data in one go are at risk.

How To Fix

Minimum fixed version

0.17.12

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If you cannot update the package immediately, consider disabling overflow checks in your development environment. You can do this by removing or modifying the RUSTFLAGS in your build configuration. For example, ensure that you do not set RUSTFLAGS="-C overflow-checks" or set overflow-checks = false in your Cargo.toml profile.

Conclusion

The vulnerability identified as RUSTSEC-2025-0009 in the Ring package poses a significant risk of application panics under certain conditions. It is crucial for developers to update to version 0.17.12 or later to mitigate this risk. Additionally, understanding the implications of overflow checks and utilizing tools like Vulert can help maintain the security of your applications.

See every vulnerability recorded for ring →

Share this vulnerability

FAQ

The vulnerability can lead to application panics, resulting in denial-of-service conditions, especially when processing large data chunks or receiving malicious packets.

You can use Vulert, which monitors and alerts for open-source vulnerabilities in real-time. Visit Vulert Scanner to check if your application is affected without needing to sign up.

Overflow checks in Rust are safety checks that prevent arithmetic operations from exceeding the maximum value of a data type, which can lead to unexpected behavior or security vulnerabilities.

No, the vulnerability is present in versions prior to 0.17.12. Updating to this version or later will mitigate the issue.

As a temporary measure, consider disabling overflow checks in your development environment to avoid panics until you can update the package.

Related vulnerabilities

Recent vulnerabilities recorded for ring.

How To Fix

Minimum fixed version

0.17.12

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback