{"id":"GHSA-fpw7-j2hg-69v5","revision":"d2981ec10a2b463d8d141595e88b838c","records":[{"revision":"d2981ec10a2b463d8d141595e88b838c","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-fpw7-j2hg-69v5","aliases":["CVE-2024-21508"],"title":"mysql2 Remote Code Execution (RCE) via the readCodeFor function","description":"Versions of the package mysql2 before 3.9.4 are vulnerable to Remote Code Execution (RCE) via the `readCodeFor` function due to improper validation of the `supportBigNumbers` and `bigNumberStrings` values.","state":0,"publishedAt":"2024-04-11T06:30:35+00:00","modifiedAt":"2026-09-10T03:50:11.2126374+00:00","affected":[{"ecosystem":"npm","name":"mysql2","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"3.9.4"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"CRITICAL"}],"references":["https://nvd.nist.gov/vuln/detail/CVE-2024-21508","https://github.com/sidorares/node-mysql2/pull/2572","https://github.com/sidorares/node-mysql2/commit/74abf9ef94d76114d9a09415e28b496522a94805","https://blog.slonser.info/posts/mysql2-attacker-configuration","https://github.com/sidorares/node-mysql2","https://github.com/sidorares/node-mysql2/blob/1609b5393516d72a4ae47196837317fbe75e0c13/lib/parsers/text_parser.js%23L14C10-L14C21","https://github.com/sidorares/node-mysql2/releases/tag/v3.9.4","https://security.snyk.io/vuln/SNYK-JS-MYSQL2-6591085"],"sourceUrl":"https://github.com/advisories/GHSA-fpw7-j2hg-69v5","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-fpw7-j2hg-69v5","identifiers":["GHSA-fpw7-j2hg-69v5","CVE-2024-21508"]},"retained":false,"historicalAffected":[]}],"coverage":[]}