Documentation

CslibFrontier.Crypto.Computational.MLDSA.QuantumCommitment

Reprogramming one ML-DSA commitment after coherent hash queries #

A quantum adversary measures a 512-bit message representative after T coherent XOR queries. The signing experiment draws a fresh ideal mask and programs the FIPS 204 commitment hash at its literal bit-string input. The measured message, the programmed address, the current hash table and the residual quantum state are available to the continuation.

For a uniform public matrix the mean square root of the largest commitment probability is bounded by the rounded-commitment count and its kernel moment. This yields the numerical bound at each FIPS 204 level after one refresh. The quantum step uses [BBBV97].

The finite oracle addresses contain every FIPS 204 commitment input, together with any additional raw hash inputs admitted by the adversary's finite query register. Equal strings from different uses name the same table entry.

@[reducible, inline]

A coherent response register has one bit per bit of the commitment digest.

The single raw oracle address queried for this representative and ring commitment.

The coherent and classical signers use the same raw message and packed high bits.

noncomputable def Cslib.Crypto.MLDSA.FIPS204.signingAddressLaw (s : Level) (extra : Finset (List Bool)) (A : PublicMatrix s) (μ : BitString 512) :

The actual SHAKE input for a fresh ideal signing mask at a chosen message representative.

Every encoded address has mass at most the largest rounded commitment atom.

noncomputable def Cslib.Crypto.MLDSA.FIPS204.commitmentRefreshProbability (s : Level) (extra : Finset (List Bool)) {W : Type u_1} {κ : Type u_2} [Fintype W] [Fintype κ] (refresh : Bool) (T : ℕ) (U : PublicMatrix s → ℕ → Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W →ₗᵢ[ℂ] Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W) (ψ : PublicMatrix s → Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W) (readout : PublicMatrix s → ↥(commitmentAddresses s extra) × DigestRegister s × W → BitString 512) (post : PublicMatrix s → (↥(commitmentAddresses s extra) → DigestRegister s) → BitString 512 → ↥(commitmentAddresses s extra) → Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W →ₗᵢ[ℂ] EuclideanSpace ℂ κ) (accept : PublicMatrix s → (↥(commitmentAddresses s extra) → DigestRegister s) → BitString 512 → ↥(commitmentAddresses s extra) → Finset κ) :

Final acceptance probability of the one-commitment experiment, averaged over the public matrix and the hash table. The adversary's query isometries, initial state and measurement of the message may all depend on the public matrix. After the address is sampled, the continuation sees either the original table or the table with a fresh uniform digest there.

theorem Cslib.Crypto.MLDSA.FIPS204.abs_commitmentRefreshProbability_sub_le_fips (s : Level) (extra : Finset (List Bool)) {W : Type u_1} {κ : Type u_2} [Fintype W] [Fintype κ] (T : ℕ) (U : PublicMatrix s → ℕ → Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W →ₗᵢ[ℂ] Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W) (ψ : PublicMatrix s → Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W) (readout : PublicMatrix s → ↥(commitmentAddresses s extra) × DigestRegister s × W → BitString 512) (post : PublicMatrix s → (↥(commitmentAddresses s extra) → DigestRegister s) → BitString 512 → ↥(commitmentAddresses s extra) → Quantum.ValueState (↥(commitmentAddresses s extra)) (DigestRegister s) W →ₗᵢ[ℂ] EuclideanSpace ℂ κ) (accept : PublicMatrix s → (↥(commitmentAddresses s extra) → DigestRegister s) → BitString 512 → ↥(commitmentAddresses s extra) → Finset κ) (hψ : ∀ (A : PublicMatrix s), ‖ψ A‖ = 1) :
|commitmentRefreshProbability s extra true T U ψ readout post accept - commitmentRefreshProbability s extra false T U ψ readout post accept| ≤ 2 * ↑T * (11 / 10 / √(2 ^ s.commitmentBoxBits))

The distinguishing advantage for one fresh ideal signing commitment after T coherent queries. The right-hand side is numerical at every FIPS 204 level.