Many documentation examples can now be run online
Seb via Digitalmars-d-announce
digitalmars-d-announce at puremagic.com
Mon Dec 19 23:05:49 PST 2016
On Tuesday, 20 December 2016 at 06:16:23 UTC, Timothee Cour wrote:
> is it properly sandboxed / hacking proof?
>
> quick tests:
>
> ```
> import std.process;
> auto msg="sleep 10";
> executeShell(msg).output.writeln;
> ```
>
> correctly results in `Application output (9: Killed)`
>
> "ls -al .." => permission denied
>
> "ls /usr/bin/ld" => -rwxr-xr-x 2 0 0 834648 Jan 3 2013
> /usr/bin/ld
>
> "ps -auwx" => ...
>
It uses DPaste (https://dpaste.dzfl.pl/) as backend - in fact I
tried to re-use most of the code for the example snippet on
dlang.org
More information about the Digitalmars-d-announce
mailing list