-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
brontide: deterministic fuzz targets #7618
brontide: deterministic fuzz targets #7618
Conversation
Concept ACK |
@Crypt-iQ: review reminder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, LGTM 🎉
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🏸
Just needs release notes, or the label to ignore that part for CI
The nilAndPanic function does not actually nil the Curve fields as it claims. dumpAndFail is a more descriptive name.
Move the functionality directly into completeHandshake instead. If a failure does happen at any point during the handshake, it is beneficial to know which line it happens on for debugging. The helper function was hiding this information.
It is best to have deterministic fuzz targets, so that if a failure occurs, it can be easily reproduced. This commit swaps the cryptographically secure RNG for a deterministic one seeded from fuzzer input.
1815536
to
354133e
Compare
Rebased and added release note. |
Fuzz targets that are truly random make it difficult to reproduce failures. This PR seeds the private key RNG from fuzzer input so that any crashes found during the initial handshake are reproducible.
Tested with 35 CPU-hours of fuzzing for each
FuzzRandom*
target, with no crashes found.