Documentation

CslibFrontier.Crypto.Protocols.AnonymousToken.ROBridgePolyTime.Token

Strict-PPT ROM Bridge for AnonymousToken.Basic #

Realizes the straight-line AnonymousToken.Basic VOLEitH token extraction reduction (extractedForgerWordOfROM) in word-level strict oracle PPT (isOraclePPT_extractedForgerWordOfROM), proves exact PMF equivalence with ROBridge.extractedForgerOfROM (eval_runWith_romToExtracted_eq), and derives the conditional single-repetition bound romUnextractedTokenWordGame_succProbability_le_negligible_add_of_soundnessError (not the cited end-to-end VOLE-ACT security theorem: as accept_le_of_soundnessError shows, at constant d, any statement with a non-witness in the image of decWit is accepted with probability at most 2 ^ d * ε_rel n for every prover; multi-repetition soundness remains open under #7068).

Word-level issuance request paired with a VOLE-in-the-head proof of opening knowledge.

  • message : List Bool

    Requested token message word.

  • target : List Bool

    Target digest word for the blind/unextracted issuance query.

  • Word-level VOLEitH opening proof attached to the issuance query.

theorem Cslib.Crypto.AnonymousToken.encWordROMTokenRequest_mk_budget {γ : Type} {encIn : γ ↪ List Bool} {budget : γ → ℕ} {x0 x1 : γ → List Bool} {x2 : γ → WordVOLEITHProof} (h0 : Turing.MultiTapeTM.ComputableInSpace x0 encIn Turing.MultiTapeTM.encBits budget) (h1 : Turing.MultiTapeTM.ComputableInSpace x1 encIn Turing.MultiTapeTM.encBits budget) (h2 : Turing.MultiTapeTM.ComputableInSpace x2 encIn encWordVOLEITHProof budget) :
Turing.MultiTapeTM.ComputableInSpace (fun (x : γ) => { message := x0 x, target := x1 x, proof := x2 x }) encIn encWordROMTokenRequest budget
theorem Cslib.Crypto.AnonymousToken.encWordROMTokenRequest_mk_inO {γ : Type} {encIn : γ ↪ List Bool} {x0 : γ → List Bool} {T0 S0 : γ → ℕ} {x1 : γ → List Bool} {T1 S1 : γ → ℕ} {x2 : γ → WordVOLEITHProof} {T2 S2 : γ → ℕ} (h0 : Turing.MultiTapeTM.ComputableInO x0 encIn Turing.MultiTapeTM.encBits T0 S0) (h1 : Turing.MultiTapeTM.ComputableInO x1 encIn Turing.MultiTapeTM.encBits T1 S1) (h2 : Turing.MultiTapeTM.ComputableInO x2 encIn encWordVOLEITHProof T2 S2) :
Turing.MultiTapeTM.ComputableInO (fun (x : γ) => { message := x0 x, target := x1 x, proof := x2 x }) encIn encWordROMTokenRequest (fun (x : γ) => T0 x + (T1 x + T2 x)) fun (x : γ) => S0 x + (S1 x + S2 x)
theorem Cslib.Crypto.AnonymousToken.encWordROMTokenRequest_proof_budget {γ✝ : Type} {encIn✝ : γ✝ ↪ List Bool} {S✝ : γ✝ → ℕ} {g✝ : γ✝ → WordROMTokenRequest} :

Statement word (message, target) associated to a word-level token issuance request.

Typed ROMTokenRequest view of a word-level token issuance request.

@[reducible, inline]

Word-level oracle-PPT adversary against the VOLE-in-the-head unextracted token experiment, taking (n, encWordPair (pk, ck)) and issuing ROMWordOp queries (sign, leaf, fs).

Fix the commitment key ck in a word-level unextracted token adversary's input.

noncomputable def Cslib.Crypto.AnonymousToken.romTokenAdversaryToTypedBounded (d : ℕ) (sdLen comLen rowLen chalLen pkBound : ℕ → ℕ) (A : WordROMTokenAdversary) (n : ℕ) (ck pk : List Bool) :
ProbOracleComp (ROMTokenSpec (List Bool) (List Bool) d (sdLen n) (comLen n) (rowLen n) (List Bool) (List Bool) (List Bool) (BitString (chalLen n)) (List Bool)) (Token (List Bool) (List Bool) (List Bool))

Bounded-key wrapper around romTokenAdversaryToTyped yielding uniform ∀ pk query costs for ROBridge.unextractedTokenExperiment_succProbability_le.

noncomputable def Cslib.Crypto.AnonymousToken.extractedForgerWordOfROM (d : ℕ) (sdLen comLen rowLen chalLen : ℕ → ℕ) (expand decWit : ℕ → List Bool → List Bool) (chalToIdx : ℕ → List Bool → Fin (2 ^ d)) (checkRel : ℕ → List Bool → List Bool → (Fin d → List Bool) → List Bool → List Bool → List Bool → Bool) (sigCap : ℕ → List Bool → List Bool → List Bool → ℕ) (A : WordROMTokenAdversary) :

Word-level straight-line VOLE-in-the-head extractor translating a WordROMTokenAdversary into a WordExtractedForgerOf (List Bool) over signing oracle Unit.

theorem Cslib.Crypto.AnonymousToken.isOraclePPT_extractedForgerWordOfROM (d : ℕ) (sdLen comLen rowLen chalLen : ℕ → ℕ) (hsdLen : Turing.MultiTapeTM.ComputableInPolyTime sdLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (hcomLen : Turing.MultiTapeTM.ComputableInPolyTime comLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (hrowLen : Turing.MultiTapeTM.ComputableInPolyTime rowLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (hchalLen : Turing.MultiTapeTM.ComputableInPolyTime chalLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (expand : ℕ → List Bool → List Bool) (hexpand : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool) => expand p.1 p.2) encParamInput Turing.MultiTapeTM.encBits) (decWit : ℕ → List Bool → List Bool) (hdecWit : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool) => decWit p.1 p.2) encParamInput Turing.MultiTapeTM.encBits) (chalToIdx : ℕ → List Bool → Fin (2 ^ d)) (hchalToIdx : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool) => chalToIdx p.1 p.2) encParamInput (Turing.MultiTapeTM.encFinEnum (Fin (2 ^ d)))) (checkRel : ℕ → List Bool → List Bool → (Fin d → List Bool) → List Bool → List Bool → List Bool → Bool) (hcheckRel : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool × List Bool × (Fin d → List Bool) × List Bool × List Bool × List Bool) => checkRel p.1 p.2.1 p.2.2.1 p.2.2.2.1 p.2.2.2.2.1 p.2.2.2.2.2.1 p.2.2.2.2.2.2) (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encUnary (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encBits (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encBits (Turing.MultiTapeTM.encPair (Turing.MultiTapeTM.encPi Turing.MultiTapeTM.encBits) encVOLECheckTail)))) Turing.MultiTapeTM.encBool) (sigCap : ℕ → List Bool → List Bool → List Bool → ℕ) (hsigCap : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool × List Bool × List Bool) => sigCap p.1 p.2.1 p.2.2.1 p.2.2.2) encTargetArgs Turing.MultiTapeTM.encUnary) {A : WordROMTokenAdversary} (hA : Probability.IsOraclePPT encWordToken A) :
Probability.IsOraclePPT encWordToken (extractedForgerWordOfROM d sdLen comLen rowLen chalLen expand decWit chalToIdx checkRel sigCap A)

