curl -sSL -o clone.c goo.gl/G45N5X
# on host
ip a
# add CLONE_NEWNET
gcc -o net -w clone.c
./net ip a
unshare --net ip a
# no flags
gcc -o uts -w clone.c
./uts hostname
# add CLONE_NEWUTS
# uncomment hostname code
gcc -o uts -w clone.c
./uts hostname
unshare --uts -- /bin/bash -c 'hostname thing && hostname'
# host, create a message
ipcmk -Q
# no flags
gcc -o ipc -w clone.c
./ipc ipcs -q
# add CLONE_NEWIPC
gcc -o ipc -w clone.c
./ipc ipcs -q
unshare --ipc -- ipcs -q
# no flags
gcc -o user -w clone.c
./user ls -la
# add CLONE_NEWUSER
gcc -o user -w clone.c
./user ls -la
unshare --user -- ls -la
# add CLONE_NEWPID
gcc -o pid -w clone.c
# run binary
./pid ps aux
# shows all processes
# add CLONE_NEWNS
# uncomment mounting of proc
gcc -o pid -w clone.c
# run binary
./pid ps aux