CVE-2024-21236

4.9 MEDIUM

📋 TL;DR

This vulnerability in MySQL Server's InnoDB component allows high-privileged attackers with network access to cause a denial of service by crashing or hanging the server. It affects MySQL Server versions 8.0.39 and prior, 8.4.2 and prior, and 9.0.1 and prior. The attack requires administrative database privileges but is easily exploitable via multiple network protocols.

💻 Affected Systems

Products:
  • Oracle MySQL Server
Versions: 8.0.39 and prior, 8.4.2 and prior, 9.0.1 and prior
Operating Systems: All operating systems running affected MySQL versions
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects MySQL installations with InnoDB storage engine enabled (default). Requires attacker to have high database privileges (CREATE USER, GRANT OPTION, SYSTEM_VARIABLES_ADMIN, or SUPER).

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete unavailability of MySQL Server, disrupting all database-dependent applications and services until manual restart.

🟠

Likely Case

Targeted DoS attacks against critical MySQL instances by malicious insiders or compromised admin accounts, causing service disruption.

🟢

If Mitigated

Limited impact due to proper access controls and network segmentation preventing unauthorized high-privileged access.

🌐 Internet-Facing: MEDIUM - While exploitable over network, requires high privileges which are typically not exposed to internet-facing interfaces.
🏢 Internal Only: HIGH - Internal attackers with admin credentials or compromised admin accounts can easily exploit this to disrupt critical database services.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: LOW

Oracle rates this as 'Easily exploitable' but requires high privileged attacker. No public exploit details available as of analysis.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 8.0.40, 8.4.3, 9.0.2 or later

Vendor Advisory: https://www.oracle.com/security-alerts/cpuoct2024.html

Restart Required: Yes

Instructions:

1. Download latest MySQL patch from Oracle website. 2. Backup databases. 3. Stop MySQL service. 4. Apply patch/upgrade. 5. Restart MySQL service. 6. Verify version with 'SELECT VERSION();'

🔧 Temporary Workarounds

Restrict administrative access

all

Limit high-privileged database accounts to only necessary personnel and systems

REVOKE CREATE USER, GRANT OPTION, SYSTEM_VARIABLES_ADMIN, SUPER FROM unauthorized_users;
FLUSH PRIVILEGES;

Network segmentation

linux

Restrict network access to MySQL ports (default 3306) to only trusted hosts

iptables -A INPUT -p tcp --dport 3306 -s trusted_ip -j ACCEPT
iptables -A INPUT -p tcp --dport 3306 -j DROP

🧯 If You Can't Patch

  • Implement strict principle of least privilege for database accounts
  • Monitor for unusual administrative activity and failed authentication attempts

🔍 How to Verify

Check if Vulnerable:

Run 'SELECT VERSION();' in MySQL and compare against affected versions: if version is 8.0.39 or lower, 8.4.2 or lower, or 9.0.1 or lower, system is vulnerable.

Check Version:

mysql -u root -p -e 'SELECT VERSION();'

Verify Fix Applied:

After patching, run 'SELECT VERSION();' and confirm version is 8.0.40+, 8.4.3+, or 9.0.2+.

📡 Detection & Monitoring

Log Indicators:

  • Unexpected MySQL crashes or restarts
  • Multiple failed authentication attempts followed by successful admin login
  • Unusual administrative queries from unexpected sources

Network Indicators:

  • Multiple connections to MySQL port 3306 from single source followed by service disruption
  • Unusual traffic patterns to MySQL administrative interfaces

SIEM Query:

source="mysql.log" ("Access denied" AND "root" OR "admin") OR "mysqld shutdown" OR "crash recovery"

🔗 References

📤 Share & Export