{"id":"CVE-2023-30547","aliases":["CVE-2023-30547","GHSA-ch3r-j5x3-6q2m"],"related":[],"kind":"vulnerability","state":"published","title":"Sandbox Escape in vm2","summary":"vm2 is a sandbox that can run untrusted code with whitelisted Node's built-in modules. There exists a vulnerability in exception sanitization of vm2 for versions up to 3.9.16, allowing attackers to raise an unsanitized host exception inside `handleException()` which can be used to escape the sandbox and run arbitrary code in host context. This vulnerability was patched in the release of version `3.9.17` of `vm2`. There are no known workarounds for this vulnerability. Users are advised to upgrade.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"vm2 is a sandbox that can run untrusted code with whitelisted Node's built-in modules. There exists a vulnerability in exception sanitization of vm2 for versions up to 3.9.16, allowing attackers to raise an unsanitized host exception inside `handleException()` which can be used to escape the sandbox and run arbitrary code in host context. This vulnerability was patched in the release of version `3.9.17` of `vm2`. There are no known workarounds for this vulnerability. Users are advised to upgrade.","source":"cvelist"},{"lang":"en","text":"There exists a vulnerability in exception sanitization of vm2 for versions up to 3.9.16, allowing attackers to raise an unsanitized host exception inside `handleException()` which can be used to escape the sandbox and run arbitrary code in host context.\n\n### Impact\nA threat actor can bypass the sandbox protections to gain remote code execution rights on the host running the sandbox.\n\n### Patches\nThis vulnerability was patched in the release of version `3.9.17` of `vm2`.\n\n### Workarounds\nNone.\n\n### References\nPoC - https://gist.github.com/leesh3288/381b230b04936dd4d74aaf90cc8bb244\n\n### For more information\n\nIf you have any questions or comments about this advisory:\n\n- Open an issue in [VM2](https://github.com/patriksimek/vm2)\n\nThanks to [Xion](https://twitter.com/0x10n) (SeungHyun Lee) of [KAIST Hacking Lab](https://kaist-hacking.github.io/) for disclosing this vulnerability.","format":"markdown","source":"ghsa"}],"published":"2023-04-17T21:42:10.514Z","modified":"2026-06-17T05:54:59.793Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"rating":"CRITICAL"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:H","score":10,"rating":"CRITICAL"}],"cwes":["CWE-74"],"affected":[{"ranges":[{"version":"< 3.9.17","status":"affected"}],"vendor":"patriksimek","product":"vm2","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"3.9.17"}],"ecosystem":"npm","package":"vm2","purl":"pkg:npm/vm2","source":"ghsa"},{"ranges":[{"status":"affected","lastAffected":"3.9.16"}],"vendor":"vm2_project","product":"vm2","cpe":"cpe:2.3:a:vm2_project:vm2:*:*:*:*:*:node.js:*:*","source":"nvd"}],"references":[{"url":"https://github.com/patriksimek/vm2/security/advisories/GHSA-ch3r-j5x3-6q2m","tags":["exploit","vendor-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/patriksimek/vm2/commit/4b22e87b102d97d45d112a0931dba1aef7eea049","tags":["patch","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/patriksimek/vm2/commit/f3db4dee4d76b19869df05ba7880d638a880edd5","tags":["patch","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://gist.github.com/leesh3288/381b230b04936dd4d74aaf90cc8bb244","tags":["exploit","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2023-30547","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/patriksimek/vm2","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/patriksimek/vm2/releases/tag/3.9.17","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"yes","technicalImpact":"total","date":"2025-02-05T20:29:43.993Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2023-30547","url":"https://www.cve.org/CVERecord?id=CVE-2023-30547","licence":"CVE Terms of Use","modified":"2025-02-05T20:30:17.472Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-ch3r-j5x3-6q2m","url":"https://github.com/advisories/GHSA-ch3r-j5x3-6q2m","licence":"CC-BY-4.0","modified":"2023-11-08T04:12:25.205Z"},{"source":"nvd","name":"NVD","id":"CVE-2023-30547","url":"https://nvd.nist.gov/vuln/detail/CVE-2023-30547","licence":"Public domain","modified":"2026-06-17T05:54:59.793Z"}],"updatedAt":"2026-11-25T22:58:23.571Z","epss":{"score":0.10019,"percentile":0.96352,"date":"2026-11-30T12:00:22.000Z"}}