0Pricing
Cryptology Academy · Lesson

zk-SNARKs: Succinct Non-Interactive Arguments

Understand the Groth16 setup, proof generation, and verification.

zk-SNARKs: Succinct Non-Interactive Arguments is a free Cryptology Academy lesson on CoddyKit — lesson 3 of 4. You can read the complete lesson below for free — then practise it hands-on in the browser with a built-in code editor and a 24/7 AI tutor. It is part of the Cryptology Academy learning path, one of 4 lessons in the course, and your progress syncs across the web and the CoddyKit app.

What Is a zk-SNARK?

A zk-SNARK (Zero-Knowledge Succinct Non-interactive ARgument of Knowledge) is a proof that: (1) is zero-knowledge, (2) is succinct (tiny proof, fast verification regardless of computation size), (3) is non-interactive (single proof string).

Motivation

Sigma protocols work for simple statements (discrete log knowledge). For complex computations — "I ran this function correctly on private inputs" — we need a general-purpose proof system. SNARKs prove arbitrary computations in O(1) verification time.

Arithmetic Circuits

The computation is first expressed as an arithmetic circuit: a directed acyclic graph of addition and multiplication gates over a finite field. Example: proving you know x such that x^3 + x + 5 = 35 without revealing x=3. The circuit has ~5 gates.

R1CS: Rank-1 Constraint System

An arithmetic circuit is converted to R1CS: a set of constraints (A*z)*(B*z) = C*z where z is a vector of all wire values. Each multiplication gate becomes one constraint. The prover must find z satisfying all constraints without revealing private wires.

QAP: Quadratic Arithmetic Programs

R1CS is converted to a QAP: polynomials A(x), B(x), C(x) such that A(x)*B(x)-C(x) is divisible by a target polynomial t(x) iff the constraints are satisfied. The prover shows they know a polynomial quotient H(x) without revealing the witness.

Groth16 Proof

Groth16 (2016) is the most efficient general SNARK. After a trusted setup (CRS generation), the prover outputs a proof of 3 group elements (~192 bytes for BLS12-381). Verification: 3 pairing operations. Constant-size proof regardless of circuit size.

Trusted Setup Ceremony

Groth16 requires a trusted setup per-circuit: sample toxic waste (a random secret), compute the Common Reference String, then destroy the toxic waste. If the waste survives, an adversary can forge proofs. Multi-party ceremonies (Powers of Tau) distribute trust.

PLONK: Universal Setup

PLONK (2019) uses a universal trusted setup: one ceremony works for all circuits up to a size bound. No per-circuit setup needed. Trade-off: slightly larger proofs than Groth16. Used in ZK-EVM implementations (Polygon Hermez, zkSync Era).

STARKs vs SNARKs

STARKs (Scalable Transparent ARguments of Knowledge) require no trusted setup and use hash functions (post-quantum secure). Trade-off: larger proofs (10s of KB vs 200 bytes). Used in StarkWare/StarkNet, Cairo language. SNARKs smaller; STARKs quantum-safe.

Pairing-Based Cryptography

Groth16 uses bilinear pairings: e: G1 × G2 → GT where e(a*P, b*Q) = e(P,Q)^{ab}. This allows checking polynomial identities in the exponent without revealing values. BLS12-381 curve is optimized for efficient Groth16 pairings.

Proof Generation Cost

Groth16 proving time for a 10^6-gate circuit: ~10 seconds on a modern CPU. Verification: ~1 ms. This asymmetry is intentional: the prover (who did the heavy computation) does the work; the verifier (blockchain node) does near-zero work.

Quick Check

What is the main drawback of Groth16 compared to PLONK?

Recap

zk-SNARKs prove arbitrary computations in constant-size proofs. Pipeline: computation → arithmetic circuit → R1CS → QAP → SNARK proof. Groth16 is most efficient (trusted setup per circuit); PLONK uses universal setup. Next: ZKP applications in blockchain.

Frequently asked questions

Is the “zk-SNARKs: Succinct Non-Interactive Arguments” lesson free?

Yes — the full text of “zk-SNARKs: Succinct Non-Interactive Arguments” is free to read here on the web, and the Cryptology Academy course includes 4 lessons in total. To practise it interactively (a built-in code editor and a 24/7 AI tutor) and unlock the rest of the Cryptology Academy course, upgrade to CoddyKit PRO.

What will I learn in “zk-SNARKs: Succinct Non-Interactive Arguments”?

Understand the Groth16 setup, proof generation, and verification. You practise Cryptology Academy with hands-on code you run directly in the browser, and a 24/7 AI tutor answers your questions as you work through the lesson.

Do I need any experience to start Cryptology Academy?

No prior experience is required. Cryptology Academy on CoddyKit is structured for beginners through advanced learners; this is — lesson 3 of 4, so you can start here or from the beginning and move at your own pace.

How long does the “zk-SNARKs: Succinct Non-Interactive Arguments” lesson take?

Most CoddyKit lessons take about 5–10 minutes. Each one is bite-sized and interactive, so you make steady progress and pick up exactly where you left off across the web and the app.

Can I write and run code in this Cryptology Academy lesson?

Yes. Every Cryptology Academy lesson includes a built-in code editor, so you write and run real code right in your browser and get instant AI feedback — no local setup required.

All lessons in this course

  1. ZKP Intuition: The Ali Baba Cave
  2. Sigma Protocols & Schnorr Identification
  3. zk-SNARKs: Succinct Non-Interactive Arguments
  4. ZKP Applications: ZK Rollups & Privacy Coins
← Back to Cryptology Academy