The invention generally relates to systems for public-key cryptography. More particularly, the invention relates to secure information exchange suitable for implementation on optical devices. The invention has particular applications which are quantum secure (that is, would not be easy to break by a quantum computer) and which thus have long term security as required by banking applications for example.
Currently there are two main types of cryptosystems used to securely exchange information over an untrusted channel: private-key, which is generally fast, but requires that keys have already been securely exchanged, and public-key which is generally slower, but has no such requirement. For example, a public-key cryptosystem may be used to securely exchange keys to be used in a private-key cryptosystem.
Some of the most-common public-key cryptosystems, such as RSA and elliptic-curve algorithms, are based on arithmetic problems which would be easy to break by a quantum computer, resulting in lack of future-proofness.
The NTRU family of cryptosystems to which NTRUEncrypt belongs is one of the main proposals for post-quantum public-key cryptography, combining strong security arguments, resistance to known quantum attacks, and small key size. NTRU are lattice-based cryptosystems, expected to be quantum-secure, the NTRU being 2nd-round candidate for the NIST post-quantum standardization process. The main operations in NTRU involve polynomial multiplication. U.S. Pat. No. 6,081,597A is a disclosure of the prior art cryptosystems.
The following prior art is acknowledged: Bagheri Khadijeh et al entitled “A non-commutative cryptosystem based on quaternion algebras”, Designs, Codes and Cryptography, Kluwer Academic Publishers, vol. 86, no. 10, 22 December 2017 (2017-12-22), pages 2345-2377, XP036577232, DOI: 10.1007/S10623-017-0451-4.
This prior art reference requires the use of quaternion algebra over a ring of multinomials. By contrast, embodiments of the invention depart from this teaching as further described in the following section.
Embodiments of the invention seek to improve on the existing prior art methodologies.
In a broad independent aspect, an embodiment of the invention provides a crypto-method of securely communicating a message; the method comprising the steps of:
In preferred embodiments, the crypto-method employs a multinomial ring which employs multinomial algebra over that ring. This difference over the most recently cited prior art is not only formal but very significant in the context of an optical implementation which provides an efficient way to perform multinomial inversion. By contrast the prior art works with a specific ideal. Embodiments of the invention allow for efficient multinomial inversion in any ideal making it more versatile than the prior art methodology. This is further advantageous in embodiments of optical implementation where the choice of ideal will be partially constrained by the optical device input size and output accuracy.
In a subsidiary aspect, the steps comprise multiplications which are performed in a ring of multinomials.
In a further subsidiary aspect, the steps comprise multiplications which are performed in the canonical algebra over R′.
In a further subsidiary aspect, the method further comprises the step of casting said message as a two-dimensional array.
In a further subsidiary aspect, the ring R′ is chosen as the quotient of Z[X,Y] over the ideal generated by two uni-variate polynomials.
In a further subsidiary aspect, the steps comprise multiplications which are performed modulo two polynomials.
In a further subsidiary aspect, the method further comprises the step of providing an optical processing system and thereby performing a two-dimensional discrete Fourier transform.
In a further subsidiary aspect, the ring R′ of multinomials is represented by the formula [X, Y]
XN1−1, YN2−1
, where (N1, N2)∈
*2wherein N1 and N2 are prime numbers.
In a further subsidiary aspect, the crypto-method further comprises the step of providing a message digest m in the form of a multinomial.
In a further subsidiary aspect, the crypto-method further comprises the steps of providing 2D optical arrays and wherein the multinomial m represents a discrete 2D array.
In a further subsidiary aspect, the crypto-method further comprises the steps of providing an optical system suitable for performing both a Fourier transform and an inverse Fourier transform and optically realising both said Fourier transform and said inverse Fourier transform.
In a further subsidiary aspect, the crypto-method comprises the steps of performing a multinomial multiplication and reducing coefficients of a product of multinomials.
In a further subsidiary aspect, the method further comprises the step of reducing the amplitude of individual coefficients of the multinomials.
In a further subsidiary aspect, the method further comprises the step of iteratively reducing coefficients of a product of multinomials by writing each factor as a sum of multinomials with smaller coefficients.
In a further subsidiary aspect, the crypto-method further comprises the step of reducing coefficients by reducing degrees of the multinomials to be multiplied.
In a further subsidiary aspect, the method further comprises the step of reducing the coefficients of a product of multinomials by writing each factor as a sum of multinomials with smaller degrees.
In a further subsidiary aspect, the security of the cryptosystem is established by reduction to a short vector problem using tensors.
In a further broad aspect, the system comprises a processor configured to perform the steps of:
In a further broad aspect, the system comprises an optical processor configured to perform Fourier transform processing to carry out a multinomial multiplication in the ring R of multinomials.
In a further broad aspect, the system comprises an optical processor configured to perform Fourier transform processing to carry out a multinomial multiplication in the canonical algebra of a ring R′ of two or more variate multinomials.
In a further broad aspect, the method for encrypting and decrypting a digital message, the method comprises the steps of:
In a subsidiary aspect, the steps are performed after reducing the magnitude of the multinomials as in the method of any one of the preceding aspects.
In a further subsidiary aspect, the system comprises an electronic processor configured to perform the steps of:
In contrast to the prior art, in certain embodiments, multiplications are performed in a ring of multinomials, instead of polynomials (in prior systems, the message and keys being cast as polynomials before performing encryption or decryption). According to embodiments of the invention, the multiplications are cast as multinomials with two variables (or more), being equivalent to two-dimensional (or higher) convolutions which can be accelerated using optical Fourier transforms.
The public-key cryptosystem methodology outlined herein as “NTRU2D” is based on NTRU but using a different set of public and private keys as well as a different algebraic structure. It is a multi-dimensional (at least two-dimensional) system, which synergistically allows for implementation on an optical device performing a two-dimensional discrete Fourier transform. The resulting system works similarly to NTRUEncrypt from a user point of view, but with different internal mechanics. Advantageously, the system can be straightforwardly extended to a higher number of dimensions, although the two-dimensional version is probably the best-suited for optical implementation.
The method could be efficiently implemented on optical chips of the type developed by Optalysys Ltd, leading to potentially decreased runtimes and smaller power consumption. PCT/EP2020/065740 illustrates examples of optical systems and is incorporated by reference.
In a subsidiary aspect, the ring R of multinomials is represented by the formula [X,Y]/
XN1−1, YN2−1
, where (N1, N2)∈
*2, wherein N1 and N2 are prime numbers.
In a subsidiary aspect, the message digest m is cast as a multinomial representing a 2D array. Accordingly, multiplications may be performed modulo two (or more) polynomials. In the prior art, the correspondence between polynomial multiplication and convolution is due to a reduction (mathematically, a modulo operation) using a fixed polynomial, whose degree is one of the parameters of the cryptosystem. Advantageously, the degrees here are two parameters of the cryptosystem.
In a further subsidiary aspect, the method further comprises the step of performing a multinomial multiplication in the ring R of multinomials using Fourier transform processing. The multiplication may thus be component-wise multiplication. In further subsidiary aspect the method further comprises the step of applying an inverse Fourier transform and representing the message digest m as a multinomial.
In a preferred embodiment, the Fourier transform (and inverse Fourier transform) processing is implemented optically. This provides enhanced security and potential faster processing.
In a further subsidiary aspect, performing the multinomial multiplication comprises the step of reducing coefficients of a product of multinomials. In an embodiment, the step of reducing coefficients comprises reducing the amplitude of the individual coefficients of the multinomials to be multiplied. In an alternative embodiment, the step of reducing coefficients comprises reducing degrees of the multinomials to be multiplied. Advantageously, each of these algorithms compensates for potential low output accuracy of optical systems.
In a preferred embodiment, using a combination of these two algorithms, multinomial multiplication can be performed on a low-accuracy device at the expense of an increased runtime. They can in principle be applied to NTRU or NTRUPrime as well as NTRU2D.
In a subsidiary aspect, the security of the cryptosystem is related to the difficulty of solving a short vector problem (which can be proved using tensors, instead of matrices for the prior art). Accordingly, the reduction involves a different type of mathematical objects compared to the prior art.
In a subsidiary aspect, using Fourier transform processing may comprise performing a block decomposition for a discrete 2D Fourier transform. One advantage of such a decomposition is to reduce the maximum modulus of the Fourier coefficients of each block, thus potentially improving the accuracy. For example, a typical workflow can be:
In a further broad aspect, the invention provides a system comprising an electronic processor configured to perform the steps of:
In a subsidiary aspect, the system comprises an optical processor configured to perform Fourier transform processing to carry out a multinomial multiplication in the ring R of multinomials.
In a further broad aspect, the invention provides a method for encrypting and decrypting a digital message, the method comprising the steps of:
In a further broad aspect, the invention provides a system comprising an electronic processor comprising the steps of:
In a further broad independent aspect, the invention provides a method for encrypting and decrypting a digital message, the method comprising the steps of:
As a public-key cryptosystem, embodiments of the present invention can be advantageously used in secure communication, including banking applications. It could be used, for instance, to exchange keys between two participants over an untrusted channel and establish a secure communication protocol.
In a subsidiary aspect, in accordance with any of the preceding aspects, if the number of variables is smaller or larger than 2, the optical Fourier transform is computed by performing sequential one- and two-dimensional Fourier transforms.
In a subsidiary aspect, in accordance with any of the preceding aspects, the two-dimensional transforms are performed either directly using the optical system or in sequential steps using a Cooley-Tukey algorithm.
In a subsidiary aspect, in accordance with any of the preceding aspects, the one-dimensional transforms are performed using a modification of a Cooley-Tukey algorithm with different twiddle factors.
NTRU is a public-key cryptosystem first proposed in 1996 [1], published in 1998 [2], and in the public domain since 2017. It consists of two families of systems: NTRUEncrypt, an asymmetric encryption scheme, and NTRUSign, a digital signature scheme. Contrary to most current schemes based on arithmetic problems which are prone to quantum attacks (using for instance Shor's algorithm), NTRU is based on lattice problems against which no efficient attack is known, and which are conjectured to be impossible to break in polynomial time. (The term ‘conjectured’ here is understood in a strong sense: decades of research on these problems and attempts at breaking them have found no evidence that they can be broken in polynomial time.) No security vulnerability was found in the more than twenty years since it was first proposed, and it is thought to be resistant against both classical and quantum attacks.
A provably secure (but less efficient) version was proposed in 2013 [3] and is currently studied by the European commission [4] as a possible future-proof alternative to current cryptosystems. Another version, called NTRU Prime, was proposed in 2016 [5] to remove some algebraic structures which might introduce weaknesses—specifically to reduce the number of automorphisms and other endomorphisms of the ring of polynomials in which calculations are performed. (However, at the time of writing, no efficient attack making use of these structures is known.)
(A ring (R, +,∘) is a set R with two binary internal operations R×R→R, hereafter denoted by + and ∘, satisfying the following axioms:
Both the original NTRUEncrypt and NTRU Prime have advanced to the second round of the NIST Post-Quantum Cryptography Standardization project (https://csrc.nist.gov/projects/post-quantum-cryptography/round-2-submissions). Besides its expected post-quantum security, the NTRU family also makes key generation particularly efficient [6], opening possible use cases where the key needs to be changed regularly.
Central to the NTRU algorithms are polynomial multiplications in a finite ring. These operations can be mapped to convolutions of vectors, and thus have efficient implementations in Fourier space. For this reason, the optical Fourier transform of embodiments of the invention can significantly increase the speed and decrease the power consumption of the algorithm.
Naive polynomial multiplication has a complexity O(n2) where n is the degree of the polynomials. A recursive algorithm splitting each polynomial in two reduces the number of required scalar multiplications to O(nlog
A public-key cryptosystem can be used, for instance, in inter-device communication in an Internet of Things network. To take a specific example, two devices would need to communicate securely to exchange personal data about a user (e.g., medical data exchanged between one device used to perform a diagnostic and a hospital storage system) which need to be protected from external unauthorized access. A secure communication channel could be opened between the two devices via the exchange of encryption ciphers, or keys for any other encryption system, which would themselves be encrypted using a public-key cryptosystem to prevent interception by any external actor. For devices operating on low power, making the cryptosystem secure enough would be challenging with current technology. The cryptosystem proposed here will alleviate this problem as its most computationally intensive operation can be performed optically, significantly reducing the power usage.
NTRUEncrypt is a family of cryptosystems with three parameters N, p, and q in * such that
It involves polynomial multiplications in the ring R=[X]/
XN−1
, which can be recast as a convolution and efficiently performed in Fourier space (see appendix A.1.1).
As any public-key cryptosystem, it involves three steps: generation of private and public keys, encryption of a message, and decryption. We now describe each of these steps.
Generation of public and private keys, with reference to
(Technically, fp can be recovered from f , so the private key may be taken as f only. However, in practice it is generally more convenient to save fp rather than to re-compute it at the decryption stage [6]. The requirement that the coefficients of f be between −1 and +1 can be relaxed in practice; although they must still be ‘small’.)
The public key is the polynomial h obtained by multiplying p, the inverse fq of f modulo q, and a polynomial g in R with coefficients in {−1, 0, +1}, and taking the result modulo q: h=(p fq·g) mod q.
An embodiment concerning how the inverse of a polynomial modulo XN−1 can be computed in appendix A.3.1. To get fp and fq, the Euclidean algorithm described there must be performed with K=p and K=
q, respectively. The relation with a short vector problem is outlined in appendix, A.4.1.
Encryption, with reference to
It is important that r be never revealed.
Decryption, with reference to
NB: This is always true if
where ∥ ∥1 denotes the sum of the absolute values of the coefficients. One can relax the assumption on q by imposing some conditions on the private key. Indeed, the conditiona=pr·g+f·m is satisfied for any message m provided
Secure parameters: Provided the parameters are chosen so that a short vector for the lattice of appendix A.4.1 cannot be found using lattice reduction techniques, the most efficient known attacks at the time of writing are meet-in-the-middle attacks. Their complexity is the square root of that of a brute-force attack [6]. Typically, the polynomials f, g, and r are chosen to have a fixed number of 1s, −1s, and 0 s. If a polynomial has d+ positive coefficients and d− negative ones, this leaves N!/(d+!d−!(N−d+−d−) possibilities. The complexity CMITM of a meet-in-the-middle attack is thus, up to a prefactor,
In 2012, the company Security Innovation, which held the NTRU patents, proposed the following sets of parameters in its NTRU tutorial (https://web.archive.org/web/20120606210107/http:/www.securityinnovation.com/security-lab/crypto/155.html, see also the article [6]). Here df, dg, and dr are the numbers of 1s in the polynomials f, g, and r, respectively. The former has one fewer −1s than it has 1s; the others have has many −1s as they have 1s, and the other coefficients are 0. The ‘security’ columns give the numbers of bits of security against meet-in-the-middle attacks as given in [6]. (We show them only when given by the NTRU team.) The key security is given by:
i.e., half the logarithm in base 2 of the number of possible polynomials g. Similarly, the message security is given by
More parameters can be found in table 2.1 of [7].
NB: These parameters are still susceptible to multiple transmission attacks [6]: if the same message is sent several times using different random vectors r, an attacker could recover most of their coefficients by multiplying the difference between encrypted messages by a pseudo-inverse of h. As described in [6], this and some other attacks can be parried by appending a hash and the output of a generating function to the message before encryption. (The modified message is sometimes called a digital envelope, parrying multiple transmission attacks.) Similarly, if g(1)=0, we have e(1)=m(1), so that some information is leaked. This can be prevented by reserving one coefficient of the message to ensure m(1) has a specified value (e.g. 0) independent of the information to be conveyed. The resulting workflow is schematically represented in
A chosen ciphertext attack is described in reference [8], making use of the fact that some messages are not decrypted correctly to learn information on the private key. This and other similar attacks can in principle be parried using the construction described in reference [9], which makes NTRUEncrypt indistinguishable against adaptive chosen-ciphertext attack (IND-CCA2) (see also [10, 11] and references therein).
More recent estimates (see for instance the presentation [12]) suggest choosing the polynomial f in the form f=1+pF, where F has df coefficients equal to 1, df equal to −1, and its other coefficients vanish, with one of the following parameter sets and p=3, shown in the following table:
Performance of electronic implementations: The NTRU project (https://tbuktu.github.lo/ntru/) reports (as of 14 May 2020) about 30,000 encryption operations per second, 22,000 decryption operations per second, or 2,000 key generations per second with 256 bits of security on an Intel Xeon™ at 1.6 GHz.
Two low-power implementations of NTRU on specialized hardware are proposed in [13] for the ‘moderate security’ parameters. The encryption-only design requires 1.72 μW and encryption takes a bit more than 56 ms. The encryption-decryption design requires about 6 μW; encryption and decryption take about 56.78 ms and 119.23 ms respectively.
The NTRU Prime family of cryptosystems (see also the ntruprime.cr.yp.to website) is a tweak of the original NTRU proposal using rings with a different structure; see reference [5]. Its development was motivated by recent quantum attacks against the Ideal-SVP [14, 15] casting doubts on the future-proofness of cryptosystems relying on cyclotomic rings. (A cyclotomic ring is a ring of integers of the number field (∈) where ∈ is a complex root of unity. One can show that it is equal to
[∈], i.e., the ring of polynomials inEwith integer coefficients. If ∈ is a root of the identity and n is the smallest positive integer such that ∈n=1, the ring of integers of
(∈) is isomorphic to
While these are not known to affect the security of NTRU, working with different rings is expected to reduce the probability that successful attacks will be found in the near- or medium-term future. NTRU Prime is currently a second-round candidate in the NIST Post-Quantum Cryptography Standardization Project (https://cscr.nist.gov/projects/post-quantum-cryptography).
The central idea of NTRU Prime is to work in the ring of polynomials [X]/
XN−X−1
for some prime number N , to reduce the number of automorphisms and other endomorphisms which might be used to construct attacks. It comes in two variants: Streamlined NTRU Prime and NTRU LPRime. The first one is extensively described in [5]. Besides the use of different rings, it also eliminates the possibility of decryption failures (by setting a lower bound on the value of the parameter q) and introduces a rounding mechanism which simplifies protection against chosen-ciphertext attacks. However, using Fourier transform methods to perform polynomial multiplications in this ring is more intricate. It is also not clear to what extent the change of ring precisely affects security beyond the speculation (supported by past examples) that reducing the number of endomorphisms may prevent yet-to-be-discovered attacks.
In general, if G is a subring of a field K and P is a polynomial of degree N with N distinct roots in K, then multiplication in the ring
is equivalent to component-wise multiplication of vectors after the change of basis given by the Vandermonde matrix of the roots of P. Indeed, if a and b are two elements of R, A and B are the vectors of their coefficients, c=ab, C the vector of coefficients of c, W the vandermonde matrix of the roots of P, and if a cross denotes the component-wise multiplication, then WC=(WA)×(WB). (This works because c(x)=a(x)b(x) provided x is a root of P.) If P(X)=Xn−1, then multiplication amounts to a discrete Fourier transform.
A bi-variate version of the algorithm described in section 2.1 is described, replacing the ring of polynomials [X]/
XN−1
by
[X, Y]/
XN1−1, YN2−1
, where (N1, N2)∈
*2.
Private key: A multinomial f∈f which has an inverse in R′ modulo p, hereafter called fp, and an inverse in R′ modulo q, hereafter called fq.
Public key: Choose a multinomial g in g. The public key is the multinomial h given by
h=(pfq·g) mod q.
It is important that r be never revealed.
Decryption: For the decryption, all the modulo operations are centred: for any integer n, a quantity modulo n is taken between 1−┌n/2┐ and └n/2┘. The decryption procedure is:
Typically, the three sets f,
y, and
r contain multinomials with small L2 norms. As shown in appendix A.4.3, finding the private key from the publicly-known parameters and public key is then as hard as solving a short vector problem.
NB: As for NTRUEncrypt, the message can, and probably should in real-world applications, be enclosed in a digital envelope before the step 3 of encryption to increase the level of security.
NB2: This cryptosystem can be generalized to a higher number of variables.
The encryption and decryption steps both rely on multinomial multiplication, which can be accelerated by making use of an optical computing device. Here, it is proposed a possible implementation using two devices: an electronic one and an optical one. It is illustrated on
This procedure can be used to compute the products at step 4 in
In practice, the first and last steps may not be required if the input or desired output are two-dimensional arrays rather than multinomials. For instance, the full NTRU2D workflow (including the key generation, encryption, and decryption) may be performed using two-dimensional arrays in place of multinomials, with each coefficient of the multinomials being identified with the corresponding coefficient in one of the arrays.
The inverse Fourier transform of the fourth step may also be replaced by a direct Fourier transform. A rescaling of the output is then required, which may be performed either immediately or at a later stage.
An embodiment will now be described in more details of one possible implementation. The data could be sent to the optical device via an optical fibre link, hereafter called the input link. For instance, it could be encoded in the intensity of monochromatic coherent light emitted by a laser upstream and modulated by a series of heaters or Mach-Zehnder interferometers. Said light would be collimated, e.g. by passing through a series of lenses, before passing through a single lens placed one focal distance away from the collimation plane. It could then be focused into another optical fibre link, hereafter called the output link, by another array of lenses. The signal could then either be converted to an electronic signal by photodiodes at the end of the output link and sent to the electronic device, or sent to the output link of the same or another optical device for further optical processing.
In one embodiment, the optical device would compute only the absolute value of the Fourier transform of the signal. The procedure should then be repeated twice, with two different constants added to the input signal, to recover the full Fourier transform.
In another embodiment, the optical device would compute the full Fourier transform of the signal.
In either of said embodiments, the procedure could be repeated several times to increase the accuracy of the output. The input data would first be split into several datasets with a smaller magnitude by the electronic device. Each dataset would be processed separately by the optical device and sent to the same or another electronic device. Said electronic device would then combine the outputs.
Said optical processing could be performed using the technology patented by Optalysys Ltd.
The decryption process may fail if the polynomial a has at least one coefficient smaller than 1−┌q/2┐ or larger than └q/2┘. Let us estimate the probability of this event. To make things simple, here we assume that
Call N the product N1 N2.
First, notice that decryption will always succeed if p min (Nr, Ng)+└p/2┐Nf≤┌q/2┐−1. To estimate the probability of decryption failure when this condition is not satisfied, assume, in one embodiment, that the probability distribution for the values of each coefficient in each of the polynomials f, g, and r is independent of its position. The probability that at least one coefficient of a is too large is then bounded (from above) by N multiplied by the probability that its first coefficient is too large.
An embodiment first looks at the distribution of values for the product r·g. Call Nr(+) the number of positive coefficients of r , Nr(−) the number of negative coefficients, and similarly for g with the letter r replaced by g. Optionally, assume these four numbers are fixed. The probability that a number n++ of +1s in r coincide with +1s of g and a number n+− of them coincide with −1s in g and similarly for −1s with the first index of n replaced by − is, for n+++n+−x≤Nr′(+) and n−++n−−≤Nr(−):
which may be rewritten as:
For each n∈, the probability that the first coefficient of r·g be equal to n is the sum of this expression over each positive of zero integer values of n++, n+−, n−+, and n−− such that n+++n+−≤Nr′(−), n−++n−−≤Nr′(−), and n++−n+−−n−++n−−=n of this expression.
The expression (1), denoted by Prg below, can be simplified using the Stirling formula in the limit N→∞. Denote with the greek letter λ the ratio of each quantity (denoted by a letter N or n with subscripts and possibly a superscript) over N, and assume these ratios are fixed as N increases. It follows:
where the function plog is defined by:
Typically, the quantity Prg thus decreases exponentially with N. It is thus expected that large deviations from typical values in the coefficients of r·g will be (up to polynomial prefactors) exponentially unlikely as N becomes large.
To get a feel for how small this probability typically is, consider the case λg(+)=λg(−)=λr(+)=λr(−)=¼ and λ++=λ+−=λ−+=λ−−= 1/16, and work with base-2 logarithms. The following arises:
For this particular set of values, the term linear in N vanishes and Prg scales like N−2. However, for these values the first coefficient of r·g is 0, so the relatively high probability is not a problem. In one embodiment, now consider the case λ++=λ+−=λ−+=⅛, λ−+=λ−−=λ−−=0. It follows:
The probability of this configuration thus scales (up to polynomial factors) like 2−N/2.
Now consider the polynomial f·m. For definiteness, assume p=3 and that each coefficient of m is a random variable chosen uniformly and independently between −1 and +1. Then, the first coefficient of the product is the sum of independent, identically distributed random variables with a vanishing mean and a variance equal to ⅔. According to the central limit theorem, in the limit Nf→∞ its distribution becomes close to a Gaussian centred on 0 with variance 2Nf/3. Denoting by Pmf this probability distribution, it follows for each n∈:
The probability that n differs from 0 by λNf, where λ is a real number whose absolute value is noticeably smaller than 1 is thus:
For λ0>0, and up to a polynomial factor, the probability that |(m·r)(0)|>λ0N goes exponentially to 0 when N→∞.
From these results, and if it is assumed that q scales at least linearly with N, the probability of decryption failure should decrease exponentially in N.
An embodiment briefly envisages a possible choice of parameters. It is only given for illustration purposes: more research is required to say whether or not they are secure against combinations of lattice-reduction and meet-in-the-middle attacks.
One embodiment is configured to aim for parameters close to those recommended for NTRUEncrypt. The same values for q and p: q=1024 and p=3 may be chosen. Optionally, choose N1 and N2 close to 20, e.g., N1=N2=23. Optionally, choose the polynomials f, g, and r to have respectively df=149, dg=148, and dr=148 coefficients equal to 1. The polynomials g and r are chosen to have as many coefficients equal to −1 as they have coefficients equal to 1, while f has one fewer of them, and its first coefficient is fixed to be 1. Call N the product N1N2.
The number of bits of security sg of g against meet-in-the-middle attacks is:
The number of bits of security sf of f is:
Finally, the number of bits of security sr of r is:
Notice that decryption failures could be eliminated by choosing q such that q≥4p min(dr,dg)+4df−1=2371. Provide an estimate of the decryption failure for q=1024. To make the analysis simpler, assume that each coefficient of g is chosen randomly in {−1,0, +1}. This should provide an overestimate of the result, as a polynomial thus chosen will generally have fewer vanishing coefficients than actual possible choices for g. The probability that r·g takes a value n1∈ and f·m a value n2∈
is then, assuming Nf and Nr can be considered large, close to
The probability Pe that the first coefficient of a be larger than [q/2]−1 in absolute value is thus of the order of
(The factor 2 n the coefficient of the sum accounts for positive and negative values.) Letting n1 take real values for a moment, the argument of the exponential is maximized when n1 takes a value such that n1/Nr=p(n−pn1)/Nf, i.e., n1=pn/(p2+Nf/Nr). The argument of the exponential is then
It is maximized for n taking its smallest possible value. Assuming q can be considered large, we thus have:
where ln denotes the natural logarithm. The quantity Pe is thus, assuming the approximations made are not too bad, smaller than 2−90. The probability that one coefficient of pr·g+f·m is larger than [q/2]−1 is smaller than NPe≈1×10−26. We thus expect it to be negligible too. If necessary, the probability of decryption error can be further decreased by increasing q.
An algorithm to generate parameters for NTRUEncrypt is given in reference [16]. In certain embodiments, it is applicable, with minor modifications, to NTRU2D.
In one embodiment, consider two multinomials a and b with at most N terms having, respectively, at most Na and Nb nonvanishing coefficients, with absolute values bounded by aM>0 and bM>0. The maximum possible absolute value of the coefficients of a·b is min(Na, Nb) aMbM.
Assume these multinomials have non-negative coefficients. Optionally, perform the multiplication using a device with a number ld of bits of accuracy, and which can deal with non-negative integers only.
Assume that na times the procedure is performed as described in appendix B.1.1 and nd that described in appendix B.1.2. The multiplication of a and b can then be recast as the sum of products of multinomials where each term has coefficients with absolute value smaller than or equal to
Each of them can thus be computed by the device if and only if
In the case of NTRU2D, take N=N1N2 and aM=bM=q−1 for each multinomial product.
The above condition becomes:
Taking N1=N2=23 and q=1024, choosing na=3 and nd=5, the left-hand side is smaller than 8. All multinomial multiplications should thus be doable on a device with 8 bits of accuracy in 15552 frames. Choosing N1=N2=15 and q=258, a value smaller than 8 can be achieved by choosing na=nd=3, so that each term requires only 1728 frames. Assuming the device can run in the GHz range, we thus expect a throughput of the order of a million of multiplications per second for these parameters. More results are given in the following table.
These estimates are based on current generic algorithms to compute the Fourier transform on a low-accuracy device. In certain embodiments, they can be significantly improved by making use of more specific algorithms designed for multinomial multiplication modulo two polynomials and an integer.
Here it is shown how polynomial multiplication in the ring R defined in section 2.1 can be performed in Fourier space. First, choose some notations. As in section 2.1, N is a positive integer and R is the ring [X]/
XN−1
of polynomials with integer coefficients modulo XN−1. Let a and b be two elements of R. Optionally call their coefficients, respectively, a0, a1, . . . , aN−1 and b0, b1, . . . bN−1, so that
Let · denote the product in R. We define c=a·b and call its coefficient c0, c1, . . . , cN−1, so that
Let a, b, and c be the N-dimensional vectors with components, respectively, aj, bj, and cj, for j between 0 and N−1. (For simplicity, in this subsection we take vector indices from 0 to N−1.)
Optionally, denote with a ˜ the discrete Fourier transform: for x∈a, b, c, define the N-dimensional vector with components
The inverse Fourier transform is given by
For each j between 0 and N−1, the coefficient of order j in the polynomial c is:
For each j between 0 and N−1, it follows (using the equality e2iπ=1 to get the second line):
where to get the last line, the new variable l=(j−k) mod N was defined, which varies between 0 and N−1 when k goes from 0 to N−1 for each j∈. This expression can be simplified as:
{tilde over (c)}u=ãu{tilde over (b)}u.
Polynomial multiplication in R is thus equivalent to component-wise multiplication in Fourier space.
Let n∈N* and (N1, N2 . . . , Nn)∈N*n. Let R′ be the ring
Let
I=Πi=1n1, Ni
Optionally, denote the multiplication in R′ by a dot. Let a and b be two elements of R′, and C≡a·b.
Optionally, call a, b, and c the sequences of their coefficients, so that
and similarly for b and c. The latter is given by:
Optionally, denote with a ˜ the discrete Fourier transform: for x∈a, b, c, x˜ is the sequence with the same shape whose elements are given by:
The inverse transform is given by:
Let U∈I. It follows:
This is equivalent to:
{tilde over (c)}U=ãU{tilde over (b)}U.
Multinomial multiplication in R′ is thus equivalent to component-wise multiplication in Fourier space.
The reason why the parameter N must be prime in NTRU is that the polynomial XN−1 must be the product of two prime polynomials in [X] to prevent some lattice-based attacks. These attacks won't be described here, but only give a simple argument showing that XN−1 has more than two factors if N is not prime.
Let a and b be two integers larger than or equal to 2 and let us assume that N=a b. Then,
So, if N is not prime, xN−1 can be expressed as the product of three non-unit polynomials.
Let K be a field. Let P and S be two elements of K[X], i.e., two polynomials over K. Then, there exists a unique couple of polynomials. (R, Q)∈K[X]2 such that the degree of R is smaller than that of S and P=QS+R. We say that Q is the quotient and R the remainder of the Euclidean division of P by S. (Q can be constructed monomial by monomial by matching the highest-order monomial in P, then the second-highest, and so on. Doing so, one can match all monomials in P with degrees smaller than or equal to that of S. What remains is R.)
Let (P, Q)∈K[X]2, where the degrees of P and Q are at least 1 and that of P is smaller than that of Q. In order to see if P is invertible modulo Q, the Euclidean algorithm is applied:
If the degree of Pi+1 is zero and Pi+1≠0, we can go back to find an inverse of P modulo Q. Indeed, we have:
P
i+1
=P
i−1
−A
i
P
i
=P
i−1
−A
i(Pi−2−Ai−1Pi−1)=(1+AiAi−1)Pi−1−AiPi−2=. . .
Going backwards, we obtain a series of expressions of the form
P
i+1
=L
j
P
i−1−j
+R
j
P
i−j
for j=0, 1, . . . , i, where the sequences (Lj) and (Rj) are defined by L0=1, R0=−Ai, and, for each j between 0 and i−1, Lj+1=Ri and Rj+1=Lj−Ai−j−1Rj. Taking j=i−1 gives:
P
i+1
=L
i−1
Q+R
i−1
P.
Since Pi+1 is a non-vanishing polynomial of degree 0, it is invertible (it is, up to the identifications of the unit polynomial with the unit of K, a nonvanishing element of K). We can thus write:
which gives
The polynomial Ri−1/Pi+1 is thus the inverse of P in K[X]/Q
.
Let p be a prime number, n be a positive integer, and N1, N2, . . . , Nn be n positive integers. Optionally, define the set I=Πi=1n1, Ni
. Optionally, work in the ring R′=
[X1, X2, . . . Xn]. Let a∈R′. Optionally, call its coefficients ai, i∈I. Let b be another element of R′ with coefficients bi, i∈I. Optionally, call c their product modulo p: c=(a·b) mod p, and its coefficients ci, i∈I. For each coefficient, it follows:
The multinomial b is the inverse of a modulo p if ci=0 for i≠0 and c0=1. Finding it is equivalent to solving a system of N1N2 . . . Nn linear equations modulo p. Since p is a prime number, p is a field and Gaussian elimination can be used to determine if a is invertible and, if yes, to compute its inverse. This can be extended to the case where p is not a prime by a suitable modification of the Gaussian reduction algorithm, as shown in the example Python code as follows:
This embodiment sketches how finding the private key of the NTRUEncrypt scheme can be related to a Short Vector Problem (SVP). Optionally, the notations of section 2.1 are used. Denote by h0, h1, . . . , hN−1 the coefficients of h, so that
Optionally, define the square matrix H of size N by: h(X)=Σi=0N−1hiXi
For any vector V of size N, HV is the vector of the coefficients of the polynomial h·v, where
v≡Σi=0N−1ViXi.
Let IN be the identity matrix in dimension N and ON the null matrix. The matrix Bh is defined by
Optionally, call f0, f1, . . . , fN−1 the coefficients of f. and g0, g1, . . . , gN−1 those of g. Since f·h=(pg) mod q, one can find integer coefficients a0, a1, . . . , aN−1 such that
(Simply choose the ais to be opposite of the coefficients of f·h−pg divided by q.) So, the vector made of the coefficients of f and p times those of g is a vector in the lattice (Bh) generated by the columns of Bh. If these coefficients are small enough, this is a small vector in the lattice.
Optionally, assume there exists an algorithm to find fin time t from the knowledge of h and q. This algorithm could be used to find pg (equal to (f·h) mod q), and thus a short vector in the lattice (Bh) after performing a number of operations polynomial in N. Finding the secret key of NTRUEncrypt for a given distribution of polynomials f and g is thus at least as hard (up to some polynomial overhead) as finding a ‘short’ (in a sense which depends on the constraints on f and g) vector in the corresponding lattices.
Similarly, recovering the message m from the encrypted e can be mapped to a Close Vector Problem. Indeed, denoting with an italic letter the sequence of the coefficients of the polynomial denoted by the corresponding bold-face letter, it follows:
From the knowledge of m, one can get r in polynomial time, and thus a vector (Bh) close to E.
The SVP is conjectured to be hard for both classical and quantum computers over random lattices. The lattice generated by the matrix Bh above is, however, not random due to its block form and the circulant nature of the matrix H. In order for the reduction to a SVP to be a convincing security argument, it is crucial that the lattice structure should not make it easy to find short vectors.
First, it is trivial to find vectors of length q. Denoting by ∥·∥2 the L2 norm (i.e., for a polynomial, the square root of the sum of its squared coefficients), the vector giving the private key has a length smaller than q if and only if
∥f∥22+p2∥g∥22<q2.
On the other hand, the norms of these polynomials must not be too small. To see this, optionally follow the argument given in section 3.6.1 of reference [6]. Optionally, generalize the matrix Bh by adding a positive parameters and define
It follows:
so that the private key can be recovered by looking for short vectors in (Bh(a)). The L2 norm of this vector is
√{square root over (α2∥f∥22+p2∥g∥22)}
For a random lattice of dimension n generated by a matrix of determinant D, the smallest vector is typically expected to have a length slightly larger than DI/n√{square root over (n/(2πe))}, where e is Euler's constant [6]. In our case, n=2N and D=αNqN. So, the shortest vector is expected to be typically slightly larger than √{square root over (αNq/(πe))}. Let c(α) be the ratio of the length of the above vector to this quantity. It follows:
An attacker may find this vector faster than would be possible for a typical random lattice if c(α) is significantly smaller than 1.
The minimum value cmin of c(α) is obtained for α=p∥g∥2/∥f∥2.
It is larger than or close to 1 provided
This is compatible with the previous condition provided
Nπeq.
The main idea of the argument given in section A.5.1 is to relate polynomial multiplication in R to matrix multiplication. This can be extended to multinomials using more general tensors instead of matrices.
To see this, optionally choose
L∈*, (N1, N2, . . . , NL)∈
*L,
and define the ring:
R′≡
[X
1
, X
2
, . . . X
L
]/
X
1
N
−1, X2N.
Let a be an element of R′. Optionally, define the tensor A of the coefficients of a. (optionally make the indices of tensors start from 0 to simplify the notations.) Let h be a multinomial in R′. Optionally, call h the sequence of its coefficients and H the corresponding tensor such that, for each possible value of (i1, i2 . . . il, j1, j2, . . . , jL)
Hi
Then, the coefficients of the product h·a are those of the tensor HA, defined by:
Optionally also define the unit tensor I of the same shape as H, defined by:
Optionally, work in the space of real tensors of shape (N1, N2, . . . , NL, 2), with indices starting from 0. Linear transformations in this space can be represented by real tensors of shape (N1, N2, , NL, 2, N1, N2, . . . , NL, 2), in the following way: if is such a tensor, and
a tensor of size (N1, N2, . . . , NL, 2), their product is the tensor
of size (N1, N2, . . . NL, 2) given by:
Optionally, define the tensor B in the following way: for each (I, J)∈(Πi=1L0, Ni
)2.
Let f and a be two elements of R′. We denote by y the product h·f and by f, a, and y the sequences of their coefficients. Optionally, define the tensor of shape (N1, N2, NL, 2) by: for each
Then,
is the tensor
of shape (N1, N2, . . . NL, 2) defined by:
I∈Πi=1L0, Ni
,
for
I,0=fI,
I,1=yI+qaI.
One can map any tensor of shape (N1, N2, . . . , NL2, N1, N2, , NL, 2) to a square matrix B of size 2 N1N2 . . . NL and any vector X of size (N1, N2, . . . , NL, 2) to a vector of the same size by turning a multi-index/to a single index given by
Optionally, call M this mapping. Using the above notations, it follows that:
M()M(
)=M(
)=M(
).
So, since the two polynomials (and thus the tensor , and thus M(™)) have integer coefficients,
M(y) is an element of the lattice (M(
)) generated by M(
).
Finding a short tensory which can be constructed from two elements of R′, f and a, allows/gives a short vector in (M(
))
The argument then proceeds as for the case of polynomials: assuming an algorithm exists to find the secret key f of NTRU2D from the knowledge of the public key h and of q, one could then compute pg=(f·h) mod q and, by suitably choosing the coefficients aI so that no yI,1 is larger than └q/2┘ in absolute value, and assuming the L2 norms of f and pg are sufficiently small, a short vector M(y) in (M(
)) with an overhead at most polynomial in N.
Similarly, recovering a message m from the ciphertext e can be mapped to a close vector problem. To see this, consider the tensors ,
, and
and with the same shape as
above and coefficients given by, for each value of I:
It follows:
=
+
.
So, since the mapping M is linear and preserves multiplication,
M()=M(
)M(
)+M(
).
Given e, from the knowledge of m, one can recover r in polynomial time in N. One can thus, also in polynomial time, get a vector which, if r and m are sufficiently small, is a vector of
(M(
))
close to M (y).
One possible difficulty for the optical implementation of NTRU2D is that coefficients of the product of two multinomials with high degrees can be significantly larger than those of each factor, which can be a problem on low-accuracy devices where the output can take a limited number of different values. We here show two techniques which can be used to mitigate the problem. They both rely on writing each factor as a sum of two multinomials and their product as a sum of products of ‘smaller’ ones. These rewritings can be done in succession several times until the two factors in each term are small enough to be dealt with by the device one wishes to implement multiplication on. The results can then be combined by a higher-accuracy device using bit- or register-shifting and additions
Let n∈*, q∈
\{0,1} and let R be either R0≡
q[X1, X2, . . . , Xn] or R0/
M1, M2, . . . , ML
where L∈
* and M1, M2, . . . ML∈R0.
Denote by · the multiplication in R. All operations are done modulo q.
Let (a, b)∈R2. Let l∈*.
Optionally assume that the coefficients of a and b are (2l)-bits integers. One can then find four multinomials a1, a2, b1, and b2 whose coefficients are l-bits integers such that a=2la1+a2 and b=2lb1+b2.
(One can take the coefficients of a1 (respectively b1) to be the integers given by the l highest bits of those of a (respectively b) and those of a2 (respectively b2) to be the integers given by the l lowest bits of those of a (respectively b).)
Consequently:
a·b=22la1·b1+2l[a1·b2+a2·b1]+a2·b2.
The product of a and b can thus be computed in the following way:
Repeating above procedures n times, the total number of multinomial multiplications is 4n, and the number of bits needed to write each coefficient of the multinomials a and b is divided by 2n.
The number of multiplication needed at each step can be reduced to 3 by noting that:
a
1
·b
2
+a
2
·b
1=(a1−a2)·(b2−b1)+a1·b1+a2·b2.
However, one bit then needs to be reserved for the sign of each coefficient.
A similar technique can be used to reduce the degrees of the multinomials. Unless explicitly stated, optionally use the same notations as above. Let k be an integer between 1 and n, and l a positive integer. We assume that the largest power of Xk in a and b is no larger than 2l. We can then choose four multinomials a1, a2, b1, and b2 with a highest power in Xk no larger than l and such that Xkla1+a2=a and Xklb1+b2=b. Then,
a·b=X
k
2l
a
1
·b
1
+X
k
l[(a1−a2)·(b2−b1)+a1·b1+a2·b2]+a2·b2.
The product of a and b can thus be computed by performing 3 multinomial multiplications (a1·b1, a2·b2, and (a1−a2)·(b2−b1)). This procedure can be iterated to reduce, possibly several times, the maximum power of several or all variables.
The optical implementation may be realized on any one or a combination of the prior art optical systems which are embodied in any of the following patent applications which are owned by Optalysys Limited:
Each one of these documents is incorporated by reference. The prior art system architectures would be configured to operate the method of various embodiments of the invention.
It will be appreciated that it is possible to extend the same algorithms to higher dimensions replacing the 2D arrays by higher-dimensional ones. Different rings of multinomials are also envisaged.
We now describe how to perform a block decomposition for the discrete 2D Fourier transform. One advantage of such a decomposition is to reduce the maximum modulus of the Fourier coefficients of each block, thus potentially improving the accuracy. A typical workflow can be:
For consistency with the notations of the rest of the document, the values of matrix indices start at 0.
Let N1 and N2 be two integers and let A be a matrix of integers with size (N1, N2). We define the Fourier transform à of A as the complex matrix with the same shape with coefficients given by:
Let n1 be a divisor of N1 and n2 a divisor of N2. Optionally define q1≡N1/n1 and q2≡N2/n2.
Optionally, define the matrices A(i,j) of size (q1, q2) for (i;j) in 0, n1−1
×
0, n2−1
by:
Optionally also define their Fourier transforms Ã(i,j) in the following way: For each couple of integers (i,j) where I is between 0 and n1−1 and j is between 0 and n2−1, is the complex matrix Ã(i,j) of size (q1; q2) given by:
Let (u,v)∈0, N1−1
×
0, N2−1
. We have:
Once the discrete Fourier transforms of the ‘blocks’ A(i,j) are computed, the full Fourier transform can thus be obtained after performing N1N2n1n2 multiplications by a complex exponential (n1n2 for each entry). To make this number small, it is desirable to keep n1 and n2 as low as possible.
The main interest of this procedure is that the Fourier coefficients of each ‘block’ are typically smaller than those of Ã. Indeed, if the absolute value of the coefficients of A is bounded from above by some positive number amax, those of the Fourier transform of each block are bounded from above by N1N2a/(n1n2), versus aN1N2 for those of Ã. A device which can reach an acceptable accuracy provided the coefficients have an absolute value no larger than some positive number ad will thus be able to compute the Fourier transform of each block provided
The Cooley-Tukey Fast Fourier Transform (FFT) is an algorithm used to compute a discrete Fourier transform with complexity O(NlogN), where N is the number of entries. It is often used to compute one-dimensional Fourier transforms on electronic hardware where the the fundamental operations are scalar additions and multiplications. This embodiment shows how to use it to accelerate the computation of the Fourier transforms of large images using an optical device of the kind referred to any previous section.
Before that, some notations are introduced:
Notice that, if mx, lx, my, and ly are two positive integers such that mxlx=nx and myly=ny, the function OFT can be used to compute a Fourier transform of shape (mx, my) as follows.
Let b be a complex array with shape (mx, my). Define the array a with shape (nx, ny) by, for each (j, k)∈[[1, nx]]×[[1, ny]],
Let {tilde over (b)} be the array obtained from OFT(a) by restricting its first coefficient to [[1, mx]] and the second one to [[1, my]]. For each (j, k)∈[[1, mx]]×[[1, my]],
So, {tilde over (b)} is the Fourier transform of b.
The question dealt with here is: Given a device which can perform the function OFT, how can one reconstruct the function FT? An embodiment presents a solution in three steps:
divide the input (which is an element of ) into dx×dy elements of
, perform OFT on each of them, and recombine the results.
Let A be an element of . For each (j, k)∈[[1, dx]]×[[1, dy]], define the array a(j,k) of shape (nx, ny) by: for each (u, v)∈[[1, nx]]×[[1, ny]], au,v(j,k)=Aj+(u−1)d
This may be rewritten using the smaller arrays just defined as:
Using that exp(c1+c2)=exp(c1)exp(c2) for any two complex numbers c1 and c2, this becomes:
Performing the last two sums is equivalent to computing the optical Fourier transform of the array a(j′,k′). So,
In this equation, the array indices are assumed to be periodic (with period equal to the size of the array in the corresponding direction) to (slightly) simplify the notations, i.e, the indices i and j of the right-most array should be taken modulo nx and ny, respectively. To get the formula without the periodicity condition, simply replace OFT(a(j′,k′))j,k by OFT(a(j′,k′))j%n
This expression can be simplified in the following way. Define the two arrays Ω(x) and Ω(y) with respective shapes Nx by dx and Ny by dy by: for each (j,j′)∈[[1, Nx]]×[[1, dx]] and (k,k′)∈[[1, Ny]]×[[1, dy]],
Then, re-introducing the modulo operator for completeness,
(Notice that this may be seen as performing nxny Fourier transforms with size Nx by Ny, keeping only dx by dy arrays for the input and output.)
Estimate the complexity C of the calculation. Call COFT the complexity of each OFT operation. There are nxny such operations and then dxdy terms to sum for each coefficient. The complexity of the full calculation is thus O((NxNy+COFT)dxdy). In general, COFT will be much smaller than NxNy for large images. Asymptotically, the complexity thus becomes O(NxNydxdy). This is better than the naive Fourier transform approach (which has complexity O(Nx2Ny2)) by a factor nxny.
This result can be further improved by performing the decomposition iteratively several times. Indeed, there is nothing special about the use of the OFT function in the above calculation: we only used that it is a Fourier transform on a subset of the full array. Let us assume, for definiteness, that there exists a positive integer m such that Nx=2mnx and Ny=2mny. Then, the Fourier transform of A can be computed by first separating A into 4 sub-arrays (the number of required recombination operations to reconstruct the full result from their Fourier transforms will be 4NxNy), then each sub-array in 4 smaller array (requiring again 4NxNy recombination operations), . . . After m such subdivisions, perform the 22m optical Fourier transforms on each sub-array of shape (nx,ny) and recombine the results using the above formula iteratively, with the function OFT replaced by the discrete Fourier transform of the small arrays. The total number of operations scales like O(4mNxNy+22mCOFT). It may be rewritten using the total number N=NxNy of coefficients, in the limit where N and nxny are both large, as
Assuming COFT is at most linear in nxny, this gives
which is better than the complexity O(Nlog2N) of the Cooley-Tukey approach for large values of nxny.
Define, for each (j, k)∈[[1, nx]]×[[1, ny]], the array ā(j,k) with shape (dx, dy) by:
∀(j′,k′)∈[[1, dx]]×[[1, dy]], āj′,k′(j,k)=Ωj,j′(x)Ωk,k′(y), OFT(a(j′,k′))j,k′
Then, the above equation becomes:
where denotes the Euclidean division. For each element (qx, qy, rx, ry) of [[0, dx−1]]×[[0, dy−1]]×[[1, nx]]×[[1, ny]], we have:
The array FT(A) can thus be computed by performing nxny Fourier transforms with shape (dx, dy) as follows. For each (rx,ry)∈[[1, nx]]×[[1, ny]], define the array Ā(r
The array Ā(r
All in all, computing the Fourier transform of A can, in a preferred embodiment, thus be performed in three steps:
If there exist a positive integer α such that Nx=nxα and Ny=nyα, this procedure can be iterated to perform the full Fourier transform using the OFT function as a building-block. This function will then be called αnxα−1nyα−1 times in total, and the procedures involves (α−1)NxNy multiplications by a complex exponential. If COFT denotes the complexity of the OFT function and Cx that of the multiplication by a complex exponential, the total complexity C is thus
(The ≈ symbol is used because some re-ordering of coefficients or matrix transpositions may be required depending on the implementation.) For large values of α, this may be simplified as:
Using the above equation
and performing the inverse Fourier transform gives, denoting by FT(1) the one-dimensional Fourier transform along the first axis:
This may be rewritten as:
Summing over km (noting that the sum gives 0 unless k′−k≡0 [dy] since Ny=nydy) gives:
Define, for each (j, k)∈[[1, nx]]×[[1, dy]], the array ā(j,k) with shape (dx,ny) by:
where %0 denotes the standard modulo operator, i.e., if n and m are two integers, n %0m is the positive integer between 0 and m−1 (included) such that n−(n %0m) divides m.
Then, the above equation becomes:
Let us call, for each (j, k)∈[[1, nx]]×[[1, dy]], the array
This gives a way to perform Ny batched one-dimensional Fourier transforms of size Nx from two-dimensional ones.
In particular, choosing Ny=ny (and thus dy=1) and Nx=nx2 (and thus dx=nx), this procedures allows to compute ny 1D Fourier transforms with size nx2 by performing
In total, this algorithm requires 3nx2ny memory accesses, nx2ny complex multiplications, and 2nx 2D Fourier transforms with shape (nx, ny) to compute ny 1D Fourier transforms with size nx2.
One- and two-dimensional Fourier transforms can be combined to produce higher-dimensional ones. For any positive integer D, the (D-dimensional) Fourier transform of a D-dimensional array A can be computed, for instance,
planes with no common non-vanishing vector and, if D is odd, one-dimensional ones in the last direction.
For instance, the three-dimensional Fourier transform of an array with shape (Nx, Ny, Nz) can be performed by doing Nz two-dimensional Fourier transforms with shape (Nx, Ny) followed by NxNy one-dimensional Fourier transforms with size Nz.
[1] Jeffrey Hoffstein, Jill Pipher, and Joseph H. Silverman. NTRU: A new high speed public key cryptosystem. 13 Aug. 1996. preliminary draft.
[2] Jeffrey Hoffstein, Jill Pipher, and Joseph H. Silverman. NTRU: A ring-based public key cryptosystem. In Joe P. Buhler, editor, Algorithmic Number Theory, pages 267-288, Berlin, Heidelberg, 1998. Springer Berlin Heidelberg.
[3] Damien Stehle and Ron Steinfeld. Making NTRUEncrypt and NTRUSign as Secure as Standard Worst-Case Problems over Ideal Lattices. Cryptology ePrint Archive, Report 2013/004, 2013. https://eprint.iacr.org/2013/004.
[4] Daniel Augot, Lejla Batina, Daniel J. Bernstein, Joppe Bos, Johannes Buchmann, Wouter Castryck, Orr Dunkelman, Tim Guneysu, Shay Gueron, Andreas Nuking, Tanja Lange, Mohamed Saied Emam Mohamed, Christian Rechberger, Peter Schwabe, Nicolas Sendrier, Frederik Vercauteren, and Bo-Yin Yang. Post-Quantum Cryptography for Long-Term Security. 7 Sep. 2015.
[5] Daniel J. Bernstein, Chitchanok Chuengsatiansup, Tanja Lange, and Christine van Vredendaal. NTRU Prime: reducing attack surface at low cost. 2018.
[6] Jeffrey Hoffstein, Jill Pipher, and Joseph H. Silverman. NTRU: A public key cryptosystem. 1999.
[7] Ruiqing Dong. Efficient Multiplication Architectures for Truncated Polynomial Ring. PhD thesis, 2016. https://scholar.uwindsor.ca/etd/5814.
[8] Eliane Jaulmes and Antoine Joux. A chosen-ciphertext attack against NTRU. In Mihir Bellare, editor, Advances in Cryptology—CRYPTO 2000, pages 20-35, Berlin, Heidelberg, 2000. Springer Berlin Heidelberg.
[9] Nick Howgrave-Graham, Joseph H. Silverman, Ari Singer, and William Whyte. NAEP: Provable Security in the Presence of Decryption Failures. 2003. wwhyte@ntru.com 12278 received 14 Aug. 2003.
[10] Eiichiro Fujisaki and Tatsuaki Okamoto. Secure Integration of Asymmetric and Symmetric Encryption Schemes. Journal of Cryptology, 26:80-101, 2013.
[11] Jeffrey Hoffstein and Joseph H. Silverman. Protecting ntru against chosen ciphertext and reaction attacks. 2000.
[12] Zhenfei Zhang. A short review of NTRU cryptosystem, 07 2017.
[13] Ali Atici, Lejla Batina, Junfeng Fan, Ingrid Verbauwhede, and S. B. O. Yalgin. Low-cost Implementations of NTRU for pervasive security. pages 79-84, 08 2008.
[14] Jean-Frangois Biasse and Fang Song. Efficient quantum algorithms for computing class groups and solving the principal ideal problem in arbitrary degree number fields. In Proceedings of the Twenty-Seventh Annual ACM-SIAM Symposium on Discrete Algorithms, SODA '16, page 893-902, USA, 2016. Society for Industrial and Applied Mathematics.
[15] Ronald Cramer, Leo Ducas, and Benjamin Wesolowski. Short stickelberger class relations and application to Ideal-SVP. Cryptology ePrint Archive, Report 2016/885, 2016. https://eprint.iacr.org/2016/885.
[16] Philip Hirschhorn, Jeffrey Hoffstein, Nick Howgrave-Graham, and William Whyte. Choosing NTRUEncrypt parameters in light of combined lattice reduction and MITM approaches. volume 5536, pages 437-455, 06 2009.
Number | Date | Country | Kind |
---|---|---|---|
2011415.3 | Jul 2020 | GB | national |
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/GB2021/051897 | 7/22/2021 | WO |