Skip to content

Get fuzztests running daily in CI#267

Merged
delta1 merged 4 commits intoElementsProject:masterfrom
apoelstra:2026-04/fuzz
Apr 24, 2026
Merged

Get fuzztests running daily in CI#267
delta1 merged 4 commits intoElementsProject:masterfrom
apoelstra:2026-04/fuzz

Conversation

@apoelstra
Copy link
Copy Markdown
Member

Copied from rust-bitcoin: run the fuzztests every day in Github CI, file issues when they fail.

Convert the fuzztests from honggfuzz to cargo-fuzz, which is (maybe) slower but much more reliable.

@apoelstra
Copy link
Copy Markdown
Member Author

My local CI does not like this because libfuzzer-sys won't build on 1.63 due to MSRV. Meanwhile, I cannot bump the MSRV of elements-fuzz separate from the wider MSRV because cargo-rbmt rejects it.

I propose we just bump the MSRV of this whole crate to 1.74 to match the rust-bitcoin ecosystem.

@apoelstra apoelstra marked this pull request as draft April 22, 2026 16:39
@apoelstra
Copy link
Copy Markdown
Member Author

Blocked on #269.

@delta1
Copy link
Copy Markdown
Member

delta1 commented Apr 23, 2026

Merged #269

@apoelstra apoelstra marked this pull request as ready for review April 23, 2026 13:11
honggfuzz is faster but has always been unreliable and frustrating to
keep working; I eventually removed it entirely from my local CI and we
removed it from the Github CI here in rust-elements.

AFL, meanwhile, I think we literally never used, though we copied it from
Matt's old rust-lightning stuff.

Anyway, something that works is better than something that's fast, so move
to libfuzzer, which I can run in both my local CI and in Github.
Now that we aren't using hongfuzz, we have reasonably well-behaved deps
in the fuzz list. So we can add this to the workspace, so that our fuzztests
are being tested and linted.
…the fuzztests fail

Copied from rust-bitcoin, but deleted the Kani stuff which doesn't apply here.

I ran all four of the fuzztests locally on one core for 60 seconds to sanity check
that they actually work. So hopefully we don't have spurious failures here.
@apoelstra
Copy link
Copy Markdown
Member Author

On 20440d3 successfully ran local tests

Copy link
Copy Markdown
Member

@delta1 delta1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 20440d3; ran tests locally

@delta1 delta1 merged commit 4a7f62a into ElementsProject:master Apr 24, 2026
10 checks passed
@apoelstra apoelstra deleted the 2026-04/fuzz branch April 24, 2026 15:11
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