CVE-2025-24294
📋 TL;DR
This vulnerability allows attackers to cause denial of service by sending specially crafted DNS packets with highly compressed domain names. When parsed by Ruby's resolv library, these packets trigger excessive CPU consumption, making applications unresponsive. This affects any Ruby application using the resolv library for DNS resolution.
💻 Affected Systems
- Ruby
⚠️ Manual Verification Required
This CVE does not have specific version information in our database, so automatic vulnerability detection cannot determine if your system is affected.
Why? The CVE database entry doesn't specify which versions are vulnerable (no version ranges provided by the vendor/NVD).
🔒 Custom verification scripts are available for registered users. Sign up free to download automated test scripts.
- Review the CVE details at NVD
- Check vendor security advisories for your specific version
- Test if the vulnerability is exploitable in your environment
- Consider updating to the latest version as a precaution
⚠️ Risk & Real-World Impact
Worst Case
Complete service outage where affected Ruby applications become unresponsive, requiring restart and potentially causing cascading failures in dependent services.
Likely Case
Degraded performance or temporary unavailability of Ruby applications processing DNS queries, particularly affecting services with high DNS resolution needs.
If Mitigated
Minimal impact with proper rate limiting, network filtering, and updated libraries preventing malicious packets from reaching vulnerable systems.
🎯 Exploit Status
Exploitation requires sending crafted DNS packets to vulnerable systems, which is straightforward for attackers with network access. No authentication required.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Ruby 3.2.7, Ruby 3.3.5, Ruby 3.4.2
Vendor Advisory: https://www.ruby-lang.org/en/news/2025/07/08/dos-resolv-cve-2025-24294/
Restart Required: Yes
Instructions:
1. Update Ruby to patched version using your package manager or Ruby version manager. 2. For Ruby 3.2.x: Update to 3.2.7. 3. For Ruby 3.3.x: Update to 3.3.5. 4. For Ruby 3.4.x: Update to 3.4.2. 5. Restart all Ruby applications and services.
🔧 Temporary Workarounds
Network filtering for DNS packets
allBlock or rate limit incoming DNS packets at network perimeter to prevent malicious packets from reaching vulnerable systems.
Use alternative DNS resolution
allConfigure applications to use alternative DNS libraries or services not based on Ruby's resolv library.
🧯 If You Can't Patch
- Implement strict rate limiting on DNS queries at application or network level
- Deploy network monitoring to detect and block anomalous DNS traffic patterns
🔍 How to Verify
Check if Vulnerable:
Check Ruby version with 'ruby --version'. If version is between 3.2.0-3.2.6, 3.3.0-3.3.4, or 3.4.0-3.4.1, system is vulnerable if using resolv library.
Check Version:
ruby --version
Verify Fix Applied:
After updating, verify with 'ruby --version' shows 3.2.7, 3.3.5, or 3.4.2 or higher. Test DNS resolution functionality remains operational.
📡 Detection & Monitoring
Log Indicators:
- Unusual CPU spikes in Ruby processes
- Increased DNS query timeouts
- Application restarts due to unresponsiveness
Network Indicators:
- High volume of DNS queries to Ruby applications
- DNS packets with unusual compression patterns
SIEM Query:
source="ruby_app_logs" AND ("CPU 100%" OR "unresponsive" OR "DNS timeout")