Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modify readme in ossfuzz #14746

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 3 additions & 2 deletions test/tools/ossfuzz/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@

We have multiple fuzzers, some based on string input and others on protobuf input. To build them, please do the following:

- Create a local docker image from `Dockerfile.ubuntu.clang.ossfuzz` in the `.circleci/docker` sub-directory. Please note that this step is likely to take at least an hour to complete. Therefore, it is recommended to do it when you are away from the computer (and the computer is plugged to power since we do not want a battery drain).
- Create a local docker image from `Dockerfile.ubuntu.clang.ossfuzz` in the `solidity/scripts/docker/buildpack-deps` sub-directory. Please note that this step is likely to take at least an hour to complete. Therefore, it is recommended to do it when you are away from the computer (and the computer is plugged to power since we do not want a battery drain). If the request fails, you can replace `gcr.io/oss-fuzz-base/base-clang:latest` with `registry.aliyuncs.com/oss-fuzz-base/base-clang:latest` in `Dockerfile.ubuntu.clang.ossfuzz`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- Create a local docker image from `Dockerfile.ubuntu.clang.ossfuzz` in the `solidity/scripts/docker/buildpack-deps` sub-directory. Please note that this step is likely to take at least an hour to complete. Therefore, it is recommended to do it when you are away from the computer (and the computer is plugged to power since we do not want a battery drain). If the request fails, you can replace `gcr.io/oss-fuzz-base/base-clang:latest` with `registry.aliyuncs.com/oss-fuzz-base/base-clang:latest` in `Dockerfile.ubuntu.clang.ossfuzz`.
- Create a local docker image from `Dockerfile.ubuntu.clang.ossfuzz` in the `solidity/scripts/docker/buildpack-deps` sub-directory. Please note that this step is likely to take at least an hour to complete. Therefore, it is recommended to do it when you are away from the computer (and the computer is plugged to power since we do not want a battery drain). If the request fails, you can replace `gcr.io/oss-fuzz-base/base-clang:latest` with `registry.aliyuncs.com/oss-fuzz-base/base-clang:latest` in `Dockerfile.ubuntu.clang.ossfuzz`.


```
$ cd .circleci/docker
$ cd solidity/scripts/docker/buildpack-deps
$ docker build -t solidity-ossfuzz-local -f Dockerfile.ubuntu.clang.ossfuzz .
```

Expand All @@ -32,6 +32,7 @@ $ rm -rf fuzzer-build && mkdir fuzzer-build && cd fuzzer-build
## Compile protobuf C++ bindings
$ protoc --proto_path=../test/tools/ossfuzz yulProto.proto --cpp_out=../test/tools/ossfuzz
$ protoc --proto_path=../test/tools/ossfuzz abiV2Proto.proto --cpp_out=../test/tools/ossfuzz
$ protoc --proto_path=../test/tools/ossfuzz solProto.proto --cpp_out=../test/tools/ossfuzz
## Run cmake
$ export CC=clang CXX=clang++
$ cmake -DCMAKE_TOOLCHAIN_FILE=cmake/toolchains/libfuzzer.cmake -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE:-Release} ..
Expand Down