One native pass of the Schnorr forking reduction #
The security proof of Schnorr signatures in the random-oracle model
(succProbability_eufCmaGame_schnorrWordROMScheme_le) runs the forger twice through the existing
FiatShamir.forkingProgram: signing calls are answered from presampled simulated transcripts
(t, c, z), which also program the oracle at (msg, t), and hash calls are answered from a table
or from a list of presampled answers. That program is a typed distribution-level object with no
runtime bound. This module gives one native pass of it, for a native forger given as a guarded
saved-coin replay (savedWordReplay), and proves that the pass is strict PPT and computes exactly
what the typed program computes.
The native state (SchnorrForkState) holds the oracle table, the signed messages, the number of
own hash queries and the number of handled calls; challenges and transcripts are words. One call
(schnorrForkStep) mirrors ForkingReduction.handler: every call consumes a transcript, and a new
hash point consumes the next answer. When the answers run out, a new point gets the empty reply
and changes nothing. This keeps each table tag at most the number of answers, so the state grows
by an amount bounded by the input and the request (IsOraclePPTOn.run_interpret_preprocess). The
final check (schnorrForkFinish) decodes the forgery with the existing total pair decoder, verifies
it with schnorrSigVerifyBits, and returns the code of the named index (forkIndexCode, mirroring
validIndex), the challenge and the response.
eval_schnorrForkPass shows that on a canonical public key, at least B transcripts and B + 1
answers, where B = savedCoinBudget … bounds the forger's calls, the pass returns exactly the
index, challenge and response that forkingAlgorithm reads from FiatShamir.forkingProgram for
schnorrWordROMScheme and the decoded saved-coin forger. Exhaustion of the banks is ruled out by
the call budget, not assumed, so the typed program's default answer is never used.
Sampling the banks, the second pass with spliced answers, extraction, and the discrete-logarithm theorem are separate steps (#2568).
Main definitions #
SchnorrForkEntry,SchnorrForkState,SchnorrForkBanks,SchnorrForkPassInput: the table entries, state, banks and input of a native pass, withenc_structureencodings.schnorrForkStep: one call of a native pass.schnorrForkRun: the guarded replay run againstschnorrForkStep.schnorrForkFinish: the final check.schnorrForkPass: one native pass.forkIndexCode,forkRunWords: the native code of a named fork index and the words a pass returns for one typed run.
Main results #
computableInPolyTime_schnorrForkStep,computableInPolyTime_schnorrForkFinish: the step and the final check run in polynomial time.isPPTOn_schnorrForkRun,isPPTOn_schnorrForkPass: the run and the pass are strict PPT in their full inputs, for every replay machine.eval_schnorrForkPass: the pass agrees exactly with the typed forking program.
References #
- D. Boneh, V. Shoup, A Graduate Course in Applied Cryptography, Version 0.6, Section 19.6.1. The native realization is original.
An entry of the oracle table of a native forking pass.
The hash point.
The challenge word at the point.
- tag : ℕ
0for a point programmed by a signing call,i + 1for the pass's own query numberi.
The encoding of a table entry: the point and challenge words, then the tag in unary.
The state of a native forking pass.
- table : List SchnorrForkEntry
The oracle table, newest entry first.
The signed messages, newest first.
- count : ℕ
The number of the pass's own hash queries.
- used : ℕ
The number of handled calls, which is also the number of consumed transcripts.
The encoding of a pass state, with both counters in unary.
The encoding of the banks: the transcripts as a list of encBits-framed word triples
(t, c, z), then the answers as a list of encBits-framed words.
One call of the native forking pass. A signing call on msg takes the next transcript
(t, c, z), returns (t, z), programs the point (msg, t) with c and logs msg. A hash call
returns the table's challenge for its point, or else the next unused answer, which it records as
the pass's own query. Every call consumes one transcript, as in ForkingReduction.handler. Once
the answers run out, a new point gets the empty reply and changes nothing, which keeps every tag
at most the number of answers.
The native forking step is computable in polynomial time.
The native pass #
The input of one native forking pass.
- secParam : ℕ
The security parameter.
The public-key word given to the forger.
The forger's saved coin tape.
- banks : SchnorrForkBanks
The presampled transcripts and answers.
The encoding of a pass input: the security parameter in unary, the public-key and tape words, then the banks.
The tuple of the fields of encSchnorrForkPassInput.
Run the guarded saved-coin replay of a native forger against schnorrForkStep, from the empty
table. Returns the forger's output words and the final state.
The native forking run is strict PPT in its full input: the security parameter, public-key word, saved tape and both banks, for every guarded replay machine.
The final check #
The final check of a native pass on the forger's output (msg, sig). The signature word is
decoded to (t, z) with the existing total pair decoder. The challenge of the point (msg, t) is
the table's, or else the next unused answer, which then counts as the pass's last own query. The
forgery wins when schnorrSigVerifyBits accepts and msg was never signed.
The result is the named index, the challenge word and the response word. The index is j + 1
when the forgery wins and its point is the pass's own query number j, with j below both the
number of answers and the number of own queries; otherwise it is 0. This mirrors validIndex
applied to ForkingReduction.verdict.
The final check of a native pass is computable in polynomial time.
One native pass of the Schnorr forking reduction: run the forger's guarded saved-coin
replay against schnorrForkStep, then make the final check schnorrForkFinish.
One native forking pass is strict PPT in the full group description and pass input: security parameter, public-key word, saved tape and both banks.
Agreement with the typed forking program #
The code of a named index determines the index.
The words a native pass returns for one run of the typed forking algorithm: the code of the named index, the forgery's challenge as a word, and its response.
One native pass agrees with the typed forking program. Let B be the saved-coin budget.
On a canonical public key, at least B transcripts and B + 1 answers, the native pass returns
exactly forkRunWords of forkingAlgorithm for the existing FiatShamir.forkingProgram of the
word Schnorr scheme and the decoded saved-coin forger: the code of the named index and the
forgery's challenge and response. The default answer of forkingAlgorithm is never used.