BR Academy
0%
What Zero-Knowledge Proofs Are·Lesson 1 of 33·8 min

What is a Zero-Knowledge Proof?

The concept

A zero-knowledge proof lets a prover convince a verifier that a statement is true without handing over the secret that makes it true. The statement is a claim you can write down, such as "I know a preimage of this hash" or "this transaction is valid and I am authorized to spend this note." The secret is the witness: the preimage, the spend key, the Merkle path. The verifier should leave convinced of the statement and unable to replay the witness as if they knew it themselves.

Three properties define the system. Completeness says an honest prover who holds a valid witness can produce a proof the verifier accepts. Soundness says a cheating prover, who does not have such a witness, is rejected except with a negligible probability. Zero-knowledge says the proof can be simulated without the witness, so it does not leak the witness or anything else the verifier could not already infer from the public statement. If you drop any of the three, you are no longer in this family of tools: a leaked witness is just a disclosure, and a proof that a liar can forge is not a proof.

ZK is a proof system, not a way to hide a file. Encryption hides a payload from anyone without a key. Hashing binds a value without revealing it, but does not by itself prove knowledge to a skeptical on-chain verifier. A signature proves control of a key, and often that is enough. You reach for ZK when you must prove a richer statement — membership, range, correctness of a batch — while keeping the witness off the public record.

Worked example

The classic classroom statement is "I know the password that hashes to H." If the prover simply sends the password, the verifier is convinced, but the witness is now public and reusable. A zero-knowledge approach has the prover demonstrate knowledge of a preimage of H so that the verifier accepts when the password is known, rejects with overwhelming probability when it is not, and learns nothing they can type into the login form later.

On a chain, a closer example is "I have a Merkle membership witness for this note, and I am not double-spending it." Posting the path would prove membership and also reveal which note was spent. A ZK circuit takes the path as a private witness, the Merkle root as public input, and produces a short proof the contract can check. The accepted proof is evidence of membership; the path never appears in the call data.

Your exercise

Write, in your own words, one real blockchain statement that is a good ZK candidate, for example "I have a Merkle membership witness for this note," and one that is a poor candidate, for example "this NFT is visually rare." For each, name the statement, the witness you would keep private, and which of the three properties would fail if you just posted the witness on-chain. The deliverable is a half-page with both statements and a one-line verdict on each property. Do not invent a protocol name you cannot describe.

Common pitfalls

Calling any private computation ZK. If the verifier learns the witness, or if a cheater can forge an accept, you do not have a zero-knowledge proof. Name the three properties before you name the product.

Treating ZK as encryption. Encryption hides a payload. A proof convinces a verifier about a statement. You often use both, but they are not substitutes.

Skipping the statement. If you cannot write the statement and the public inputs in one sentence, you are not ready to pick a circuit.

Production notes

When you propose ZK in a design review, start with the statement, the witness, and who the verifier is (a contract, a client, a rollup). Tools and proving systems come second. Teams that start with a favorite stack often discover the statement was "we want privacy" rather than a checkable claim.

Write down what would happen if the witness leaked. If the answer is "nothing we would not already accept with a signature," you may not need ZK. If the answer is "every note in the set can now be linked," you need both a proof and an operational story for keys, client software, and ceremonies.

Completeness bugs show up as honest users who cannot prove. Soundness bugs show up as thieves who can. Zero-knowledge bugs show up as observers who learn a linkage or a value from the proof or from sloppy metadata around it. Your incident runbook should distinguish those three, because the fix is different for each.

Do not promise "the chain learns nothing" if you still publish amounts, counterparties, or unique gas patterns. The proof can be zero-knowledge while the application is not. Later lessons on privacy will make that gap precise; this lesson is about not over-claiming the primitive.

If you need a feeling for the math without drowning in it: the verifier checks a relation between public inputs and a proof object, and the protocol is built so that producing an accepting proof is infeasible without a witness, yet possible and efficient with one. You will see circuits, proving keys, and verifying keys later. You do not need them to write a good statement today.

Keep a running list of statements you might prove in your own system. You will refine them into circuits in the writing-circuits module. A list of slogans will not survive contact with a constraint system; a list of statements will.

Recap

  • A ZK proof convinces a verifier a statement is true without handing over the witness.
  • Completeness, soundness, and zero-knowledge are the three properties; drop one and you have a different tool.
  • Write the statement and the witness first; tools and product names come after.

Resources

  • Ethereum.org — Zero-knowledge proofs: https://ethereum.org/en/zero-knowledge-proofs/
  • Wikipedia — Zero-knowledge proof (definitions and history): https://en.wikipedia.org/wiki/Zero-knowledge_proof
  • Vitalik Buterin — SNARKs, STARKs, and succinct arguments (overview): https://vitalik.eth.limo/general/2021/01/26/snarks.html