openmina / mina-p2p-messages-rs

0 stars 0 forks source link

Implement fuzzing tests for binprot decoding #6

Open akoptelov opened 2 years ago

akoptelov commented 2 years ago

Decoding fuzzing is the first priority since this is primarily what Mina does when receiving bytes from the network.

akoptelov commented 2 years ago

@dkuehr I'm using fuzzcheck for fuzzing decoding. What should I do to get a report like you did previously?

dkuehr commented 2 years ago

@akoptelov fuzzcheck-rs generates coverage information in JSON format,same author wrote a tool to generate reports but I never was able to make it work so instead I wrote my own set of Python scripts to produce reports with a kcov-like template to keep the report's layout consistent with our previous tools (https://github.com/tezedge/action_fuzzer_ci/blob/main/report.py).

Now that we have the chance, I recommend to generate coverage reports in a different way. For example we can know how many times each part of code was hit, but in the past we had to discard that information to keep it consistent with kcov reports which can only detect 1-hit. That information can be useful for generating flame-graphs etc..