The forking reduction for Fiat–Shamir in the random-oracle model #
Fiat–Shamir signatures and Fiat–Shamir non-interactive proofs are proved secure by the same
reduction ([BS23], Theorems 19.16 and 20.3.4, with the general forking lemma of
[BN06], Lemma 1). The adversary makes signing (or proving) calls and hash calls and
outputs a candidate (m, (t, z)): a message or statement m and a transcript commitment t and
response z. The reduction runs it as a program over its own hash oracle alone:
- signing calls are answered without a secret, from one presampled value per call, and may
program the oracle table at a point and log an entry (
Signer); - hash calls are answered from the table, or by the reduction's own oracle, recording the position of each such query;
- the candidate wins when its transcript at
point m tis accepting and it was not produced by a logged signing call (Check); the reduction then names the position of the query for that point.
This module states the reduction once (ForkingReduction.program) and proves the facts every
security proof needs: with its oracle answered uniformly, it has the winning law of the adversary
against the presampled game signer (map_run_program); it names a valid query whenever it wins,
so the forking lemma bounds the winning probability (toReal_le_add_sqrt_fork_of_le); and a
successful fork yields two accepting candidates at the same point with different challenges
(exists_of_mem_support_fork). The only assumption linking signer and check is
RejectsProgrammed: a candidate at a programmed point whose log entry is logged is not fresh.
Main definitions #
Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.Signer,Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.Check: the scheme-specific parts.Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.handler: the reduction's answers to the adversary's calls.Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.program: the adversary with simulated signing, as a program over the hash oracle naming the query of its candidate.Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.gameHandler,Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.finishGame: the corresponding game, with the lazy random oracle.
Main results #
Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.map_run_program: the reduction simulates the game.Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.runWithAnswers_program: the reduction's runs on fixed answers.Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.toReal_le_add_sqrt_fork_of_le: the forking lemma for the reduction.Cslib.Crypto.Protocols.SigmaProtocol.ForkingReduction.exists_of_mem_support_fork: extraction data from a successful fork.
References #
The state of the reduction while it runs the adversary: the oracle table, each point with its challenge and, when the reduction asked its own oracle for the point, the position of that query; the entries logged by signing calls; the number of queries asked so far; and the presampled values not used yet.
How the reduction answers a signing call q without a secret, from one presampled value s:
it returns (step s q).1 and, when (step s q).2 = some (x, c, l), programs the oracle at x with
c and logs l.
- fallback : S
The value used once the presampled values run out.
The reply to a call and what it programs and logs.
The final check on a candidate (m, (t, z)): its challenge is the oracle's value at
point m t, and it wins when accepts m t c z and fresh m t log.
- point : M → T → Point
The oracle point of a candidate.
- accepts : M → T → C → Z → Bool
Whether the candidate's transcript is accepting.
Whether the candidate was not produced by a logged signing call.
No candidate at a point the signer programmed is fresh once that call's log entry is logged. This is what makes a winning candidate name its own hash query.
Answer the adversary's calls without a secret, consuming one presampled value per call. A signing call follows the signer. A hash call returns the table's challenge, or asks the reduction's own oracle and records the answer with the position of the query.
The outcome of the final check: whether the candidate won, the candidate and its challenge.
- won : Bool
Whether the candidate won.
- message : M
The candidate's message or statement.
- commitment : T
The candidate's commitment.
- challenge : C
The challenge at the candidate's point.
- response : Z
The candidate's response.
The verdict on a candidate whose point has challenge c: when it wins, the reduction names
position, the position of the query for its point.
Check a candidate, querying its point when the table lacks it.
The reduction. The adversary A, with signing calls answered by σ from samples, as a
program over the hash oracle alone. It names the query of the candidate's point when the
candidate wins.
The game's signer from one value s: signing calls follow the signer, programming the lazy
oracle's table, and hash calls are answered by the lazy random oracle.
The game's final check: query the candidate's point on the lazy oracle and test it.
The reduction simulates the game #
The reduction simulates the game. With its oracle answered uniformly, the reduction wins exactly when the adversary wins against the game's signer with the same presampled values.
The reduction's runs on fixed answers #
The reduction's runs on fixed answers. On any list of answers, a winning candidate names a position, and a named position is that of the query for the candidate's point, answered there with the candidate's challenge, and the candidate's transcript is accepting.
The reduction asks at most one query per hash call of the adversary, and one more to check the candidate.
Forking the reduction #
The forking lemma for the reduction ([BN06], Lemma 1). If an event has
probability at most ε more than the reduction's winning probability, over coins first that
fix the check, the adversary and the presampled values, and the adversary makes at most Qro hash
calls, then the event has real probability at most (Qro + 1) / |C| + √((Qro + 1) · succ) + ε,
where forking the reduction succeeds with probability at most succ.
Extraction data from a successful fork. Both runs of a successful fork of the reduction
start from the same coins s and name the same query: their candidates outcome and outcome'
have the same point, different challenges, and accepting transcripts.