Open agroce opened 1 year ago
(I think the hour is optimistic, it may have gotten lucky; I'd fuzzed this code a while back and found nothing with a 24 hour run, and another run in progress hasn't found it yet)
@FooBarWidget let me know when you get a chance if this is real or a subtle issue with the API I'm somehow missing. It's genuinely a fairly hard target even for a fuzzer, without some patience. I know this project hasn't been touched in a while, but it's still pegged on your github and seems to have users!
Hi, sorry I'm not maintaining this repository at the moment. But if you're able to fix this bug and also add a test for it and submit a PR then I would be grateful.
Found this using the DeepState tool for fuzzing, took an hour of fuzzing via AFL.
Here's a C++ program that shows the problem, also available at https://github.com/agroce/deepstate-boyer-moore-horspool/blob/master/bmhturbofail.cpp
The two string sizes are minimal, as are the byte values used (lower any of the bytes any more, or shrink the string, and there is at least no similar failing test case, so the exact pattern is meaningful).