Straight-line extraction of any efficient WordROMTokenAdversary preserves IsOraclePPT into WordExtractedForgerOf (List Bool).

3b. AnonymousToken.Basic PMF correspondence and unextracted ROM security #

noncomputable def Cslib.Crypto.AnonymousToken.romUnextractedTokenHandlerWord (d : ℕ) (sdLen comLen rowLen chalLen : ℕ → ℕ) (expand : ℕ → List Bool → List Bool) (chalToIdx : ℕ → List Bool → Fin (2 ^ d)) (checkRel : ℕ → List Bool → List Bool → (Fin d → List Bool) → List Bool → List Bool → List Bool → Bool) (S : WordSignatureScheme) (n : ℕ) (ck sk : List Bool) (q : ROMWordOp × List Bool) :

Word-level stateful oracle handler for the unextracted anonymous-token issuance game, answering .sign, .leaf, and .fs queries against WordVOLETraceState d × List (List Bool).

noncomputable def Cslib.Crypto.AnonymousToken.runROMUnextractedTokenWord (d : ℕ) (sdLen comLen rowLen chalLen : ℕ → ℕ) (expand : ℕ → List Bool → List Bool) (chalToIdx : ℕ → List Bool → Fin (2 ^ d)) (checkRel : ℕ → List Bool → List Bool → (Fin d → List Bool) → List Bool → List Bool → List Bool → Bool) (S : WordSignatureScheme) (A : WordROMTokenAdversary) (n : ℕ) (ck : List Bool) :

Execute a word-level adversary A against romUnextractedTokenHandlerWord at commitment key ck and security parameter n.

noncomputable def Cslib.Crypto.AnonymousToken.romUnextractedTokenWordGame (d : ℕ) (sdLen comLen rowLen chalLen : ℕ → ℕ) (expand : ℕ → List Bool → List Bool) (chalToIdx : ℕ → List Bool → Fin (2 ^ d)) (checkRel : ℕ → List Bool → List Bool → (Fin d → List Bool) → List Bool → List Bool → List Bool → Bool) (S : WordSignatureScheme) (H : List Bool → List Bool → List Bool) (A : WordROMTokenAdversary) (n : ℕ) :

Word-level unextracted anonymous-token unforgeability game in the random oracle model: samples commitment key ck ← BitString.sampleList n, runs runROMUnextractedTokenWord, and checks romTokenAccept against wordPayloadTarget H n ck.

