Documentation

CslibFrontier.Crypto.Computational.SIS.Basic

The short integer solution problem #

A short integer solution ([Ajt96]) for a matrix A ∈ ℤ_q^{n×m} and a bound β is a nonzero integer vector z with every coordinate in [-β, β] and A z ≡ 0 (mod q) (SIS.IsSolution). It is a predicate for any modulus and index types, so that protocols can extract solutions for matrices such as [A | T].

sisExperiment q β S is the SIS experiment for one modulus, dimension and bound: the challenger draws a uniform A ∈ ℤ_q^{n×m}, and the solver S wins when it returns a short integer solution for A. The solver receives and returns typed values; there are no encodings or security parameter. The experiment tests the integer answer itself and assumes no relation between β and q. When q ≤ β and m ≠ 0, the vector with one coordinate q and all others 0 is a short solution for every matrix, so for such parameters winning does not depend on the matrix.

The asymptotic hypothesis SIS P fixes a parameter family P : SISParams (dimensions, nonzero modulus and bound for each security parameter) and asserts that every solver that is uniform strict PPT on encodings (SISParams.Solver.IsPPT) has negligible advantage. A solver machine reads SISParams.encInput, the unary security parameter followed by the row-major framed residues of A (SIS.encodeMatrix), and writes the framed binary sign-magnitude coordinates of its answer (SIS.encodeVec).

SIS is an explicit computational hardness hypothesis against uniform classical strict PPT programs, not a theorem. It asserts hardness for no particular parameters, and no worst-case lattice reduction is formalized.

Main definitions #

Main results #

References #

def Cslib.Crypto.SIS.IsSolution {q : ℕ} {ρ : Type u_1} {ι : Type u_2} [Fintype ι] (A : Matrix ρ ι (ZMod q)) (β : ℕ) (z : ι → ℤ) :

z is a short integer solution for A: it is nonzero, every coordinate lies in [-β, β], and A z ≡ 0 (mod q).

