Point-and-permute garbling is efficient #
PointPermute.scheme family of CslibFrontier.Crypto.Primitives.Garbling.PointPermute is an
efficient garbling scheme (Scheme.IsEfficient) whenever the word family family is computed in
polynomial time, as PseudorandomFunction.polyTime provides: PointPermute.scheme_isEfficient.
Circuits are encoded by encValidCircuit (n, m in unary, wire numbers in binary). Privacy of
the scheme, with a polynomial-time simulator and a certified reduction, is
PseudorandomFunction.prvSim_pointPermute in
CslibFrontier.Crypto.Primitives.Garbling.PointPermute.Privacy.
The garbler writes each gate's block from the gate list of the encoded circuit; wire numbers read
from that list are capped at the length of the coins, which changes nothing since a wire beyond
the coins reads the all-zero key and permutation bit either way. The evaluator is a fold over the
gates whose state grows by one label per gate. The semantics ev is that of valid circuits, whose
certificate evalCirc_polyTime is in CslibFrontier.Crypto.Primitives.Garbling.Efficient. The
certificates for the keyed function on words, tweaks, keys, permutation bits and labels are stated
compositionally for reuse, and so is that for the decoding information (decInfoWord_polyTime).
En is the projective encoding projectiveEncode of
CslibFrontier.Crypto.Primitives.Garbling.Projective, certified there
(projectiveEncode_polyTime). The certificate for De (decodeWord_polyTime) is public too:
half-gates garbling has the same En and De.
The body of a garbled function is written from gate data by bodyWith, which takes the rows as a
parameter and is certified once (bodyWith_polyTime); the garbler, the simulator and the hybrid
views of the prv.sim reduction supply only their rows.
Main definitions #
Cslib.Crypto.Garbling.PointPermute.bodyWith: the body of a garbled function from gate data.
Main results #
Cslib.Crypto.Garbling.PointPermute.scheme_isEfficient: point-and-permute garbling is efficient.
The keyed function on words is computed in polynomial time.
Tweaks are computed in polynomial time.
The width of wire numbers is computed in polynomial time.
Permutation bits are read in polynomial time.
Keys are read in polynomial time.
Labels are read in polynomial time.
De runs in polynomial time.
The body of a garbled function #
The body of a garbled function with n inputs and q gates, written from gate data: for each
gate g < q, the numbers A g and B g of its argument wires as wireWidth n q-bit numbers, then
its four rows row g a b i, where a and b are its argument wires numbered from 0 and capped
at cap - 1. The garbler, the simulator and the hybrid views of the prv.sim reduction write their
bodies this way, each with its own rows. The cap keeps the unary wire numbers given to the rows
polynomial in the data, which writes them in binary; a caller caps where the rows cannot tell a
larger wire number from the cap.
bodyWith is the body written gate by gate. When the gate data agree on the gates
g < q with the argument wires A' g and B' g, and the rows on the capped argument wires with
row' g, bodyWith is the word of A', B' and row' over the gates.
The body of a garbled function is computed in polynomial time from gate data: n, q and
the cap in unary, the argument wire numbers in binary, and rows computed in polynomial time on the
gate, its capped argument wires and the row number in unary.
Garbling #
The decoding information of a valid circuit on the garbler's coins, the permutation bits of its output wires, is computed in polynomial time.
Coins and semantics #
Point-and-permute garbling is efficient for every family computed in polynomial time
(PseudorandomFunction.polyTime supplies hf): the length readers n and m, the number of
coins and the garbler on (1^k, f, r), and En, Ev, De and ev on their encoded arguments,
run in polynomial time, for valid circuits encoded by encValidCircuit.