What is a validity proof?
- Author
- CRYPTO PORT Editorial
- Published
- Updated
- Reading time
- 6 min
In short
A validity proof is a mathematical proof, submitted alongside a batch, that the layer 2 computation followed the rules. Unlike a fraud proof, nothing is accepted first and challenged later — the proof is verified up front. No challenge window is needed, so the only delay is generating and verifying the proof.
Key points
- A proof of correct computation submitted up front
- Verified before acceptance, so no challenge window is required
- Generating proofs takes time and specialised hardware
- Verification stays cheap relative to the work being proved
Definition
A cryptographic proof that a layer 2 state transition followed the protocol rules. Layer 1 verifies the proof before accepting the result, so no after-the-fact challenge is needed.
With a validity proof, the layer 2 executes all the transactions in a batch and then produces a proof that the execution followed the rules. A layer 1 contract verifies that proof and records the new state only if it passes. An incorrect result is rejected at verification and never gets recorded at all.
The difference from a fraud proof is the ordering. A fraud proof accepts first and overturns later if an error surfaces; a validity proof checks the proof before accepting. The former needs a challenge window, while the latter structurally does without one.
The cost lands on the proving side. Proving thousands of transactions takes heavy computation, and provers running specialised hardware need minutes to tens of minutes. Verification on layer 1, by contrast, is far lighter than the work proved — that asymmetry is what makes the whole design viable.
Note that the proof only guarantees the computation followed the published rules. If those rules, as encoded in the contract, are flawed, or if an admin key can replace the contract, a valid proof still will not protect your assets.
Watch out for
- · A proof attests to rule-following computation, not to the soundness of those rules or the contract
- · If proof generation halts, no new state finalises and withdrawals stall with it
- · Where an admin key can swap the contract, a valid proof still leaves funds at risk