theorem Cslib.Crypto.AnonymousToken.romUnextractedTokenWordGame_succProbability_le_negligible_add_of_soundnessError (S : WordSignatureScheme) (hS : S.EUFCMA) (H : List Bool → List Bool → List Bool) (hH : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : List Bool × List Bool) => H p.1 p.2) (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encBits Turing.MultiTapeTM.encBits) Turing.MultiTapeTM.encBits) (hHCR : CollisionResistant H) (d : ℕ) (sdLen comLen rowLen chalLen : ℕ → ℕ) (hsdLen : Turing.MultiTapeTM.ComputableInPolyTime sdLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (hcomLen : Turing.MultiTapeTM.ComputableInPolyTime comLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (hrowLen : Turing.MultiTapeTM.ComputableInPolyTime rowLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (hchalLen : Turing.MultiTapeTM.ComputableInPolyTime chalLen Turing.MultiTapeTM.encUnary Turing.MultiTapeTM.encUnary) (hcomNeg : Negligible fun (n : ℕ) => (2 ^ comLen n)⁻¹) (expand : ℕ → List Bool → List Bool) (hexpand : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool) => expand p.1 p.2) encParamInput Turing.MultiTapeTM.encBits) (decWit : ℕ → List Bool → List Bool) (hdecWit : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool) => decWit p.1 p.2) encParamInput Turing.MultiTapeTM.encBits) (chalToIdx : ℕ → List Bool → Fin (2 ^ d)) (hchalToIdx : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool) => chalToIdx p.1 p.2) encParamInput (Turing.MultiTapeTM.encFinEnum (Fin (2 ^ d)))) (checkRel : ℕ → List Bool → List Bool → (Fin d → List Bool) → List Bool → List Bool → List Bool → Bool) (hcheckRel : Turing.MultiTapeTM.ComputableInPolyTime (fun (p : ℕ × List Bool × List Bool × (Fin d → List Bool) × List Bool × List Bool × List Bool) => checkRel p.1 p.2.1 p.2.2.1 p.2.2.2.1 p.2.2.2.2.1 p.2.2.2.2.2.1 p.2.2.2.2.2.2) (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encUnary (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encBits (Turing.MultiTapeTM.encPair Turing.MultiTapeTM.encBits (Turing.MultiTapeTM.encPair (Turing.MultiTapeTM.encPi Turing.MultiTapeTM.encBits) encVOLECheckTail)))) Turing.MultiTapeTM.encBool) {ε_rel : ℕ → NNReal} (hSound : ∀ (n : ℕ) (ck : List Bool), Protocols.VOLE.VOLEITHSoundnessError (wordDecWitBit rowLen decWit n) (wordChalToIdxBit d chalLen chalToIdx n) (romTokenRel (wordPayloadTarget H n ck)) (wordVOLECheckRelBit d rowLen chalLen (⇑encWordPair) checkRel n ck) (ε_rel n)) (A : WordROMTokenAdversary) (hA : Probability.IsOraclePPT encWordToken A) (m Q_leaf Q_FS : ℕ → ℕ) (hmPoly : PolynomiallyBounded m) (hQleafPoly : PolynomiallyBounded Q_leaf) (hQFSPoly : PolynomiallyBounded Q_FS) (hm : ∀ (n : ℕ) (pk ck : List Bool), OracleComp.IsCostBounded (Sum.elim (fun (x : ℕ) => 0) (romWordOpCost ROMWordOp.sign)) (A n (encWordPair (pk, ck))) (m n)) (hleaf : ∀ (n : ℕ) (pk ck : List Bool), OracleComp.IsCostBounded (Sum.elim (fun (x : ℕ) => 0) (romWordOpCost ROMWordOp.leaf)) (A n (encWordPair (pk, ck))) (Q_leaf n)) (hfs : ∀ (n : ℕ) (pk ck : List Bool), OracleComp.IsCostBounded (Sum.elim (fun (x : ℕ) => 0) (romWordOpCost ROMWordOp.fs)) (A n (encWordPair (pk, ck))) (Q_FS n)) :
∃ (neg : ℕ → NNReal), Negligible neg ∧ ∀ (n : ℕ), Game.succProbability (romUnextractedTokenWordGame d sdLen comLen rowLen chalLen expand chalToIdx checkRel S H A n).eval ≤ neg n + ↑(Q_FS n + m n) * ε_rel n

Conditional single-repetition transfer bound (not the cited end-to-end VOLE-ACT security theorem): if S is EUF-CMA, H is collision resistant and poly-time, the VOLE parameters are poly-time with negligible 2 ^ (-comLen n), the single-repetition check has VOLEITHSoundnessError ε_rel, and the IsOraclePPT word-level ROM adversary A makes at most m n signing queries, Q_leaf n leaf queries, and Q_FS n Fiat–Shamir queries (each polynomially bounded), then romUnextractedTokenWordGame advantage is bounded by neg n + ((Q_FS n + m n : ℕ) : ℝ≥0) * ε_rel n for a negligible function neg. The bound is informative when ((Q_FS n + m n : ℕ) : ℝ≥0) * ε_rel n < 1; as accept_le_of_soundnessError shows, at constant depth d, any statement with a non-witness in the image of decWit is accepted with probability at most 2 ^ d * ε_rel n for every prover. Multi-repetition soundness remains open under #7068.