Instances For
    @[instance_reducible]
    instance Cslib.Crypto.SIS.instDecidableIsSolutionOfFintype {q : ℕ} {ρ : Type u_1} {ι : Type u_2} [Fintype ρ] [Fintype ι] (A : Matrix ρ ι (ZMod q)) (β : ℕ) (z : ι → ℤ) :

    Residue vectors #

    def Cslib.Crypto.SIS.inInfNormBound {q : ℕ} {ι : Type u_1} (β : ℕ) (z : ι → ZMod q) :

    A residue vector z : ι → ZMod q has centered representatives bounded by β in ℓ_∞ norm when |(z i).valMinAbs| ≤ β for every coordinate i.

    Instances For
      @[instance_reducible]
      instance Cslib.Crypto.SIS.instDecidableInInfNormBoundOfFintype {q : ℕ} {ι : Type u_1} [Fintype ι] (β : ℕ) (z : ι → ZMod q) :
      def Cslib.Crypto.SIS.IsResidueSolution {q : ℕ} {ρ : Type u_1} {ι : Type u_2} [Fintype ι] (A : Matrix ρ ι (ZMod q)) (β : ℕ) (z : ι → ZMod q) :

      A residue vector z : ι → ZMod q is a short solution for A when it is nonzero, its centered representatives lie in [-β, β], and A *ᵥ z = 0.

      Instances For
        @[instance_reducible]
        instance Cslib.Crypto.SIS.instDecidableIsResidueSolutionOfFintype {q : ℕ} {ρ : Type u_1} {ι : Type u_2} [Fintype ρ] [Fintype ι] (A : Matrix ρ ι (ZMod q)) (β : ℕ) (z : ι → ZMod q) :
        def Cslib.Crypto.SIS.liftCentered {q : ℕ} {ι : Type u_1} (z : ι → ZMod q) :
        ι → ℤ

        Lift a residue vector z : ι → ZMod q to its centered integer representatives in (-q/2, q/2].

        @[simp]
        theorem Cslib.Crypto.SIS.intCast_comp_liftCentered {q : ℕ} {ι : Type u_1} (z : ι → ZMod q) :

        Reducing the centered integer lift modulo q recovers the original residue vector.

        @[simp]
        theorem Cslib.Crypto.SIS.liftCentered_ne_zero_iff {q : ℕ} {ι : Type u_1} (z : ι → ZMod q) :

        The centered integer lift is nonzero if and only if the residue vector is nonzero.

        theorem Cslib.Crypto.SIS.isResidueSolution_iff_isSolution {q : ℕ} {ρ : Type u_1} {ι : Type u_2} [Fintype ι] (A : Matrix ρ ι (ZMod q)) (β : ℕ) (z : ι → ZMod q) :

        A residue vector is a short solution if and only if its centered integer lift is a short integer solution.

        Encodings #

        def Cslib.Crypto.SIS.encodeMatrix {rows cols q : ℕ} (A : Matrix (Fin rows) (Fin cols) (ZMod q)) :

        Row-major framed binary encoding of a matrix over ZMod q, encoding each entry's canonical representative in [0, q) with encNat.

        Matrices of fixed shape over ZMod q are determined by their encodings when q ≠ 0.

        Encode an integer vector Fin m → ℤ as a framed list of binary sign-magnitude words.

        Integer vectors of fixed length are determined by their encodings.

        The fixed-instance experiment #

        noncomputable def Cslib.Crypto.sisExperiment (q : ℕ) [NeZero q] {n m : ℕ} (β : ℕ) (S : Matrix (Fin n) (Fin m) (ZMod q) → ProbComp (Fin m → ℤ)) :

        The SIS experiment ([Ajt96]) for modulus q, dimensions n × m and bound β: the challenger draws a uniform A ∈ ℤ_q^{n×m}; the solver wins when it returns a short integer solution for A.

        noncomputable def Cslib.Crypto.sisAdvantage (q : ℕ) [NeZero q] {n m : ℕ} (β : ℕ) (S : Matrix (Fin n) (Fin m) (ZMod q) → ProbComp (Fin m → ℤ)) :

        The SIS advantage of S: its success probability in sisExperiment.

        Parameter families #

        Parameter family for the short integer solution problem over an arbitrary nonzero modulus schedule q, including primes, powers of two and other composites.

        • n : ℕ → ℕ

          Number of rows of the public matrix.

        • m : ℕ → ℕ

          Number of columns of the public matrix.

        • q : ℕ → ℕ

          Modulus at each security parameter.

        • β : ℕ → ℕ

          Norm bound on solution vectors, interpreted according to the norm-specific SIS game (ℓ_∞ in SIS, Euclidean ℓ₂ in Euclidean-norm variants).

        • hq (security : ℕ) : NeZero (self.q security)

          Every modulus is nonzero.

        The input of a SIS solver for the family P: the security parameter and a public matrix of the dimensions and modulus that P assigns to it.

        The words a machine reads for a SIS input: the security parameter and the encoded matrix.

        A SIS input is determined by its words.

        The encoding of a SIS input: the framed unary security parameter followed by the encoded matrix (encInput_apply).

        The security parameter of a SIS input is computable in polynomial time from its encoding.

        @[reducible, inline]

        A SIS solver for the family P: given the security parameter κ and a matrix of the dimensions and modulus of P at κ, it returns an integer vector. Solver.IsPPT states its efficiency on encodings.

        A SIS solver is PPT when one uniform strict PPT machine reads encInput and writes the encoding of the solver's answer.

        The SIS hardness hypothesis for a parameter family P: every PPT solver has negligible advantage in sisExperiment at the parameters P assigns to each security parameter. This is a hypothesis against classical adversaries, not a theorem of hardness.

        Source. This is the problem of [Ajt96] (ECCC report TR96-007), "The definition of the random class", p. 4: given vectors u₁, …, u_m ∈ ℤⁿ, here the columns of A, find a short vector in the lattice Λ(ν, q) of integer sequences h with ∑ hᵢ uᵢ ≡ 0 (mod q). [Lyu12], Definition 3.1, p. 6 (ePrint full version 2011/537), states it for arbitrary parameters as ℓ₂-SIS_{q,n,m,β}: given a uniform A ∈ ℤ_q^{n×m}, find v ∈ ℤ^m \ {0} with A v = 0 and ‖v‖ ≤ β. This definition differs from these in four ways.

        • The bound β is on the ℓ_∞ norm, where both sources bound the Euclidean norm (Ajtai's Theorem 1, p. 6, by n). A vector of Euclidean norm at most β meets it, and one that meets it has Euclidean norm at most β √m.
        • The matrix is uniform, which is Ajtai's idealized distribution λ' (p. 4). His random class λ (p. 5) fixes the last column so that a short vector is planted, and he shows that its distribution is exponentially close to uniform.
        • The family P is arbitrary, where Ajtai takes m = ⌊c₁ n log n⌋ and q = ⌊n^{c₂}⌋.
        • Solvers are uniform classical strict PPT programs, whose success probability must be negligible in κ. Ajtai's Theorem 1 assumes an algorithm polynomial in n that succeeds with probability at least 1/2, or n^{-c} (Remark 1, p. 6).