Capstone: Bitcoin-Lite Node
Lesson, slides, and applied problem sets.
View SlidesLesson
2 min readCapstone: Bitcoin-Lite Node
Why this module exists
The real difficulty of blockchain engineering is integration. The capstone requires you to stitch together:
- Serialization and hashing
- UTXO validation
- Script execution
- Mempool selection
- Mining and PoW checks
- Chain selection and reorgs
1) Validation pipeline
A node must reject invalid data early:
- Header sanity + PoW
- Merkle root check
- Transaction validation (UTXO + scripts)
- State update
2) Mining pipeline
- Select transactions (fee rate + availability)
- Create coinbase
- Compute merkle root
- Search nonce
- Broadcast block
3) Reorg safety
Longer chains can arrive after you mine. Your node must rollback and re-apply state deterministically.
4) Design constraints
We use toy choices to keep code manageable:
- Fixed difficulty
- Simplified sighash
- P-256 instead of secp256k1
These keep the system learnable while retaining the shape of Bitcoin.
What you will build
A full node + miner that accepts transactions, mines blocks, and maintains a consistent UTXO set across forks.
Key takeaways
- A blockchain is an execution engine with strict determinism.
- Robustness is about invariants, not just features.
- The capstone is where correctness matters most.
Module Items
Bitcoin-Lite Node
Capstone Checkpoint
End-to-end node invariants.