start: make us dumpable
start: make us dumpable

When set set{u,g}id() the kernel will make us undumpable. This is unnecessary
since we can guarantee that whatever is running inside the child process at
this point this is fully trusted by the parent. Making us dumpable let's users
use debuggers on the child process before the exec as well and also allows us
to open /proc/<child-pid> files in lieu of the child.
Note, that we only need to perform the prctl(PR_SET_DUMPABLE, ...) if our
effective uid on the host is not 0. If our effective uid on the host is 0 then
we will keep all capabilities in the child user namespace across set{g,u}id().

Signed-off-by: Christian Brauner <48455ab3070520a2d174545c7239d6d0fabd9a83@ubuntu.com>

ss1h2a3tw/lxc,caglar10ur/lxc,thmo/lxc,caglar10ur/lxc,thmo/lxc,ss1h2a3tw/lxc,thmo/lxc,hallyn/lxc,caglar10ur/lxc,ss1h2a3tw/lxc,hallyn/lxc,hallyn/lxc