Reviewed Aug 2026
DE
BA-14 · LESSON 04

Fuzzing and property tests

KEY DEFINITIONS

Terms used in this lesson

Proof-of-work target
The maximum header-hash value accepted for a block; lowering it makes valid hashes harder to find.
Descriptor
A machine-readable description of the scripts, keys, and derivation paths a Bitcoin wallet watches or can spend.
PSBT
Partially Signed Bitcoin Transaction: a format for passing an unsigned or partly signed transaction between constructors and signers.

Generated inputs uncover parser and state-machine edge cases while invariants catch broad classes of failure.

65 min Difficulty 3/5 Not started

Loading lesson visuals...

01

Learn the idea

Fuzzing generates or mutates many inputs to find crashes, hangs, excessive resource use, or violated assertions. A property test generates structured cases and checks an invariant across them. A seed reproduces one generated failure, and shrinking reduces it to a smaller counterexample. Coverage guides which code paths the generator reaches.

GUIDED EXPLANATION1/5 ideas inspected
1

Choose a hostile boundary

Parsers, script interpreters, network messages, descriptors, PSBTs, and state transitions process attacker-controlled or complex data.

Inspect each idea before the worked example.
The worked example follows the explanation

Inspect every idea above to open it.

Important distinctionA long fuzz run with no crashes proves the parser is correct.

It establishes only that tested inputs and reached paths did not trigger monitored failures. Properties, corpus quality, coverage, and unmodeled semantic bugs remain.

02
FINISH LEARNING FIRST

The questions unlock after every required learning activity

Inspect every guided idea, open the worked example, rebuild its mechanism, and complete the deterministic lesson tool. Your progress is saved automatically.