Comment Comment by fransr The page explicitly says: "Note: The vm module is not a security mechanism. Do not use it to run untrusted code."https://nodejs.org/api/vm.html#vm_vm_executing_javascript parent fransr 9 years ago
https://nodejs.org/api/vm.html#vm_vm_executing_javascript