CVE-2024-21511CWE-94

Versions of the package mysql2 before 3.9.7 are vulnerable to Arbitrary Code Injection due to improper sanitization of the timezone parameter in the…

Critical · published April 23, 2024

CVSS v3.1
9.8
EPSS
1%
Percentile
63.5
In the wild
Unconfirmed
What it is

🔥 A timezone parameter in MySQL? It sounds harmless, but it could let an attacker run code on your server! Think of it like a restaurant that accepts any dinner reservation without checking the guest list. A crafty diner could not only take a table but also decide what dishes get served! With this vulnerability, an attacker could inject arbitrary code into your MySQL server, leading to complete system compromise. Imagine someone walking into your restaurant and rewriting the menu — they could manipulate your database, steal sensitive information, or even wipe everything clean. Absolutely devastating!

Put simply

Think of it like a restaurant that accepts any dinner reservation without checking the guest list. A crafty diner could not only take a table but also decide what dishes get served! The issue arises from improper sanitization of the timezone parameter in the readCodeFor function, allowing malicious input to bypass security checks and execute code on the server.

What to do

With this vulnerability, an attacker could inject arbitrary code into your MySQL server, leading to complete system compromise. Imagine someone walking into your restaurant and rewriting the menu — they could manipulate your database, steal sensitive information, or even wipe everything clean. Absolutely devastating! Upgrade your mysql2 package to version 3.9.7 or later immediately to close this hole. Additionally, review your code to ensure that all parameters are validated and sanitized properly. Don't leave any room for errors! You've got this! Take action now to protect your server and keep your data safe. 🛡️

The record
Technical detail
CVSS v3.1
9.8 · CRITICAL
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H/E:P
CVSS v4.0
Not supplied
EPSS
0.01034 · 63.5th percentile
Weakness
CWE-94 · Improper Control of Generation of Code ('Code Injection')
Published
2024-04-23T05:00Z
EPSS history
Timeline
  • 23 APR 05:00Z
    Versions of the package mysql2 before 3.9.7 are vulnerable to Arbitrary Code Injection due to improper sanitization of the timezone parameter in the…
    cvelistv5