3 ms·
But couldn’t the code you download easily just execute `rm -rf / --no-preserve-root`? The problem isn’t executing code from a random URL (which NPM still has);
by colejohnson66 6y ago
But couldn’t the code you download easily just execute `rm -rf / --no-preserve-root`? The problem isn’t executing code from a random URL (which NPM still has); it’s that even though there’s a sandbox, there’s still ways out of it.
- earthboundkid 6y agoNot in Deno. To run that, you’d need to shell out, which Deno won’t let you do without explicitly granted permission at the CLI.
- jdminhbg 6y agoOthers have noted Deno has good protections around this, but I would add that it has those because running a package from NPM is in and of itself just executing code from a random URL, and that has caused plenty of problems in the past.