Effective fuzzing starts from valid inputs and perturbs them. Generating well-formed G, M, and C addresses gives the mutators a realistic base so the fuzzer explores the boundary of validity rather than only obvious garbage.
Issues/what to fix
- Implement
fn random_valid_address(kind: AddressKind, rng: &mut impl Rng) -> String producing correctly checksummed strkey for G, M, and C.
- For M addresses, embed a random 64-bit muxed id so the decoder path is exercised across the full u64 range.
- Verify each generated address round-trips through
parse and panic in the generator itself if it does not, since that would mean the seed source is broken.
Files location
src/generate.rs
Expected result
The generator emits addresses that all parse successfully, covering every address kind.
Join the contributor Telegram group: https://t.me/+g6EPIsHod0RhZGZk
Effective fuzzing starts from valid inputs and perturbs them. Generating well-formed G, M, and C addresses gives the mutators a realistic base so the fuzzer explores the boundary of validity rather than only obvious garbage.
Issues/what to fix
fn random_valid_address(kind: AddressKind, rng: &mut impl Rng) -> Stringproducing correctly checksummed strkey for G, M, and C.parseand panic in the generator itself if it does not, since that would mean the seed source is broken.Files location
src/generate.rsExpected result
The generator emits addresses that all parse successfully, covering every address kind.
Join the contributor Telegram group: https://t.me/+g6EPIsHod0RhZGZk