Enable fuzzing of hashes in CI#1422
Closed
tcharding wants to merge 4 commits intorust-bitcoin:masterfrom
Closed
Conversation
Littering the codebase with `#[cfg(not(fuzzing))]` is a bit messy just to quieten the linter during fuzzing. Instead just globally allow.
Currently we run a bunch of unit tests that check the state of data structures during hashing however we hobble these data structures when fuzzing so the tests fail and are meaningless. Exclude unit tests that test state if fuzzing.
Currently we do not run fuzzing in CI for hashes, lets enable it.
Member
Author
|
Neither of the attempts I made work (the last two patches). Will try again another time. |
Member
|
To get hash fuzzing to work in CI you actually have to fix the hash fuzzing code. Enabling or disabling stuff isn't going to do it. |
Member
Author
|
Needs more thought. |
Merged
apoelstra
added a commit
that referenced
this pull request
Apr 28, 2023
2860aae fuzz: don't fuzz hashes against RustCrypto (Andrew Poelstra) 6467728 fuzz: disable tests unless 'cfg(fuzzing)' is passed; update README for reproducing failures (Andrew Poelstra) 6e2ee5b fuzz: run 'cargo fmt' on all the fuzz targets (Andrew Poelstra) 9cfc0fc fuzz: add contrib/test.sh so we at least 'cargo test' it in CI (Andrew Poelstra) 933ecb1 fuzz: fix warnings, clippy lints, 1.48.0 failures (Andrew Poelstra) fd88e48 fuzz: remove AFL support (Andrew Poelstra) ab467cb fuzz: make hongfuzz fuzzing the default feature (Andrew Poelstra) 6f754df fuzz: add fuzzing README (Andrew Poelstra) f093765 fix fuzz.sh and cycle.sh to use generated lists of targets (Andrew Poelstra) 6534f22 fuzz: auto-generate CI and Cargo.toml files (Andrew Poelstra) 8021034 rename travis-fuzz.sh to fuzz.sh; partially patch CI (Andrew Poelstra) 0be75f7 move hashes/fuzz into main fuzz/ directory (Andrew Poelstra) 5a891de move bitcoin fuzz targets into bitcoin/ subdirectory (Andrew Poelstra) e3111c7 move bitcoin/fuzz into repo root; add to workspace (Andrew Poelstra) Pull request description: Several big changes here: * Moves fuzzing to its own workspace with a `contrib/test.sh` etc so that CI will check that it compiles * FIx all warnings, clippy lints, MSRV problems, etc.; mostly move to Rust 2018 * Merge `hashes/` fuzztests into workspace * Rewrite all scripts; add file that auto-generates CI fuzz job and Cargo.toml so we don't have to manually keep these in sync * Remove bitrotted and partial AFL support. Supercedes #1422 I suspect the hashes fuzztests will actually fail since we haven't touched them in so long. Will address that if CI fails here. ACKs for top commit: sanket1729: ACK 2860aae tcharding: ACK 2860aae Tree-SHA512: b1aa3d6fac75fee51966f1d3f3245784e331bdea2a3fa7d6609bc4196c34f81acb7701faf8f269c3741568ea100438f24a2f06e75c8d01cb84c8b22d7886f1dd
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Draft builds on #1420 and #1421 and I'm not sure if this will work.
Currently we do not run fuzzing in CI for hashes, lets enable it.