Pearl Prove cryptographic proof desk

Don't trust the block. Prove the transaction.

Pearl Prove is the proof desk for Pearl (PRL): it checks cryptographic inclusion — that a transaction really sits inside a block's merkle tree — decodes 80-byte block headers and verifies proof-of-work against the nBits target, and builds merkle roots from transaction lists. Everything runs in this page; the SHA-256 implementation is vendored and cross-tested.

What this proves — and what it doesn't. A valid inclusion proof shows a transaction is committed to by a block header. It does not prove that header came from the chain you care about: fetch headers from a blockbook or pearld node you trust, and check confirmations against your own tip.

Inclusion proof

Two ways in: fetch a block and let the page build the proof for you, or paste a proof someone handed you and check it against a header's merkle root.

Large blocks fetch every page of the tx list from blockbook. Blocks above ~5,000 transactions are refused — paste a proof instead.

Proof walk

Nothing proved yet.

How the math works

1 · Hash

Every tree node is double-SHA256(left ‖ right) on the internal (little-endian) byte order. Txids are shown big-endian; the page flips them before hashing — the most common hand-rolled-prover bug.

2 · Odd rule

A lone node is hashed with itself, exactly as node/blockchain/merkle.go does upstream. This is why the proof for the last tx of an odd block starts with the tx's own hash on the right.

3 · Verify

Walk the path from the leaf: at each step hash sibling ‖ running (sibling left) or running ‖ sibling (sibling right). If the final digest equals the header's merkle root, the transaction is committed — no trust in the prover required.

Construction verified against upstream BuildMerkleTreeStore (master @ 3fe2267) and empirically: recomputing the root from all 40 txids of Pearl mainnet block 120195 reproduces the chain's merkle root byte-for-byte (tests/fixture-120195.json).