4 ms·
What about Node.js's `vm` module?
by SomeHacker44 10y ago
What about Node.js's `vm` module?
- novaleaf 10y agothanks, I didn't actually know about that. it looks like a perfect (and simple) solution for running on nodejs. wish there was something like that for browsers too! edit: i guess there is this: https://github.com/substack/vm-browserify https://github.com/substack/vm-browserify
- AgentME 10y agoNote that the vm module doesn't protect against local denial-of-service attacks: user-written javascript executed with it could allocate tons of memory or run forever (despite any configured timeouts: https://github.com/nodejs/node/issues/3020 https://github.com/nodejs/node/issues/3020).