vm2 information disclosure via util.getCallSites()

Severity: medium · CVSS 5.8 · Published 2026-09-17

vm2 is a sandbox that runs untrusted Node.js code in isolation. A flaw in how the sandbox exposes Node.js utility functions allows attacker-controlled code to call util.getCallSites(), which leaks sensitive host process information including file paths, function names, and internal bridge details that should be hidden. An attacker can use this information to better understand the host environment and potentially launch further attacks.

Technologies: vm2 (npm), Patriksimek Vm2. Vendors: npm, Patriksimek.

Quick answers

Is This vulnerability exploited in the wild?
No. Junglewise Threat Intelligence has no report of This vulnerability being exploited in the wild.
How severe is This vulnerability?
Medium severity, with a CVSS score of 5.8, published 17 September 2026.
Which products and versions are affected?
vm2 (npm) <= 3.11.7; Patriksimek Vm2 <= 3.11.7.
Is there a fix for This vulnerability?
Yes: fixed in 3.11.8. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is This vulnerability attacked?
It is attacked over the network, in a software library.
Am I affected?
Check whether you run vm2 (npm) or Patriksimek Vm2 at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • Fixed in: 3.11.8

Technical details

vm2 exposes the host util module as an unfiltered shallow copy and the deprecated sys builtin through the generic builtin loader. On Node.js >= 22.9, this grants sandboxed code access to util.getCallSites(), a stack-introspection API that returns the full host call stack with absolute file paths and function names. This bypasses existing host-frame redaction in GHSA-v27g-jcqj-v8rw, which only applies to Error.prepareStackTrace formatting; getCallSites() is a separate information disclosure channel.

Affected products

  • patriksimek vm2 <= 3.11.7

Timeline

  • 2026-08-27: disclosed
  • 2026-08-27: patched: Fixed in version 3.11.8
  • 2026-09-17: advisory

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.