vm2 is vulnerable to Sandbox Escape
100
Critical Risk
vm2 exposes host functions to guest code through a bridge. When a non-strict host function is called with a nullish receiver (bareword, detached, or via call/apply/bind with no receiver), V8 binds this to the host realm global and the bridge passes that object into the sandbox. Guest code then uses the real host global to run commands through process.getBuiltinModule('child_process'), escaping the sandbox. The fix stores the host global at bridge initialization and returns undefined instead of passing it at the host to sandbox coercion points, while keeping strict function semantics.
You are affected if you are using a version that falls within the vulnerable range and your embedding code exposes a non-strict (sloppy mode) host function to the sandbox.
vm2 is vulnerable to Sandbox Escape in versions 3.9.6 - 3.12.0.
Upgrade the vm2 library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant
ISO 42001Compliant© All Intel data is openly available and commercially licensed.