Skip to content

smite-ir: mutate byte params with repeated interesting bytes - #214

Open
erickcestari wants to merge 1 commit into
lnfuzz:masterfrom
erickcestari:repeated-byte-mutation
Open

smite-ir: mutate byte params with repeated interesting bytes#214
erickcestari wants to merge 1 commit into
lnfuzz:masterfrom
erickcestari:repeated-byte-mutation

Conversation

@erickcestari

Copy link
Copy Markdown
Contributor

Byte parameter mutations could only fill with uniformly random bytes, which essentially never produces a field that is entirely 0x00 or 0xFF. Some targets only misbehave on such a field, e.g. CLN's funding_txid==0 assertion crash.

Add repeated-fill mutations for both fixed and variable byte parameters, with the repeated byte biased toward INTERESTING_U8.

Closes #179

@morehouse

Copy link
Copy Markdown
Collaborator

Ran into an issue with this change -- we can now actually create invalid private keys with repeated 0xff bytes. This causes panics in the executor.

Byte parameter mutations could only fill with uniformly random bytes,
which essentially never produces a field that is entirely 0x00 or 0xFF.
Some targets only misbehave on such a field, e.g. CLN's funding_txid==0
assertion crash.

Add repeated-fill mutations for both fixed and variable byte parameters,
with the repeated byte biased toward INTERESTING_U8.
@erickcestari
erickcestari force-pushed the repeated-byte-mutation branch from 5c71a8d to c0696be Compare August 28, 2026 18:36
@erickcestari

Copy link
Copy Markdown
Contributor Author

Ran into an issue with this change -- we can now actually create invalid private keys with repeated 0xff bytes. This causes panics in the executor.

True. I've fixed it by mutating and remediating the private key if it's invalid. It should keep the key in a range of 1 <= k < n

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.

Repeated byte parameter mutation

2 participants