vm2 is a sandbox that can run untrusted code with Node's built-in modules. In versions 3.9.17 and lower of vm2 it was possible to get a read-write reference to the node `inspect` method and edit options for `console.log`. As a result a threat actor can edit options for the `console.log` command. This vulnerability was patched in the release of version `3.9.18` of `vm2`. Users are advised to upgrade. Users unable to upgrade may make the `inspect` method readonly with `vm.readonly(inspect)` after creating a vm.
vm2 is a sandbox that can run untrusted code with Node's built-in modules. In versions 3.9.17 and lower of vm2 it was possible to get a read-write reference to the node `inspect` method and edit options for `console.log`. As a result a threat actor can edit options for the `console.log` command. This vulnerability was patched in the release of version `3.9.18` of `vm2`. Users are advised to upgrade. Users unable to upgrade may make the `inspect` method readonly with `vm.readonly(inspect)` after creating a vm.
vm2 is a sandbox that can run untrusted code with Node's built-in modules. In versions 3.9.17 and lower of vm2 it was possible to get a read-write reference to the node `inspect` method and edit options for `console.log`. As a result a threat actor can edit options for the `console.log` command. This vulnerability was patched in the release of version `3.9.18` of `vm2`. Users are advised to upgrade. Users unable to upgrade may make the `inspect` method readonly with `vm.readonly(inspect)` after creating a vm.
In versions 3.9.17 and lower of vm2 it was possible to get a read-write reference to the node `inspect` method and edit options for `console.log`.
### Impact
A threat actor can edit options for `console.log`.
### Patches
This vulnerability was patched in the release of version `3.9.18` of `vm2`.
### Workarounds
After creating a vm make the `inspect` method readonly with `vm.readonly(inspect)`.
### References
PoC - https://gist.github.com/arkark/c1c57eaf3e0a649af1a70c2b93b17550
### For more information
If you have any questions or comments about this advisory:
- Open an issue in [VM2](https://github.com/patriksimek/vm2)
Thanks to @arkark (Takeshi Kaneko) of GMO Cybersecurity by Ierae, Inc. for disclosing this vulnerability.
EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON.
Original publisher date fields
datePublished: May 15, 2023, 7:45:13 PM
dateUpdated: Jan 22, 2025, 9:42:56 PM
7 related source bulletins · separate from aliases
WID-SEC-W-2023-1217: vm2: Mehrere Schwachstellen
CVE-2023-32313 · CVE-2023-32314
RHSA-2023:3353: Red Hat Security Advisory: Multicluster Engine for Kubernetes 2.0.9 security fixes and container updates
CVE-2023-32313 · CVE-2023-32314
RHSA-2023:3326: Red Hat Security Advisory: Red Hat Advanced Cluster Management 2.6.6 security fixes and container updates
CVE-2023-28856 · CVE-2023-32313 · CVE-2023-32314
RHSA-2023:3296: Red Hat Security Advisory: Multicluster Engine for Kubernetes 2.2.4 security fixes and container updates
CVE-2023-32313 · CVE-2023-32314
RHSA-2023:3325: Red Hat Security Advisory: Multicluster Engine for Kubernetes 2.1.7 security fixes and container updates
CVE-2023-32313 · CVE-2023-32314
RHSA-2023:3297: Red Hat Security Advisory: Red Hat Advanced Cluster Management 2.7.4 security fixes and container updates
CVE-2023-32313 · CVE-2023-32314
RHSA-2023:3356: Red Hat Security Advisory: Red Hat Advanced Cluster Management 2.5.9 security fixes and container updates
CVE-2023-32313 · CVE-2023-32314
No normalized affected-package data is projected for this source revision. The original publisher record may contain additional product and version evidence; this does not establish that a package is unaffected.
NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON.
Source analysis status: Modified
Weakness classifications: CWE-74 · NVD-CWE-noinfo
Original publisher date fields
published: 2023-05-15T20:15:09.070
lastModified: 2026-06-17T05:58:32.993
1 source CPE criteria · context only
cpe:2.3:a:vm2_project:vm2:*:*:*:*:*:node.js:*:*
The original JSON retains the logical configuration operators, exclusions and version bounds.
No normalized affected-package data is projected for this source revision. The original publisher record may contain additional product and version evidence; this does not establish that a package is unaffected.