Proof of concept code for breaking out of docker via runC# Breaking out of Docker via RunC
A proof of concept code for CVE-2019-5736
This POC is heavily based on [YuvalAvra's POC](https://github.com/twistlock/RunC-CVE-2019-5736).
I do not claim any credit for the code utilised in this POC.
More information about this vulnerability and a demonstration of how it can be exploited can be found in the [worksheet](Worksheet.pdf).
Information in the worksheet is based a [blog post](https://www.twistlock.com/labs-blog/breaking-docker-via-runc-explaining-cve-2019-5736/)
by Twistlock Labs.
## Usage
This POC has the ability to modify binaries on the host system, therefore, is recommended to be conducted in a virtual machine.
The POC overwrites runC on the host machine with code to setup a persistent remote desktop using VNC
Clone the repository:
```shellscript
$ git clone https://github.com/RyanNgWH/CVE-2019-5736-POC
```
Build and run the Docker image:
```shellscript
$ docker build -t image_name:latest /path/to/malicious_image_POC
$ docker run --rm image_name:latest
```
[4.0K] /data/pocs/b9d9e460e77eaa40a4ede4b59dc9ade6c3fac842
├── [1006] Dockerfile
├── [1.7K] new_runc
├── [ 13K] overwrite_runc
├── [2.9K] overwrite_runc.c
├── [1.0K] README.md
├── [ 929] run_at_link.c
└── [2.4M] Worksheet.pdf
0 directories, 7 files