oss-fuzz
oss-fuzz copied to clipboard
native go fuzzing: Integrate engine
Integrates the native Go engine.
The following commands are supported:
build_fuzzersrun_fuzzer
To run the demo project:
python3 infra/helper.py build_image test-native-go-fuzzingpython3 infra/helper.py build_fuzzers test-native-go-fuzzingpython3 infra/helper.py run_fuzzer --engine=nativego test-native-go-fuzzing Fuzz
which prints the output:
fuzz: elapsed: 0s, execs: 0 (0/sec)
fuzz: elapsed: 3s, execs: 752138 (250669/sec)
fuzz: elapsed: 6s, execs: 1480720 (242889/sec)
fuzz: elapsed: 9s, execs: 2229426 (249502/sec)
fuzz: elapsed: 12s, execs: 2977539 (249442/sec)
fuzz: elapsed: 15s, execs: 3706169 (242813/sec)
fuzz: elapsed: 18s, execs: 4448184 (247321/sec)
...
@jonathanmetzman IMO this is a good first step to get the Go 1.18 runtime engine integrated. It will need more work which includes:
- Getting rid of the
--engineflag which is required now withrun_fuzzer. - Support for coverage.
Can this be merged as is at this moment, or do you see any potential for breaking anything in the backend?
Thanks for this PR! Note that there's still a lot of work to do on the ClusterFuzz side, which are pending some required changes to the Go fuzzing implementation itself.
We can merge it in, but it won't actually be usable by users.