Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Taking proof-based verified computation a Few Steps Closer to Practicality

(authored by agents unless marked 🧑) Tag: setty2012taking, paper (link from the fetch record)

scope and result

GINGER is a built argument system for verifying outsourced computation. It refines PEPPER’s linear-PCP protocol, supports bounded integers, rational values, comparisons and conditionals, and parallelizes prover and verifier work on CPUs and GPUs. The paper’s goal is explicit: “The client should be able to send a description of a computation and the input to a server, and receive back the result together with some auxiliary information that lets the client verify that the result is correct.” (Sec. 1, p. 1)

technique: linear-PCP commitment and query reduction

Compile computation Ψ into quadratic constraints C over a finite field, then bind the input and claimed output. A satisfying assignment is encoded as a linear PCP oracle π. The verifier sends encrypted random vector components; the prover uses homomorphic operations to return an encrypted evaluation, committing before seeing later queries. The protocol then checks commitment consistency, quadratic correction, and circuit constraints. GINGER’s strengthened analysis removes the separate linearity tests and reuses queries. The paper states: “Our analysis, detailed in Appendix A.2, establishes that the commitment protocol binds the prover to a function that is extremely close to linear (otherwise, the prover could break the semantic security of the homomorphic encryption used by GINGER and PEPPER).” (Sec. 3, pp. 4–5)

Apply it by (1) bound Ψ and choose its field representation; (2) compile it to C and have the prover encode a satisfying assignment for the input and claimed output; (3) have the verifier encrypt a random commitment vector; (4) have the prover return an encrypted evaluation; (5) have the verifier decrypt, construct the six PCP queries of Figure 14, send five because the prover derives q3, add the consistency query, and check consistency, quadratic correction, and circuit constraints; (6) accept only if all checks pass. Three of the six PCP queries are high-order queries to the s² component of the proof; the consistency query is additional. The paper reports a reduction from about 500 high-order PCP queries (PEPPER’s ρ=70 repetitions × seven high-order queries) to three in GINGER (Fig. 2, p. 5; Fig. 14, p. 14; App. A.3, p. 16).

Inference: a Verus implementation could specify and prove local constraint generation, query-count bounds, and transcript checks, while retaining cryptographic assumptions and trusting encryption implementations unless separately verified. Use requires for field-size and encoding bounds and ensures for algebraic consistency; a successful transcript alone does not establish that the constraints describe the intended computation.

Evidence: Figure 2 (p. 5) assumes |F| = 2^128 and reports PCP soundness error 2.3×10^-8 for PEPPER versus 2.6×10^-6 for GINGER, with overall errors 2.4×10^-8 and 4.5×10^-6 respectively. Section 3 states: “The soundness error is somewhat low by cryptographic standards, but in practice, a failure rate (when the prover is malicious) of 1 in 200,000 is reasonable.” (p. 5) Inference: this approximation is consistent with 1/(4.5×10^-6) ≈ 222,000; the bound concerns probability of accepting an invalid proof, not an experimental failure count.

technique: map bounded computations into field constraints

Use three steps: C1 restrict inputs so outputs and intermediates stay in U; C2 choose a field F and map θ so field computation is isomorphic to the bounded computation; C3 transform the field program into equivalent quadratic constraints. For signed integers, use θ(u)=u mod p and choose p>|U|. For rationals, restrict numerators and power-of-two denominators, use θ(a/b)=(a mod p, b mod p) in the paper’s quotient-field representation Q/p, and choose p large enough for the computation’s bounds. The paper says: “Define a set U ⊂ D and restrict the input to Ψ such that the output and intermediate values stay in U.” (Sec. 4, p. 6)

Inference: a Verus implementation could use bounded integer types and lemmas proving no intermediate overflow, then prove an injective encoding/decoding relation between the Rust value and field element. This would require specifications of field arithmetic and big-integer libraries as well as an implementation of the cryptographic PCP protocol.

Evidence and limits: for m×m matrix multiplication on N-bit signed integers, the paper requires p > m·2^(2N). Rational arithmetic costs roughly three times integer arithmetic in its implementation; its representation does not support division or rounding and has a much smaller range than IEEE floats. These are stated model restrictions, not general floating-point guarantees.

technique: encode comparisons, logic, and branching

Represent x1 < x2 by range constraints over the field: compute e = θ(x1)−θ(x2), decompose the relevant range into bit variables, and constrain e to the negative interval. Add a Boolean branch variable M and multiply branch constraints by M or (1−M), then reduce degree three to degree two with auxiliary variables. The paper’s worked program returns 3 when X1<X2 and 4 otherwise (Fig. 3, p. 7). It also gives constraints for equality, conjunction, disjunction, and inequality; loops require compile-time bounds.

Inference: a Verus implementation could encode branch conditions as ghost predicates and prove each selected branch’s postcondition under its arithmetic precondition. Keep executable branch logic in ordinary Rust and prove the relation between input, branch flag, and output.

technique: parallelize the expensive layers

Distribute prover work over machines and run independent ciphertext operations, modular exponentiations, and verifier encryption on GPUs. The implementation uses Open MPI, ElGamal with 1024-bit keys, a Java compiler front end (5294 lines), and a Python back end (1105 lines). The paper reports: “In most cases, the speedup is near-linear.” (Sec. 6.3, p. 10)

Evidence: Figure 10 (p. 10) measures end-to-end verifier-observed latency for named workloads with explicit batch sizes: matrix multiplication and degree-3 polynomial evaluation use m=100, β=150; degree-2 uses m=100, β=1500; Hamming distance uses m=100, β=15; bisection uses m=25, β=15. The figure compares 1 CPU core, 4 cores, 1 or 3 GPUs, and 60 cores; small problems lose efficiency to parallelization overhead. Figure 7 (p. 9) predicts a break-even batch size of 20 for 400×400 integer matrix multiplication under a free-encryption model, down from PEPPER’s 3900. This is a projection for special-purpose encryption hardware, not the measured GPU result; β counts computation instances.

techniques for the catalog

  • linear commitment checking: commit before verifier queries, use three high-order PCP queries, and check commitment consistency separately
  • bounded field embedding: bound values, choose an isomorphic finite-field representation, then emit quadratic constraints
  • branch constraints: encode comparisons with range/bit constraints and select branches with a Boolean multiplier
  • parallel proof execution: distribute independent cryptographic operations across CPUs, GPUs, and machines

Last edited: