diff options
Diffstat (limited to 'images/syzkaller')
-rw-r--r-- | images/syzkaller/Dockerfile | 11 | ||||
-rw-r--r-- | images/syzkaller/README.md | 58 | ||||
-rw-r--r-- | images/syzkaller/default-gvisor-config.cfg | 15 |
3 files changed, 0 insertions, 84 deletions
diff --git a/images/syzkaller/Dockerfile b/images/syzkaller/Dockerfile deleted file mode 100644 index 9a85ae345..000000000 --- a/images/syzkaller/Dockerfile +++ /dev/null @@ -1,11 +0,0 @@ -FROM gcr.io/syzkaller/env - -# This image is mostly for investigating syzkaller crashes, so let's install -# developer tools. -RUN apt update && apt install -y git vim strace gdb procps - -WORKDIR /syzkaller/gopath/src/github.com/google/syzkaller - -RUN git init . && git remote add origin https://github.com/google/syzkaller && git fetch origin && git checkout origin/master && make - -ENTRYPOINT ./bin/syz-manager --config /tmp/syzkaller/syzkaller.cfg diff --git a/images/syzkaller/README.md b/images/syzkaller/README.md deleted file mode 100644 index 7e500cab3..000000000 --- a/images/syzkaller/README.md +++ /dev/null @@ -1,58 +0,0 @@ -syzkaller is an unsupervised coverage-guided kernel fuzzer. - -* [Github](https://github.com/google/syzkaller) -* [gVisor dashboard](https://syzkaller.appspot.com/gvisor) - -# How to run syzkaller. - -First, we need to load a syzkaller docker image: - -```bash -make load-syzkaller -``` - -or we can rebuild it to use an up-to-date version of the master branch: - -```bash -make rebuild-syzkaller -``` - -Then we need to create a directory with all artifacts that we will need to run a -syzkaller. Then we will bind-mount this directory to a docker container. - -We need to build runsc and place it on the artifact directory: - -```bash -make RUNTIME_DIR=/tmp/syzkaller refresh -``` - -The next step is to create a syzkaller config. We can copy the default one and -customize it: - -```bash -cp images/syzkaller/default-gvisor-config.cfg /tmp/syzkaller/syzkaller.cfg -``` - -Now we can start syzkaller in a docker container: - -```bash -docker run --privileged -it --rm \ - -v /tmp/syzkaller:/tmp/syzkaller \ - gvisor.dev/images/syzkaller:latest -``` - -All logs will be in /tmp/syzkaller/workdir. - -# How to run a syz repro. - -We need to repeat all preparation steps from the previous section and save a -syzkaller repro in /tmp/syzkaller/repro. - -Now we can run syz-repro to reproduce a crash: - -```bash -docker run --privileged -it --rm -v \ - /tmp/syzkaller:/tmp/syzkaller --entrypoint="" \ - gvisor.dev/images/syzkaller:latest ./bin/syz-repro -config \ - /tmp/syzkaller/syzkaller.cfg /tmp/syzkaller/repro -``` diff --git a/images/syzkaller/default-gvisor-config.cfg b/images/syzkaller/default-gvisor-config.cfg deleted file mode 100644 index c69641c21..000000000 --- a/images/syzkaller/default-gvisor-config.cfg +++ /dev/null @@ -1,15 +0,0 @@ -{ - "name": "gvisor", - "target": "linux/amd64", - "http": ":80", - "workdir": "/tmp/syzkaller/workdir/", - "image": "/tmp/syzkaller/runsc", - "syzkaller": "/syzkaller/gopath/src/github.com/google/syzkaller", - "cover": false, - "procs": 1, - "type": "gvisor", - "vm": { - "count": 1, - "runsc_args": "--debug --network none --platform ptrace --vfs2 --fuse -net-raw -watchdog-action=panic" - } -} |