arrow-left

All pages
gitbookPowered by GitBook
1 of 1

Loading...

Short integer solutions (SIS)

hashtag
Introduction

In this section we will study the short integer solution problem and a hashing algorithm that is based on this algorithm.

hashtag
Short integer solution problem

Definition

Let be a Short Integer Solution problem. We define it as such:

Given uniformly random vectors , forming the columns of a matrix , find a nonzero integer vector of norm (short) such that

Without the constraint the solution would be as simple as Gaussian elimination. Also we want otherwise would be a fine solution.

Notice that a solution for can be converted to a solution for the extension by appending s to

  • big easy (the more vectors we are given, the easier the problem becomes)

  • big hard (the more dimension we work in the harder the problem becomes)

Solution existence is based on parameters set. One should think about them as follows:

  • is the security parameter. The bigger it is the harder the problem becomes

  • is set depending from application to application. Usually

  • , think of it as

hashtag
SIS as a SVP problem

// TODO

hashtag
Ajtai's hashing function

  • Parameters: ,

  • Key:

  • Input: Short vector

hashtag
Hash function properties:

Compression

We know and . Since we chose .

Collision resistance:

triangle-exclamation

halp here

Sage example:

hashtag
Cryptanalysis

Inverting the function:

Given and find such that

Formulating as a lattice problem:

Find arbitrary such that

  • All solutions to are of the form where

  • So we need to find a short vector in

  • Equivalent, find closest to (CVP)

hashtag
Hermite normal form

// TODO

hashtag
Security Reduction

triangle-exclamation

If somebody can explain the security bounds and reduction better, please do.

hashtag
Resources

  • +

  • - page 18

Ξ²=\beta = Ξ²=the bound is set depending on application and Ξ²β‰ͺq\beta \ll qΞ²β‰ͺq

Output: fA(x)=Axβ€Šmodβ€Šq\boxed {f_A(x) = Ax \bmod q}fA​(x)=Axmodq​ where fA:{0,1}mβ†’(Z/qZ)nf_A : \{0, 1\}^m \to (\mathbb{Z}/q\mathbb Z)^nfA​:{0,1}mβ†’(Z/qZ)n

SISn,m,q,Ξ²SIS_{n, m, q, \beta}SISn,m,q,β​
mmm
ai∈(Z/qZ)na_i∈(\mathbb{Z}/q\mathbb Z)^naiβ€‹βˆˆ(Z/qZ)n
A∈(Z/qZ)nΓ—mA∈(\mathbb{Z}/q\mathbb Z)^{nΓ—m}A∈(Z/qZ)nΓ—m
z∈Zmz∈\mathbb{Z}^mz∈Zm
β€–z‖≀β‖zβ€– ≀β‖z‖≀β
fA(z)=Az=βˆ‘iaiβ‹…zi=0∈(Z/qZ)nz1a1βƒ—+z2a2βƒ—+...+zmamβƒ—=0f_A(z) = Az = \sum_i a_i \cdot z_i = 0 \in (\mathbb{Z}/q\mathbb Z)^n \\ z_1\vec{a_1} + z_2\vec{a_2} +...+ z_m\vec{a_m} = 0fA​(z)=Az=iβˆ‘β€‹ai​⋅zi​=0∈(Z/qZ)nz1​a1​​+z2​a2​​+...+zm​am​​=0
Ξ²\betaΞ²
Ξ²<q\beta < qΞ²<q
z=(q,0,...,0)∈Zmz = (q,0, ..., 0) \in \mathbb{Z}^mz=(q,0,...,0)∈Zm
zzz
AAA
[A∣Aβ€²][A| A'][A∣Aβ€²]
000
zzz
⇒\Rightarrow⇒
m⇒m \Rightarrowm⇒
n⇒n \Rightarrown⇒
nnn
mmm
m≫nm \gg nm≫n
q=poly(n)q = \text{poly}(n)q=poly(n)
q=O(n2)q = \mathcal{O}(n^2)q=O(n2)
m,n,q∈Zm, n, q \in \mathbb{Z}m,n,q∈Z
m>nlog⁑2qm > n \log_2 qm>nlog2​q
A∈(Z/qZ)nΓ—mA \in (\mathbb{Z}/q\mathbb Z)^{n \times m}A∈(Z/qZ)nΓ—m
x∈{0,1}mβ‡’x \in \{0, 1\}^m \Rightarrowx∈{0,1}mβ‡’
x∈{0,1}mβ‡’βˆ£X∣=2nx \in \{0, 1\}^m \Rightarrow |\mathcal{X}| = 2^nx∈{0,1}mβ‡’βˆ£X∣=2n
Ax∈Y=(Z/qZ)nβ‡’βˆ£(Z/qZ)n∣=qn=(2log⁑q)nAx \in \mathcal Y = (\mathbb{Z}/q\mathbb Z)^n \Rightarrow |(\mathbb{Z}/q\mathbb Z)^n| = q^n = (2^{\log q})^nAx∈Y=(Z/qZ)nβ‡’βˆ£(Z/qZ)n∣=qn=(2logq)n
m>nlog⁑qβ‡’βˆ£X∣>∣Y∣m > n \log q \Rightarrow |\mathcal{X}| > |\mathcal{Y}| m>nlogqβ‡’βˆ£X∣>∣Y∣
AAA
yyy
x∈{0,1}mx \in \{0, 1\}^mx∈{0,1}m
Ax=yβ€Šmodβ€ŠqAx = y \bmod qAx=ymodq
ttt
At=yβ€Šmodβ€ŠqAt = y \bmod qAt=ymodq
Ax=yAx = yAx=y
t+LβŠ₯t + L^{\perp}t+LβŠ₯
LβŠ₯(A)={x∈Zm:Ax=0∈(Z/qZ)n}{L}^\perp(A) = \{x \in \mathbb{Z}^m : Ax = 0 \in (\mathbb{Z}/q\mathbb Z)^n \}LβŠ₯(A)={x∈Zm:Ax=0∈(Z/qZ)n}
t+LβŠ₯(A)t + {L}^{\perp}(A)t+LβŠ₯(A)
v∈LβŠ₯(A)v \in {L}^{\perp}(A)v∈LβŠ₯(A)
ttt
https://simons.berkeley.edu/sites/default/files/docs/14967/sis.pdfarrow-up-right
https://www.youtube.com/watch?v=qZIjVX61NFc&list=PLgKuh-lKre10rqiTYqJi6P4UlBRMQtPn0&index=4arrow-up-right
https://crypto.stanford.edu/cs355/18sp/lec9.pdfarrow-up-right
https://eprint.iacr.org/2015/939.pdfarrow-up-right
from Crypto.Util.number import long_to_bytes, bytes_to_long

n, m, q = 20, 40, 1009
set_random_seed(1337)
A = random_matrix(Zmod(q),n, m)

print(A.parent())
# Full MatrixSpace of 20 by 40 dense matrices over Ring of integers modulo 1009
print(A.lift().parent())
# Full MatrixSpace of 20 by 40 dense matrices over Integer Ring

msg = b'msg'
x = vector(Zmod(q), [int(i) for i in bin(bytes_to_long(msg))[2:].zfill(m)]) # pad message
print(len(x)
# 40

print(x.parent())
# Vector space of dimension 40 over Ring of integers modulo 1009

print(len(A * x))
# 20