-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add SIS Estimate Functionality #96
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also add a doctest to README.rst to showcase the new capabilities?
docs/algorithms/sis-lattice.rst
Outdated
params = SIS.Parameters(n=113, q=2048, length_bound=512, norm=2) | ||
params | ||
|
||
The simplest (and quickest to estimate) model is solving for the SIS instance with a euclidian norm length bound and assuming the Gaussian heuristic [CheNgu12]_.Then, we can solve for the required root hermite factor [EC:GamNgu08]_ that will guarantee BKZ outputs a short enough vector:: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are we referencing CheNgu12 here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough. Couldn't exactly find a better reference for the Gaussian heuristic. Removed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, sorry, I misread, yes, this is fine. Sorry for the noise
docs/algorithms/sis-lattice.rst
Outdated
|
||
SIS.lattice(params) | ||
|
||
The exact reduction shape model doesn't matter when using euclidian norm bounds, as the required block size is calculated directly from the length bound. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-> "does not"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
docs/algorithms/sis-lattice.rst
Outdated
|
||
SIS.lattice(params.updated(length_bound=70), red_shape_model=Simulator.CN11) | ||
|
||
Another option is to simulate a rerandomization of the basis, such that the q-vectors are *forgotten*. This results in the ``LGSA`` simulator, where the short, unit vectors are still present in the basis. See Figure 12 in the dilithium submission for an example.We can then improve on this result by first preprocessing the basis with block size β followed by a single SVP call in dimension η [RSA:LiuNgu13]_. We call this the BDD approach since this is essentially the same strategy as preprocessing a basis and then running a CVP solver:: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Capitalise "Dilithium"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Space after Dilithium
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This BDD stuff seems a leftover from somewhere else?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was. Forgot to delete. Resolved.
estimator/sis_lattice.py
Outdated
**kwds, | ||
): | ||
""" | ||
This function optimizes costs for a fixed guessing dimension ζ. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Guessing dimension might be a bit misleading?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed to make a bit more descriptive.
Wooohoo! |
Resolves #25
Adds a new, separate API for SIS estimation specifically, alongside a new SISParameters data class. Initial support is only for lattice attacks on SIS, so only an sis_lattice attack file is included. Outputs for SIS with an Infinity norm length bound are tuned to match the Dilithium NIST Round 3 specification https://pq-crystals.org/dilithium/data/dilithium-specification-round3-20210208.pdf when using the new basis shape estimator. Schemes.py has been updated to include unforgeability parameters for Dilithium and secret key recovery plus unforgeability parameters for Falcon.