Loading...
Skip to main content
npm (Node.js)

mysql2 Known Vulnerabilities & Fixes

mysql2 has 2 known security vulnerabilities in npm (Node.js). Upgrade to version 3.9.7 or later to resolve all known issues. Data sourced from OSV, enriched with EPSS exploit probability and CISA KEV.

2 Vulnerabilities

Low Immediate Risk

No actively exploited vulnerabilities detected. Monitor and update in your next maintenance window.

Recommended safe version: 3.9.7

Upgrading to 3.9.7 or later resolves all 2 known vulnerabilities in mysql2. Run: npm install mysql2@3.9.7

Is mysql2 in your project?

Check if you're affected and upgrade to 3.9.7 to stay secure.

2
Total
2
Critical
0
High
0
Medium
0
Low

Security Summary

  • 2 affected version ranges have been identified across these 2 advisories.
  • 100% of known issues have a published fixed version.
  • Remediation: npm update mysql2

Vulnerabilities

2 unique vulnerabilities — sorted by exploitation risk (KEV → EPSS → CVSS). Click a CVE/GHSA ID for full details. First disclosed Apr 11, 2024, most recently Apr 23, 2024 (12 days apart).

CVE / GHSASeverityAffectedFixed In
CVE-2024-21511
MySQL2 for Node Arbitrary Code Injection
CRITICAL
All versions3.9.7
CVE-2024-21508
mysql2 Remote Code Execution (RCE) via the readCodeFor function
CRITICAL
All versions3.9.4

About This Data

Vulnerability data for mysql2 is sourced from the Open Source Vulnerability (OSV) database, aggregating reports from GitHub Advisory Database, NIST NVD, and ecosystem-specific sources.

CVSS (Common Vulnerability Scoring System) scores reflect exploitability and impact. EPSS (Exploit Prediction Scoring System) scores indicate the probability of exploitation within the next 30 days. Vulnerabilities marked with are listed in the CISA Known Exploited Vulnerabilities (KEV) catalog.

Related npm (Node.js) Packages

Other packages in this ecosystem, ranked by shared vulnerabilities where available.

Check Your Dependencies

Scan your project to check if you're using a vulnerable version of mysql2.

Data from OSV DatabaseUpdated daily200K+ vulnerabilities indexed