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

Remove test cases with a duplicate trace map #359

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sgabe
Copy link
Contributor

@sgabe sgabe commented Jan 6, 2022

This PR is intended to somewhat improve the efficiency of fuzzing by marking test cases that have the same trace map as already fuzzed during the dry run stage.

@ifratric
Copy link
Collaborator

ifratric commented Jan 7, 2022

Hmm won't the code in https://github.com/googleprojectzero/winafl/blob/master/afl-fuzz.c#L3114 already take care of that, specifically won't the new_bits be zero in case where a sample with the same trace map was seen before?

@sgabe
Copy link
Contributor Author

sgabe commented Jan 24, 2022

My understanding is that currently the user is only warned that some test cases look useless at the end of processing the input directory. The proposed change explicitly marks the bigger redundant case at the end of the dry run stage to be excluded from the seed corpus. Otherwise, it does not affect the fuzzing process, which is already taken care of, as redundant cases will not be added to the corpus.

@ifratric
Copy link
Collaborator

ifratric commented Jan 25, 2022

Understood! My question is, could this be integrated in the "main" loop of perform_dry_run and simply remove all testcases for which calibrate_case returns FAULT_NOBITS rather than doing two additional nested loops over the queue? Relying on FAULT_NOBITS would (AFAIK) also have a benefit of not only removing the testcases for which checksums are exactly the same (a relatively rare case) but also those where the sample covarerage is a subset of coverage seen so far in other samples.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants