Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Would this allow to safely eval Node.js code in a sandbox?


Not "Node.js code" specifically as Node.js itself can't be compiled to wasm. JavaScript can be compiled to wasm, but that won't include the whole Node.js standard library and doesn't seem to be what you are asking.

Check out Deno for a sandbox that is getting there. Their new release does (aim to) support most Node.js code, where it previously and intentionally did not support node_modules nor CommonJS to the best of my knowledge.

If you care more about wasm than sandboxing in general, one project called javy is interesting, but you'll quickly notice they bring their own IO library and not much else in terms of something that compares to Node.js' API.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: