Closed gy741 closed 6 years ago
@gy741 Can you test https://github.com/tosone/minimp3 with same fuzzer?
@lieff
Yes, A little modification is necessary, but it is possible.
@lieff As the decoding part is written in C in minimp3, the fuzzing tests might not crash even it causes out of range error?
If binding part guaranteed range check and safe data & len passing, then should not crash on any data.
OK but how about, not only crashes, but also silent errors? Sorry if I'm wrong, but on C side, there are no boundary checks, right? Is it possible to guarantee that there is no such boundary error on C side?
C side have boundary check within passed mp3_bytes range, so if memory within this range available everything should be ok, otherwise it's a bug.
I mean, for example, is there a boundary check for tabindex
at https://github.com/tosone/minimp3/blob/master/minimp3.h#L779 ? In the past fuzzing test for this go-mp3, various boundary errors have been found.
Yes, all boundaries should be fine (as I think), I've ask for fuzzing test to double check that. This code relatively young, so, errors still possible.
Thank you!
@lieff
I proceeded to fuzzing about 10 hours.
I did not find a bug.
@lieff To fuzz the C mp3 library, you'll want to use either http://lcamtuf.coredump.cx/afl/ or libfuzzer ( https://github.com/google/fuzzer-test-suite/blob/master/tutorial/libFuzzerTutorial.md . I can help you set this up if you're interested.
@dgryski Thanks) I will try this.
Hello.
I found a index out of range bug in go-mp3.
Please confirm.
Thanks.
reproduce code:
Log