Description
vm2 before 3.11.7 contains a remote code execution vulnerability when require.external is enabled without an explicit require.root that excludes node_modules. Sandboxed code can require vm2's own package, instantiate an unrestricted NodeVM instance, and execute arbitrary host OS commands via child_process.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| patriksimek | vm2 | < 3.11.7 | 3.11.7 |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| npm | vm2 | < 3.11.7 | 3.11.7 | GHSA-j3hm-6rg5-mchv |
Advisories 1
- WID-SEC-2026-2997 vm2: Mehrere Schwachstellen BSI CERT-Bund (WID) · Oct 27, 2026
References
- GitHub Security Advisory (GHSA-j3hm-6rg5-mchv) vendor-advisory
- VulnCheck Advisory: vm2 before 3.11.7 Remote Code Execution via require.external third-party-advisory