Postquantum Cryptography 2008
Postquantum Cryptography 2008
Editorial Board
David Hutchison
Lancaster University, UK
Takeo Kanade
Carnegie Mellon University, Pittsburgh, PA, USA
Josef Kittler
University of Surrey, Guildford, UK
Jon M. Kleinberg
Cornell University, Ithaca, NY, USA
Alfred Kobsa
University of California, Irvine, CA, USA
Friedemann Mattern
ETH Zurich, Switzerland
John C. Mitchell
Stanford University, CA, USA
Moni Naor
Weizmann Institute of Science, Rehovot, Israel
Oscar Nierstrasz
University of Bern, Switzerland
C. Pandu Rangan
Indian Institute of Technology, Madras, India
Bernhard Steffen
University of Dortmund, Germany
Madhu Sudan
Massachusetts Institute of Technology, MA, USA
Demetri Terzopoulos
University of California, Los Angeles, CA, USA
Doug Tygar
University of California, Berkeley, CA, USA
Gerhard Weikum
Max-Planck Institute of Computer Science, Saarbruecken, Germany
Johannes Buchmann Jintai Ding (Eds.)
Post-Quantum
Cryptography
13
Volume Editors
Johannes Buchmann
Technische Universität Darmstadt
Fachbereich Informatik
Hochschulstraße 10, 64289 Darmstadt, Germany
E-mail: buchmann@[Link]
Jintai Ding
The University of Cincinnati
Department of Mathematical Sciences
P.O. Box 210025, Cincinnati, OH 45221-0025, USA
E-mail: [Link]@[Link]
ISSN 0302-9743
ISBN-10 3-540-88402-5 Springer Berlin Heidelberg New York
ISBN-13 978-3-540-88402-6 Springer Berlin Heidelberg New York
This work is subject to copyright. All rights are reserved, whether the whole or part of the material is
concerned, specifically the rights of translation, reprinting, re-use of illustrations, recitation, broadcasting,
reproduction on microfilms or in any other way, and storage in data banks. Duplication of this publication
or parts thereof is permitted only under the provisions of the German Copyright Law of September 9, 1965,
in its current version, and permission for use must always be obtained from Springer. Violations are liable
to prosecution under the German Copyright Law.
Springer is a part of Springer Science+Business Media
[Link]
© Springer-Verlag Berlin Heidelberg 2008
Printed in Germany
Typesetting: Camera-ready by author, data conversion by Scientific Publishing Services, Chennai, India
Printed on acid-free paper SPIN: 12538829 06/3180 543210
Preface
Executive Committee
Program Chairs Johannes Buchmann (Technical University of
Darmstadt)
Jintai Ding (University of Cincinnati)
General Chair Timothy Hodges (University of Cincinnati)
Local Committee Timothy Hodges (University of Cincinnati)
Jintai Ding (University of Cincinnati)
Dieter Schmidt (University of Cincinnati)
Program Committee
Referees
G. Albert J. Ding W. Schindler
K. Akiyama B. Feng N. Sendrier
R. Avanzi R. Fujita A. Silverberg
J. Baena P. Gaborit M. Stam
D. Bernstein M. Gotaishi M. Szydlo
J. Buchmann L. Goubin K. Tanaka
D. Cabarcas T. Helleseth S. Tsujii
C. Clough T. Lange T. Walther
C. Crepeau X. Nie C. Xing
A. Diene C. Paar B. Yang
C. Ding L. Salvail
VIII Organization
Sponsors
The Taft Research Center at the University of Cincinnati
Department of Mathematical Sciences, University of Cincinnati
FlexSecure
R
GmbH, Darmstadt, Germany
Table of Contents
1 Introduction
In 1978, McEliece published a work where he proposed to use the theory of
error correcting codes for confidentiality purposes. More precisely, he designed
an asymmetric encryption algorithm whose principle may be sum up as follows:
Alice applies a secret encoding mecanisms to a message and add to it a large
number of errors, that can only be corrected by Bob who has information about
the secret encoding mechanisms. The zero-knowledge authentication scheme pro-
posed by Stern in [24] is based on a well-known error-correcting codes problem
usually referred as the Syndrome Decoding Problem (SD in short). It is therefore
considered as a good alternative to the numerous authentication schemes whose
security relies on number theory problems, like the factorization and the discrete
logarithm problems.
The concept of ring signature was introduced by Rivest, Shamir and Tau-
man [20] (called RST in the following). A ring signature is considered to be
a simplified group signature without group managers. Ring signatures are re-
lated, but incomparable, to the notion of group signatures in [8]. On one hand,
group signatures have the additional feature that the anonymity of a signer can
be revoked (i.e. the signer can be traced) by a designated group manager, on
the other hand, ring signatures allow greater flexibility: no centralized group
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 1–16, 2008.
c Springer-Verlag Berlin Heidelberg 2008
2 C. Aguilar Melchor, P.-L. Cayrel, and P. Gaborit
manager or coordination among the various users is required (indeed, users may
be unaware of each other at the time they generate their public keys). The orig-
inal motivation was to allow secrets to be leaked anonymously. For example, a
high-ranking government official can sign information with respect to the ring of
all similarly high-ranking officials, the information can then be verified as coming
from someone reputable without exposing the actual signer.
Bresson et al. [5] extended the ring signature scheme into a threshold ring sig-
nature scheme using the concept of partitioning and combining functions. Assume
that t users want to leak some secret information, so that any verifier will be con-
vinced that t users among a select group held for its validity. Simply constructing t
ring signatures clearly does not prove that the message has been signed by differ-
ent signers. A threshold ring signature scheme effectively proves that a minimum
number of users of a certain group must have actually collaborated to produce the
signature, while hiding the precise membership of the subgroup (for example the
ring of public keys of all members of the President’s Cabinet).
In [5], the size of the signature grows with the number of users N and the
number of signers t. More precisely, the size of such t-out-of-N signature is
: 2O(t) log2 N × (tl + N l) computations in the easy direction where l is the
security parameter.
Later, Liu et al. [15] proposed another threshold ring signature based on
Shamir’s secret sharing scheme. Their scheme is separable, with a signature
length linear in N but a complexity in O(N 2 ) for t ≈ N/2 (the cost of secret
sharing scheme). The Mesh signature of [4] can also be used in that case: the
signature length is also linear in N but the verification is in N t bilinear pairings
verifications.
A variation for ring signature was introduced in [26], where the author in-
troduced the notion of linkable ring signature by which a signer can sign only
once being anonymous, since a verifier can link a second signature signed by
the same signer. Although this property may have interesting applications (in
particular for e-vote) it does not provide full anonymity (in the sense that it can-
not be repeated). Later their scheme was extended to threshold ring signature
with a complexity in O(N ), but again, only a linkable ring signature which does
not correspond to original researched feature of [20] and [5], a fully anonymous
scheme.
It was remarked in [12] that this problem could also be used with Stern’s
scheme, the proof works exactly the same. Notice that the practical difficulty of
both SD and MD problems are the same: the difficulty of finding a word of small
weight in a random code. The associated intractable assumptions associated to
these problems are denoted by SD assumption and MD assumption, see [25]
for a precise formal definition of the SD assumption related to the SD problem.
where h(a|b) denotes the hash of the concatenation of the sequences a and b.
2. [Challenge Step] V sends b ∈ {0, 1, 2} to L.
3. [Answer Step] Three possibilities :
– if b = 0 : L reveals y and σ.
– if b = 1 : L reveals (y ⊕ s) and σ.
– if b = 2 : L reveals σ(y) and σ(s).
4. [Verification Step] Three possibilities :
– if b = 0 : V verifies that c1 , c2 have been honestly calculated.
– if b = 1 : V verifies that c1 , c3 have been honestly calculated.
– if b = 2 : V verifies that c2 , c3 have been honestly calculated, and that the
weight of σ(s) is ω.
5. Iterate the steps 1,2,3,4 until the expected security level is reached.
Remark 1. During the fourth Step, when b equals 1, it can be noticed that Hy t
derives directly from H(y ⊕ s)t since we have:
The only drawback of this point of view is that it relates the secret key with the
matrix H but in our case we will be able to take advantage of that.
Fig. 2. Threshold ring signature scheme in the case where the t signers are P1 , · · · , Pt
and the leader L = P1 , for a group of N members
8 C. Aguilar Melchor, P.-L. Cayrel, and P. Gaborit
signers among N (see Fig 2 ), proves (by a slightly modified Stern’s scheme - one
adds a condition on the form of the permutation) to the verifier V that he knows
a codeword s of weight tω with a particular structure:s has a null syndrome for
H and a special form on its N blocks of length n: each block of length has
weight 0 or ω. In fact this particular type of word can only be obtained by a
cooperation processus between t members of the ring. Eventually the complexity
is hence the cost of N times the cost of a Stern authentication for a single prover
(the multiplication factor obtained on the length of the matrix H used in the
protocol) and this for any value of t.
Besides the combination of two Stern protocols (one done individually by each
signer Pi with the leader, and one slightly modified done by the leader with the
verifier), our scheme relies on the three following main ideas:
1. The master public key H is obtained as the direct sum of all the public
matrices Hi of each of the N users.
2. Indistinguashability among the members of the ring is obtained first, by
taking a common syndrome value for all the members of the ring: the null syn-
drome, and second, by taking secret keys si with the same weight ω (public
value) associated to public matrices Hi .
3. Permutation constraint: a constraint is added in Stern’s scheme on the type
of permutation used: instead of using a permutation of size N n we use a n-block
permutation on N blocks, which guarantees that the prover knows a word with
a special structure, which can only be obtained by the interaction of t signers.
4.2 Setup
The Setup algorithm is run to obtain the values of the parameters l, n, k, t, w. l
is the security parameter, n and n − k the matrix parameters, ω the weight of
the secret key si , t the number of signers. This algorithm also creates a public
database pk1 , , pkN , (here matrices Hi ). remark that parameters:n, k and ω are
fixed once for all, and that any new user knowing these public parameters can
join the ring. The parameter t has just to be precised at the beginning of the
protocol.
The matrices Hi are constructed in the following way: choose si a random
vector of weight ω, generate k − 1 random vectors and consider the code Ci
obtained by these k words (the operation can be reiterated until the dimension
is exactly k). The matrix Hi is then a (n − k) × n generator matrix of the dual
code of Ci . Remark that this construction lead to a rather large public matrix
Hi , we will consider in Section 7, an intersting variation of the construction.
4.3 Make-GPK
Each user owns a (n − k) × n-matrix Hi (public) and a n-vector si (secret) of
small weight ω (public) such that
Hi sti = 0.
A New Efficient Threshold Ring Signature Scheme Based on Coding Theory 9
1. [Commitment Step]
– Each of the signers chooses yi ∈ Fn 2 randomly and a random permutation σi of
{1, 2, . . . , n} and sends to L the commitments c1,i , c2,i and c3,i such that :
c1,i = h(σi |Hi yit ); c2,i = h(σi (yi )); c3,i = h(σi (yi ⊕ si ))
where h(a1 | · · · |aj ) denotes the hash of the concatenation of the sequence formed by
a1 , · · · , a j .
– L chooses N − t random yi ∈ Fn and N − t random permutations σi of {1, 2, . . . , n}
– L fixes the secret si of the N − t missing users at 0 and computes the N − t
corresponding commitments by choosing random yi and σi (t + 1 ≤ i ≤ N ).
– L chooses a random constant n-block permutation Σ on N blocks {1, · · · , N } in
order to obtain the master commitments:
– L sends C1 , C2 and C3 to V .
2. [Challenge Step] V sends a challenge b ∈ {0, 1, 2} to L which sends b to the t signers.
3. [Answer Step] Let Pi be one of the t signers. The first part of the step is between each
signer and L.
– Three possibilities :
• if b = 0 : Pi reveals yi and σi .
• if b = 1 : Pi reveals (yi ⊕ si ) (denoted by (y ⊕ s)i ) and σi .
• if b = 2 : Pi reveals σi (yi ) (denoted by (σ(y))i ) and σi (si ) (denoted by (σ(s))i ).
– L simulates the N − t others Stern’s protocol with si = 0 and t + 1 ≤ i ≤ N .
– L computes the answer for V (and sends it) :
• if b = 0 : L constructs y = (y1 , · · · , yN ) and Π = Σ ◦ σ (for σ = (σ1 , · · · , σN ))
and reveals y and Π.
• if b = 1 : L constructs y ⊕ s = ((y ⊕ s)1 , · · · , (y ⊕ s)N ) and reveals y ⊕ s and Π.
• if b = 2 : L constructs Π(y) and Π(s) reveals them.
4. [Verification Step] Three possibilities :
– if b = 0 : V verifies that Π(s) is a n-block permutation and that C1 , C2 have been
honestly calculated.
– if b = 1 : V verifies that Π(s) is a n-block permutation and that C1 , C3 have been
honestly calculated.
– if b = 2 : V verifies that C2 , C3 have been honestly calculated, and that the weight
of Π(s) is tω and that Π(s) is formed of N blocks of length n and of weight ω or 0.
5. Iterate the steps 1,2,3,4 until the expected security level is reached.
Remark: In order to simplify the description of the protocol (and to avoid double
indexes), we consider in the following that the t signers correspond to the first t
matrices Hi (1 ≤ i ≤ t) (although more generally their order can be considered
random in {1, .., N } since the order depends of the order of the N matrices sent
by the leader.
10 C. Aguilar Melchor, P.-L. Cayrel, and P. Gaborit
5 Security
5.1 Our Security Model
The security of our protocol relies on two notions of unforgeability and anonymity
secure under the Mininum Distance problem assumption in the random oracle
model.
To prove the first notion we prove that our protocol is an Honest-Verifier Zero-
Knowledge (HZVZK) Proof of Knowledge. It has been proven in [11] that every
HVZK protocol can be turned into a signature scheme by setting the challenge
to the hash value of the comitment together with the message to be signed. Such
a scheme has been proven secure against existential forgery under adaptatively
chosen message attack in the random oracle model in [19].
The second notion of anonymity for our scheme in a threshold context is
defined as follows:
Definition 5.1 (Threshold ring signature anonymity). Let R = {Rk (·, ·)}
be a family of threshold ring signature schemes.
We note SIG ← S(G, M, Rk ) a random choice among the signatures of a t
user group G concerning a message M using the ring signature scheme Rk .
A New Efficient Threshold Ring Signature Scheme Based on Coding Theory 11
R is said to be anonymous if for any c > 0, there is a K such that for any
k > K, any two different subgroups G1 , G2 of t users, any message M and any
polynomial-size probabilistic circuit family C = {Ck (·, ·)},
G being randomly chosen among {G1 , G2 }, and P(k) being the set of all the
public information about the ring signature scheme.
Remark. It is also not possible to have information leaked between signers during
the protocol since each signer only gives information to L (for instance) as in a
regular Stern’s scheme which is zero-knowledge.
Now we consider anonymity of our protocol, the idea of the proof is that if
an adversary has the possibility to get more information on who is a signer
among the N potential signers or who is not, it would mean in our case that the
12 C. Aguilar Melchor, P.-L. Cayrel, and P. Gaborit
adversary is able to know with a better probability than 2/3 that a block si of
s = (s1 , · · · , sN ) of size n among the N such blocks associated to the created
common secret s is completely zero or not. But since we saw that our protocol
was zero-knowledge based on a light modification of the Stern protocol, it would
mean that the adversary is able to get information on the secret s during the
interaction between L and V , which is not possible since the protocol is zero-
knowledge. Formally we obtain:
Proof. Suppose that for a given M , a given c > 0 and two given subgroups G1 , G2
of t users there is a family of circuits C = {Ck (·, ·)} such that for any K there
is a k > K such that
rather than pure random matrice for such matrices. A double circulant matrix
is a matrix of the form Hi = (I|C) for C a random n/2 × n/2 cyclic matrix
and I the identity matrix. Following this idea one can construct the matrices Hi
as follows: consider si = (a|b) where a and b are random vectors of length n/2
and weight ≈ ω/2, then consider the matrix (A|B) obtained for A and B square
(n/2 × n/2) matrices obtained by the n/2 cyclic shifts of a and b (each row of A
is a shift of the previous row, begining with first row a or b).
Now consider the code Gi generated by the matrix (A|B), the matrix Hi can
then be taken as Hi = (I|C) such that Hi is a dual matrix of Gi and C is cyclic
since A and B are cyclic, and hence can be described with only its first row). It
is explained in [12] that this construction does not decrease the difficulty of the
decoding but clearly decrease dramatically the size of the description of Hi : n/2
bits against n2 /2.
It is then possible to define a new problem:
It is not known whether this problem is NP-complete or not, but the problem
is probably as hard as the M D problem, and on practical point of view (see [12]
for details) the practical security is almost the same for best known attack that
the MD problem. Practicly the author of [12] propose n = 347.
Now all the proof of security we considered in this paper can also be adpated
to the MD-DC problem, since for the generalized Stern protocol we introduced
we can take any kind of Hi with the same type of problem: knowing a small
weight vector associated to Hi (in fact only the problem assumption changes).
8 Conclusion
In this paper we presented a new (fully anonymous) t-out-of-N threshold ring
signature scheme based on coding theory. Our protocol is a very natural general-
ization ot the Stern authentication scheme and our proof is based on the original
proof of Stern. We showed that the notion of weight of vector particularly went
well in the context of ring signature since the notion of ad hoc group corresponds
well to the notion of direct sum of generator matrices and is compatible with
the notion of sum of vector of small weight. Eventually we obtain a fully anony-
mous protocol based on a proof of knowledge in the random oracle model. Our
protocol is the first non-generic protocol based on coding theory and (as usual
for code based protocol) is very fast compared to other number theory based
protocols.
Moreover the protocol we described can also be easily generalized to the case of
general access scenario. Eventually the fact that our construction is not based on
number theory but on coding theory may represent an interesting alternative.
We hope this work will enhance the potential of coding theory in public key
cryptography.
References
1. Abe, M., Ohkubo, M., Suzuki, K.: 1-out-of-N signatures from a variety of keys. In:
Zheng, Y. (ed.) ASIACRYPT 2002. LNCS, vol. 2501. Springer, Heidelberg (2002)
2. Bender, A., Katz, J., Morselli, R.: Ring Signatures: Stronger Definitions, and Con-
structions Without Random Oracles. In: Halevi, S., Rabin, T. (eds.) TCC 2006.
LNCS, vol. 3876, pp. 60–79. Springer, Heidelberg (2006)
3. Berlekamp, E., McEliece, R., van Tilborg, H.: On the inherent intractability of cer-
tain coding problems. IEEE Transactions on Information Theory IT-24(3) (1978)
A New Efficient Threshold Ring Signature Scheme Based on Coding Theory 15
4. Boyen, X.: Mesh Signatures. In: Naor, M. (ed.) EUROCRYPT 2007. LNCS,
vol. 4515, pp. 210–227. Springer, Heidelberg (2007)
5. Bresson, E., Stern, J., Szydlo, M.: Threshold ring signatures and applications to
ad-hoc groups. In: Yung, M. (ed.) CRYPTO 2002. LNCS, vol. 2442. Springer,
Heidelberg (2002)
6. Canteaut, A., Chabaud, F.: A new algorithm for finding minimum-weight words
in a linear code: application to primitive narrow-sense BCH codes of length 511.
IEEE Transactions on Information Theory IT-44, 367–378 (1988)
7. Chandran, N., Groth, J., Sahai, A.: Ring signatures of sub-linear size without
random oracles. In: Arge, L., Cachin, C., Jurdziński, T., Tarlecki, A. (eds.) ICALP
2007. LNCS, vol. 4596, pp. 423–434. Springer, Heidelberg (2007)
8. Chaum, D., van Heyst, E.: Group signatures. In: Davies, D.W. (ed.) EUROCRYPT
1991. LNCS, vol. 547, pp. 257–265. Springer, Heidelberg (1991)
9. Courtois, N., Finiasz, M., Sendrier, N.: How to achieve a MCEliece based digital
signature scheme. In: Boyd, C. (ed.) ASIACRYPT 2001. LNCS, vol. 2248. Springer,
Heidelberg (2001)
10. Dodis, Y., Kiayias, A., Nicolosi, A., Shoup, V.: Anonymous identification in ad-
hoc groups. In: Cachin, C., Camenisch, J.L. (eds.) EUROCRYPT 2004. LNCS,
vol. 3027. Springer, Heidelberg (2004)
11. Fiat, A., Shamir, A.: How to Prove Yourself: Practical Solutions to Identification
and Signature Problems. In: Odlyzko, A.M. (ed.) CRYPTO 1986. LNCS, vol. 263,
pp. 186–194. Springer, Heidelberg (1987)
12. Gaborit, P., Girault, M.: Lightweight code-based authentication and signature ISIT
2007 (2007)
13. Herranz, J., Saez, G.: Forking lemmas for ring signature schemes. In: Johansson,
T., Maitra, S. (eds.) INDOCRYPT 2003. LNCS, vol. 2904, pp. 266–279. Springer,
Heidelberg (2003)
14. Kuwakado, H., Tanaka, H.: Threshold Ring Signature Scheme Based on the Curve.
Transactions of Information Processing Society of Japan 44(8), 2146–2154 (2003)
15. Liu, J.K., Wei, V.K., Wong, D.S.: A Separable Threshold Ring Signature Scheme.
In: Lim, J.-I., Lee, D.-H. (eds.) ICISC 2003. LNCS, vol. 2971, pp. 352–369. Springer,
Heidelberg (2004)
16. MacWilliams, F.J., Sloane, N.J.A.: The Theory of Error Correcting Codes. North-
Holland, Amsterdam (1977)
17. Naor, M.: Deniable Ring Authentication. In: Yung, M. (ed.) CRYPTO 2002. LNCS,
vol. 2442, pp. 481–498. Springer, Heidelberg (2002)
18. Pierce, J.N.: Limit distributions of the minimum distance of random linear codes.
IEEE Trans. Inf. theory IT-13, 595–599 (1967)
19. Pointcheval, D., Stern, J.: Security proofs for signature schemes. In: Maurer, U.M.
(ed.) EUROCRYPT 1996. LNCS, vol. 1070, pp. 387–398. Springer, Heidelberg
(1996)
20. Rivest, R.L., Shamir, A., Tauman, Y.: How to leak a secret. In: Boyd, C. (ed.)
ASIACRYPT 2001. LNCS, vol. 2248, pp. 552–565. Springer, Heidelberg (2001)
21. Sendrier, N.: Cryptosystèmes à clé publique basés sur les codes correcteurs
d’erreurs, Mémoire d’habilitation, Inria 2002 (2002),
[Link]
22. Shacham, H., Waters, B.: Efficient Ring Signatures without Random Oracles. In:
Okamoto, T., Wang, X. (eds.) PKC 2007. LNCS, vol. 4450, pp. 166–180. Springer,
Heidelberg (2007)
23. Shamir, A.: How to share a secret. Com. of the ACM 22(11), 612–613 (1979)
16 C. Aguilar Melchor, P.-L. Cayrel, and P. Gaborit
24. Stern, J.: A new identification scheme based on syndrome decoding. In: Stinson,
D.R. (ed.) CRYPTO 1993. LNCS, vol. 773. Springer, Heidelberg (1994)
25. Stern, J.: A new paradigm for public key identification. IEEE Transactions on
Information THeory 42(6), 2757–2768 (1996),
[Link]
26. Tsang, P.P., Wei, V.K., Chan, T.K., Au, M.H., Liu, J.K., Wong, D.S.: Separa-
ble Linkable Threshold Ring Signatures. In: Canteaut, A., Viswanathan, K. (eds.)
INDOCRYPT 2004. LNCS, vol. 3348, pp. 384–398. Springer, Heidelberg (2004)
27. Vardy, A.: The intractability of computing the minimum distance of a code. IEEE
Transactions on Information Theory 43(6), 1757–1766 (1997)
28. Véron, P.: A fast identification scheme. In: Proceedings of IEEE International Sym-
posium on Information Theory 1995, Whistler, Canada (Septembre 1995)
29. Wong, D.S., Fung, K., Liu, J.K., Wei, V.K.: On the RSCode Construction of Ring
Signature Schemes and a Threshold Setting of RST. In: Qing, S., Gollmann, D.,
Zhou, J. (eds.) ICICS 2003. LNCS, vol. 2836, pp. 34–46. Springer, Heidelberg (2003)
30. Xu, J., Zhang, Z., Feng, D.: A ring signature scheme using bilinear pairings. In:
Lim, C.H., Yung, M. (eds.) WISA 2004. LNCS, vol. 3325. Springer, Heidelberg
(2005)
31. Zhang, F., Kim, K.: ID-Based Blind Signature and Ring Signature from Pairings.
In: Zheng, Y. (ed.) ASIACRYPT 2002. LNCS, vol. 2501. Springer, Heidelberg
(2002)
32. Zheng, D., Li, X., Chen, K.: Code-based Ring Signature Scheme. International
Journal of Network Security 5(2), 154–157 (2007),
[Link]
[Link]
Square-Vinegar Signature Scheme
1 Introduction
Multivariate public-key cryptosystems (MPKCs) stand among the systems
thought to have the potential to resist quantum computer attacks [4]. This is
because their main security assumption is based on the problem of solving a
system of multivariate polynomial equations, a problem which is still as hard for
a quantum computer to solve as a conventional computer [12,22].
The area of multivariate public-key cryptography essentially began in 1988
with an encryption scheme proposed by Matsumoto and Imai [17]. This system
has since been broken [19], but has inspired many new encryption and signature
schemes. One of these is HFE (Hidden Field Equations), proposed in 1996 by
Patarin [20].
An HFE scheme could still be secure, but the parameters required would
make it so inefficient as to be practically unusable. Many variants of HFE have
been proposed and analyzed, in particular one called HFEv− , a signature scheme
which combines HFE with another system called Oil-Vinegar and also uses the
“−” construction. More about HFEv− in Sect. 2.2. A recent proposal is Quartz,
a signature scheme with HFEv− at its core. Quartz-7m, with slightly differ-
ent parameter choices, is believed secure. These schemes have enticingly short
signatures.
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 17–30, 2008.
c Springer-Verlag Berlin Heidelberg 2008
18 J. Baena, C. Clough, and J. Ding
However, the problem with HFE-based signature schemes is that until now,
they were quite slow. In this paper, we study how some simple but very surprising
changes to existing ideas can yield a system with much faster signing and key
generation at the same security levels as other HFE-based signature schemes. In
particular, we set out to make an HFEv− system with similarly short signatures
and greater efficiency in the form of fast signing times.
This paper is organized as follows. In Sect. 2, we discuss relevant background
on HFE and Quartz systems. In Sect. 3, we introduce the new variant Square-
Vinegar, providing a theoretical overview along with explicit constructions and
experimental data. In Sect. 4, known attacks are addressed and more experi-
mental results presented. Additional data can be found in the appendix.
where the coefficients aij , bi , c are randomly chosen from K and D is a fixed
positive integer. A map of this form is often referred to as an HFE map.
By composing F with ϕ and its inverse we obtain the set of n quadratic
multivariate polynomials F̃ = ϕ ◦ F ◦ ϕ−1 : k n → k n . Then we hide the
structure of this map by means of two invertible affine linear transformations
S, T : k n → k n . The public key is the set of quadratic multivariate polynomials
(g1 , g2 , . . . , gn ) = T ◦ F̃ ◦ S. The private key consists of the map F and the affine
linear transformations S and T .
In such a scheme the most delicate matter is the choice of the total degree
D of F . D cannot be too large since decryption (or signing) involves solving
the equation F (X) = Y for a given Y ∈ K using the Berlekamp algorithm, a
process whose complexity is determined by D. However this total degree cannot
be too small either to avoid algebraic attacks, like the one developed by Kipnis
and Shamir [15] and the Gröbner Bases (GB) Attack [9].
HFEv is a combination of HFE and the Unbalanced Oil & Vinegar scheme
[14,21]. The main idea of HFEv is to add a small number v of new variables,
referred to as the vinegar variables, to HFE. This makes the system somehow
more complicated and changes the structure of the private map. In this case we
replace the map F with a more complicated map G : K × k v → K.
We can combine HFE− and HFEv to obtain the so called HFEv− signature
scheme. In this scheme, r polynomials are kept secret and v additional variables
are introduced.
Quartz is an HFEv− signature scheme with a special choice of the parameters,
which are k = F2 , n = 103, D = 129, r = 3 and v = 4 [24,25]. These parameters
of Quartz have been chosen in order to produce very short signatures: only 128
bits. This makes Quartz specially suitable for very specific applications in which
short signatures are required, like RFID. Quartz was proposed to NESSIE [18],
but it was rejected perhaps due to the fact that its parameters were not chosen
conservatively enough. In 2003 Faugère and Joux stated in [9] that the published
version of Quartz could be broken using Gröbner bases with slightly fewer than
280 computations.
At present time two modified versions of Quartz are thought to be secure,
based on the estimations of [9] on Quartz. The first one, called Quartz-513d, has
parameters k = F2 , n = 103, D = 513, r = 3 and v = 4. The second version,
Quartz-7m, has parameters k = F2 , n = 103, D = 129, r = 7 and v = 0. In
these versions the high degree D makes the signing process very slow. In fact
Quartz-513d was considered impractical for this reason, even as it was proposed.
Xv = (x1 , . . . , xv ) represents the new vinegar variables. More precisely the maps
βi and γ are of the form
βi (Xv ) = ξi,j · xj + νi ,
1≤j≤v
γ(Xv ) = ηj,l · xj xl + σj · xj + τ ,
1≤j<l≤v 1≤j≤v
S −1 (ϕ(X̃), w1 , . . . , wv ) ∈ k n+v .
4 Security Analysis
In this section we will consider known attacks against MPKCs (Gröbner Basis,
Kipnis-Shamir, and Vinegar attacks) and discuss their effectiveness against our
new scheme. This will lead us to suggest parameter values for a viable Square-
Vinegar system.
Before considering the aforementioned attacks in detail, let us mention some
minor attacks. First, there do not yet seem to be any attacks against MPKCs
utilizing knowledge of plaintext-ciphertext (or document-signature) pairs. Sec-
ondly, the recent attack on SFlash [8] does not apply here because that attack
used hidden symmetry and invariants of the SFlash public key to overcome the
omission of certain polynomials from the public key, but our public key does not
have such hidden invariants or symmetry due the presence of the vinegar vari-
ables. Also, the attacks used against perturbed systems such as IPHFE, [6,7], do
not seem directly applicable, especially considering the differences between even
and odd characteristic and internal and external perturbation.
Solving these equations directly, without the use of the internal structure of
the system, is known as the algebraic attack. Currently the most efficient al-
gebraic attacks are the Gröbner basis algorithms F4 [10] and F5 [11]. Another
algorithm called XL has also been widely discussed but F4 is seen to be more ef-
ficient [1], so we focused our energy on studying algebraic attacks via F4 . Among
the best implementations of these algorithms is the F4 function of MAGMA [2],
which represents the state of the art in polynomial solving technology.
In [9], algebraic attacks were used to break HFE. The results in that paper
seem to indicate that for any q, an HFE system with small D can be broken in
such a way. However, this is not the case and their claims only hold up when
working over characteristic 2.
Since the system (4) is underdetermined, we expect to find many solutions for
it. In order to forge a signature for the given document, it suffices to find only one
such solution. So we can guess values for some of the variables yielding a system
with the same number of equations but fewer variables, as was done in [3]. This
speeds up the attack significantly. Therefore we randomly guessed v + r of the
variables and then used the Gröbner basis attack to solve the resulting system
of n − r equations with n − r variables, which is faster to solve than (4).
Based on recent observations about MPKCs over odd characteristic [5], we
believe that the choices q = 13 or q = 31 provide a strong defense against an
algebraic attack via Gröbner bases. The key point in the case of odd character-
istic is that the field equations xqi − xi for i = 1, 2, . . . , n + v, appear to be less
useful to an attacker due to their higher degree. In particular, the efficiency of
the Gröbner basis attack seems to rely on small characteristic. It is stated in [5]
that this stems from the fact that characteristic 2 field equations x2i − xi = 0
help to keep the degrees of the polynomials used in the Gröbner basis algorithm
low whereas, for example, x13 i − xi = 0 or xi − xi = 0 are much less useful
31
Fig. 1. Running time and required memory under GB Attack for q = 31, v = 4, r = 3
and D = 2. No field equations are used in the attack.
Fig. 2. Running time and required memory under GB attack for q = 31, v = 4, r = 3
and D = 2. Including the field equations in the attack.
time required by the GB attack to forge a signature for large values of q, as seen
in Fig. 3. This also justifies the choices of q = 13 and q = 31, since increasing q
will not augment the security of the system.
We also constructed random polynomial equations of the same dimensions
(same q, n, v and r) and found that the time needed to solve such random
equations using Gröbner bases is essentially the same as is needed to break
Square-Vinegar with our choices of parameters. Table 4 shows these times for
different n.
As observed on the graphs, we could only obtain data for n up to 14, due to
memory limitations (any request above 1.2 GB would be immediately rejected
by the computer that we used). However, even among the data that we were able
to collect, we observed that as n increases, the maximum degree of polynomial
used by F4 also increases. Larger scale experiments are being conducted to study
systematically how fast this degree increases as n increases; these results will be
presented in a future paper.
26 J. Baena, C. Clough, and J. Ding
From the information gathered with our experiments it appears that under our
choices of parameters, F4 is no more efficient in solving the public key equations
(4) of a Square-Vinegar scheme than a system of random equations.
5 Conclusion
In this paper we analyzed a new HFEv− system that seems to have great po-
tential. We showed that with relatively short signatures, Square-Vinegar can be
used to sign documents very fast. This was accomplished by working in an odd
characteristic and using a low-degree polynomial where previously a very high
degree was required. We performed computer experiments to test the security of
Square-Vinegar. We used algebraic attacks against smaller-scale systems to de-
termine proper q, D, n, r, and v values for plausible schemes. We also examined
other MPKC attacks and gave reasons why Square-Vinegar should be resistant
to them.
In the future we would like to have a better understanding of the apparent
benefit of odd characteristic. We will also, as mentioned above, study the re-
lationship between n and the polynomials used in GB attacks. In addition, we
will further study the effectiveness of attacks similar to those against perturbed
systems.
References
1. Ars, G., Faugère, J.-C., Imai, H., Kawazoe, M., Sugita, M.: Comparison Between
XL and Gröbner Basis Algorithms. In: Lee, P.J. (ed.) ASIACRYPT 2004. LNCS,
vol. 3329, pp. 338–353. Springer, Heidelberg (2004)
2. Computational Algebra Group, University of Sydney. The MAGMA computational
algebra system for algebra, number theory and geometry (2005),
[Link]
3. Courtois, N., Daum, M., Felke, P.: On the Security of HFE, HFEv- and Quartz. In:
Desmedt, Y.G. (ed.) PKC 2003. LNCS, vol. 2567, pp. 337–350. Springer, Heidelberg
(2002)
1
On an Intel(R) Pentium(R) D CPU 3.00 GHz.
28 J. Baena, C. Clough, and J. Ding
4. Ding, J., Gower, J.E., Schmidt, D.: Multivariate Public Key Cryptosystems.
Springer, Heidelberg (2006)
5. Ding, J., Schmidt, D., Werner, F.: Algebraic Attack on HFE Revisited. In: The
11th Information Security Conference, Taipei, Taiwan (September 2008)
6. Ding, J., Schmidt, D.: Cryptanalysis of HFEv and the Internal Perturbation of HFE
cryptosystems. In: Vaudenay, S. (ed.) PKC 2005. LNCS, vol. 3386, pp. 288–301.
Springer, Heidelberg (2005)
7. Dubois, V., Granboulan, L., Stern, J.: Cryptanalysis of HFE with Internal Pertur-
bation. In: Okamoto, T., Wang, X. (eds.) PKC 2007. LNCS, vol. 4450, pp. 249–265.
Springer, Heidelberg (2007)
8. Dubois, V., Fouque, P.-A., Shamir, A., Stern, J.: Practical Cryptanalysis of
SFLASH. In: Menezes, A. (ed.) CRYPTO 2007. LNCS, vol. 4622, pp. 1–12.
Springer, Heidelberg (2007)
9. Faugère, J.-C., Joux, A.: Algebraic cryptanalysis of hidden field equation (HFE)
cryptosystems using Gröbner bases. In: Boneh, D. (ed.) CRYPTO 2003. LNCS,
vol. 2729, pp. 44–60. Springer, Heidelberg (2003)
10. Faugère, J.-C.: A new efficient algorithm for computing Gröbner bases (F4 ). Journal
of Pure and Applied Algebra 139, 61–88 (1999)
11. Faugère, J.-C.: A new efficient algorithm for computing Gröbner bases without
reduction to zero (F5 ). In: International Symposium on Symbolic and Algebraic
Computation — ISSAC 2002, pp. 75–83. ACM Press, New York (2002)
12. Gray, M.R., Johnson, D.S.: Computers and Intractability – A guide to the Theory
of NP-Completeness. W.H. Freeman and Company, New York (1979)
13. Jiang, X., Ding, J., Hu, L.: Kipnis-Shamir’s Attack on HFE Revisited. Cryptology
ePrint Archive, Report 2007/203, [Link]
14. Kipnis, A., Patarin, J., Goubin, L.: Unbalanced oil and vinegar signature schemes.
In: Stern, J. (ed.) EUROCRYPT 1999. LNCS, vol. 1592, pp. 206–222. Springer,
Heidelberg (1999)
15. Kipnis, A., Shamir, A.: Cryptanalysis of the HFE public key cryptosystem by
relinearization. In: Wiener, M. (ed.) CRYPTO 1999. LNCS, vol. 1666, pp. 19–30.
Springer, Heidelberg (1999)
16. Kipnis, A., Shamir, A.: Cryptanalysis of the Oil and Vinegar Signature Scheme.
In: Krawczyk, H. (ed.) CRYPTO 1998. LNCS, vol. 1462, pp. 257–267. Springer,
Heidelberg (1998)
17. Matsumoto, T., Imai, H.: Public quadratic polynomial-tuples for efficient signature
verification and message encryption. In: Günther, C.G. (ed.) EUROCRYPT 1988.
LNCS, vol. 330, pp. 419–453. Springer, Heidelberg (1988)
18. NESSIE: New European Schemes for Signatures, Integrity, and Encryption. Infor-
mation Society Technologies Programme of the European Commission (IST-1999-
12324), [Link]
19. Patarin, J.: Cryptanalysis of the Matsumoto and Imai public key scheme of Euro-
crypt 1988. In: Coppersmith, D. (ed.) CRYPTO 1995. LNCS, vol. 963, pp. 248–261.
Springer, Heidelberg (1995)
20. Patarin, J.: Hidden Field Equations (HFE) and Isomorphism of Polynomials (IP):
Two new families of asymmetric algorithms. In: Maurer, U. (ed.) EUROCRYPT
1996. LNCS, vol. 1070, pp. 33–48. Springer, Heidelberg (1996); extended Version,
[Link]
21. Patarin, J.: The Oil and Vinegar Signature Scheme. In: Dagstuhl Workshop on
Cryptography (September 1997)
Square-Vinegar Signature Scheme 29
22. Patarin, J., Goubin, L.: Trapdoor one-way permutations and multivariate polyno-
mials. In: Han, Y., Quing, S. (eds.) ICICS 1997. LNCS, vol. 1334, pp. 356–368.
Springer, Heidelberg (1997); extended Version,
[Link]
∗
23. Patarin, J., Goubin, L., Courtois, N.: C−+ and HM: variations around two schemes
of T. Matsumoto and H. Imai. In: Ohta, K., Pei, D. (eds.) ASIACRYPT 1998.
LNCS, vol. 1514, pp. 35–50. Springer, Heidelberg (1998)
24. Patarin, J., Goubin, L., Courtois, N.: Quartz, 128-bit long digital signatures. In:
Naccache, D. (ed.) CT-RSA 2001. LNCS, vol. 2020, pp. 352–357. Springer, Heidel-
berg (2001)
25. Patarin, J., Goubin, L., Courtois, N.: Quartz, 128-bit long digital signatures. An
updated version of Quartz specification, pp. 357-359,
[Link]
Fig. 4. Running time under GB attack for n = 13, r = 3 and D = 2, for several values
of v. No field equations are used in the attack.
Fig. 5. Running time and required memory under GB attack for q = 13, v = 4, r = 3
and D = 2. No field equations are used in the attack.
30 J. Baena, C. Clough, and J. Ding
Fig. 6. Running time and required remory under GB attack for q = 13, v = 4, r = 3
and D = 2. Including the field equations in the attack.
Attacking and Defending
the McEliece Cryptosystem
1 Introduction
The McEliece cryptosystem was proposed by McEliece in 1978 [10] and the
original version, using Goppa codes, remains unbroken. Quantum computers
do not seem to give any significant improvements in attacking code-based sys-
tems, beyond the generic improvements possible with Grover’s algorithm, and
so the McEliece encryption scheme is one of the interesting candidates for post-
quantum cryptography.
A drawback of the system is the comparably large key size — in order to
hide the well-structured and efficiently decodable Goppa code in the public key,
the full generator matrix of the scrambled code needs to be published. Various
attempts to reduce the key size have used other codes, most notably codes over
Permanent ID of this document: 7868533f20f51f8d769be2aa464647c9. Date of this
document: 2008.08.07. This work has been supported in part by the National Science
Foundation under grant ITR–0716498.
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 31–46, 2008.
c Springer-Verlag Berlin Heidelberg 2008
32 D.J. Bernstein, T. Lange, and C. Peters
larger fields instead of subfield codes; but breaks of variants of the McEliece
system have left essentially only the original system as the strongest candidate.
The fastest known attacks on the original system are based on information set
decoding as implemented by Canteaut and Chabaud [4] and analyzed in greater
detail by Canteaut and Sendrier [5].
In this paper we reconsider attacks on the McEliece cryptosystem and present
improvements to Stern’s attack [17] (which predates the Canteaut–Chabaud at-
tack) and demonstrate that our new attack outperforms any previous ones. The
result is that an attack on the originally proposed parameters of the McEliece
cryptosystem is feasible on a moderate computer cluster. Already Canteaut and
Sendrier had pointed out that the system does not hold up to current security
standards but no actual attack was done before. We have implemented our new
method and expect results soon.
On the defense side our paper proposes new parameters for the McEliece
cryptosystem, selected from a much wider range of parameters than have been
analyzed before. The codes we suggest are also suitable for the Niederreiter
cryptosystem [11], a variant of the McEliece cryptosystem. The new parameters
are designed to minimize public-key size while achieving 80-bit, 128-bit, or 256-
bit security against known attacks — and in particular our attack. (Of course, by
a similar computation, we can find parameters that minimize costs other than key
size.) These new parameters exploit the ability to choose code lengths that are
not powers of 2. They also exploit a recently introduced list-decoding algorithm
for binary Goppa codes — see [2]; list decoding allows senders to introduce more
errors into ciphertexts, leading to higher security with the same key size, or
alternatively the same security with lower key size.
The matrix H = (QT |In−k ) is then a parity-check matrix for C. There might
not exist a systematic generator matrix for C, but there exists a systematic
generator matrix for an equivalent code obtained by permuting columns of C.
The classical decoding problem is to find the closest codeword x ∈ C to a
given y ∈ Fn2 , assuming that there is a unique closest codeword. Here close
means that the difference has small Hamming weight. Uniqueness is guaranteed
if there exists a codeword x whose distance from y is less than half the minimum
distance of C.
Classical Goppa codes. Fix a finite field F2d , a basis of F2d over F2 , and
a set of n distinct elements α1 , . . . , αn in F2d . Fix an irreducible polynomial
g ∈ F2d [x] of degree t, where 2 ≤ t ≤ (n − 1)/d. Note that, like [15, page 151]
and unlike [10], we do not require n to be as large as 2d .
The Goppa code Γ = Γ (α1 , . . . , αn , g) consists of all elements c = (c1 , . . . , cn )
in Fn2 satisfying
n
ci
=0 in F2d [x]/g.
i=1
x − αi
The dimension of Γ is at least n − td and typically is exactly n − td. For cryp-
tographic applications one assumes that the dimension is exactly n − td. The
td × n matrix ⎛ ⎞
1/g(α1 ) · · · 1/g(αn )
⎜ α1 /g(α1 ) · · · αn /g(αn ) ⎟
⎜ ⎟
H=⎜ .. .. .. ⎟,
⎝ . . . ⎠
1 /g(α1 ) · · · αn /g(αn )
αt−1 t−1
The most effective attack known against the McEliece and Niederreiter cryp-
tosystems is “information-set decoding.” There are actually many variants of
this attack. A simple form of the attack was introduced by McEliece in [10, Sec-
tion III]. Subsequent variants were introduced by Leon in [8], by Lee and Brickell
in [7], by Stern in [17], by van Tilburg in [18], by Canteaut and Chabanne in [3],
by Canteaut and Chabaud in [4], and by Canteaut and Sendrier in [5].
The new attack presented in Section 4 of this paper is most easily understood
as a variant of Stern’s attack. This section reviews Stern’s attack.
How to break McEliece and Niederreiter. Stern actually states an attack
on a different problem, namely the problem of finding a low-weight codeword.
However, as mentioned by Canteaut and Chabaud in [4, page 368], one can
Attacking and Defending the McEliece Cryptosystem 35
decode a linear code — and thus break the McEliece system — by finding a low-
weight codeword in a slightly larger code.
Specifically, if C is a length-n code over F2 , and y ∈ Fn2 has distance w from
a codeword c ∈ C, then y − c is a weight-w element of the code C + {0, y}.
Conversely, if C is a length-n code over F2 with minimum distance larger than
w, then a weight-w element e ∈ C + {0, y} cannot be in C, so it must be in
C + {y}; in other words, y − e is an element of C with distance w from y.
Recall that a McEliece ciphertext y ∈ Fn2 is known to have distance t from
a unique closest codeword c in a code C that has minimum distance at least
2t + 1. The attacker knows the McEliece public key, a generator matrix for C,
and can simply append y to the list of generators to form a generator matrix for
C + {0, y}. The only weight-t codeword in C + {0, y} is y − c; by finding this
codeword the attacker finds c and easily solves for the plaintext.
Similar comments apply if the attacker is given a Niederreiter public key,
i.e., a parity-check matrix for C. By linear algebra the attacker quickly finds a
generator matrix for C; the attacker then proceeds as above. Similar comments
also apply if the attacker is given a Niederreiter ciphertext. By linear algebra the
attacker finds a word that, when multiplied by the parity-check matrix, produces
the specified ciphertext. The bottleneck in all of these attacks is finding the
weight-t codeword in C + {0, y}.
Beware that there is a slight inefficiency in the reduction from the decoding
problem to the problem of finding low-weight codewords: if C has dimension k
and y ∈ / C then C +{0, y} has slightly larger dimension, namely k+1. The user of
the low-weight-codeword algorithm knows that the generator y will participate
in the solution, but does not pass this information to the algorithm. In this paper
we focus on the low-weight-codeword problem for simplicity.
How to find low-weight words. Stern’s attack has two inputs: first, an integer
w ≥ 0; second, an (n − k) × n parity-check matrix H for an [n, k] code over F2 .
Other standard forms of an [n, k] code, such as a k × n generator matrix, are
easily converted to the parity-check form by linear algebra.
Stern randomly selects n − k out of the n columns of H. He selects a random
size- subset Z of those n−k columns; here is an algorithm parameter optimized
later. He partitions the remaining k columns into two sets X and Y by having
each column decide independently and uniformly to join X or to join Y .
Stern then searches, in a way discussed below, for codewords that have exactly
p nonzero bits in X, exactly p nonzero bits in Y , 0 nonzero bits in Z, and exactly
w − 2p nonzero bits in the remaining columns. Here p is another algorithm
parameter optimized later. If there are no such codewords, Stern starts with a
new selection of columns.
The search has three steps. First, Stern applies elementary row operations to
H so that the selected n − k columns become the identity matrix. This fails,
forcing the algorithm to restart, if the original (n − k) × (n − k) submatrix of H
is not invertible. Stern guarantees an invertible submatrix, avoiding the cost of
a restart, by choosing each column adaptively as a result of pivots in previous
columns. (In theory this adaptive choice could bias the choice of (X, Y, Z), as
36 D.J. Bernstein, T. Lange, and C. Peters
Stern points out, but the bias does not seem to have a noticeable effect on
performance.)
Second, now that this (n − k) × (n − k) submatrix of H is the identity matrix,
each of the selected n − k columns corresponds to a unique row, namely the row
where that column has a 1 in the submatrix. In particular, the set Z of columns
corresponds to a set of rows. For every size-p subset A of X, Stern computes
the sum (mod 2) of the columns in A for each of those rows, obtaining an -bit
vector π(A). Similarly, Stern computes π(B) for every size-p subset B of Y .
Third, for each collision π(A) = π(B), Stern computes the sum of the 2p
columns in A ∪ B. This sum is an (n − k)-bit vector. If the sum has weight
w − 2p, Stern obtains 0 by adding the corresponding w − 2p columns in the
(n − k) × (n − k) submatrix. Those w − 2p columns, together with A and B,
form a codeword of weight w.
Forcing more existing pivots. More generally, one can artificially reuse ex-
actly n − k − c column selections, and select the remaining c new columns ran-
domly from among the other k columns, where c is a new algorithm parameter.
Then only c columns need to be newly pivoted. Reducing c below (k/n)(n − k)
saves time correspondingly.
Beware, however, that smaller values of c introduce a dependence between
iterations and require more iterations before the algorithm finds the desired
weight-w word. See Section 5 for a detailed discussion of this effect.
The extreme case c = 1 has appeared before: it was used by Canteaut et al. in
[3, Algorithm 2], [4, Section II.B], and [5, Section 3]. This extreme case minimizes
the time for Gaussian elimination but maximizes the number of iterations of the
entire algorithm.
Illustrative example from the literature: Canteaut and Sendrier report in [5,
Table 2] that they need 9.85 · 1011 iterations to handle n = 1024, k = 525,
w = 50 with their best parameters (p, ) = (2, 18). Stern’s algorithm, with the
same (p, ) = (2, 18), needs only 5.78 · 1011 iterations. Note that these are not
the best parameters for Stern’s algorithm; the parameters p = 3 and = 28 are
considerably better.
Another illustrative example: Canteaut and Chabaud recommend (p, ) =
(2, 20) for n = 2048, k = 1025, w = 112 in [4, Table 2]. These parameters use
5.067 · 1029 iterations, whereas Stern’s algorithm with the same parameters uses
3.754 · 1029 iterations.
Canteaut and Chabaud say that Gaussian elimination is the “most expensive
step” in previous attacks, justifying the switch to c = 1. We point out, however,
that this switch often loses speed compared to Stern’s original attack. For ex-
ample, Stern’s original attack (without reuse of existing pivots) uses only 2124.06
bit operations for n = 2048, k = 1025, w = 112 with (p, ) = (3, 31), beating the
algorithm by Canteaut et al.; in this case Gaussian elimination is only 22% of
the cost of each iteration.
Both c = 1, as used by Canteaut et al., and c = (k/n)(n − k), as used
(essentially) by Stern, are beaten by intermediate values of c. See Section 5 for
some examples of optimized choices of c.
Faster pivoting. Adding the first selected row to various other rows cancels
all remaining 1’s in the first selected column. Adding the second selected row to
various other rows then cancels all remaining 1’s in the second selected column.
It has frequently been observed — see, e.g., [1] — that there is an overlap of
work in these additions: about 25% of the rows will have both the first row and
the second row added. One can save half of the work in these rows by simply
precomputing the sum of the first row and the second row. The precomputation
involves at most one vector addition (and is free if the first selected column
originally began 1, 1).
More generally, suppose that we defer additions of r rows; here r is another
algorithm parameter. After precomputing all 2r − 1 sums of nonempty subsets of
these rows, we can handle each remaining row with, on average, 1 − 1/2r vector
additions, rather than r/2 vector additions. For example, after precomputing
38 D.J. Bernstein, T. Lange, and C. Peters
The product of these probabilities is the chance that the first iteration succeeds.
If iterations were independent, as in Stern’s original attack, then the average
number of iterations would be simply the reciprocal of the product of the prob-
abilities. But iterations are not, in fact, independent. The difficulty is that the
number of errors in the selected n − k columns is correlated with the number of
errors in the columns selected in the next iteration. This is most obvious in the
extreme case c = 1 considered by Canteaut et al.: swapping one selected column
for one deselected column is quite likely to preserve the number of errors in the
selected columns. The effect decreases in magnitude as c increases, but iterations
also become slower as c increases; optimal selection of c requires understanding
how c affects the number of iterations.
40 D.J. Bernstein, T. Lange, and C. Peters
We have implemented the type-1 Markov analysis and the type-3 Markov
analysis. To save time we use floating-point computations with a few hundred
bits of precision rather than exact rational computations. We use the MPFI
library (on top of the MPFR library on top of GMP) to compute intervals
around each floating-point number, guaranteeing that rounding errors do not
affect our final results.
As a check we have also performed millions of type-1, type-2, and type-3
simulations and millions of real experiments decoding small numbers of errors.
The simulation results are consistent with the experimental results. The type-
1 and type-3 simulation results are consistent with the predictions from our
Markov-chain software. Type 1 is slightly slower than type 3, and type 2 is
intermediate. Our graphs below use type 3. Our current attack software uses
type 2 but we intend to change it to type 3.
Results. For each (n, t) in a wide range, we have explored parameters for our
new attack and set new records for the number of bit operations needed to
63 108
62 106
61
104
60
102
59
100
58
98
57
56 96
55 94
0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.50 0.55 0.60 0.65 0.70 0.75 0.80
190 350
340
185
330
180
320
175
310
170
300
165 290
0.50 0.55 0.60 0.65 0.70 0.75 0.80 0.50 0.55 0.60 0.65 0.70 0.75 0.80
Fig. 1. Attack cost for n = 1024, n = 2048, n = 4096, n = 8192. Horizontal axis is the
code rate (n − t lg n)/n. Vertical axis is lg(bit operations).
42 D.J. Bernstein, T. Lange, and C. Peters
decode t errors in an [n, n − t lg n] code. Figure 1 shows our new records. Note
that the optimal attack parameters (p, m, , c, r) depend on n, and depend on t
for fixed n.
We have implemented, and are carrying out, an attack against the cryptosys-
tem parameters originally proposed by McEliece. Our attack software extracts a
plaintext from a ciphertext by decoding 50 errors in a [1024, 524] code over F2 .
If we were running our attack software on a single computer with a 2.4GHz In-
tel Core 2 Quad Q6600 CPU then we would need, on average, approximately 1400
days (258 CPU cycles) to complete the attack. We are actually running our attack
software on more machines. Running the software on 200 such computers — a
moderate-size cluster costing under $200000 — would reduce the average time to
one week. Note that no communication is needed between the computers.
These attack speeds are much faster than the best speeds reported in the
previous literature. Specifically, Canteaut, Chabaud, and Sendrier in [4] and [5]
report implementation results for a 433MHz DEC Alpha CPU and conclude that
one such computer would need approximately 7400000 days (268 CPU cycles):
“decrypting one message out of 10,000 requires 2 months and 14 days with 10
such computers.”
Of course, the dramatic reduction from 7400000 days to 1400 days can be
partially explained by hardware improvements — the Intel Core 2 Quad runs at
5.54× the clock speed of the Alpha 21164, has four parallel cores (compared
to one), and can perform three arithmetic instructions per cycle in each core
(compared to two). But these hardware improvements alone would only reduce
7400000 days to 220000 days.
The remaining speedup factor of 150, allowing us to carry out the first success-
ful attack on the original McEliece parameters, comes from our improvements
of the attack itself. This section discusses the software performance of our at-
tack in detail. Beware that optimizing CPU cycles is different from, and more
difficult than, optimizing the simplified notion of “bit operations” considered in
Section 4.
We gratefully acknowledge contributions of CPU time from several sources.
At the time of this writing we are carrying out about 3.26 · 109 attack iterations
each day:
• about 0.26 · 109 iterations/day from 16 cores of the System Architecture and
Networking Distributed and Parallel Integrated Terminal (sandpit) at TU/e;
• about 0.13 · 109 iterations/day from 8 cores of the Argo cluster at the Aca-
demic Computing and Communications Center at the University of Illinois
at Chicago (UIC);
• about 0.13 · 109 iterations/day from 6 cores at the Center for Research and
Instruction in Technologies for Electronic Security (RITES) at UIC; and
• about 0.13 · 109 iterations/day from 4 cores owned by D. J. Bernstein and
Tanja Lange.
We plan to publish our attack software to allow public verification of our speed
results and to allow easy reuse of the same techniques in other decoding prob-
lems.
Number of iterations. Recall that the Canteaut-et-al. attack uses 9.85 · 1011
iterations on average, with (in our notation) p = 2, = 18, m = 1, and c = 1.
To avoid excessive time spent handling collisions in the main loop, we in-
creased from 18 to 20. This increased the number of iterations to 11.14 · 1011 .
We then increased m from 1 to 5: for each selection of column sets X, Y we try
five sets Z1 , Z2 , Z3 , Z4 , Z5 . We further increased c from 1 to 32: each iteration
replaces 32 columns from the previous iteration. These choices increased various
parts of the per-iteration time by factors of 5 and (almost) 32 respectively; but
the choices also combined to reduce the number of iterations by a factor of more
than 6, down to 1.85 · 1011 .
Further adjustment of the parameters will clearly produce additional improve-
ments, but having reached feasibility we decided to proceed with our attack.
Time for each iteration. Our attack software carries out an attack iteration
in 6.38 million CPU cycles on one core of a busy Core 2 Quad. “Busy” means
that the other three cores of the Core 2 Quad are also working on the attack; the
cycle counts drop slightly, presumably reflecting reduced L2-cache contention, if
only one core of the Core 2 Quad is active.
About 6.20 of these 6.38 million CPU cycles are accounted for by the following
major components:
• 0.68 million CPU cycles to select new column sets X and Y and to perform
Gaussian elimination. We use 32 new columns in each iteration, as mentioned
above. Each new column is handled by an independent pivot, modifying a few
hundred thousand bits of the matrix; we use standard techniques to combine
64 bit modifications into a small number of CPU instructions, reducing the
cost of the pivot to about 20000 CPU cycles. Further improvements are
clearly possible with further tuning.
• 0.35 million CPU cycles to precompute π(L) for each single column L. There
are m = 5 choices of π, and k = 525 columns L for each π. We handle each
π(L) computation in a naive way, costing more than 100 CPU cycles; this
could be improved but is not a large part of the overall computation.
• 0.36 million CPU cycles to clear hash tables. There are two hash tables, each
with 2 = 220 bits, and clearing both tables costs about 0.07 million CPU
44 D.J. Bernstein, T. Lange, and C. Peters
cycles; this is repeated m = 5 times, accounting for the 0.36 million CPU
cycles.
• 1.13 million CPU cycles to mark, for each size-p set A, the bit at position
π(A) in the first hash table. We use p = 2, so there are 262 · 261/2 = 34191
choices of A, and m = 5 choices of π, for a total of 0.17 million marks,
each costing about 6.6 CPU cycles. Probably the 6.6 could be reduced with
further CPU tuning.
• 1.30 million CPU cycles to check, for each set B, whether the bit at position
π(B) is set in the first hash table, and if so to mark the bit at position π(B)
in the second hash table while appending B to a list of colliding B’s.
• 1.35 million CPU cycles to check, for each set A, whether the bit at position
π(A) is set in the second hash table, and if so to append A to a list of
colliding A’s.
• 0.49 million CPU cycles to sort the list of colliding sets A by π(A) and to
sort the list of colliding sets B by π(B). We use a straightforward radix sort.
• 0.54 million CPU cycles to skim through each collision π(A) = π(B), check-
ing the weight of the sum of the columns in A ∪ B. There are on average
about 5 · 34453 · 34191/220 ≈ 5617 collisions. Without early aborts this step
would cost 1.10 million CPU cycles.
For comparison, Canteaut et al. use 260 million cycles on an Alpha 21164
for each of their iterations (“1000 iterations of the optimized algorithm are per-
formed in 10 minutes . . . at 433 MHz”).
References
1. Bard, G.V.: Accelerating cryptanalysis with the Method of Four Russians. Cryp-
tology ePrint Archive: Report 2006/251 (2006),
[Link]
2. Bernstein, D.J.: List decoding for binary Goppa codes (2008),
[Link]
3. Canteaut, A., Chabanne, H.: A further improvement of the work factor in an
attempt at breaking McEliece’s cryptosystem. In: Charpin, P. (ed.) EUROCODE
1994 (1994), [Link]
4. Canteaut, A., Chabaud, F.: A new algorithm for finding minimum-weight words
in a linear code: application to McEliece’s cryptosystem and to narrow-sense BCH
codes of length 511. IEEE Transactions on Information Theory 44(1), 367–378
(1998)
5. Canteaut, A., Sendrier, N.: Cryptanalysis of the original McEliece cryptosystem.
In: Ohta, K., Pei, D. (eds.) ASIACRYPT 1998. LNCS, vol. 1514, pp. 187–199.
Springer, Heidelberg (1998)
6. Engelbert, D., Overbeck, R., Schmidt, A.: A summary of McEliece-type cryp-
tosystems and their security. Cryptology ePrint Archive: Report 2006/162 (2006),
[Link]
7. Lee, P.J., Brickell, E.F.: An observation on the security of McEliece’s public-key
cryptosystem. In: Günther, C.G. (ed.) EUROCRYPT 1988. LNCS, vol. 330, pp.
275–280. Springer, Heidelberg (1988)
8. Leon, J.S.: A probabilistic algorithm for computing minimum weights of large
error-correcting codes. IEEE Transactions on Information Theory 34(5), 1354–1359
(1988)
46 D.J. Bernstein, T. Lange, and C. Peters
9. Li, Y.X., Deng, R.H., Wang, X.M.: On the equivalence of McEliece’s and Niederre-
iter’s public-key cryptosystems. IEEE Transactions on Information Theory 40(1),
271–273 (1994)
10. McEliece, R.J.: A public-key cryptosystem based on algebraic coding theory, Jet
Propulsion Laboratory DSN Progress Report, 42–44 (1978),
[Link] report2/42-44/[Link]
11. Niederreiter, H.: Knapsack-type cryptosystems and algebraic coding theory. Prob-
lems of Control and Information Theory. Problemy Upravlenija i Teorii Informa-
cii 15(2), 159–166 (1986)
12. Overbeck, R., Sendrier, N.: Code-based cryptography. In: Bernstein, D.J., Buch-
mann, J., Dahmen, E. (eds.) Introduction to post-quantum cryptography. Springer,
Berlin (to appear)
13. Patterson, N.J.: The algebraic decoding of Goppa codes. IEEE Transactions on
Information Theory IT-21, 203–207 (1975)
14. Pippenger, N.: The minimum number of edges in graphs with prescribed paths.
Mathematical Systems Theory 12, 325–346 (1979),
[Link]
15. Sendrier, N.: On the security of the McEliece public-key cryptosystem. In: Blaum,
M., Farrell, P.G., van Tilborg, H.C.A. (eds.) Information, coding and mathematics.
Kluwer International Series in Engineering and Computer Science, vol. 687, pp.
141–163. Kluwer, Dordrecht (2002)
16. Sidelnikov, V.M., Shestakov, S.O.: On insecurity of cryptosystems based on gen-
eralized Reed-Solomon codes. Discrete Mathematics and Applications 2, 439–444
(1992)
17. Stern, J.: A method for finding codewords of small weight. In: Cohen, G., Wolf-
mann, J. (eds.) Coding Theory and Applications 1988. LNCS, vol. 388, pp. 106–113.
Springer, Heidelberg (1989)
18. van Tilburg, J.: On the McEliece public-key cryptosystem. In: Goldwasser, S. (ed.)
CRYPTO 1988. LNCS, vol. 403, pp. 119–131. Springer, Heidelberg (1990)
McEliece Cryptosystem Implementation: Theory
and Practice
1 Introduction
McEliece encryption scheme was proposed in 1978 [13]. During the thirty years
that have elapsed since, its security, as a one way trapdoor encryption scheme
has never been seriously threatened.
Most of the previous works have been devoted to cryptanalysis and to semantic
security but fewer attempts have been made to examine implementation issues.
Implementing a (public key) cryptosystem is a tradeoff between security and
efficiency. For that reason, cryptanalysis and implementation have to be consid-
ered in unison.
Though the public key size is rather large, the McEliece encryption scheme
possesses some strong features. It has a good security reduction and low com-
plexity algorithms for encryption and decryption. As a consequence, it is con-
ceivable, compared with number-theory based cryptosystems, to gain an order
of magnitude in performance.
In the first part, we will describe a slightly modified version of the scheme
(which we call hybrid). It has two modifications, the first increases the infor-
mation rate by putting some data in the error pattern. The second reduces the
public key size by making use of a generator matrix in row echelon form. We
will show that the same security reduction as for the original system holds. We
will then describe the key generation, the encryption and the decryption algo-
rithms and their implementation. Finally we will give some computation time
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 47–62, 2008.
c Springer-Verlag Berlin Heidelberg 2008
48 B. Biswas and N. Sendrier
for various parameters, compare them with the best known attacks, and discuss
the best tradeoffs.
2 System Description
We define an injective mapping ϕ : {0, 1} → Wn,t where Wn,t denotes the set
of words of length n and Hamming weight t. Both ϕ and ϕ−1 should be easy to
compute and the integer should be close to log2 nt . As for the original scheme,
we use Goppa codes.
Those changes will improve the credentiality of the system and, as we shall see
in §3, have no impact on the security of the system.
1
wH (·) denotes the Hamming weight.
McEliece Cryptosystem Implementation: Theory and Practice 49
n = 8192
300
250
200 n = 4096
150
n = 2048
100
50 n = 1024
0
0 0.2 0.4 k/n 0.6 0.8 1
3 Cryptographic Security
The first reductional proof of security for the McEliece encryption scheme was
given by Kobara and Imai in [12]. In the same paper, several semantically secure
conversions, generic and ad-hoc, are proposed. The purpose of those conversion
is to transform a One Way Encryption (OWE) scheme, the weakest notion of
security, into a scheme resistant to adaptative chosen ciphertext attack (IND-
CCA2), the strongest notion of security.
In this section, we prove that under two algorithmic assumptions (the hardness
of decoding and the pseudo-randomness of Goppa codes), the hybrid version of
McEliece encryption scheme is one way.
50 B. Biswas and N. Sendrier
The first assumption states the difficulty of decoding in the average case in a
linear code whose parameters are those of a binary Goppa codes.
Assumption 1. For all (T, ε)-adversary over Ω0 , the ratio T /ε is not upper
bounded by a polymonial in n.
The worst-case is known to be difficult (the associated decision problem is NP-
complete) in the general case [4] (Syndrome Decoding) and in the bounded case
[9] (Goppa Parameterized Bounded Decoding). The status of the average case is
unknown, but it is believed to be difficult [1].
The second assumption states that there exists no efficient distinguisher for
Goppa codes. In other words, the generator matrix of a Goppa code looks ran-
dom.
Assumption 2. For all (T, ε)-distinguisher over Gm,t , the ratio T /ε is not up-
per bounded by a polymonial in n.
There is no formal result to assess this assumption. However, there is no known
invariant for linear code, computable in polynomial time, which behave differ-
ently for random codes and for binary Goppa codes.
We use the notations and definitions of the previous section. The public key
is a binary k × (n − k) matrix R. We consider a public injective mapping ϕ :
{0, 1} → Wn,t . The hybrid McEliece encryption is defined as
Before proving the theorem, we will prove some intermediate results in the form
of three lemmas. We will use the following notations:
– Sk×n the binary systematic k × n matrices (i.e. of the form (Id | R)),
– Gm,t = Gm,t ∩ Sk×n the systematic generator matrices of Goppa codes,
– E = Im(ϕ) ⊂ Wn,t the image of {0, 1} by ϕ. In practice E can be any subset
of Wn,t .
52 B. Biswas and N. Sendrier
4 Implementation
4.1 Description
We give in Figure 2 a pseudo-code description of the hybrid McEliece encryption
scheme compliant with the description in §2. Algorithms are detailed in the next
section.
McEliece Cryptosystem Implementation: Theory and Practice 53
keygen(m, t) encrypt(x, e, R)
L ← rand permut(F2m ) return (x x · R) + ϕ(e)
g ← rand irred poly(t)
(R, L ) ← get public key(L, g) decrypt(y, L, g)
SK ← (L , g) e ← decode(y, L, g)
PK ← R return (LSBk (y − e), ϕ−1 (e))
return (P K, SK)
4.2 Algorithms
We describe below the main algorithms require for the implementation of the
hybrid McEliece encryption scheme. We won’t describe the finite field operations,
the usual polynomial operations (including the extended Euclidian algorithm
for computing the modular inverse) and linear algebra operations (including the
Gaussian elimination).
In all the above algorithms, we consider an irreducible binary Goppa code
Γ (L, g) with L = (α1 , . . . , αn ) and g(z) ∈ F2m [z] monic irreducible of degree t.
Building the generator matrix. Let fj (z) = (z − αj )−1 mod g(z) for all
j = 1, . . . , n. A word a = (a1 , . . . , an ) ∈ Fn2 is in Γ (L, g) if and only if
54 B. Biswas and N. Sendrier
n
n
aj
Ra (z) = aj fj (z) = mod g(z) = 0 (1)
j=1 j=1
z − αj
This defines a t×m parity check matrix over F2m whose j-th column is formed by
the t coefficients, in F2m , of the polynomial fj (z). If we write the field elements
of F2m in a basis over F2 , each of those columns becomes a binary word of length
tm and the n binary column corresponding to the expansions of the fj (z) form
a binary tm × n parity check matrix H of Γ (L, g). We then apply a Gaussian
elimination on H, starting with the last columns, to obtain a k × (n − k) binary
matrix R such that (RT | Id) = U HP with U non-singular and P a permutation
matrix. The matrix P is the product of a small number (between 0 and a few
units) of transpositions. A code with parity check matrix (RT | Id) will admit
G = (Id | R) as generator matrix, so R is the public key. Figure 4 describes the
whole procedure.
decode(b, L, g)
S(z) ← syndrome(b, L, g)
σ(z) ← solve key eq(S(z), g(z))
(γ1 , . . . , γt ) ← Berlekamp trace algorithm(σ)
e ← error((γ1 , . . . , γt ), L)
return e
5 Simulation Results
We implemented the hybrid version of McEliece encryption scheme in C program-
ming language. In Figures 6 and 7 we plot the running time per plaintext byte
versus the logarithm in base 2 of the work factor of the best known attack [6].
Various values of t were tried for an extension degree 11 ≤ m ≤ 15. As
expected, for a fixed m, the performance gets better for smaller values of t.
However, for a fixed security level, the best performance is not obtained for the
smallest block size (i.e. extension degree). On the contrary the system works
better for higher extension degrees. However, for m ≥ 13 encryption speed for
fixed security becomes steady. See Figure 6 and Figure 7.
extension degree m = 11
extension degree m = 12
extension degree m = 13
Encryption cost (cpu-cycles per byte)
500
400
300
200
100
0
50 100 150 200 250 300
Binary work factor (power of 2)
Fig. 6. Encryption cost vs binary work factor for different extension degrees
56 B. Biswas and N. Sendrier
extension degree m = 11
extension degree m = 12
extension degree m = 13
extension degree m = 14
extension degree m = 15
6000
Decryption cost (cpu-cycles per byte)
5000
4000
3000
2000
1000
0
50 100 150 200 250 300
Binary work factor (power of 2)
Fig. 7. Decryption cost vs binary work factor for different extension degrees
cycles/byte
(m, t) encrypt decrypt key size security
(10, 50) 243 7938 32 kB 60
(11, 32) 178 1848 73 kB 88
(11, 40) 223 2577 86 kB 96
(12, 21) 126 573 118 kB 88
(12, 41) 164 1412 212 kB 130
(13, 18) 119 312 227 kB 93
(13, 29) 149 535 360 kB 129
(14, 15) 132 229 415 kB 91
(15, 13) 132 186 775 kB 90
(16, 12) 132 166 1532 kB 91
McEliece Cryptosystem Implementation: Theory and Practice 57
cycles/byte
encrypt decrypt
RSA 1024 (1) 800 23100
RSA 2048 (1) 834 55922
NTRU (2) 4753 8445
(1)
RSA encryption (with malleability defense) using OpenSSL.
(2)
ntru-enc 1 ees787ep1 NTRU encryption with N = 787 and q = 587. Software
written by Mark Etzel (NTRU Cryptosystem).
implementation of other public key encryption schemes (see Table 2), McEliece
encryption gains an order of magnitude for both encryption and decryption.
The source used for Table 2 is an EBATS preliminary report2 of March 2007.
6 Conclusion
We presented here a new modified version of McEliece cryptosystem and its
full implementation. We have shown that code-based public key encryption
scheme compares favorably with optimized implementation of number theory
based schemes.
The system we have implemented here is very fast and offers much flexibility
in the choice of parameters. One of the main observations we made from this
implementation work is the fact that increasing the extension degree m seems to
offer an interesting trade off. Presently, our program do not allow an extension
degree greater than 16.
The source code of the whole implementation is freely avalaible on our website
[Link] The Niederreiter scheme is similar to
McEliece’s in most aspects. We intend to make it available as well.
References
1. Barg, A.: Complexity issues in coding theory. In: Pless, V.S., Huffman, W.C. (eds.)
Handbook of Coding theory, ch. 7, vol. I, pp. 649–754. North-Holland, Amsterdam
(1998)
2. Bellare, M., Rogaway, P.: Optimal asymetric encryption. In: De Santis, A. (ed.)
EUROCRYPT 1994. LNCS, vol. 950, pp. 92–111. Springer, Heidelberg (1995)
3. Berlekamp, E.R.: Factoring polynomials over large finite fields. Mathematics of
Computation 24(111), 713–715 (1970)
4. Berlekamp, E.R., McEliece, R.J., van Tilborg, H.C.: On the inherent intractability
of certain coding problems. IEEE Transactions on Information Theory 24(3) (May
1978)
5. Berson, T.: Failure of the McEliece public-key cryptosystem under message-resend
and related-message attack. In: Kalisky, B. (ed.) CRYPTO 1997. LNCS, vol. 1294,
pp. 213–220. Springer, Heidelberg (1997)
2
[Link]
58 B. Biswas and N. Sendrier
6. Canteaut, A., Chabaud, F.: A new algorithm for finding minimum-weight words in
a linear code: Application to McEliece’s cryptosystem and to narrow-sense BCH
codes of length 511. IEEE Transactions on Information Theory 44(1), 367–378
(1998)
7. Canteaut, A., Sendrier, N.: Cryptanalysis of the original McEliece cryptosystem.
In: Ohta, K., Pei, D. (eds.) ASIACRYPT 1998. LNCS, vol. 1514, pp. 187–199.
Springer, Heidelberg (1998)
8. Cover, T.: Enumerative source encoding. IEEE Transactions on Information The-
ory 19(1), 73–77 (1973)
9. Finiasz, M.: Nouvelles constructions utilisant des codes correcteurs d’erreurs en
cryptographie à clef publique. Thèse de doctorat, École Polytechnique (October
2004)
10. Ganz, J.: Factoring polynomials using binary representations of finite fields. IEEE
Transactions on Information Theory 43(1), 147–153 (1997)
11. Hall, C., Goldberg, I., Schneier, B.: Reaction attacks against several public-key
cryptosystems. In: Varadharajan, V., Mu, Y. (eds.) ICICS 1999. LNCS, vol. 1726,
pp. 2–12. Springer, Heidelberg (1999)
12. Kobara, K., Imai, H.: Semantically secure McEliece public-key cryptosystems -
Conversions for McEliece PKC. In: Kim, K. (ed.) PKC 2001. LNCS, vol. 1992, pp.
19–35. Springer, Heidelberg (2001)
13. McEliece, R.J.: A public-key cryptosystem based on algebraic coding theory. In:
DSN Prog. Rep., Jet Prop. Lab., California Inst. Technol., Pasadena, CA, pp.
114–116 (January 1978)
14. Patterson, N.J.: The algebraic decoding of Goppa codes. IEEE Transactions on
Information Theory 21(2), 203–207 (1975)
15. Pointcheval, D.: Chosen-ciphertext security for any one-way cryptosystem. In: Imai,
H., Zheng, Y. (eds.) PKC 2000. LNCS, vol. 1751, pp. 129–146. Springer, Heidelberg
(2000)
16. Sendrier, N.: Finding the permutation between equivalent codes: the support split-
ting algorithm. IEEE Transactions on Information Theory 46(4), 1193–1203 (2000)
17. Sendrier, N.: Cryptosystèmes à clé publique basés sur les codes correcteurs
d’erreurs. Mémoire d’habilitation à diriger des recherches, Université Paris 6
(March 2002)
18. Sendrier, N.: Encoding information into constant weight words. In: IEEE Confer-
ence, ISIT 2005, pp. 435–438, Adelaide, Australia (September 2005)
19. Sun, H.M.: Further cryptanalysis of the McEliece public-key cryptosystem. IEEE
Trans. on communication letters 4(1), 18–19 (2000)
A Goppa Code
Let m and t denote two positive integers. We will denote Gm,t the set of all
binary irreducible t-error correcting Goppa codes, defined below.
Definition 3. Let L = (α1 , . . . , αn ) be a sequence of n = 2m distinct elements
in F2m and g(z) ∈ F2m [z] an irreducible monic polynomial of degree t. The
binary irreducible Goppa code with support L and generator polynomial g(z),
denoted by Γ (L, g), is defined as the set of words (a1 , . . . , an ) ∈ Fn2 such that
n
aj
Ra (z) = = 0 mod g(z).
j=1
z − αj
McEliece Cryptosystem Implementation: Theory and Practice 59
The Goppa code Γ (L, g) has length n = 2m and dimension3 k ≥ n − mt. We can
associate to it an efficient (polynomial time) decoding procedure, denoted ΨL,g ,
which can correct up to t errors. For all x ∈ Γ (L, g) and all e ∈ {0, 1}n, we have
(wH (e) ≤ t) ⇒ (ΨL,g (x + e) = e).
B Additional Proofs
Proof. (of Lemma 1) Let A denote the (T, ε)-adversary over Ω1 of the statement.
By definition, it is such that
Succ(A | e ∈ E) = Succ(A | Ω1 ) ≥ ε.
We have
Proof. (of Lemma 2) Let A denote the (T, ε)-adversary over Ω2 of the state-
ment. We consider the distinguisher D defined for all G ∈ {0, 1}k×n by D(G) =
(A(xG + e, G) = e) where (x, e) is randomly and uniformly chosen in {0, 1}k × E.
We have
PΩ0 (D(G)) = Succ(A | e ∈ E)
PΩ0 (D(G) | Ω2 ) = Succ(A | e ∈ E, G ∈ Gm,t )
¿From which we easily derive
To run D, one has to compute the ciphertext xG + e which has a cost upper
bounded by O(n2 ) and to make one call to A. So we have |D| ≤ T + O(n2 ).
By definition of A, we have Succ(A | Ω2 ) ≥ ε. Thus at least one of the two
right-hand side terms of the inequality (2) is greater than ε/2. This implies that
either A verifies
ε
Succ(A | Ω1 ) ≥
2
or D verifies
ε
Adv(D, Gm,t ) ≥ ,
2
which proves the lemma.
3
Equality holds in all cases of practical interest.
60 B. Biswas and N. Sendrier
Proof. (of Lemma 3) We denote Syst(G) a procedure which returns on any input
G = (U | V ) ∈ {0, 1}k such that U is non-singular the matrix (Id | U −1 V ) ∈
Sk×n . On other inputs, Syst() leave G unchanged.
Let A denote the (T, ε)-adversary over Ω3 of the statement.
We define the adversary A as A (y, G) = A(y, Syst(G)). We define the dis-
tinguisher D which returns true on input G if and only if Syst(G) ∈ Sk×n . The
running time of Syst() is upper bounded by O(n3 ), thus |A | ≤ T + O(n3 ) and
|D| = O(n3 ).
If A succeeds with (x, e, G) ∈ Ω2 and Syst(G) ∈ Sk×n , then A succeeds with
(x , e, Syst(G)) ∈ Ω3 for some x . We have
and (note that the events “e ∈ E” and “Syst(G) ∈ Gm,t ” are independent)
(source) encoder Wn,t → {0, 1}∗ whose decoder is used for processing binary
data. Unfortunately they all have either a high computation cost, or a variable
length encoder.
Here, we use another encoder which uses a new recursive dichotomic model
for the constant weight words. Let x = (xL xR ) ∈ Wn,t , with n = 2m , where
xL and xR have length n/2 = 2m−1 and i = wH (xL ), we define
nil if i ∈ {0, 2m }
Fm,t (x) = L R
i, Fm−1,i (x ), Fm−1,t−i (x ) else
Berlekamp trace algorithm was originally published in [3]. The following presen-
tation is inspired from [10]. This algorithm is very efficient for finite fields with
small characteristic. The trace function T r(·) of F2m over F2 is defined by
2 m−1
T r(z) = z + z 2 + z 2 + ... + z 2 ,
it maps the field F2m onto it’s ground field F2 . A key property of the trace
function is that if (β1 , ..., βm ) is any basis of F2m over F2 , then every element
α ∈ F2m is uniquely represented by the binary m-tuple
The basic idea of the Berlekamp trace algorithm is that any f (z) ∈ F2m [z], with
m
f (z) | z 2 − z, splits into two polynomials
g(z) = gcd(f (z), T r(β · z)) and h(z) = gcd(f (z), 1 + T r(β · z)).
The above property of the trace ensures that if β iterates through the basis
(β1 , ..., βm ), we can separate all the roots of f (z) (see Figure 8).
62 B. Biswas and N. Sendrier
E Patterson Algorithm
The Patterson algorithm [14] solves the Goppa code key equation: given R(z)
and g(z) in F2m [z], with g(z) of degree t respectively, find σ(z) of degree t such
that
d
R(z)σ(z) = σ(z) mod g(z)
dz
d
We write σ(z) = σ0 (z)2 + zσ1 (z)2 . Since σ(z) = σ1 (z)2 , we have
dz
(1 + zR(z))σ1 (z)2 = R(z)σ0 (z)2 mod g(z).
Because g(z) is irreducible, R(z) can be inverted modulo g(z). We put h(z) =
z + R(z)−1 mod g(z) and we have
h(z)σ1 (z)2 = σo (z)2 mod g(z).
The mapping f (z) → f (z)2 mod g(z) is bijective and linear over Ftm
2 , there is a
unique polynomial S(z) such that S(z)2 = h(z) mod g(z). We have
S(z)σ1 (z) = σ0 (z) mod g(z).
The polynomial σ0 (z), σ1 (z) are the unique solution of the equation
⎧
⎨ S(z)σ1 (z) = σ0 (z) mod g(z)
deg σ0 ≤ t/2 (3)
⎩
deg σ1 ≤ (t − 1)/2
The three steps of the algorithm are the following
1. Compute h(z) = z + R(z)−1 mod g(z) using the extended Euclidian algo-
rithm.
2. Compute S(z) = h(z) mod g(z)
If s(z) such that s(z)2 = z mod g(z) has been precomputed and h(z) =
h0 + h1 z + . . . + ht−1 z t−1 , we have
(t−1)/2
m−1
t/2−1
m−1
S(z) = h22i zi + h22i+1 z i s(z)
i=0 i=0
3. Compute (σ0 (z), σ1 (z)) as in (3) using the extended Euclidian algorithm.
The polynomial σ(z) = σ0 (z)2 + zσ1 (z)2 is returned.
Merkle Tree Traversal Revisited
1 Introduction
Digital signatures are extremely important for the security of computer networks
such as the Internet. For example, digital signatures are widely used to ensure
authenticity and integrity of updates for operating systems and other software
applications. Currently used signature schemes like RSA and ECDSA base their
security on the hardness of factoring and computing discrete logarithms. In the
past 20 years, there has been significant progress in solving these problems which
is why the key sizes for RSA and ECDSA are constantly increased [9]. The
security of RSA and ECDSA is also threatened by large quantum computers
that, if built, are able to solve the underlying problems in linear time and thus
are able to completely break RSA and ECDSA [12]. The research on alternative
signature schemes, so-called post quantum signature schemes, is therefore of
extreme importance.
One of the most interesting post-quantum signature schemes is the Merkle
signature scheme (MSS)[10]. Its security can be reduced to the collision resis-
tance of the used hash function [4]. The best known quantum algorithm to find
collisions of hash functions achieves only a square root speed-up compared to the
birthday attack [6]. Therefore, the security of MSS is only marginally affected
if large quantum computers are built. If a specific hash function is found to be
insecure, MSS is easily saved by using a new, secure hash function. This makes
MSS an intriguing candidate for a post-quantum signature scheme. It is therefore
important to implement the Merkle signature scheme as efficiently as possible.
In recent years, many improvements for MSS were proposed [2, 3, 5, 11]. With
those improvements, the performance of MSS is now competitive. However, sign-
ing with MSS is in most cases still slower than signing with ECDSA. This paper
proposes an MSS improvement that reduces the signing time.
The time required for generating a Merkle signature is dominated by the time
for computing the authentication path, that later allows the verifier to deduce
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 63–78, 2008.
c Springer-Verlag Berlin Heidelberg 2008
64 J. Buchmann, E. Dahmen, and M. Schneider
the validity of the one-time verification key from the validity of the MSS public
key. Current algorithms [1, 7, 10, 13, 14] for computing authentication paths
have fairly unbalanced running times. The best case runtime of those algorithms
is significantly shorter than the worst case runtime. So the computation of some
authentication paths is very slow while other authentication paths can be com-
puted very quickly.
Here we propose an authentication path algorithm which is significantly faster
in the worst case than the best algorithm known so far. This is Szydlo’s algorithm
from [13] which provides the optimal time-memory trade-off. In fact, the worst
case runtime of our algorithm is very close to its average case runtime which,
in turn, equals the average case runtime of the best known algorithm proposed
in [13]. The idea of our algorithm is to balance the number of leaves that are
computed in each authentication path computation, since leaves are by far the
most expensive nodes in the Merkle tree. All other known approaches balance
the number of nodes. This does not balance the running time since computing
an inner node only requires one hash function evaluation, while computing a
leaf takes several hundred hash function evaluations; this is because leaves are
essentially one-time verification keys and thus the cost for computing a leaf is
determined by the key pair generation cost of the respective one-time signature
scheme. This problem is pointed out in [1, 11] but no solution has been provided
so far. Our algorithm balances the number of leaves that are computed in each
round. Inner nodes are computed as required and since their cost is negligible
compared to leaves, the worst case time required by our algorithm is extremely
close to the average case time. To be more precise, for each authentication path
our algorithm computes H/2 leaves and 3/2(H − 3) + 1 inner nodes in the worst
case and (H − 1)/2 leaves and (H − 3)/2 inner nodes on average, where H is the
height of the Merkle tree. Our algorithm needs memory to store 3.5H − 4 nodes.
Previous work. There are two different approaches to compute authentication
paths. In [10] Merkle proposes to compute each authentication node separately.
This idea is adopted by Szydlo [14], where he implements a better scheduling of
the node calculations and achieves the optimal trade-off, that is O(H) time and
O(H) space. In [13], Szydlo further improves the constants. For each authen-
tication path his algorithm computes H nodes of the Merkle tree and requires
storage for 3H − 2 nodes.
The second approach is called fractal Merkle tree traversal [7]. This approach
splits the Merkle tree into smaller subtrees and stores a stacked series of sub-
trees that contain authentication paths for several succeeding leaves. Varying the
height h of the subtrees allows a trade-off between time and space needed for the
tree traversal. Using the low space solution (h = log H) requires O(H/ log H)
time and O(H 2 / log H) space. In [1], the authors improve the constants of this
algorithm and prove the optimality of the fractal time-memory trade-off.
Organisation. Section 2 describes a simplified version of our algorithm for
Merkle trees of even height. The general algorithm is presented in Appendix A.
Section 3 compares the new algorithm with that of Szydlo [13]. Section 4 states
our conclusion. Appendix B considers the computation of leaves using a PRNG.
Merkle Tree Traversal Revisited 65
τ =2 Right node
Left node
ϕ=3
Fig. 1. The height of the first parent of leaf ϕ that is a left node is τ = 2. The dashed
nodes denote the authentication path for leaf ϕ. The arrows indicate the path from
leaf ϕ to the root.
The value τ tells us on which heights the authentication path for leaf ϕ + 1
requires new nodes. It requires new right nodes on heights h = 0, . . . , τ − 1 and
a single new left node on height τ .
Computing inner nodes. A basic tool to compute inner nodes of a Merkle
tree is the treehash algorithm shown in Algorithm 1. This algorithm uses a stack
Stack with the usual push and pop operations and the Leafcalc(ϕ) routine
which computes the ϕth leaf1 . To compute a node on height h, Algorithm 1 must
be executed 2h times and requires the leaf indices to be input successively from
1
That is, it computes the ϕth one-time key pair and obtains the leaf from the one-time
verification key.
66 J. Buchmann, E. Dahmen, and M. Schneider
Algorithm 1. Treehash
Input: Leaf index ϕ, stack Stack
Output: Updated stack Stack
1. Leaf ← Leafcalc(ϕ)
2. while Leaf has the same height in the tree as the top node on Stack do
(a) Top ← [Link]()
(b) Leaf ← f (Top Leaf)
3. [Link](Leaf)
4. Return Stack
We now describe our Merkle tree traversal algorithm in detail. We begin with
a simplified version that requires the height of the Merkle tree to be even. The
general version, which comprises a time-memory trade-off suggested by Szydlo,
is discussed in Appendix A. Like Szydlo’s algorithm [13], we deploy two different
strategies to compute authentication nodes, depending on whether the node is
a left child (left authentication node, left node) or a right one. The difference to
Szydlo’s algorithm is, that we only schedule the computation of leaves and not
tree nodes in general.
Data structures. Our algorithm uses the following data structures:
– Treehashh .height. This entry stores the height of the lowest tail node
stored by this treehash instance, either on the stack Stack or in the
entry Treehashh .node. If Treehashh does not store any tail nodes
Treehashh .height = h holds. If Treehashh is finished or not initialized
Treehashh .height = ∞ holds.
• Keeph , h = 0, . . . , H − 2. An array of nodes that stores certain nodes for the
efficient computation of left authentication nodes.
Initialization. The initialization of our algorithm is done during the MSS key
pair generation. We store the authentication path for the first leaf (ϕ = 0): Authh
= yh [1], h = 0, . . . , H − 1. We also store the next right authentication node in
the treehash instances: Treehashh .node = yh [3], for h = 0, . . . , H − 3. Finally
we store the single next right authentication node on height H − 2: Retain =
yH−2 [3]. Figure 2 shows which nodes are stored during the initialization.
Auth3
Auth2 Retain
Auth1
Auth0
Fig. 2. Initialization of our algorithm. Dashed nodes denote the authentication path
for leaf (ϕ = 0). Dash-dotted nodes denote the nodes stored in the treehash instances
and the single node Retain.
Update and output phase. In the following we describe the update and output
phase of our algorithm. Algorithm 2 shows a pseudo-code description. Input is
the index of the current leaf ϕ ∈ {0, . . . , 2H − 2}, the height of the Merkle tree
H ≥ 2, where H must be even, and the algorithm state Auth, Keep, Retain,
and Treehash prepared in previous rounds or during the initialization. Our
algorithm first generates the authentication path for the next leaf ϕ + 1 and
then computes the algorithm state for the next step. Output is the authentication
path for leaf ϕ + 1.
Computing left authentication nodes. We review the computation of left nodes
due to [13]. The basic idea is to store certain right nodes in an array Keeph ,
h = 0, . . . , H − 2 and use them later to compute left authentication nodes using
only one evaluation of the hash function.
If in round ϕ ∈ {0, . . . , 2H − 2}, the parent of leaf ϕ on height τ + 1 is a
left node (this can be verified by checking if ϕ/2τ +1 is even), then Authτ
is a right node and we store it in Keepτ (Line 2). In round ϕ = ϕ + 2τ the
authentication path for leaf ϕ + 1 requires a new left authentication node on
height τ = τ + 1. The left child of this authentication node is the authentication
68 J. Buchmann, E. Dahmen, and M. Schneider
node on height τ − 1 of leaf ϕ . The right child of this node was stored in
Keepτ −1 in round ϕ. The new left authentication node on height τ is then
computed as Authτ = f Authτ −1 Keepτ −1 (Line 4a). For those rounds ϕ
where τ = 0 holds, the single new left node required for the authentication path
of leaf ϕ + 1 is the current leaf ϕ. We compute it using the algorithm Leafcalc,
i.e. we set Auth0 = Leafcalc(ϕ) (Line 3).
Computing right authentication nodes. Unlike left authentication nodes, right au-
thentication nodes must be computed from scratch, i.e. starting from the leaves.
This is because none of their child nodes were used in previous authentication
paths. We use one Treehash instance for each height where right authentication
nodes must be computed, i.e. for heights h = 0, . . . , H − 3.
In round ϕ ∈ {0, . . . , 2H − 2}, the authentication path for leaf ϕ + 1 requires
new right authentication nodes on heights h = 0, . . . , τ − 1. Our algorithm is
constructed such that for h ≤ H − 3 these nodes are already computed and
stored in Treehashh .node. If a new authentication node is required on height
h = H − 2 we copy it from the node Retain. Note that there is only one new
right node required on this height during the whole runtime of Algorithm 2.
The authentication path for leaf ϕ + 1 is obtained by copying the nodes from
Treehashh .node and Retain to Authh for h = 0, . . . , τ − 1 (Line 4b).
After copying the right nodes, all treehash instances on height h = 0, . . . , τ −1
are initialized for the computation of the next right authentication node. The
index of the leaf to begin with is ϕ + 1 + 3 · 2h . If ϕ + 1 + 3 · 2h ≥ 2H holds, then
no new right node will be required on this height and the treehash instance is
not initialized anymore (Line 4c).
The last step of the algorithm is to update the treehash instances using the
Treehashh .update() method (Line 5). We perform H/2 − 1 updates in each
round. One update corresponds to one execution of Algorithm 1, i.e. one update
requires the computation of one leaf and the necessary hash function evaluations
to compute this leaf’s parents. We use the strategy from [13] to decide which
of the H − 2 treehash instances receives an update. The treehash instance that
receives an update is the instance where Treehashh .height contains the smallest
value. If there is more than one such instance, we choose the one with the lowest
index (Line 5a).
2.2 Correctness
In this section we show the correctness of Algorithm 2. First we show that the
budget of H/2 − 1 updates per round is sufficient for the treehash instances to
compute the required authentication nodes on time. Then we will show that it
is possible for all treehash instances to share a single stack.
Nodes are computed on time. If Treehashh is initialized in round ϕ, the
authentication node on height h computed by this instance is required in round
ϕ + 2h+1 . During these 2h+1 rounds there are (H − 2)2h updates available and
Treehashh requires 2h updates to complete.
Merkle Tree Traversal Revisited 69
1. Let τ = 0 if leaf ϕ is a left node or let τ be the height of the first parent of leaf ϕ
which is a left node:
τ ← max{h : 2h |(ϕ + 1)}
2. If the parent of leaf ϕ on height τ +1 is a left node, store the current authentication
node on height τ in Keepτ :
if ϕ/2τ +1 is even and τ < H − 1 then Keepτ ← Authτ
3. If leaf ϕ is a left node, it is required for the authentication path of leaf ϕ + 1:
if τ = 0 then Auth0 ← Leafcalc(ϕ)
4. Otherwise, if leaf ϕ is a right node, the authentication path for leaf ϕ + 1 changes
on heights 0, . . . , τ :
if τ > 0 then
(a) The authentication path for leaf ϕ+1 requires a new left node on height τ . It is
computed using the current authentication node on height τ − 1 and the node
on height τ − 1 previously stored in Keepτ −1 . The node stored in Keepτ −1
can then be removed:
Authτ ← f (Authτ −1 ||Keepτ −1 ), remove Keepτ −1
(b) The authentication path for leaf ϕ + 1 requires new right nodes on heights
h = 0, . . . , τ − 1. For h ≤ H − 3 these nodes are stored in Treehashh and for
h = H − 2 in Retain:
for h = 0 to τ − 1 do
if h ≤ H − 3 then Authh ← Treehashh .node
if h = H − 2 then Authh ← Retain
(c) For heights 0, . . . , τ − 1 the treehash instances must be initialized anew. The
treehash instance on height h is initialized with the start index ϕ + 1 + 3 · 2h
if this index is smaller than 2H :
for h = 0 to τ − 1 do
if ϕ + 1 + 3 · 2h < 2H then Treehashh .initialize(ϕ + 1 + 3 · 2h )
5. Next we spend the budget of H/2 − 1 updates on the treehash instances to prepare
upcoming authentication nodes:
repeat H/2 − 1 times
(a) We consider only stacks which are initialized and not finished. Let s be the
index of the treehash instance whose lowest tail node has the lowest height.
In case there is more than one such instance we choose the instance with the
j
lowest index: ff
s ← min h : Treehashh .height = min {Treehashj .height}
j=0,...,H−3
(b) The treehash instance with index s receives one update:
Treehashs .update()
6. The last step is to output the authentication path for leaf ϕ + 1:
return Auth0 , . . . , AuthH−1 .
70 J. Buchmann, E. Dahmen, and M. Schneider
h−1
2h+1 i
H−3
i+1
· 2 + 2 h
+ 2h = (H − 2)2h (2)
i=0
2
i=h+1
This shows that the budget of H/2 − 1 leaves per round suffices. For h = H − 3
this bound is tight.
Sharing a single stack works. To show that it is possible for all treehash
instances to share a single stack, we have to show that if Treehashh receives
an update and has previously stored tail nodes on the stack, all these tail nodes
are on top of the stack.
When Treehashh receives its first update, the height of the lowest tail node
of Treehashi , i ∈ {h+1, . . . , H −3} is at least h. Otherwise, one of the instances
on height i would receive an update (Line 5a). This means that Treehashh is
completed before Treehashi receives another update and thus tail nodes of
higher treehash instances do not interfere with tail nodes of Treehashh .
While Treehashh is active and stores tail nodes on the stack, it is possible
that treehash instances on lower heights i ∈ {0, . . . , h − 1} receive updates and
store nodes on the stack. If Treehashi receives an update, the height of the
lowest tail node of Treehashh has height ≥ i. This implies that Treehashi
is completed before Treehashh receives another update and therefore doesn’t
store tail nodes on the stack anymore.
we have to add the H/2 − 1 leaves to compute right nodes and one leaf and one
inner node to compute left nodes (Lines 3, 4a in Algorithm 2). All together we
get the following theorem:
Average costs. We now estimate the average cost of our algorithm in terms of
leaves (L) and inner nodes (I) to compute. We begin with the right nodes. On
height h = 0 there are 2H−1 right leaves to compute. On heights h = 1, . . . , H −3,
there are 2H−h−1 right nodes to compute. Each of these nodes requires the
computation of 2h leaves and 2h − 1 inner nodes. For the left nodes, we must
compute one leaf and one inner node every second step, alternating. This makes
a total of 2H−1 leaves and inner nodes. Summing up yields
H−3 H−3
2 H−h−1
·2 +2
h H−1
L+ 2 H−h−1
· (2 − 1) + 2
h H−1
I (3)
h=0 h=1
H −1 H H −3 H
= ·2 L+ ·2 +4 I (4)
2 2
as total number of leaves and inner nodes that must be computed. To obtain
the average cost per step we divide by 2H .
Space required by the stack. We will show that the stack stores at most one
tail node on each height h = 0, . . . , H − 5 at a time.
Treehashh , h ∈ {0, . . . , H − 3} stores up to h tail nodes on different heights
to compute the authentication node on height h. The tail node on height h − 1 is
stored in Treehashh .node and the remaining tail nodes on heights 0, . . . , h − 2
are stored on the stack. When Treehashh receives its first update, the following
two conditions hold:
1. All treehash instances on heights < h are either empty or completed and
store no tail nodes on the stack.
2. All treehash instances on heights > h are either empty or completed or have
tail nodes of height at least h.
Both conditions follow directly from Line 5a in Algorithm 2. These conditions
imply that while Treehashh is active, all tail nodes on the stack that have
height at most h − 2 are on different heights.
If a treehash instance on height i = h + 1, . . . , H − 3 stores a tail node on
the stack, then all treehash instances on heights i + 1, . . . , H − 3 have tail nodes
of height at least i, otherwise the treehash instance on height i wouldn’t have
received any updates in the first place (recall that Treehashi .height = i holds
if Treehashi was just initialized). This implies that all tail nodes on the stack
that have height at least h and at most H − 5 are on different heights.
72 J. Buchmann, E. Dahmen, and M. Schneider
In round ϕ = 2H−1 − 2 this bound is tight. This is the last round before the
treehash instance on height H − 3 must be completed and as we saw in Section
2.2, all available updates are required in this case. The desired upper bound is
estimated as follows:
log 2 u
u
B≤ + 1 + 2u − 1 − log2 u
2h
h=1
log2 u
1 1
=u + 2u − 1 = u 1 − log u + 2u − 1
2h 2 2
h=1
1 3 3
≤u 1− + 2u − 1 = 3u − = (H − 3)
2u 2 2
The next step is to show that the above mentioned case is indeed the worst case.
If a treehash instance on height < H − 3 receives all updates and is completed
in this round, less than B hashes are required. The same holds if the treehash
instance receives all updates but is not completed in this round. The last case
to consider is the one where the u available updates are spend on treehash
instances on different heights. If the active treehash instance Treehashh stores
a tail node ν on height j, it will receive updates until it has a tail node on height
j +1. This requires 2j updates and the computation of 2j inner nodes. Additional
Merkle Tree Traversal Revisited 73
3 Comparison
We now compare our algorithm with Szydlo’s algorithm from [13]. We compare
the number of leaves, inner nodes, and total hash function evaluations computed
per step in the worst case and the average case.
The computation of an inner node costs one hash function evaluation. This
follows directly from the construction rule for Merkle trees of Equation (1). The
cost to compute one leaf, in terms of hash function evaluations, depends on
the one-time signature scheme used for the MSS. The Lamport–Diffie one-time
signature scheme [8] requires 2n evaluations of the hash function, where n is the
output length of the hash function. The Winternitz one-time signature scheme
[5] roughly requires 2w · n/w evaluations of the hash function, where w is the
Winternitz parameter. For our comparison, we use a cost of 100 hash function
evaluations for each leaf calculation.
Table 1 shows the number of leaves, inner nodes, and total hash function
evaluations computed per step in the worst case and the average case. These
values were obtained experimental. The number of leaves and inner nodes our
algorithm requires according to Theorem 1 are given in parentheses.
This table shows, that the cost for the inner nodes is negligible compared to
the cost for the leaf calculations. Our algorithm reduces the total number of hash
function evaluations required in the worst case by more than 49%, 27%, 28%, 15%
for H = 4, 10, 14, 20, respectively, even when using the comparatively low ratio
74 J. Buchmann, E. Dahmen, and M. Schneider
Table 1. Comparison of the worst case and average case runtime of our algorithm
and Szydlos algorithm from [13]. The values according to Theorem 1 are given in
parentheses.
of 100 hash function evaluations per leaf. When using larger ratios, as they
occur in practice, the advantage of our algorithm is more distinct. We state the
comparison only for Merkle trees up to a height of H = 20, since for larger
heights the MSS key pair generation becomes too inefficient so that Merkle trees
of height H > 20 cannot be used in practice [2].
For H = 4, 10, 14, 20, our algorithm needs to store 10, 31, 45, 66 nodes and
Szydlo’s algorithm needs to store 10, 28, 40, 58 nodes, respectively. Although
Szydlo’s algorithm requires slightly less storage, additional implementing effort
and possibly overhead must be taken into account when using Szydlo’s algorithm
on platforms without dynamic memory allocation. This is because Szydlo’s algo-
rithm uses separate stacks for each of the H treehash instances, where, roughly
speaking, each stack can store up to O(H) nodes but all stacks together never
store more than O(H) nodes at a time. The simple approach of reserving the
maximal required memory for each stack yields memory usage quadratic in H.
Table 1 also shows, that our algorithm on average performs slightly better than
Szydlo’s algorithm. This is a result of the slightly increased memory usage of our
algorithm. More importantly, comparing the average case and worst case runtime
shows, that the worst case runtime of our algorithm is extremely close to its
average case runtime. This certifies that our algorithm provides balanced timings
for the authentication path generation and thus the MSS signature generation.
4 Conclusion
We proposed a new algorithm for the computation of authentication paths in a
Merkle tree. In the worst case, our algorithm is significantly faster than the best
algorithm known so far, namely Szydlo’s algorithm from [13]. In fact, the worst
Merkle Tree Traversal Revisited 75
case runtime of our algorithm is very close to its average case runtime which,
in turn, equals the average case runtime of Szydlo’s algorithm. The main idea
of our algorithm is to distinguish between leaves and inner nodes of the Merkle
tree and balance the number of leaves computed in each step.
In detail, our algorithm computes H/2 leaves and 3/2(H − 3) + 1 inner nodes
in the worst case and (H − 1)/2 leaves and (H − 3)/2 inner nodes on average. For
example, we reduce the worst case cost for computing authentication paths in a
Merkle tree of height H = 20 by more than 15% compared to Szydlo’s algorithm.
When implementing our algorithm, the space bound of 3.5H − 4 nodes can be
achieved without additional effort, even on platforms that do not offer dynamic
memory allocation.
References
1. Berman, P., Karpinski, M., Nekrich, Y.: Optimal trade-off for Merkle tree traversal.
Theoretical Computer Science 372(1), 26–36 (2007)
2. Buchmann, J., Coronado, C., Dahmen, E., Döring, M., Klintsevich, E.: CMSS — an
improved Merkle signature scheme. In: Barua, R., Lange, T. (eds.) INDOCRYPT
2006. LNCS, vol. 4329, pp. 349–363. Springer, Heidelberg (2006)
3. Buchmann, J., Dahmen, E., Klintsevich, E., Okeya, K., Vuillaume, C.: Merkle
signatures with virtually unlimited signature capacity. In: Katz, J., Yung, M. (eds.)
ACNS 2007. LNCS, vol. 4521, pp. 31–45. Springer, Heidelberg (2007)
4. Coronado, C.: On the security and the efficiency of the Merkle signature scheme.
Cryptology ePrint Archive, Report 2005/192 (2005), [Link]
5. Dods, C., Smart, N., Stam, M.: Hash based digital signature schemes. In: Smart,
N. (ed.) Cryptography and Coding 2005. LNCS, vol. 3796, pp. 96–115. Springer,
Heidelberg (2005)
6. Grover, L.K.: A fast quantum mechanical algorithm for database search. In: Pro-
ceedings of the Twenty-Eighth Annual Symposium on the Theory of Computing,
pp. 212–219. ACM Press, New York (1996)
7. Jakobsson, M., Leighton, T., Micali, S., Szydlo, M.: Fractal Merkle tree representa-
tion and traversal. In: Joye, M. (ed.) CT-RSA 2003. LNCS, vol. 2612, pp. 314–326.
Springer, Heidelberg (2003)
8. Lamport, L.: Constructing digital signatures from a one way function. Technical
Report SRI-CSL-98, SRI International Computer Science Laboratory (1979)
9. Lenstra, A.K., Verheul., E.R.: Selecting cryptographic key sizes. Journal of Cryp-
tology 14(4), 255–293 (2001); updated version (2004),
[Link]
10. Merkle, R.C.: A certified digital signature. In: Brassard, G. (ed.) CRYPTO 1989.
LNCS, vol. 435, pp. 218–238. Springer, Heidelberg (1990)
11. Naor, D., Shenhav, A., Wool, A.: One-time signatures revisited: Practical fast sig-
natures using fractal merkle tree traversal. In: IEEE – 24th Convention of Electrical
and Electronics Engineers in Israel, pp. 255–259 (2006)
12. Shor, P.W.: Algorithms for quantum computation: Discrete logarithms and factor-
ing. In: Proc. 35th Annual Symposium on Foundations of Computer Science, pp.
124–134. IEEE Computer Society Press, Los Alamitos (1994)
76 J. Buchmann, E. Dahmen, and M. Schneider
13. Szydlo, M.: Merkle tree traversal in log space and time (preprint, 2003),
[Link]
14. Szydlo, M.: Merkle tree traversal in log space and time. In: Cachin, C., Camenisch,
J.L. (eds.) EUROCRYPT 2004. LNCS, vol. 3027, pp. 541–554. Springer, Heidelberg
(2004)
1. Let τ = 0 if leaf ϕ is a left node or let τ be the height of the first parent of leaf ϕ
which is a left node:
τ ← max{h : 2h |(ϕ + 1)}
2. If the parent of leaf ϕ on height τ +1 is a left node, store the current authentication
node on height τ in Keepτ :
if ϕ/2τ +1 is even and τ < H − 1 then Keepτ ← Authτ
3. If leaf ϕ is a left node, it is required for the authentication path of leaf ϕ + 1:
if τ = 0 then Auth0 ← Leafcalc(ϕ)
4. Otherwise, if leaf ϕ is a right node, the authentication path for leaf ϕ + 1 changes
on heights 0, . . . , τ :
if τ > 0 then
(a) The authentication path for leaf ϕ+1 requires a new left node on height τ . It is
computed using the current authentication node on height τ − 1 and the node
on height τ − 1 previously stored in Keepτ −1 . The node stored in Keepτ −1
can then be removed:
Authτ ← f (Authτ −1 ||Keepτ −1 ), remove Keepτ −1
(b) The authentication path for leaf ϕ + 1 requires new right nodes on heights
h = 0, . . . , τ − 1. For h ≤ H − K − 1 these nodes are stored in Treehashh and
for h ≥ H − K in Retainh :
for h = 0 to τ − 1 do
if h ≤ H − K − 1 then Authh ← Treehashh .node
if h > H − K − 1 then Authh ← Retainh .pop()
(c) For heights 0, . . . , min{τ − 1, H − K − 1} the treehash instances must be ini-
tialized anew. The treehash instance on height h is initialized with the start
index ϕ + 1 + 3 · 2h if this index is smaller than 2H :
for h = 0 to min{τ − 1, H − K − 1} do
if ϕ + 1 + 3 · 2h < 2H then Treehashh .initialize(ϕ + 1 + 3 · 2h )
5. Next we spend the budget of (H − K)/2 updates on the treehash instances to
prepare upcoming authentication nodes:
repeat (H − K)/2 times
(a) We consider only stacks which are initialized and not finished. Let s be the
index of the treehash instance whose lowest tail node has the lowest height.
In case there is more than one such instance we choose the instance with the
j
lowest index: ff
s ← min h : Treehashh .height() = min {Treehashj .height()}
j=0,...,H−K−1
(b) The treehash instance with index s receives one update:
Treehashs .update()
6. The last step is to output the authentication path for leaf ϕ + 1:
return Auth0 , . . . , AuthH−1 .
78 J. Buchmann, E. Dahmen, and M. Schneider
by Treehashh and the second (SeedNext) is used for upcoming right nodes
on this height. SeedNext is updated using the PRNG in each round. During
the initialization, we set SeedNexth = Seed3·2h for h = 0, . . . , H − K − 1. In
each round, at first all seeds SeedNexth are updated using the PRNG. If in
round ϕ a new treehash instance is initialized on height h, we copy SeedNexth
to SeedActiveh . In that case SeedNexth = Seedϕ+1+3·2h holds and thus is
the correct seed to begin computing the next authentication node on height h.
Explicit Hard Instances of the
Shortest Vector Problem
1 Introduction
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 79–94, 2008.
c Springer-Verlag Berlin Heidelberg 2008
80 J. Buchmann, R. Lindner, and M. Rückert
that finding this vector is hard for the lattices in our challenge. We also present
first experimental results that confirm the analysis.
Our challenge at [Link] can be considered as
an analogue of similar challenges for the integer factoring problem [36] and the
problems of computing discrete logarithms in the multiplicative group of a finite
field [27], or in the group of points on an elliptic curve over a finite field [10].
Our aim is to evaluate the current state-of-the-art in practical lattice basis
reduction by providing means for an immediate and well-founded comparison.
As a first application of the proposed challenge, we compare the performance of
LLL-type reduction methods — LLL [24], Stehlé’s fpLLL [30], Koy and Schnorr’s
segment LLL (sLLL) [22] — and block-type algorithms — Schnorr’s BKZ [38, 39],
Koy’s primal-dual (PD) [21], Ludwig’s practical random sampling 1 (PSR) [26].
To our knowledge, this is the first comparison of these algorithms.
Related work. Lattice reduction has been subject to intense studies over the last
decades, where a couple of methods and reduction schemes, in particular the
LLL algorithm by Lenstra, Lenstra, and Lovász [24], have been developed and
successively improved. Especially, the block Korkine Zolorarev algorithm (BKZ),
due to Schnorr [38, 39], has become the standard method when strong lattice
basis reduction is required.
There have been several approaches to measure the effectiveness of known
lattice reduction algorithms, especially in the context of the NTRU cryptosystem
[17]. Some of them, as in [18, 19], base their analysis on cryptosystems while
others, like [13, 31], make a more general approach using random lattices.
To our knowledge, there has never been a unified challenge, one that is in-
dependent of a specific cryptosystem, for lattice reduction algorithms. In all
previous challenges, the solution was always known to the creator.
2 Preliminaries
Let Rn denote the n-dimensional real vectorspace. We write the vectors of this
space in boldface to distinguish them from numbers. Any two vectors v, w ∈ Rn
have an inner product v, T
w = v w. Any v ∈ Rn has a length given by the
Euclidean norm v2 = v, v = v12 + · · · + vn2 . In addition to the Euclidean
norm, we also use the maximum mnorm v∞ = maxi=1,...,n {|vi | }.
A lattice in Rn is a set L = { i=1 xi bi | xi ∈ Z}, where b1 , . . . , bm are linearly
independent over R. The matrix B = [b1 , . . . , bm ] is called a basis of the lattice L
1
A practical variant of Schnorr’s random sampling reduction [40].
Explicit Hard Instances of the Shortest Vector Problem 81
and we write L = L(B). The number of linearly independent vectors in the basis
is the dimension of the lattice. If dim(L(B)) = n the lattice is full-dimensional.
An m-dimensional lattice L = L(B) has many different bases, namely all
the matrices in the orbit B GLm (Z) = {BT | T ∈ GLm (Z)}. If the lattice is
full-dimensional and integral, that is L ⊆ Zn , then there exists a unique basis
B = (bi,j ) of L, which is in Hermite normal form (HNF), i.e.
i. bi,j = 0 for all 1 ≤ j < i ≤ m
ii. bi,i > bi,j ≥ 0 for all 1 ≤ i < j ≤ m
Furthermore, the volume vol(L) of a full-dimensional lattice is defined as
| det(B)|, for any basis B of L. For every m-dimensional lattice L there is a
dual (or polar, reciprocal) lattice L∗ = {x ∈ Rm | ∀y ∈ L : x, y ∈ Z}. For any
full-dimensional lattice L = L(B), it holds that L∗ = L((B −1 )T ). The length
of the shortest lattice vector, denoted with λ1 = λ1 (L), is called first successive
minimum.
We set t = n ln(q).
√ Then, (5) implies that (4) is satisfied. It remains to prove
that v∞ < n/ m because this implies v2 < n. Using (6), we have
n ln(q) n ln(nc2 ) ∗ 2 n c2 ln(n) 2 c2
t
v∞ < e m ≤ e m ≤ e c1 n ln(n) ≤ e c1 n ln(n)
≤e c1
.
For a rigorous proof of inequality ∗ see Appendix A. Together with (1), this
evaluates to
“ ”
2 c1
2 c2
ln n n n
e c1
≤e 4 c1 c1 ln(n)
≤ ≤√ ,
c1 ln(n) m
Hardness of finding short vectors. In the following, we show that being able to
find short vectors in an m-dimensional lattice chosen uniformly at random from
L(c1 , c2 , n, ·) ∈ L, implies being able to solve (conjectured) hard lattice problems
for all lattices of dimension n.
In his seminal work [2], Ajtai proved the following theorem that connects
average-case instances of certain lattice problems to worst-case instances. The
problems are defined as follows.
! √ 2 / log n
1 n1/ log log n n/ log n n 2n log log n/ log n 2n(log log n)
Ajtai’s construction in [2] defines all lattices implicitly. In this section, we show
how to generate explicit integral bases for these lattices.
For any m ≥ 500, we now construct a lattice Lm of dimension m, which is our
hard instance of the SVP. The lattice Lm is of the form L(c1 , c2 , n, X), where the
parameters c1 , c2 , n, X are chosen as a function of the dimension m as follows.
We start with a desired lattice dimension m, set c2 = 1, and choose c1 , n =
n(m) such that (1) and (2) hold. This is done by setting
3.π1 π2 π3 π4 . . . ,
so πi , for i ≥ 1, is the ith decimal digit of π in the expansion after the decimal
point. In order to compensate for potential statistical bias, we define
Now, we use the sequence (π1∗ , π2∗ , π3∗ , π4∗ , . . .) as a substitute for a sequence of
uniformly distributed random bits.
The matrix X = (xi,j ) ∈ Zn×m
q is chosen via
k+log2 (q)
xi,j = 2l−k πl∗ mod q for 1 ≤ i ≤ n, 1 ≤ j ≤ m ,
l=k
with k = k(i, j) = ((i − 1) m + (j − 1)) log2 (q) + 1 .
With that, we have selected a “random” element L(c1 , c2 , n, X), for which we
will now generate an integral basis.
4
The digits of π can be optained from [Link]
Explicit Hard Instances of the Shortest Vector Problem 85
The choice of parameters. We now argue that our choice of the paramters leads
to m-dimensional lattices Lm = L(c1 , c2 , n, X), in which vectors of norm less
than n(m) are hard to find.
We have chosen c2 = 1. By Theorem 1, this guarantees the existence of lattice
vectors with norm less than n(m) = q in Lm .
A choice of c2 < 1, and thus q < n, would imply that all q-vectors, namely
vectors that are zero except for one entry q, in Zm have Euclidean norm less
than n(m). This renders the lattice challenge preposterous because q-vectors are
easy to find. Moreover, Theorem 1 only guarantees the existence of one short
vector, which in this case might be a q-vector.
86 J. Buchmann, R. Lindner, and M. Rückert
m n, q γ
500 63 1.0072m
825 127 1.0050m
1000 160 1.0042m
1250 208 1.0036m
1500 256 1.0031m
1750 304 1.0027m
2000 348 1.0024m
On the other hand, choosing c2 > 1 enlarges c1 , and because of (2) decreases
n(m). Then, the hardness of lattice problems in a large dimension m would be
based on the worst-case hardness of lattice problems in a very small dimension
n. As n decreases, our hardness argument becomes less meaningful because even
worst-case lattice problems in small dimensions are believed to be easy.
Table 1 shows how m and n are related for the selected lattices Lm . For a
graphical overview, up to m = 2000, refer to Appendix B. Thus, in order to
apply Theorem 2 as a strong indication for hardness, we keep n(m) close to m in
the above construction. We choose a pseudo-random X to get a random element
in L(c1 , c2 , n, ·), as required by Theorem 2. Using the recent improvement of
Ajtai’s result due to Gentry, Peikert, and Vaikuntanathan [14], it is possible to
choose c2 arbitrarily close to 1. Their results can also be used to improve our
construction, by providing an even stronger indication of hardness. For this, we
refer the reader to the extended version [8].
To give an even stronger argument for the hardness of the SVP in our lattices,
we use a result by Gama and Nguyen [13]. They argue that finding vectors v in
a lattice L is difficult if
v < γvol(L)1/m , (10)
where γ ≤ 1.01m and m is the dimension of L. In this inequality, γ is called
Hermite factor. For γ ≤ 1.005m Gama and Nguyen state that computing vectors
v that satisfy (10) is “totally out of reach”.
Finding a vector v ∈ Lm of length less than n(m) means finding a vector v
that satisfies (10) with Hermite factor
n(m)
γ< .
vol(Lm )1/m
necessary Hermite factor falls below 1.004n and 1.003n. We think that finding
short vectors in the corresponding lattices will require entirely new algorithms.
Toy challenges. In Section 4, we have seen that the problem of finding a vector
of length less than n(m) in lattices Lm starts to become difficult for m ≥ 500
and it should be infeasible for m ≥ 825.
Thus, we define a relaxed variant of the family L. It is the family of all lattice
sets L(2, 1, n, ·), i.e. we set c2 = 1 and c1 = 2, so (1) does not necessarily hold.
Although, in such lattices, there is no guarantee for the existence of lattice vec-
tors of norm less than n(m), such vectors indeed exist in practice. Moreover, our
explicit construction in Section 4 still works and produces bases for lattices Lm ,
m < 500. In the following, the lattices Lm , 200 ≤ m < 500, will be referred to
as toy challenges. Explicit parameters for this range can be found in Appendix
D. There, we also compute the necessary Hermite factor as in Section 4. The
factors suggest that current lattice reduction methods are supposed to find lat-
tice vectors of norm less than n(m). Our experiments with block-type methods
confirm this.
All experiments were run on a single core AMD Opteron at 2.6 GHz, using
Shoup’s NTL [41] in version 5.4.2 and GCC 4.1.2. .
Implementations. For LLL and BKZ, we used the famous implementations in-
tegrated in the NTL. We thank Filipović and Koy for making available their
implementations of sLLL and PD, which were part of the diploma thesis [12].
We also thank Ludwig for making available and updating his implementation of
PSR that was part of his PhD thesis [26]. Finally, we thank Cadé and Stehlé for
making available their implementation of fpLLL. It was obtained from [42].
Figure 2 and Figure 3 depict the performance, i.e. the length of the shortest
obtained vector and the logarithmic running time in seconds, for LLL-type and
block-type methods, respectively. The boxed line in the left figures shows the
norm bound n(m) that has to be undercut. While block-type methods reliably
find vectors of norm less than n(m) up to a dimension around 500, the best
LLL-type algorithms merely succeed in dimensions < 300.
While being arguably efficient with our choice of parameters, sLLL is unable
to find sufficiently short vectors even in dimension 200. For larger dimensions,
88 J. Buchmann, R. Lindner, and M. Rückert
ln(τ )
ln(·22 )
5
9
8 4
7 3
6 2
5 1
200 300 400 500 600 700 800 200 300 400 500 600 700 800
m m
9
8 6
7 5
6
4
5
4 3
200 300 400 500 600 700 800 200 300 400 500 600 700 800
m m
8.8
8.7
8.6
8.5
8.4
ln(·22 )
8.3
8.2
8.1
8
7.9
7.8
7.7
4 6 8 10 12 14 16
β
6 The Challenge
In Section 4, we have constructed challenge lattices Lm of dimension m, for
m ≥ 500. The results in Section 3 together with the pseudo-random choice of
Lm guarantee the existence of vectors v ∈ Lm with v2 < n(m), which are
hard to find. For a toy example, refer to Appendix C.
As stated before, we want the lattice challenge to be open in the sense that
it does not terminate when the first short vector is found. Having proven the
existence of just one solution might suggest that there are no more, but during
practical experiments, we found that many successively shorter vectors exist. For
example in Figure 4, we display that in dimension m = 500 BKZ with increasing
block size subsequently finds smaller and smaller lattice vectors.
We propose the following challenge to all researchers and students.
Lattice Challenge
The contestants are given lattice bases of lattices Lm , together with
a norm bound ν. Initially, we set ν = n(m).
Acknowledgements
We would like to thank Oded Regev for his helpful remarks and suggestions.
Furthermore, we thank the program committee and the anonymous reviewers
for their valuable comments.
References
1. Aharonov, D., Regev, O.: Lattice problems in NP ∩ coNP. J. ACM 52(5), 749–765
(2005)
2. Ajtai, M.: Generating hard instances of lattice problems. In: Proceedings of the
Annual Symposium on the Theory of Computing (STOC), pp. 99–108. ACM Press,
New York (1996)
3. Ajtai, M., Dwork, C.: A public-key cryptosystem with worst-case/average-case
equivalence. In: Proceedings of the Annual Symposium on the Theory of Com-
puting (STOC), pp. 284–293. ACM Press, New York (1997)
4. Ajtai, M., Kumar, R., Sivakumar, D.: A sieve algorithm for the shortest lattice
vector problem. In: Proceedings of the Annual Symposium on the Theory of Com-
puting (STOC), pp. 601–610. ACM Press, New York (2001)
5. Bailey, D., Crandall, R.: On the random character of fundamental constant expan-
sions. Experimental Mathematics 10(2), 175–190 (2001)
6. Bailey, D., Crandall, R.: Random generators and normal numbers. Experimental
Mathematics 11(4), 527–546 (2002)
7. Banaszczyk, W.: New bounds in some transference theorems in the geometry of
numbers. Mathematische Annalen 296(4), 625–635 (1993)
8. Buchmann, J., Lindner, R., Rückert, M.: Explicit hard instances of the shortest
vector problem (extended version). Cryptology ePrint Archive, Report 2008/333
(2008), [Link]
9. Cai, J., Nerurkar, A.: An improved worst-case to average-case connection for lattice
problems. In: Proceedings of the Annual Symposium on Foundations of Computer
Science (FOCS), pp. 468–477 (1997)
10. Certicom Corp. The Certicom ECC Challenge,
[Link]
11. Coppersmith, D., Shamir, A.: Lattice Attacks on NTRU. In: Fumy, W. (ed.) EU-
ROCRYPT 1997. LNCS, vol. 1233, pp. 52–61. Springer, Heidelberg (1997)
12. Filipović, B.: Implementierung der gitterbasenreduktion in segmenten. Master’s
thesis, Johann Wolfgang Goethe-Universität Frankfurt am Main (2002)
13. Gama, N., Nguyen, P.Q.: Predicting lattice reduction. In: Smart, N.P. (ed.) EU-
ROCRYPT 2008. LNCS, vol. 4965, pp. 31–51. Springer, Heidelberg (2008)
14. Gentry, C., Peikert, C., Vaikuntanathan, V.: Trapdoors for hard lattices and new
cryptographic constructions. In: Ladner, R.E., Dwork, C. (eds.) STOC, pp. 197–
206. ACM Press, New York (2008)
15. Goldreich, O., Goldwasser, S.: On the limits of nonapproximability of lattice prob-
lems. J. Comput. Syst. Sci. 60(3), 540–563 (2000)
16. Goldreich, O., Goldwasser, S., Halevi, S.: Public-key cryptosystems from lattice
reduction problems. In: Kaliski Jr., B.S. (ed.) CRYPTO 1997. LNCS, vol. 1294,
pp. 112–131. Springer, Heidelberg (1997)
17. Hoffstein, J., Pipher, J., Silverman, J.H.: NTRU: A ring-based public key cryp-
tosystem. In: Buhler, J. (ed.) ANTS 1998. LNCS, vol. 1423, pp. 267–288. Springer,
Heidelberg (1998)
Explicit Hard Instances of the Shortest Vector Problem 91
18. Hoffstein, J., Silverman, J.H., Whyte, W.: Estimated breaking times for NTRU
lattices. Technical Report 012, Version 2, NTRU Cryptosystems (2003),
[Link]
19. Howgrave-Graham, N., Pipher, H.J.J., Whyte, W.: On estimating the lattice secu-
rity of NTRU. Technical Report 104, Cryptology ePrint Archive (2005),
[Link]
20. Kleinbock, D., Weiss, B.: Dirichlet’s theorem on diophantine approximation and
homogeneous flows. [Link]. 4, 43 (2008)
21. Koy, H.: Primale-duale Segment-Reduktion (2004),
[Link]
22. Koy, H., Schnorr, C.-P.: Segment LLL-reduction of lattice bases. In: Silverman,
J.H. (ed.) CaLC 2001. LNCS, vol. 2146, pp. 67–80. Springer, Heidelberg (2001)
23. Lagarias, J.C., Lenstra Jr., H.W., Schnorr, C.-P.: Korkin-Zolotarev bases and suc-
cessive minima of a lattice and its reciprocal lattice. Combinatorica 10(4), 333–348
(1990)
24. Lenstra, A., Lenstra, H., Lovász, L.: Factoring polynomials with rational coeffi-
cients. Mathematische Annalen 261(4), 515–534 (1982)
25. Ludwig, C.: A faster lattice reduction method using quantum search. In: Ibaraki,
T., Katoh, N., Ono, H. (eds.) ISAAC 2003. LNCS, vol. 2906, pp. 199–208. Springer,
Heidelberg (2003)
26. Ludwig, C.: Practical Lattice Basis Sampling Reduction. PhD thesis, Technische
Universität Darmstadt (2005), [Link]
27. McCurley, K.S.: The discrete logarithm problem. In: Pomerance, C. (ed.) Cryptol-
ogy and computational number theory, Providence, pp. 49–74. American Mathe-
matical Society (1990)
28. Micciancio, D.: Almost perfect lattices, the covering radius problem, and applications
to Ajtai’s connection factor. SIAM Journal on Computing 34(1), 118–169 (2004)
29. Micciancio, D., Regev, O.: Worst-case to average-case reductions based on gaussian
measures. SIAM Journal on Computing 37(1), 267–302 (2007)
30. Nguyen, P.Q., Stehlé, D.: Floating-point LLL revisited. In: Cramer, R. (ed.) EU-
ROCRYPT 2005. LNCS, vol. 3494, pp. 215–233. Springer, Heidelberg (2005)
31. Nguyen, P.Q., Stehlé, D.: LLL on the average. In: Hess, F., Pauli, S., Pohst, M.E.
(eds.) ANTS 2006. LNCS, vol. 4076, pp. 238–256. Springer, Heidelberg (2006)
32. Peikert, C.: Limits on the hardness of lattice problems in p norms. In: IEEE
Conference on Computational Complexity, pp. 333–346. IEEE Computer Society
Press, Los Alamitos (2007)
33. Regev, O.: Quantum computation and lattice problems. SIAM J. Comput. 33(3),
738–760 (2004)
34. Regev, O.: On lattices, learning with errors, random linear codes, and cryptography.
In: Proceedings of the 37th annual ACM symposium on Theory of computing, pp.
84–93. ACM Press, New York (2005)
35. Regev, O.: On the complexity of lattice problems with polynomial approximation
factors. In: A survey for the LLL+25 conference (2007)
36. RSA Security Inc. The RSA Challenge Numbers,
[Link]
37. Schmidt, W.: Diophantine Approximation. Lecture Notes in Mathematics, vol. 785.
Springer, Heidelberg (1980)
38. Schnorr, C.: A hierarchy of polynomial time lattice basis reduction algorithms.
Theoretical Computer Science 53, 201–224 (1987)
39. Schnorr, C.: Block reduced lattice bases and successive minima. Combinatorics,
Probability and Computing 4, 1–16 (1994)
92 J. Buchmann, R. Lindner, and M. Rückert
40. Schnorr, C.: Lattice reduction by random sampling and birthday methods. In:
Alt, H., Habib, M. (eds.) STACS 2003. LNCS, vol. 2607, pp. 146–156. Springer,
Heidelberg (2003)
41. Shoup, V.: Number theory library (NTL) for C++, [Link]
42. Stehlé, D.: Damien Stehlé’s homepage at école normale supérieure de Lyon,
[Link]
holds. By (1), we have that c1 ≥ 1/(2 ln(2)). Evaluating both sides of (11) with
n = 1, 2, 3, we find that the inequality holds for these n. For all n ≥ 4, consider
the following.
We have that c1 ≥ 1/(2 ln(2)) ≥ 2/4 ln(4), which implies
350
300
250
200
n
150
100
50
0
200 400 600 800 1000 1200 1400 1600 1800 2000
m
C Challenge Example
The following low-dimensional example gives an idea of what the challenge lat-
tices, and the short vectors in them, essentially look like. Its block structure is
similar to the one found by Coppersmith and Shamir for NTRU lattices [11].
This is not surprising because both belong to the class of modular lattices.
Example 1. The transposed challenge basis for m = 30, n = q = 8 looks like:
[
[1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -4 -7 -4 -7 -6 -2 -3 -7]
[0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -7 -4 -1 0 -6 -7 -1 -5]
[0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -2 -2 -6 -2 -6 -6 -4 -6]
[0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -6 -7 -1 -5 -5 -1 -4 -3]
[0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -7 -4 -2 -3 -1 0 -1 -3]
[0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -6 -3 -5 -7 -3 -7 0 -2]
[0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -5 -1 -6 -6 -6 -4 -3 -5]
[0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 0 -2 -2 -2 -7]
[0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 -4 -4 -3 0 -5 -7 -6 -4]
[0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 -3 -2 -4 -6 -4 -3 -2 -3]
[0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 -7 -6 -4 0 0 -2 -7 -4]
[0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 -4 -1 0 0 -7 -3 -7 0]
[0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 -1 -6 -3 0 -4 -1 -2 -3]
[0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 -3 -1 0 -4 -3 -3 -2 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 -6 -6 -2 -2 -1 -3 -6 -6]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 -7 -7 -4 -2 -1 -2 -5]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 -6 -2 -1 -4 -4 -3 -2 -6]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 -2 -6 -1 -1 -5 -4 -3 -3]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 -4 0 -5 -4 -6 -7 -5 -2]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 -4 -3 -3 0 -5 -3 -3 -7]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 -4 0 -3 -2 -2 -6 -4 -4]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 -5 -5 -3 0 -1 -3 0 -6]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0 0 0 0 0 0 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0 0 0 0 0 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0 0 0 0 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0 0 0 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0 0 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0]
[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8]
]
[0 0 0 0 -1 1 0 0 -1 0 0 0 1 0 0 0 0 0 1 0 0 0 0 -1 0 0 1 0 0 0]
√
and its Euclidean norm is 7 < n = 8.
94 J. Buchmann, R. Lindner, and M. Rückert
D Toy Challenges
m n, q γ
200 30 1.0146m
225 33 1.0133m
250 36 1.0123m
275 38 1.0115m
300 41 1.0107m
325 44 1.0101m
350 46 1.0095m
375 49 1.0091m
400 51 1.0086m
425 54 1.0082m
450 56 1.0079m
475 59 1.0075m
Practical-Sized Instances of Multivariate PKCs:
Rainbow, TTS, and IC-Derivatives
1 Introduction
MPKCs (multivariate public key cryptosystems) [14, 31] are PKCs whose public
keys are multivariate polynomials in many small variables. It has two properties
that are often touted: Firstly, it is considered a significant possibility for Post-
Quantum Cryptography, with potential to resist future attacks with quantum
computers. Secondly, it is often considered to be faster than the competition.
Extant MPKCs almost always hide the private map Q via composition with
two affine maps S, T . So, P = (p1 , . . . , pm ) = T ◦ Q ◦ S : Kn → Km , or
S Q T
P : w = (w1 , . . . , wn ) → x = MS w + cS → y → z = MT y + cT = (z1 , . . . , zm )
(1)
The public key consists of the polynomials in P. P(0) is always taken to be zero.
In any given scheme, the central map Q belongs to a certain class of quadratic
maps whose inverse can be computed relatively easily. The maps S, T are affine
(sometimes linear) and full-rank. The xj are called the central variables. The
polynomials giving yi in x are called the central polynomials; when necessary
to distinguish between the variable and the value, we will write yi = qi (x).
The key of a MPKC is the design of the central map because, solving a generic
multivariate quadratic system is hard, so the best solution for finding w given z
invariably turns to other means, which depend on the structure of Q.
Corresponding author.
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 95–108, 2008.
c Springer-Verlag Berlin Heidelberg 2008
96 A.I.-T. Chen et al.
1.1 Questions
Four or five years ago, it was shown that instances of TTS and C ∗− , specifically
TTS/4 and SFLASH, are faster signature schemes than traditional competition
using RSA and ECC [1, 10, 33]. These two instances both been broken in the
meantime [18, 20]. Now that the width of a typical ALU is 64 bits, commodity
PC hardware has never been more friendly to RSA and ECC. While multivariates
still represent a future-proofing effort, can we still say that MPKCs are efficient
on commodity hardware?
Currently the fastest multivariate PKCs seems to be from the Rainbow and IC
families [16,17]. We run comparisons using Pentium III (P3) machines (on which
NESSIE contestants are tested) and modern Core 2 and Opteron (hereafter C2
an K8) machines. On these test runs, we can say that compared to implementa-
tions using standard PKCs (DSA, RSA, ECDSA), present instances of MPKCs
with design security levels of around 280 can hold their own in terms of efficiency.
In this paper, we describe how we select our Rainbow and IC-derived in-
stances sketch our implementation. We also suggest the new approach of using
bit-slicing when evaluating in GF(16) or other small fields during the construc-
tion of the private map.
In the comparison here, we use D. J. Bernstein’s eBATs system to do bench-
marking. We can conclude that
In [4], Berbain, Billet and Gilbert describe several ways to compute the public
maps of MPKCs and compare their efficiency. However, they do not describe the
evaluation of the private maps.
[18] summarizes the state of the art against generalized Rainbow/TTS schemes.
The school of Stern et al developed differential attacks that breaks minus variants
98 A.I.-T. Chen et al.
[24, 20] and internal perturbation [23]. Ways to circumvent these attacks are
proposed in [13, 19].
The above attacks the cryptosystem as an EIP or “structural” problem. To
solve the system of equations, we have this
Problem MQ(q; n, m): Solve the system p1 (x) = p2 (x) = · · · = pm (x) = 0,
where each pi is a quadratic in x = (x1 , . . . , xn ). All coefficients and variables
are in K = GF(q), the field with q elements.
Best known methods for generic MQ are F4 -F5 or XL whose complexities [11,
21,22,32] are very hard to evaluate; asymptotic formulas can be found in [2,3,32].
vl
n
(k)
(k)
yk = qk (x) = αij xi xj + βi xi , if k ∈ Ol := {vl + 1 · · · vl+1 }.
i=1 j=i i<vl+1
where v counts the vinegar variables that never appears until the final seg-
ment.
3. Trying for a direct solution. The complexity is roughly as MQ(q; m, m).
4. Using the Reconciliation Attack [18], the complexity is as MQ(q; vu , m).
5. Using the Rainbow Band Separation from [18], the complexity is determined
by that of MQ(q; n, m + n).
6. Against TTS, there is Oil-and-Vinegar Separation [30,26,27], which finds an
Oil subspace that is sufficiently large (estimates as corrected in [33]).
" #
CUOV ≈ q n−2o−1 o4 + (some residual term bounded by o3 q m−o /3) m.
o is the max. oil set size, i.e., there is a set of o central variables which are
never multiplied together in the central equations, and no more.
first segment to get by the minrank and high rank attacks. To be comparable
to the sizes of 3IC-p, we choose the vinegar (structural) sequence (24, 20, 20).
The digest is 160 bits and the signature 192. We use random parameters under
this framework and don’t do TTS. The implementations are described below. In
each of the two instances, the central map is inverted by setting up and solving
two identically-sized linear systems.
11
yi = xi + ai1 xσi + ai2 xσi + pij xj+18 xπi (j)
j=0
+ pi,12 xπi (12) xπi (15) + pi,13 xπi (13) xπi (16) + pi,14 xπi (14) xπi (17) , i = 18 · · · 29
[indices 0 · · · 17 appears exactly once in each random permutation πi ,
and exactly once among the σ, σ (where six σi slots are empty)];
11
yi = xi + ai1 xσi + ai2 xσi + ai3 xσi + xj+29 (pij xπi (j) + pi,j+12 xπi (j+12) )
j=0
+ pi,24 xπi (24) xπi (27) + pi,25 xπi (25) xπi (28) + pi,26 xπi (26) xπi (29) , i = 30 · · · 41
[indices 0 · · · 29 appears exactly once in each random permutation πi ,
and exactly once among the σ, σ , σ (where six σi slots are empty)].
19
yi = xi + ai1 xσi + ai2 xσi + pij xj+23 xπi (j)
j=0
+ pi,20 xπi (20) xπi (22) + pi,21 xπi (21) xπi (23) , i = 24 · · · 43
[indices 0 · · · 23 appears exactly once in each random permutation πi ,
and exactly once among the σ, σ (there are only four σi )];
19
yi = xi + ai1 xσi + ai2 xσi + ai3 xσi + xj+44 (pij xπi (j) + pi,j+20 xπi (j+20) )
j=0
+ pi,40 xπi (40) xπi (42) + pi,41 xπi (41) xπi (43) , i = 44 · · · 63
[indices 0 · · · 43 appears exactly once in each random permutation πi ,
and exactly once among the σ, σ , σ (there are only four σi )].
Practical-Sized Instances of Multivariate PKCs 101
The -invertible cycle [17] can be best considered an improved version or ex-
tension of Matsumoto-Imai, otherwise known as C ∗ [28]. Let’s review first the
latter.
Triangular (and Oil-and-Vinegar, and variants thereof) systems are sometimes
called “single-field” or “small-field” approaches to MPKC design, in contrast to
the approach taken by Matsumoto and Imai in 1988. In such “big-field” variants,
the central map is really a map in a larger field L, a degree n extension of a finite
field K. To be quite precise, we have a map Q : L → L that we can invert, and
pick a K-linear bijection φ : L → Kn . Then we have the following multivariate
polynomial map, which is presumably quadratic (for efficiency):
Q = φ ◦ Q ◦ φ−1 . (2)
then, one “hide” this map Q by composing from both sides by two invertible
affine linear maps S and T in Kn , as in Eq. 1.
Matsumoto and Imai suggest that we pick a K of characteristic 2 and this
map Q
α
Q : x −→ y = x1+q , (3)
where x is an element in L, and such that gcd(1 + q α , q n − 1) = 1. The last
condition ensures that the map Q has an inverse, which is given by
−1
Q (x) = xh , (4)
where h(1 + q α ) = 1 mod (q n − 1). This ensures that we can decrypt any secret
message easily by this inverse. Hereafter we will simply identify a vector space
Kk with larger field L, and Q with Q, totally omitting the isomorphism φ from
formulas.
IC also uses an intermediate field L = Kk and extends C ∗ by using the
following central map from (L∗ ) to itself:
Most of the analysis of the properties of the 3IC map can be found in [17] —
the 3IC and C ∗ maps has a lot in common. Typically, we take out 1/3 of the
variables with a minus variation (3IC− ).
For encryption schemes, “2IC” or = 2, q = 2, α = 1 is suggested.
where the power operation assumes the vector space to represent a field. The
number of Patarin relations decrease quickly down to 0 as r increases. For every
y, we may find Q−1 (y) by guessing at v(x) = b, finding a candidate x =
Q−1
2IC (y + b) and checking the initial assumption that v(x) = b. Since we repeat
the high going-to-the-h-th-power procedure q r times, we are almost forced to let
q = 2 and make r as low as possible.
Clearly the public key of C ∗− inherits some of that symmetry. Now not every
skew-symmetric action by a matrix Mζ that corresponds to an L-multiplication
that result in MTζ Hi + Hi Mζ being in the span of the public-key differential
matrices, because S := span{Hi : i = 1 · · · n − r} as compared to span{Hi :
i = 1 · · · n} is missing r of the basis matrices. However, as the authors of [20]
argued heuristically and backed up with empirical evidence, if we just pick the
first three MTζ Hi + Hi Mζ matrices, or any three random linear combinations of
n−r
the form i=1 bi (MTζ Hi + Hi Mζ ) and demand that they fall in S, then
1. There is a good chance to find a nontrivial Mζ satisfying that requirement;
2. This matrix really correspond to a multiplication by ζ in L;
3. Applying the skew-symmetric action of this Mζ to the public-key matrices
leads to other matrices in span{Hi : i = 1 · · · n} that is not in S.
Why three? There are n(n − 1)/2 degrees of freedom in the Hi , so to form a
span of n− r matrices takes n(n− 3)/2 + r linear relations among its components
(n − r and not n because if we are attacking C ∗− , we are missing r components
of the public key). There are n2 degrees of freedom in an n × n matrix U . So, if
we take a random public key, it is always possible to find a U such that
U T H1 + H1 U, U T H2 + H2 U ∈ S = span{Hi : i = 1 · · · n − r},
U T H1 + H1 U, U T H2 + H2 U, U T H3 + H3 U ∈ S,
there are many more conditions than degrees of freedom, hence it is unlikely to
find a nontrivial solution for truly random Hi . Conversely, for a set of public keys
from C ∗ , tests [20] shows that it almost surely eventually recovers the missing r
equations and break the scheme.
Similarly, [24] and the related [29] shows a similar attack (with a more complex
backend) almost surely breaks 3IC− and any other IC− . For the IC case, the
point is the differential expose the symmetry for a linear map (X1 , X2 , X3 ) →
(ξ1 X1 , ξ2 X2 , ξ3 X3 ). Exactly the same symmetric property is found enabling the
same kind of attacks.
It was pointed out [15] that Internal Perturbation is almost exactly equal to
both Vinegar variables and Projection, or fixing the input to an affine subspace.
Let s be one, two or more. We basically set s variables of the public key to be
zero to create the new public key. However, in the case of signature schemes,
each projected dimension will slow down the signing process by a factor of q. A
104 A.I.-T. Chen et al.
4 Implementation Techniques
Most of the techniques here are not new, just implemented here. However, we
do suggest that the bit-sliced Gaussian Elimination idea is new.
bit-slicing and build lookup tables of all the cross-terms. Over GF(2) we evaluate
only the non-zero polynomials.
where the addition is the bitwise XOR and the multiplication of expressions of
a, b, c, d and αi are done in GF(22 ). Division can be effected via (ati + b)−1 =
i−1
Rijk , which comprise most of the public key, may be computed as in [34]:
⎡ ⎛ ⎞⎤
n−1
Rijk = ⎣(MT )k,(−n+m) ⎝ p ((MS )αi (MS )βj + (MS )αj (MS )βi )⎠⎦
=n−m p xα xβ in y
The second sum is over all cross-terms p xα xβ in the central equation for
y . For every pair i < j, we can compute at once Rijk for every k in O(n2 )
totalling O(n4 ). Similar computations for Pik and Qik take even less time.
The instances that we chose are tested not to suffer the same kind of attacks
that fell previous TTS schemes, but we still don’t have any conclusive evidence
one way or the other of how likely this type of system can stand in the long run.
Acknowledgements
The authors thank Prof. Jintai Ding and Pei-Yuan Wu for invaluable comments
and discussions, and also to National Science Council for sponsorship under
Grant 96-2221-E-001-031-MY3.
References
1. Akkar, M.-L., Courtois, N.T., Duteuil, R., Goubin, L.: A fast and secure imple-
mentation of SFLASH. In: Desmedt, Y.G. (ed.) PKC 2003. LNCS, vol. 2567, pp.
267–278. Springer, Heidelberg (2002)
2. Bardet, M., Faugère, J.-C., Salvy, B.: On the complexity of Gröbner basis com-
putation of semi-regular overdetermined algebraic equations. In: Proceedings of
the International Conference on Polynomial System Solving, pp. 71–74, Previously
INRIA report RR-5049 (2004)
Practical-Sized Instances of Multivariate PKCs 107
3. Bardet, M., Faugère, J.-C., Salvy, B., Yang, B.-Y.: Asymptotic expansion of the
degree of regularity for semi-regular systems of equations. In: Gianni, P. (ed.)
MEGA 2005 Sardinia (Italy) (2005)
4. Berbain, C., Billet, O., Gilbert, H.: Efficient implementations of multivariate
quadratic systems. In: Biham, E., Youssef, A.M. (eds.) SAC 2006. LNCS, vol. 4356,
pp. 174–187. Springer, Heidelberg (2007)
5. Bernstein, D.J., Birkner, P., Joye, M., Lange, T., Peters, C.: Twisted edwards
curves. In: Vaudenay, S. (ed.) AFRICACRYPT 2008. LNCS, vol. 5023, pp. 389–
405. Springer, Heidelberg (2008)
6. Bernstein, D.J., Lange, T.: Faster addition and doubling on elliptic curves. In:
Kurosawa, K. (ed.) ASIACRYPT 2007. LNCS, vol. 4833, pp. 29–50. Springer,
Heidelberg (2007)
7. Bernstein, D.J., Lange, T.: Inverted edwards coordinates. In: Boztaş, S., Lu, H.-F.
(eds.) AAECC 2007. LNCS, vol. 4851, pp. 20–27. Springer, Heidelberg (2007)
8. Billet, O., Gilbert, H.: Cryptanalysis of rainbow. In: De Prisco, R., Yung, M. (eds.)
SCN 2006. LNCS, vol. 4116, pp. 336–347. Springer, Heidelberg (2006)
9. Coppersmith, D., Stern, J., Vaudenay, S.: The security of the birational permuta-
tion signature schemes. Journal of Cryptology 10, 207–221 (1997)
10. Courtois, N., Goubin, L., Patarin, J.: SFLASH: Primitive specification (second
revised version), Submissions, Sflash, 11 pages (2002),
[Link]
11. Courtois, N.T., Klimov, A., Patarin, J., Shamir, A.: Efficient algorithms for solving
overdefined systems of multivariate polynomial equations. In: Preneel, B. (ed.)
EUROCRYPT 2000. LNCS, vol. 1807, pp. 392–407. Springer, Heidelberg (2000),
[Link]
12. Ding, J.: A new variant of the Matsumoto-Imai cryptosystem through perturbation.
In: Bao, F., Deng, R., Zhou, J. (eds.) PKC 2004. LNCS, vol. 2947, pp. 305–318.
Springer, Heidelberg (2004)
13. Ding, J., Gower, J.: Inoculating multivariate schemes against differential attacks.
In: Yung, M., Dodis, Y., Kiayias, A., Malkin, T. (eds.) PKC 2006. LNCS, vol. 3958.
Springer, Heidelberg (2006), [Link]
14. Ding, J., Gower, J., Schmidt, D.: Multivariate Public-Key Cryptosystems. In: Ad-
vances in Information Security. Springer, Heidelberg (2006)
15. Ding, J., Schmidt, D.: Cryptanalysis of HFEv and internal perturbation of HFE. In:
Vaudenay, S. (ed.) PKC 2005. LNCS, vol. 3386, pp. 288–301. Springer, Heidelberg
(2005)
16. Ding, J., Schmidt, D.: Rainbow, a new multivariable polynomial signature scheme.
In: Ioannidis, J., Keromytis, A., Yung, M. (eds.) ACNS 2005. LNCS, vol. 3531, pp.
164–175. Springer, Heidelberg (2005)
17. Ding, J., Wolf, C., Yang, B.-Y.: -invertible cycles for multivariate quadratic public
key cryptography. In: Okamoto, T., Wang, X. (eds.) PKC 2007. LNCS, vol. 4450,
pp. 266–281. Springer, Heidelberg (2007)
18. Ding, J., Yang, B.-Y., Chen, C.-H.O., Chen, M.-S., Cheng, C.-M.: New differential-
algebraic attacks and reparametrization of rainbow. In: Bellovin, S.M., Gennaro,
R., Keromytis, A., Yung, M. (eds.) ACNS 2008. LNCS, vol. 5037, pp. 242–257.
Springer, Heidelberg (2008), [Link]
19. Ding, J., Yang, B.-Y., Dubois, V., Cheng, C.-M., Chen, O.C.-H.: Breaking the
symmetry: a way to resist the new differential attack. In: ICALP 2008. LNCS.
Springer, Heidelberg (2008), [Link]
108 A.I.-T. Chen et al.
20. Dubois, V., Fouque, P.-A., Shamir, A., Stern, J.: Practical cryptanalysis of
SFLASH. In: Menezes, A. (ed.) CRYPTO 2007. LNCS, vol. 4622, pp. 1–12.
Springer, Heidelberg (2007)
21. Faugère, J.-C.: A new efficient algorithm for computing Gröbner bases (F4 ). Journal
of Pure and Applied Algebra 139, 61–88 (1999)
22. Faugère, J.-C.: A new efficient algorithm for computing Gröbner bases without
reduction to zero (F5 ). In: International Symposium on Symbolic and Algebraic
Computation — ISSAC 2002, pp. 75–83. ACM Press, New York (2002)
23. Fouque, P.-A., Granboulan, L., Stern, J.: Differential cryptanalysis for multivariate
schemes. In: Cramer, R. (ed.) EUROCRYPT 2005. LNCS, vol. 3494, pp. 341–353.
Springer, Heidelberg (2005)
24. Fouque, P.-A., Macario-Rat, G., Perret, L., Stern, J.: Total break of the IC- sig-
nature scheme. In: Public Key Cryptography, pp. 1–17 (2008)
25. Goubin, L., Courtois, N.T.: Cryptanalysis of the TTM cryptosystem. In: Okamoto,
T. (ed.) ASIACRYPT 2000. LNCS, vol. 1976, pp. 44–57. Springer, Heidelberg
(2000)
26. Kipnis, A., Patarin, J., Goubin, L.: Unbalanced Oil and Vinegar signature schemes.
In: Stern, J. (ed.) EUROCRYPT 1999. LNCS, vol. 1592, pp. 206–222. Springer,
Heidelberg (1999)
27. Kipnis, A., Shamir, A.: Cryptanalysis of the oil and vinegar signature scheme.
In: Krawczyk, H. (ed.) CRYPTO 1998. LNCS, vol. 1462, pp. 257–266. Springer,
Heidelberg (1998)
28. Matsumoto, T., Imai, H.: Public quadratic polynomial-tuples for efficient signature
verification and message-encryption. In: Günther, C.G. (ed.) EUROCRYPT 1988.
LNCS, vol. 330, pp. 419–545. Springer, Heidelberg (1988)
29. Ogura, N., Uchiyama, S.: Remarks on the attack of fouque et al. against the ic
scheme. Cryptology ePrint Archive, Report 2008/208 (2008),
[Link]
30. Wolf, C., Braeken, A., Preneel, B.: Efficient cryptanalysis of RSE(2)PKC and
RSSE(2)PKC. In: Blundo, C., Cimato, S. (eds.) SCN 2004. LNCS, vol. 3352, pp.
294–309. Springer, Heidelberg (2005), [Link]
31. Wolf, C., Preneel, B.: Taxonomy of public key schemes based on the problem of
multivariate quadratic equations. Cryptology ePrint Archive, Report 2005/077, 64
pages, May 12 (2005), [Link]
32. Yang, B.-Y., Chen, J.-M.: All in the XL family: Theory and practice. In: Park, C.-
s., Chee, S. (eds.) ICISC 2004. LNCS, vol. 3506, pp. 67–86. Springer, Heidelberg
(2005)
33. Yang, B.-Y., Chen, J.-M.: Building secure tame-like multivariate public-key cryp-
tosystems: The new TTS. In: Boyd, C., González Nieto, J.M. (eds.) ACISP 2005.
LNCS, vol. 3574, pp. 518–531. Springer, Heidelberg (2005)
34. Yang, B.-Y., Chen, J.-M., Chen, Y.-H.: TTS: High-speed signatures on a low-cost
smart card. In: Joye, M., Quisquater, J.-J. (eds.) CHES 2004. LNCS, vol. 3156,
pp. 371–385. Springer, Heidelberg (2004)
Digital Signatures Out of Second-Preimage
Resistant Hash Functions
1 Introduction
In 1979, Ralph Merkle proposed a digital signature scheme constructed out of
cryptographic hash functions only [7]. The interest of this scheme is that, unlike
most public-key cryptosystems, its security does not rely on number-theoretic
problems. Even if a particular hash function appears insecure, the scheme can be
easily repaired by using a different hash function. Finally, the current research
suggests that the Merkle signature scheme (MSS) will be only marginally affected
if large quantum computers are built, something that is not true for popular
public-key cryptosystems such as RSA and ECC.
The security of the original construction of the MSS relies on a collision re-
sistant hash function for the hash tree and a preimage resistant function for the
one-time signature stage [3]. Regarding security, this construction has two draw-
backs. First, recent attacks on the collision resistance of popular hash functions
such as MD5 [15] and SHA1 [14] show that collision resistance is a goal which
is hard to achieve. Second, the security level of Merkle signatures is determined
by the collision resistance property of the hash function and therefore affected
by birthday attacks.
In [8], the authors argue, without proof, that the security level of the MSS
should be determined by the second-preimage resistance property of the hash
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 109–123, 2008.
c Springer-Verlag Berlin Heidelberg 2008
110 E. Dahmen et al.
function. Although no attack based on a collision finder is known for the MSS,
its security proof does not exclude the existence of such attacks. In addition,
Rohatgi proposes using target-collision resistant hash functions for achieving
goals that are similar to ours [11]. Unfortunately, practical hash functions were
not designed with target-collision resistance in mind, and keyed hash functions
such as HMAC lose all of their security properties when their key is revealed,
and as such, cannot be regarded as target-collision resistant. Although we agree
with [8] that second-preimage resistance should be at the heart of the security
of the MSS, we emphasize that until now, no satisfactory solution is known, at
least from a provable security perspective.
In this paper, we propose a new construction for Merkle authentication trees
and show that the resulting signature scheme is secure against adaptive chosen
message attacks, assuming a second-preimage resistant hash function and a se-
cure one-time signature scheme. Our construction is inspired by the XOR tree
proposed by Bellare and Rogaway for building universal one-way hash functions
out of universal one-way compression functions [1]. However, we use the XOR
tree for a totally different purpose, namely establishing the unforgeability of the
Merkle signature scheme, and we relax the assumption on the compression func-
tion to second-preimage resistance. Even for hash functions with short output
size, our scheme provably yields a high security level; compared to the original
MSS, not only security is improved, but the size of signatures is reduced as well.
The paper is organized as follows: in Section 2 we review security notions
for hash functions and signature schemes. In Section 3 we introduce the new
construction and its security proof. In Section 4 we estimate the security level
of the new scheme. In Section 5 we consider the problem of signing arbitrarily
long messages. In Section 6 we present practical considerations. In Section 7 we
state our conclusion.
adversary A that runs in time at most tow (resp. tspr or tcr ), the probability of
finding a preimage (resp. second-preimage or collision) is smaller than ow (resp.
spr or cr ).
Using generic (brute-force) attacks to compute preimages or second-preimages,
one requires tow = tspr = 2n−k evaluations of the hash function, to find a
preimage or second preimage with probability ow = spr = 1/2k . Due to the
birthday paradox, one requires tcr = 2n/2 evaluations of the hash function to
find a collision with probability cr = 1/2.
...
yi [j]
random mask random mask
(part of public key) k H (two masks/level)
vi [0] vi [1]
k H k H
Key Pair Generation. The key pair generation of our scheme works as follows.
First choose h ≥ 1, to determine the number of signatures that can be generated
with this key pair, i.e. 2h many. Next compute 2h OTS key pairs (Xj , Yj ), for
j = 0, . . . , 2h −1. We assume that each signature key and verification key consists
of 2l bit strings each of length n. Then choose a key for the hash function k ∈R K
and masks vi [0], vi [1] ∈R {0, 1}n uniformly at random for i = 0, . . . , h+l−1. The
2h · 2l n-bit strings from the verification keys form the leaves of the SPR-Merkle
tree, which in total yields a tree of height h + l. The nodes are denoted by yi [j],
where i = 0, . . . , h + l denotes the height of the node in the tree (the root has
height 0 and the leaves have height h + l) and j = 0, . . . , 2i − 1 denotes the
position of the node on that height, counting from left to right. The inner nodes
are computed as
yi [j] = Hk yi+1 [2j] ⊕ vi [0] yi+1 [2j + 1] ⊕ vi [1]
Remark 1. In case the number of bit strings L in the verification key of the
chosen OTS is not a power of 2, the resulting SPR-Merkle tree has height h +
log2 L. The SPR-Merkle tree is constructed such that the subtrees below the
2h nodes yh [j] are unbalanced trees of height log2 L.
Digital Signatures Out of Second-Preimage Resistant Hash Functions 113
Verification. The verification consists of two steps. First the verifier verifies the
one-time signature of message M using the supplied verification key Ys . Then
he verifies the authenticity of Ys as follows: first he uses the 2l bit strings in Ys
to compute the inner node yh [s] as
yi [j] = Hk yi+1 [2j] ⊕ vi [0] yi+1 [2j + 1] ⊕ vi [1]
for i = h + l − 1, . . . , h and j = s2i−h , . . . , (s + 1)2i−1 − 1. Then he uses the
authentication path As and recomputes the path from yh [s] to the root y0 [0] as
⎧
⎨ Hk ai+1 ⊕ vi [0] pi+1 ⊕ vi [1] , if s/2h−i+1 ≡ 1 mod 2
pi =
⎩H pi+1 ⊕ vi [0] ai+1 ⊕ vi [1] , if s/2h−i+1 ≡ 0 mod 2
k
authentication
path to root
path
p0 = y0 [0]
p1 = y1 [0] a1 = y1 [1]
yh−1 [0] ah−1 = yh−1 [s/2−1] ph−1 = yh−1 [s/2] yh−1 [2h−1 −1]
illustrates how the authentication path can be utilized in order to recompute the
root y0 [0].
Algorithm 1. AdvSPR,OTS
Case 1 (Ys , As ) = (Ys , As ). The fact that the verification key Ys can be
authenticated against the root y0 [0] implies a collision of Hk , see Appendix C.
This collision can either occur during the computation of the inner node yh [s] or
during the computation of the path from yh [s] to the root y0 [0]. The adversary
AdvSPR,OTS is successful in finding a second-preimage of x if the node ya [b]
is computed as ya [b] = Hk (x ) with x = x . Since the position of node ya [b]
was chosen at random, the probability that the collision occurs precisely at this
position is at least 1/(2h+l − 1). In total, the success probability of AdvSPR,OTS
is at least /(2h+l − 1), where is the success probability of the forger.
4 Comparison
Security Level. We compute the security level of the SPR-MSS and compare it
with the original MSS that relies on collision resistance (CR-MSS). As OTS we
use the Lamport–Diffie one-time signature scheme (LD–OTS) [6]. The following
theorem establishes the security of the LD–OTS (details of the reduction can be
found in Appendix A).
≤ 4n · ow
t = tow − tSig − tGen
116 E. Dahmen et al.
Table 1 shows the security level of SPR-MSS and CR-MSS for different values of
n. It also shows the upper bounds for h such that the security level of SPR-MSS
and CR-MSS can be estimated as 2n−h−log2 n−4 and 2n/2−1 , respectively.
Table 1 shows that the security level is increased drastically when using the
SPR-MSS. As a consequence, the SPR-MSS not only has weaker security as-
sumptions, but hash functions with much smaller output size suffice to obtain
the same security level as the CR-MSS. Nowadays, a security level of at least 280
is required. When using n = 128, the SPR-MSS achieves a security level greater
than 280 for h ≤ 38. To obtain a similar security level with CR-MSS, one must
use n = 224.
Sizes. The CR-MSS public key consists of the root of the Merkle tree and the
key for the hash function. Assuming this key has bit length n, the size of an
CR-MSS public key is 2 · n bits. The SPR-MSS public key must also contain
the 2(h + l) XOR masks, each of bit length n. Therefore, in total the size of an
SPR-MSS public key is 2(h + l + 1) · n bits. In case of the LD–OTS we have
l = log2 2n. Using the same hash function, the signature size is the same for the
CR-MSS and the SPR-MSS. When using the LD–OTS, the one-time signature
of the message consists of n bit strings of length n. The verification key also
consists of n bit strings of length n, since half of the verification key can be
computed from the signature. The authentication path consists of h bit strings
of length n. In total, the size of a signature is (2n + h) · n bits. Table 2 compares
the signature and public key size of the SPR-MSS and the CR-MSS when using
h = 20.
Table 2 shows that in addition to its superior security, the SPR-MSS also
provides smaller signatures than the CR-MSS, at the expense of larger public
keys. In fact, in many cases the signer’s public key, embedded in a certificate, is
part of the signature; for that reason the sum of the sizes of the public key and
the signature is often relevant. However, even in this case, the SPR-MSS is still
superior to the CR-MSS.
118 E. Dahmen et al.
C1 C2 C3
M H1 H2 H3 Sig
K1 K2 K3 σ
signature= K1 , K2 , K3 , σ with σ = Sig(K3 ||C3 )
Fig. 3. Iterating TCR hash functions
6 Practical Considerations
7 Conclusion
We proposed SPR-MSS, a variant of the Merkle signature scheme with much
weaker security assumptions than the original construction. More precisely, our
scheme is existentially unforgeable under adaptive chosen message attacks, as-
suming second-preimage and preimage resistant hash functions. Compared to
the original Merkle signature which relies on a collision-resistant hash function,
SPR-MSS provides a higher security level even when the underlying hash func-
tion has a smaller output size. For instance, when using a 128-bit hash function
such as MD5, which is still secure in view of second-preimage resistance, SPR-
MSS offers a security level better than 280 for trees of height up to 38.
References
1. Bellare, M., Rogaway, P.: Collision-resistant hashing: Towards making UOWHFs
practical. In: Kaliski Jr., B.S. (ed.) CRYPTO 1997. LNCS, vol. 1294, pp. 470–484.
Springer, Heidelberg (1997)
2. Dods, C., Smart, N., Stam, M.: Hash based digital signature schemes. In: Smart,
N. (ed.) Cryptography and Coding 2005. LNCS, vol. 3796, pp. 96–115. Springer,
Heidelberg (2005)
3. Garcı́a, L.C.C.: On the security and the efficiency of the merkle signature scheme.
Cryptology ePrint Archive, Report 2005/192 (2005), [Link]
4. Goldwasser, S., Micali, S., Rivest, R.L.: A digital signature scheme secure against
adaptive chosen-message attacks. SIAM Journal on Computing 17(2), 281–308
(1988)
5. Halevi, S., Krawczyk, H.: Strengthening digital signatures via randomized hash-
ing. In: Dwork, C. (ed.) CRYPTO 2006. LNCS, vol. 4117, pp. 41–59. Springer,
Heidelberg (2006)
6. Lamport, L.: Constructing digital signatures from a one way function. Technical
Report SRI-CSL-98, SRI International Computer Science Laboratory (1979)
7. Merkle, R.C.: A certified digital signature. In: Brassard, G. (ed.) CRYPTO 1989.
LNCS, vol. 435, pp. 218–238. Springer, Heidelberg (1990)
8. Naor, D., Shenhav, A., Wool, A.: One-time signatures revisited: Have they become
practical. Cryptology ePrint Archive, Report 2005/442 (2005),
[Link]
Digital Signatures Out of Second-Preimage Resistant Hash Functions 121
9. Naor, M., Yung, M.: Universal one-way hash functions and their cryptographic
applications. In: 21st Annual ACM Symposium on Theory of Computing - STOC
1989, pp. 33–43. ACM Press, New York (1989)
10. Rogaway, P., Shrimpton, T.: Cryptographic hash-function basics: Definitions, im-
plications, and separations for preimage resistance, second-preimage resistance, and
collision resistance. In: Roy, B., Meier, W. (eds.) FSE 2004. LNCS, vol. 3017, pp.
371–388. Springer, Heidelberg (2004)
11. Rohatgi, P.: A compact and fast hybrid signature scheme for multicast packet
authentication. In: ACM Conference on Computer and Communications Security
- CSS 1999, pp. 93–100. ACM Press, New York (1999)
12. Shoup, V.: A composition theorem for universal one-way hash functions. In: Pre-
neel, B. (ed.) EUROCRYPT 2000. LNCS, vol. 1807, pp. 445–452. Springer, Hei-
delberg (2000)
13. Szydlo, M.: Merkle tree traversal in log space and time. In: Cachin, C., Camenisch,
J.L. (eds.) EUROCRYPT 2004. LNCS, vol. 3027, pp. 541–554. Springer, Heidelberg
(2004)
14. Wang, X., Yin, Y.L., Yu, H.: Finding collisions in the full SHA-1. In: Shoup, V.
(ed.) CRYPTO 2005. LNCS, vol. 3621, pp. 17–36. Springer, Heidelberg (2005)
15. Wang, X., Yu, H.: How to break MD5 and other hash functions. In: Cramer, R.
(ed.) EUROCRYPT 2005. LNCS, vol. 3494, pp. 19–35. Springer, Heidelberg (2005)
Algorithm 2. AdvPre
Algorithm 3. AdvCR,OTS
Input: Key for the hash function k ∈R K, height of the tree h ≥ 1, an instance of the
underlying OTS consisting of a verification key Y and the corresponding signing oracle
SigX (·)
Output: Collision of Gk , existential forgery for the supplied instance of the OTS, or
failure
1 Introduction
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 124–136, 2008.
c Springer-Verlag Berlin Heidelberg 2008
Cryptanalysis of Rational Multivariate Public Key Cryptosystems 125
Note the denominators used in both rational maps are the same in the
two nonlinear map respectively. Gn+1 is the common denominator for G; it
enables the public key to consist of exactly n + 1 polynomials. Fn+1 is the
common denominator for F ; it enables the composition of degree 2 rational
functions to result in a degree 4 rational function, not that of higher degree.
To see how this works, we’ll introduce a division function, φ : k n+1 −→ k n
x1
with φ(x1 , . . . , xn+1 ) = ( xn+1 , · · · , xxn+1
n
). Also let F̄ , Ḡ : k n −→ k n+1 each
be quadratic polynomials that satisfy
φ ◦ Ḡ = L3 ◦ G and φ ◦ F̄ = L2 ◦ F ◦ L1
resulting in P = φ ◦ Ḡ ◦ φ ◦ F̄ = φ ◦ (Ḡ ◦ φ) ◦ F̄ .
Now let G̃ be the homogenization of Ḡ, i.e. G̃ : k n+1 → k n+1 where
∀ 1 ≤ i ≤ n + 1, G̃i (v1 , . . . , vn+1 ) = vn+1
2 v1
Ḡi ( vn+1 , · · · , vn+1
vn
)=
vn+1 Ḡi ◦ φ(v1 , . . . , vn+1 ).
2
3. The private key. The private key is the set of the five maps F, G, L1 , L2 , L3
and the key to invert the non-linear maps F and G. The map P can illus-
trated as: k n −L→1 k n −F→ k n −L→2 k n −G→ k n −L→3 k n .
The design principles of the quadratic rational components, F and G, are
identical, except that they use different choices for the random parameters
involved. A two-part construction is used. The first part is what the designers
call a core transformation. The second part is called the sequential part, since
inversion is accomplished sequentially. Its structure can be seen as triangular.
The core tranformation is applied only to the last two components, namely
C = ( FFn−1 , Fn ), which can be viewed as a map k 2 −→ k 2 . To construct
n+1 Fn+1
Fn−1 , Fn , Fn+1 , we first randomly choose 12 elements in k: α1 , . . . , α6 and
β1 , . . . , β6 . C has an inverse which is given by:
C −1 (yn−1 , yn ) = ( α1 yn−1 +α2 yn +α3
α4 yn−1 +α5 yn +α6 ,
β1 yn−1 +β2 yn +β3
β4 yn−1 +β5 yn +β6 ).
yn−2 ∗(τn−2,1 xn−1 xn +τn−2,2 xn−1 +τn−2,3 xn +τn−2,4 )−bn−2 (xn−1 ,xn )
yielding xn−2 = an−2 (xn−1 ,xn ) .
After obtaining xn−2 , we can plug known values into the fourth last com-
ponent function of F and derive xn−3 . This sequential solution method
is continued to find the rest of (x1 , . . . , xn ) which gives us a solution for
F (x1 , ..., xn ) = (y1 , ..., yn ). Inversion of G is performed in the exact same
manner as F .
Note that in the inversion process, division is required in the calculation
of each of the components of (x1 , . . . , xn ). In each case, the expression for the
divisor is linear in terms of known values of input variables (xi+1 , . . . , xn )
and the given values of output variables (yi , . . . , yn ). In both cases, the prob-
ability of valid division is approximately q−1 q . The probability of successfully
q−1 2n
inverting both F and G, and thus P , therefore, is approximately q .
3 Cryptanalysis of RMPKC
Our attack can be viewed as the decomposition of maps. The cryptanalysis of
RMPKC is performed as follows: given P , the composition of L3 ◦ G ◦ L2 ◦ F ◦ L1 ,
generate a new set of maps L3 , G , L2 , F , and L1 such that
L3 ◦ G ◦ L2 ◦ F ◦ L1 = L3 ◦ G ◦ L2 ◦ F ◦ L1 ,
and G and F can be inverted in the same way as G and F , with the keys
to inversion obtained during the process. This new set of maps can be viewed
as a private key equivalent to the original one, thus can be used to defeat the
RMPKC cryptosystem.
To decompose RMPKC, we will use the partial derivative method, which
takes the composition of two homogeneous quadratic polynomial maps forming
Cryptanalysis of Rational Multivariate Public Key Cryptosystems 129
a homogeneous quartic map, and decomposes it into quadratic maps which, when
composed together, form the original quartic map [9]. Consider g ◦ f where g =
(g1 (x1 , . . . , xm ), .., gm (x1 , . . . , xm ) , f = (f1 (x1 , . . . , xm ), .., fm (x1 , . . . , xm )
and each of the gi ’s and the fi ’s are homogeneous quadratic polynomials. The
first step is to find F = Span { fi : 1 ≤ i ≤ m }, a vector space over k.
Once found, one can select linearly independent quadratics from it, say
(f1 , . . . , fm
). Then by solving a set of linear equations, one can find (g1 , . . . , gm
)
such that ∀ 1 ≤ i ≤ m, gi ◦ f = gi ◦ f where f = (f1 , . . . , fm ).
The critical step of this process is finding F . The following definitions are
needed: D = Span { ∂x ∂
j
gi ◦ f (x1 , . . . , xm ) : 1 ≤ i, j ≤ m };
Λ = { xj f : 1 ≤ j ≤ m, f ∈ F }; R = { θ : ∀ 1 ≤ i ≤ m, xi θ ∈ D }. When
each of the fi ’s and gi ’s are homogeneous quadratic polynomials, D ⊆ Λ. This
is true basically because
∂
∂xj (gi ◦ f) = m
P ∂
∂wr gi (f ) × ∂
∂xj fr (x1 , . . . , xm )
r=1
∂ ∂
where ∂w r
gi (f ) is linear in the f ’s and ∂x j
f (x1 , . . . , xm ) is linear in the (x1 , . . . ,
xm ).
We calculate D and R from g ◦ f . If D = Λ, then R = F and this step is
complete. When D ⊂ Λ, R ⊂ F. Why R ⊆ F and D = Λ ⇐⇒ R = F should be
fairly easy to see.
Application of the partial derivative attack to RMPKC requires some addi-
tional work. As we saw in the explanation of the public key, we have access
to n + 1 polynomials of the form Pi = G̃i ◦ F̄ (x1 , . . . , xn ) where G̃i is a ho-
mogeneous quadratic polynomial and F̄ consists of non-homogeneous quadratic
polynomials. Our first step is to homogenize each of the Pi ’s, which effectively
homogenizes each of the F̄i ’s, yielding the following:
where each of the P̃i ’s are homogeneous quartic polynomials and each of the G̃i ’s
and F̃i ’s are homogeneous quadratic polynomials.
Then we begin the partial derivative attack, by calculating D from G̃i ◦
F̃ (x1 , . . . , xn+1 ). We never get D = Λ, due to the triangular structure of G and
the use of k which has characteristic 2. We are able to recover F by applying the
attack with a new method of projection of our functions to subplanes; the details
will be provided in the section that follows. After finding F , we de-homogenize
the space by setting xn+1 = 1.
The second challenge that the specifics of RMPKC present to the partial
derivative attack is the challenge to select the polynomials F1 , . . . , Fn+1
from
F |xn+1 =1 in such a way that they may be easily inverted. The procedure we
use to find such F1 , . . . , Fn+1
is described below. The process results in a linear
transformation L1 and a quadratic rational map F , which inverts in the same
Λ = { xj f : 1 ≤ j ≤ n + 1, f ∈ F } ⊂ H3
R = { f ∈ H2 : ∀1 ≤ i ≤ n + 1, xi f ∈ D }.
Since the polynomials of G̃ and F̃ are homogeneous quadratics, we are guar-
anteed D ⊆ Λ and R ⊆ F. We also have D = Λ ⇐⇒ R = F . Because of the
structure of the original polynomials in G and the use of a field of characteristic
2, we will always find D ⊂ Λ and therefore R ⊂ F. So we use the following
definitions of Γ and γ to help explain how to see what is happening with indi-
vidual f ’s in F , why they do not find themselves in R, and how we are going to
eventually find them with our alternative approach.
Γ (f ) = { θ ∈ H1 : θf ∈ D } and γ(f ) = dim( Γ (f ) ).
Clearly, f ∈ R ⇐⇒ γ(f ) = n+1. We always get γ(f ) ≤ n+1, and M in { γ(f ) :
f ∈ F } describes how far away from obtaining R = F for any given application
of RMPKC. For n = 5 and n = 6, we find M in { γ(f ) : f ∈ F } = n almost
every time. For n = 7 we usually get M in { γ(f ) : f ∈ F } = n − 1. And for
n ≥ 8 we most likely get M in { γ(f ) : f ∈ F } = n−2. Our alternative approach
works most simply for M in { γ(f ) : f ∈ F } = n. We will describe this now in
detail; then briefly show how we accomplish this for M in { γ(f ) : f ∈ F } < n.
We again start with the key definitions, valid ∀ 1 ≤ s ≤ n + 1; and we have
access to each Ds and Rs .
Cryptanalysis of Rational Multivariate Public Key Cryptosystems 131
Λs = { xi f : 1 ≤ i ≤ n + 1(i = s), f ∈ Fs } .
Rs = { f ∈ H2 : ∀ 1 ≤ i ≤ n + 1(i = s), xi f ∈ Ds } .
Γs (f ) = { θ ∈ H1 : θf ∈ Ds } , γs (f ) = dim( Γs (f ) ).
Now we always get Ds ⊆ Λs , Rs ⊆ Fs , and Ds = Λs ⇐⇒ Rs = Fs ⇐⇒
M in { γs (f ) : f ∈ Fs } = n. Fortunately for this attack, with high probability,
γs (f ) = M in { γ(f ), n } . This is a crucial point. At this time, we do not have
a mathematical explanation for why it is so; our experiments confirm it with
consistent results. Once we get ∀ 1 ≤ s ≤ n + 1, Rs = Fs , finding F is easy.
Let Rs+ = Rs + Span { xs xi : 1 ≤ i ≤ n + 1 } . When Rs = Fs , F ⊂ Rs+ .
n+1
T
Furthermore, if ∀ 1 ≤ s ≤ n + 1, Rs = Fs , then F = s=1 Rs+ , completing the
task of finding F .
For the cases of M in { γ(f ) : f ∈ F } < n, we expand our alternative
approach one or more levels further. Notice above the spaces Rs+ , which are
created by setting xs = 0, finding Ds and Rs , then adding Span { xs xi : 1 ≤ i ≤
n + 1 } . For n = 7, when we have M in { γ(f ) : f ∈ F } = n − 1, we use xs1 =
0 = xs2 where s1 = s2 . Following the same manner we form Ds1 ,s2 and Rs1 ,s2 .
Then we let Rs+1 ,s2 = Rs1 ,s2 + Span { xs1 xi : 1 ≤ i ≤ n +
T
1 } + Span { xs2 xi :
1 ≤ i ≤ n + 1 } . With consistency, we do get F = 1≤s1 ,s2 ≤n+1 Rs+1 ,s2 .
s1 =s2
For n ≥ 8, when we have M in { γ(f ) : f ∈ F } = n − 2, we use xs1 = 0 =
xs2 = 0 = xs3 where s1 = s2 = s3 = s1 . Following the same manner we form
Ds1 ,s2 ,s3 and Rs1 ,s2 ,s3 . Then we let Rs+1 ,s2 ,s3 = Rs1 ,s2 ,s3 + Span { xs1 xi : 1 ≤
i ≤ n + 1 } + Span { xs2 xi : 1 ≤ i ≤ T n + 1 } + Span { xs3 xi : 1 ≤ i ≤ n + 1 } .
Again we consistently get F = 1≤s1 ,s2 ,s3 ≤n+1 Rs+1 ,s2 ,s3 .
s1 =s2 =s3 =s1
and L1,n are the last two components of the linear transformation L1 . Next we
find the three-dimensional subspace of F which forms the core transformation,
2 2
i.e. let R = F ∩ Span { θn−1 , θn , θn−1 θn , θn−1
, θn , 1 }.
By construction, we know not only that ∃ R1 , R2 , R3 ∈ R such that R =
Span { R1 , R2 , R3 } and R3 ∈ Span { θn−1 2 , θn 2 , θn−1 θn , 1 } and R1 , R2 ∈
Span { θn−1 , θn , 1 } , but also that ∃ θn−1 , θn ∈ Span { θn−1
, θn } where
R1 , R2 ∈ Span { θn−1 , θn , 1 } and R3 ∈ Span { θn−1 θn , 1 } . Furthermore, R3
θn +bθn +c. We can find appropriately
2 2
can be chosen so that R3 = θn−1 +aθn−1
θn−1 = θn−1 + sθn and θn = θn−1 + tθn by finding the right values for s and t.
We solve for s and t by equating the quadratic terms of our chosen R3 , i.e.
θn−1 2
+ aθn−1 θn + bθn 2 = (θn−1
+ sθn )(θn−1
+ tθn ). So s + t = a and st = b.
Thus s(a − s) = b, i.e. s − as + b = 0. In characteristic 2, this last equation is
2
or equivalently
We equate the coefficients of the terms (1, xn−1 , xn , (xn−1 )2 , xn−1 xn , and
(xn−1 )2 xn ) and simultaneously solve for the α1 , . . . , α6 . In the same manner
we find β1 , . . . , β6 by starting with
F (xn−1 ,xn ) F (xn−1 ,xn )
β1 Fn−1
(x ,x )
+β2 F n (x ,x )
+β3
n+1 n−1 n n+1 n−1 n
x =n F (xn−1 ,xn ) F (xn−1 ,xn )
=
β4 Fn−1
(x ,x )
+β5 F n (x ,x )
+β6
n+1 n−1 n n+1 n−1 n
β1 Fn−1 (xn−1 ,xn ) +β2 Fn (xn−1 ,xn ) +β3 Fn+1 (xn−1 ,xn )
β4 Fn−1
(xn−1 ,xn ) +β5 Fn (xn−1 ,xn ) +β6 Fn+1
(xn−1 ,xn )
will be the quadratic polynomial in two variables such that Gn+1 (φn−1 , φn ) =
Ḡn+1 (x1 , . . . , xn , 1).
Now we randomly choose gn−1 , gn ∈ V such that V = Span { gi : n − 1 ≤ i ≤
n + 1 }. We then determine g1 , . . . , gn−2 and φ1 , . . . , φn−2 sequentially, by first
choosing gn−2 and φn−2 , then working our way to g1 and φ1 . Our procedure is
as follows:
134 J. Ding and J. Wagner
Step 2 clearly comprises the bulk of the run time. Finding of the exact denom-
1
inator of F takes almost all of this time, requiring 24 (16n6 + 131n5 + 440n4 +
3 2
595n + 419n + 114n) operations. However, step 1 has computational complex-
ity of O(n7 ) and step 3 has computational complexity of O(n9 ) so eventually at
higher values for n step 3 will comprise the bulk of the run time.
Remark. The steps above shows our attack is not a simple application of any
one existing attack method, let alone, just the Minrank attack alone. The key
is that we need first to accomplish a polynomial map decomposition and then
recover a subtle rational map decomposition equivalent to the original one, which
requires much more than the Minrank method. One more important point is
the direct algebraic attack, namely from the public key, we can derive a set of
polynomial equations once we are given the ciphertext, but these are degree
4 equations not degree 2 equations, whose computation complexity, as we
all know, is much higher than the case of degree 2 equations. This is further
complicated by the fact that we are working on the field of size of 232 , where
the field equations can not be used. This is confirmed by our experiments, for
example, Magma F 4 implementation failed to solve even the cases n = 5 on an
ordinary PC, which was proposed more than 20 years ago.
4 Conclusion
We develop a new improved 2R decomposition method to break the family of
rational multivariate public key cryptosystems proposed by Tsujii, Fujioka, and
Hirayama in 1989. We show that it is polynomial time to break this family of
cryptosystems in terms of the number of variables, the critical parameter of
the system. We demonstrate in experiments that our method is very efficient
and we can break the scheme originally suggested for practical applications in
a few seconds on a standard PC. The main contribution is that we develop new
techniques to improve the original 2R decomposition such that it can be used
successfully to attack a special family of rational maps. Although we defeat the
136 J. Ding and J. Wagner
References
1. International Workshop on Post-Quantum Cryptography. Katholieke Universiteit
Leuven, Belgium, May 24–26 (2006), [Link]
2. Faugere, J.-C., Perret, L.: Cryptanalysis of 2R- Schemes. In: Dwork, C. (ed.)
CRYPTO 2006. LNCS, vol. 4117, pp. 357–372. Springer, Heidelberg (2006)
3. Fell, H., Diffie, W.: Analysis of a public key approach based on polynomial sub-
stitution. In: Williams, H.C. (ed.) CRYPTO 1985. LNCS, vol. 218, pp. 340–349.
Springer, Heidelberg (1986)
4. Goubin, L., Patarin, J.: Asymmetric Cryptography with S-Boxes, Extended Ver-
sion, [Link]
5. Tsujii, S., Fujioka, A., Hirayama, Y.: Generalization of the public key cryptosys-
tem based on the difficulty of solving a system of non-linear equations. ICICE
Transactions (A) J72-A 2, 390–397 (1989), [Link]
6. Tsujii, S., Tadaki, K., Fujita, R.: Piece In Hand Concept for Enhancing the Security
of Multivariate Type Public Key Cryptosystems: Public Key Without Containing
All the Information of Secret Key, Cryptology ePrint Archive, Report 2004/366
(2004), [Link]
7. Tsujii, S., Kurosawa, K., Itoh, T., Fujioka, A., Matsumoto, T.: A public key cryp-
tosystem based on the difficulty of solving a system of nonlinear equations. ICICE
Transactions (D) J69-D 12, 1963–1970 (1986)
8. Lih-Chung, W., Yuh-Hua, H., Lai, F., Chun-Yen, C., Bo-Yin, Y.: Tractable rational
map signature. In: Vaudenay, S. (ed.) PKC 2005. LNCS, vol. 3386, pp. 244–257.
Springer, Heidelberg (2005)
9. Ye, D.F., Lam, K.Y., Dai, Z.D.: Cryptanalysis of 2R Schemes. In: Wiener, M. (ed.)
CRYPTO 1999. LNCS, vol. 1666, pp. 315–325. Springer, Heidelberg (1999)
10. Specifications of SFLASH, NESSIE documentation,
[Link]
Syndrome Based Collision Resistant Hashing
Matthieu Finiasz
ENSTA
1 Introduction
At Mycrypt 2005 Augot, Finiasz and Sendrier proposed a new “provably collision
resistant” family of hash functions [1]. This family, called Fast Syndrome Based
hash function (or simply FSB), is provably collision resistant in the sense that
finding a collision for FSB requires to solve a hard problem of coding theory,
namely, the Syndrome Decoding problem. However, even if finding collisions
requires to solve an NP-complete problem, some algorithms still exist to solve
it and choosing secure parameters for the function turned out to be harder
than expected. As a consequence, some attacks were found making some of the
originally proposed parameters unsafe. The aim of this article is to review the
different FSB variants and the various attacks against them, and to clearly point
out which parameters are insecure and which are not.
The FSB construction is based on the Merkle-Damgård design. Therefore, we
only describe the compression function which is then iterated in order to obtain
the hash function. As a result, if finding collisions for this compression function
is hard, then finding collisions for the full hash function will also be hard. The
goal of this design is to be able to reduce the problem of finding collisions to the
syndrome decoding problem.
The compression function is composed of two sub-functions:
– First a constant weight encoding function which takes the s input bits of the
compression function and outputs a binary word of length n and Hamming
weight w,
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 137–147, 2008.
c Springer-Verlag Berlin Heidelberg 2008
138 M. Finiasz
2 Description
As explained, the FSB compression function is composed of two sub-functions :
the constant weight encoding function takes s input bits and outputs a word of
length n and weight w, the syndrome computation function uses a binary matrix
H of size r × n and multiplies it by the previous low weight word to output r
bits.
kilobytes (if not a few megabytes), which is a lot for most constrained envi-
ronments. For this reason, an improved version was presented in [6], still using
regular words for constant weight encoding, but this time using a quasi-cyclic
binary matrix H.
Quasi-cyclic codes are very interesting as they decrease the size of the description
of the hash function a lot (a single line is enough). Moreover, it is proven in [8]
that when the size of the cyclic blocs is a prime p (and 2 is a generator of GF(p)),
these codes have properties similar to random codes.
Unfortunately, some of the parameters proposed in [6] were awkwardly se-
lected, making them subject to new attacks that we will present in the following
section.
3 Known Attacks
The aim of our hash function construction is to be collision resistant. As it
uses the Merkle-Damgård design, it is sufficient that our compression function is
collision resistant. We thus want to evaluate the complexity of the best collision
search algorithms against it. In practice, there are two ways to find a collision
in the FSB compression function:
– Either find a collision in the constant weight encoding algorithm: choosing
an injective encoding is enough to guarantee that no such collision exists,
– Or find two words of weight w having the same syndrome: that is, find two
words c and c such that H × c = H × c .
As our compression function needs to compress, this second type of collision
always exists, our goal is thus only to make them hard to find!
In other words, finding collisions for FSB requires to find a set of 2w or less
columns of H which XOR to zero.
this requires to either find a structure in H making this search easier, or find
a low weight code word in a random code (that is, assume that H contains no
specific structure making decoding easier).
For the original version of FSB, a truly random matrix is used for H, therefore,
the probability that a structure exists in H is negligible. For the quasi-cyclic
version, an obvious structure exists: the matrix is quasi-cyclic. Nevertheless, if
the quasi-cyclic length is well chosen, no specific decoding algorithm is known
and decoding can only be done as in a random code. However, as we will see in
Section 3.4, a bad choice for the quasi-cyclic length can make the search for low
weight code words much easier.
Considering no structure can be found in H, the best decoding algorithm for
a random binary code is the Canteaut-Chabaud algorithm [4]. This algorithm
is the most advanced of the information set decoding algorithms family and
is specifically designed to solve the hardest decoding instances, that is, finding
words of weight w close to the Gilbert-Varshamov bound when a single solution
exists. Here, the weights we are looking for are much larger (otherwise no com-
pression is possible) which places us in a domain where decoding is somehow
easier and where a large number of solutions exist. Giving a closed formula for
the complexity of this algorithm is very difficult, especially when many solutions
exist, but it is however possible to program an algorithm computing the best
possible work factor for a given set of parameters. Additionally, for the domain
of parameters we are considering, the Canteaut-Chabaud algorithm is almost
always slower than the generalized birthday technique we describe in the next
section. When choosing parameters we thus simply checked that the work factor
for this attack was above the expected security level, and this was always the case.
bits again and so on, until only two lists are left and the standard birthday
technique can be used. With this technique, collisions can be found in time/space
r
complexity of O(2 a+1 ), for any value of a such that enough elements are found
to populate the 2a starting lists.
Depending on s and r, the size of the input and output of the compression
function, it is easy to evaluate the largest possible value for a, and thus the
best possible complexity for this attack. There are s input bits to the function,
meaning that 2s different inputs exist. Thus, 2s words of weight w can be built.
w
The number L of different words of weight 2a−1 that can be built must thus
verify 2a−1 ≤ 2 . Additionally, if we want the attack to be possible, the size
L s
r
L of the starting lists must be large enough, meaning that we need L ≥ 2 a+1 .
Thus, any valid parameter a must verify:
r
2 a+1 r s a small 2a−1 s
≤ 2 s
⇐⇒ − a + 1 ≤ ⇐⇒ ≤ . (1)
2a−1 a+1 2a−1 a+1 r
For s = r, it is interesting to note that a = 3 verifies the inequality. If we want
the function to compress (that is, s > r), a = 3 will thus always be possible,
r
and a security higher than 2 4 is never possible. This is why a final compression
function (see Section 4.2) will always be necessary.
3.3 Linearization
The linearization attack against FSB was presented in [9]. The idea of this attack
is that when w becomes large enough, the problem of finding a collision can be
linearized in order to reduce it to a linear algebra problem. A collision can then
be found in polynomial time!
There are two forms to this attack: first the straight-forward linearization,
then a extension making it possible to use this attack in some cases where it
could not normally apply.
This is a linear system to solve and it is done in polynomial time. Thus, as soon
as 2w ≥ r, finding a collision for FSB can be done in polynomial time.
142 M. Finiasz
Extension of the Attack. When w < r2 , the previous attack can still be applied,
but the matrix H will no longer be square and the probability that a solution B
exists will probably be negligible. To improve this, one can use a larger alphabet:
instead of choosing two columns one can choose three columns of H at a time and
code two bits of B with them. However, three columns give three possibilities and
two bits of B require four columns (with the fourth column being the XOR of the
second and the third). Thus, each solution vector B using extended alphabets
will have probability 14 per set of three columns of being invalid. This solution
will thus increase the chance that a solution vector B can be found, but will
decrease the probability that this solution is realizable in practice. According
to [9], if 2w + 2w = r (with w ≤ w), the probability that a valid solution is
found is: 2w
3
× 0.28879 ! 2−0.830w −1.792 .
4
This attack is thus usable as soon as w ≥ r4 , but it will mostly be of interest
when w is close to r2 .
for the parameter a of Wagner’s algorithm is smaller than before, but the attack
applies to r bits only and the final complexity drops significantly. When selecting
parameters for FSB, it is important that such an attack cannot be applied.
4 Other Issues
4.1 IV Weakness
As pointed out in [7] another weakness of the original FSB compression function
lies in the way the input to the compression function is handled. In particular,
Syndrome Based Collision Resistant Hashing 143
the chaining bits (or IV) and the message bits are simply concatenated, and
no mixing whatsoever is applied. When using regular words, this means that
the output of the compression function is simply the XOR of two independent
hashes: one resulting from the IV bits, the other one from the message bits. If
one can find a collision on the message part of the compression function (this will
be somehow harder than a normal collision as less input bits are available), then
this collision is IV independent. This has no influence on the collision resistance
of the function, but it is a problem when using the hash function as a MAC or
as a PRF for example: the resistance to some attacks falls from the cost of an
inversion (or second preimage) to the cost of building a message only collision
(which will probably be just above the cost for building a standard collision).
In order to avoid such problems, the best thing would be to mix the input bits
through a diffusion function. However, such a mixing is quite costly and would
severely reduce the throughput of the hash function. The best solution is thus
probably to integrate this diffusion in the constant weight encoding function. As
stated in Section 5.1, a simple interleaving of the message bits with the IV bits
is enough to avoid this problem.
5 Possible Candidates
5.1 Constant Weight Encoding
There are many ways to perform constant weight encoding, spanning from the
one to one encoding where all words of weight w are equiprobable, to the regular
word encoding. The first one is the most bit efficient (the compression function
will have the largest possible input for some given parameters n and w), the
second one is the fastest. When dealing with hash functions, speed is usually
a very important factor and fast constant weight encoding would be a natural
choice, however, concerning security, all results on the hardness of syndrome
decoding consider random words of weight w, not regular words (or words with
any other structure). Luckily, when looking for collisions, a collision for any
given constant weight encoding is also a collision for the one to one encoding:
any pair of words of weight w (even with a strong structure) can be coded with
the one to one equiprobable encoding. Thus, finding collisions for FSB using
regular words can not be easier than finding collisions for FSB using a more bit
efficient encoding.
However, no proof can be given that finding collisions for regular words is
indeed harder than with the one to one equiprobable encoding. Thus, when
choosing parameters for FSB, we will consider the security of FSB with one to
one constant weight encoding, even if a faster encoding is used in practice.
The conclusion of this is that using regular word encoding is certainly the
best choice for efficiency. However, as seen in Section 4.1, using such an encoding
causes IV weakness issues. In order to avoid these issues it is necessary that every
index of a non-zero bit of the constant weight word depends from the value of
both the IV and the message. This way, no IV independent collision can be built.
Interleaving the bits coming from the IV (or chaining value) with those of the
message is thus a solution. Depending on the parameters chosen for the function,
different interleavings will be possible.
With this definition, any matrix H built of blocks which are Toeplitz matrices
will be a truncated quasi-cyclic matrix with p > 2r, but in order to be as close
as possible to standard quasi-cyclic matrices, we will always choose r very close
to p. Then, the description of the r × n matrix H can be reduced to a “first line”
of nr × p bits and the values of p and r.
As explained in [8], in order for p to be a suitable choice it must be prime,
and 2 must be a generator of GF(p). Hence, it is easy to check the best p for
a given r: one simply needs to test the primes greater than r one by one until
2 is a generator. For example, for r = 512 we get p = 523, for r = 768 we get
p = 773 and for r = 1024 we get p = 1061.
Parameters for 80-bit Security. Choosing r = 512 and a security of 280 against
collisions we get from Equation (1) that s ≤ 1688. Now, to avoid linearization
attacks we need w ≤ r4 = 128. If we choose w = 128, we get for n = 218 a value
s = 1587 which is suitable. Our first proposition is thus to use:
with regular word encoding, and a truncated quasi-cyclic matrix with p = 523.
For the IV interleaving, each of the w positions are coded by 11 input bits,
4 of which are taken from the IV and the rest from the message. With these
parameters FSB reads input blocs of 896 bits and outputs 512 bits. These bits
can then be compressed to 160 bits using a suitable final compression function.
The matrix H is described by 267 776 bits (∼ 32.7kB).
146 M. Finiasz
Parameters for 128-bit Security. For 128-bit security we need r larger than 512.
We can use r = 768 and obtain s ≤ 2048. If we pick w = 192 and n = 3 × 215 we
get s = 1999 and linearization attacks are impossible. Our proposition is to use:
with regular word encoding, and a truncated quasi-cyclic matrix with p = 773.
Each position is coded using 9 input bits, so the IV interleaving will take 4 bits
from the IV and 5 bits from the message each time. FSB thus reads input blocs
of 960 bits and output 768 bits which, at the end, need to be compressed to 256
bits. The matrix H is described by 98 944 bits (∼ 12kB).
The same parameters, using a shorter n = 3 × 214 will probably be more
efficient as each position will be coded with 8bits, 4 from the IV and 4 from the
message, even if only 768 bit blocs are read instead of 960 bit blocs. Moreover,
it will have a shorter description (∼ 6kB) and the security against collisions will
be a little higher (about 2133 ).
6 Conclusion
Taking into account all the different attacks against FSB, it is still possible
to select parameters that offer both a high level of security (relying on well
identified problems) and a satisfying efficiency. Also, apart from the choice of
the final compression function, the other choices that had to be made for FSB
seem clear: use regular word encoding (with IV interleaving) and a truncated
quasi-cyclic matrix. For the final compression function, using a provably secure
pseudo-random generator could be a good choice: use the output of FSB as
an IV and generate the desired number of bits of output. One could then use
the generators of Blum-Blum-Shub [3], or preferably for post-quantum security
QUAD [2].
References
1. Augot, D., Finiasz, M., Sendrier, N.: A family of fast syndrome based cryptographic
hash functions. In: Dawson, E., Vaudenay, S. (eds.) Mycrypt 2005. LNCS, vol. 3715,
pp. 64–83. Springer, Heidelberg (2005)
2. Berbain, C., Gilbert, H., Patarin, J.: QUAD: a practical stream cipher with prov-
able security. In: Vaudenay, S. (ed.) EUROCRYPT 2006. LNCS, vol. 4004, pp.
109–128. Springer, Heidelberg (2006)
3. Blum, L., Blum, M., Shub, M.: Comparison of two pseudo-random number gen-
erators. In: Chaum, D., Rivest, R.L., Sherman, A. (eds.) Crypto 1982, pp. 61–78.
Plenum (1983)
4. Canteaut, A., Chabaud, F.: A new algorithm for finding minimum-weight words in
a linear code: Application to McEliece’s cryptosystem and to narrow-sense BCH
codes of length 511. IEEE Transactions on Information Theory 44(1), 367–378
(1998)
Syndrome Based Collision Resistant Hashing 147
5. Coron, J.-S., Joux, A.: Cryptanalysis of a provably secure cryptographic hash func-
tion. IACR eprint archive (2004), [Link]
6. Finiasz, M., Gaborit, P., Sendrier, N.: Improved fast syndrome based cryptographic
hash functions. In: Rijmen, V. (ed.) ECRYPT Workshop on Hash Functions (2007)
7. Fouque, P.-A., Leurent, G.: Cryptanalysis of a hash function based on quasi-cyclic
codes. In: Malkin, T. (ed.) CT-RSA 2008. LNCS, vol. 4964, pp. 19–35. Springer,
Heidelberg (2008)
8. Gaborit, P., Zémor., G.: Asymptotic improvement of the Gilbert-Varshamov bound
for linear codes. In: IEEE Conference, ISIT 2006, pp. 287–291 (2006)
9. Saarinen, M.-J.O.: Linearization attacks against syndrome based hashes. In: Sri-
nathan, K., Rangan, C.P., Yung, M. (eds.) INDOCRYPT 2007. LNCS, vol. 4859,
pp. 1–9. Springer, Heidelberg (2007)
10. Wagner, D.: A generalized birthday problem. In: Yung, M. (ed.) CRYPTO 2002.
LNCS, vol. 2442, pp. 288–304. Springer, Heidelberg (2002)
Nonlinear Piece In Hand Perturbation Vector
Method for Enhancing Security of Multivariate
Public Key Cryptosystems
1 Introduction
Multivariate Public Key Cryptosystems (MPKCs, for short) originally proposed
in 80’s as possible alternatives to the traditional, widely-used public key cryp-
tosystems, such as RSA and ElGamal cryptosystems. One of the motivations for
researching MPKC is that the public key cryptosystems based on the intractabil-
ity of prime factorization or discrete logarithm problem are presently assumed
to be secure, but their security will not be guaranteed in the quantum computer
age. On the other hand, no quantum algorithm is known so far to be able to
solve efficiently the underlying problem of MPKCs, i.e., the problem of solving a
set of multivariate quadratic or higher degree polynomial equations over a finite
field.
Since the original research of MPKCs was started, many new schemes have
been proposed so far. At the same time, many new methods to cryptanalyze
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 148–164, 2008.
c Springer-Verlag Berlin Heidelberg 2008
Nonlinear Piece In Hand Perturbation Vector Method 149
MPKCs have also been discovered. Recently, for the purpose of resisting these
attacks, the research on the method for enhancing security of MPKCs is becom-
ing one of the main themes of this area. The piece in hand (PH, for short) matrix
method aims to bring the computational complexity of cryptanalysis close to ex-
ponential time by adding random polynomial terms to original MPKC. The PH
methods were introduced and studied in a series of papers [27, 28, 29, 30, 31, 32,
33, 34]. Among them, there are primary two types of the PH matrix methods;
the linear PH matrix methods and the nonlinear PH matrix methods. In par-
ticular, the papers [31, 32, 33, 34] proposed the linear PH matrix method with
random variables and the nonlinear PH matrix method, and showed that these
PH matrix methods lead to the substantial gain in security against the Gröbner
basis attack under computer experiments.
Because of the nonlinearity of the PH matrix, the nonlinear PH matrix meth-
ods are expected to enhance the security of the original MPKC more than the lin-
ear PH matrix methods in general. Thus, in the present paper, we propose a new
PH method, called NonLinear Piece in Hand Perturbation Vector (NLPHPV, for
short) method, which can be applied to both encryption schemes and signature
schemes in general.1 The adopted application of perturbation vector is similar to
the internal perturbation method [3] and the construction of R-SE(2)PKC [13],
where random transformation is mixed with the “non-singular” transformation.
In particular, on the internal perturbation method, computational complexity
by the Gröbner basis attack is reported in [5], the paper showed that when r
is not too small (i.e., r 6), the perturbed Matsumoto-Imai cryptosystem [3]
is secure against the Gröbner basis attack, where r is the perturbation dimen-
sion. Note, however, that in exchange for enhancing the security, the decryption
process of the internal perturbation method becomes q r times slower than un-
perturbed one, where q is the number of field elements. This fact contrasts with
our NLPHPV method in a sense that it does not require repeated processes of
decryption process which grows exponentially, though the cipher text size be-
comes slightly large. From this point of view of efficiency, NLPHPV method can
be a good alternative to the internal perturbation method. We also discuss on
security benefit of the NLPHPV method against major known attacks, i.e., the
Gröbner basis attack, the rank attack [37], and the differential attack [9]. Based
on also our security considerations, we suggest concrete parameter sizes for the
NLPHPV method.
This paper is organized as follows. We begin in Section 2 with some basic
notation and a brief introduction of the schemes of MPKCs in general. We in-
troduce the NLPHPV method in Section 3. We then show, based on computer
experiments, that the NLPHPV method properly provides substantial security
against the Gröbner basis attack in Section 4. We discuss the immunity of the
NLPHPV method against known attacks in Section 5. Based on the discussion,
we suggest parameters for the NLPHPV method in Section 6. We conclude this
paper with the future direction of our work in Section 7.
1
In signature scheme, the parameters of the NLPHPV method are restricted to some
region. We will deal with the issue in Section 3 and Subsection 5.2.
150 R. Fujita, K. Tadaki, and S. Tsujii
2 Preliminaries
In this section we review the schemes of MPKCs in general after introducing
some notations about fields, polynomials, and matrices.
2.1 Notations
We represent a column vector in general by bold face symbols such as p, E, and
X.
– Fq : finite field which has q elements with q ≥ 2.
– Fq [x1 , . . . , xk ]: set of all polynomials in variables x1 , x2 , . . . , xk with coeffi-
cients in Fq .
– S n×l : set of all n × l matrices whose entries are in a nonempty set S with
positive integers n and l. Let S n×1 = S n .
– S n : set of all column vectors consisting n entries in S.
– AT ∈ S l×n : transpose of A for matrix A ∈ S n×l .
– f (g) = (h1 , . . . , hn )T ∈ Fq [x1 , . . . , xm ]n : substitution of g for the variables
in f , where f = (f1 , . . . , fn )T ∈ Fq [x1 , . . . , xk ]n , g = (g1 , . . . , gk )T ∈
Fq [x1 , . . . , xm ]k are polynomial column vectors. Each hi is the polynomial in
Fq [x1 , . . . , xm ] obtained by substituting g1 , . . . , gk for the variables x1 , . . . , xk
in fi , respectively.
– f (p) ∈ Fq n : vector obtained by substituting p1 , . . . , pk for the variables
x1 , . . . , xk in f , respectively, for f ∈ Fq [x1 , . . . , xk ]n and p ∈ Fq k , where
p = (p1 , . . . , pk )T with p1 , . . . , pk ∈ Fq .
k
- z
-
plain text in
original MPKC K z
p z−p p z−p
- - - -
p u
x µ λ u1 u2
plain text
random
- variables plain text
-
random number
-
variables
t z−p−t
- t
z
x Aµ p y = Au1
- - - -
p k−p p k−p
public key
plain text computation
„ « e
cipher text
p ∈ Fq p - p E - ec ∈ Fq g
∈ Fq z
Z
}
Z u
Z >
Z
Z secret key
Z
original MPKC
Z computation
Z „ « secret key of
random number Z p original MPKC
u ∈ Fq z−p ∈ Fq k c ∈ Fq n
y
6
E: public key of original MPKC
The encryption and decryption processes in the NLPHPV method are schemat-
ically represented in Figure 3.
4 Experimental Results
We report in Table 1 and Table 2 the time required for the GB attack against
the perturbed Matsumoto-Imai-Plus cryptosystem (PMI+, for short) [6] and the
Matsumoto-Imai cryptosystem (MI, for short) [18] enhanced by the NLPHPV
method. Note that n = k and q = 2 for the public keys E ∈ Fq [x1 , . . . , xk ]n
of MI by its specification. We deal with the case of p = z = k, f = l in
0 „ «1
„«„ « p
D0x D
2
The equation is replaced with =@ u1 A for unknown x and λ
C λ
f (z)
when the matrix D above is randomly chosen.
Nonlinear Piece In Hand Perturbation Vector Method 155
5 Discussion on Security
In this section, we discuss the security of the NLPHPV method against major
known attacks. The main purpose of this section is to enclose the secure pa-
rameter region of the NLPHPV method by both theoretical and experimental
observations.
3
The optimal choice of H is still open. We will clarify this point in the future work.
156 R. Fujita, K. Tadaki, and S. Tsujii
5.1 GB Attack
In 2004 Wolf, Braeken, and Preneel [37] introduced an attack against a class of
MPKCs, called step-wise triangular schemes (STS, for short), based on the rank
calculation of the public key (see also [1, 10, 23]). On the other hand, recently,
Ito, Fukushima, and Kaneko [11] proposed an attack against the MPKC which
is obtained by applying the linear PH matrix method to the sequential solution
method as an original MPKC. Their attack makes use of an STS-like structure
of the MPKC.
In fact, the structure of the public key of the NLPHPV method can be seen as
a gSTS (general step-wise ⎛ triangular
⎞ structure) [37]. The detailed description is
C
⎜ Ip 0 ⎟
given below. Let A = ⎜ ⎟
⎝ 0 A 0 ⎠ ∈ Fq
z×z
be an invertible matrix, where A, C
R
are as in Section 3, Ip is the identity matrix in Fq p×p , and R is a specific matrixin
x
Fq (z−k−f )×z . For A , we define x = (x1 , . . . , xf , . . . , xf +k , . . . , xz )T = A ,
def λ
where x, λ are as in Section 3. Let x1 = (x1 , . . . , xf )T , x2 = (xf +1 , . . . , xf +k )T ,
T x x
and x3 = (xf +k+1 , . . . , xz ) be parts of x . Then, x1 = C , x2 = ,
λ Aµ
where µ is as in Section 3. We denote H = (h1 , . . . , hl ) ∈ Fq [x1 , . . . , xf ] ,
T l
, = By , where E,
We denote y = (y1 , . . . , yg )T . Then, E , B are as in Section 3.
In this gSTS, the number of layers is 3, the numbers of new variables (step-
width) are f , k, z − k − f , and the numbers of equations (step-height) are l, n,
h, respectively. This structure may bring down undesirable vulnerability against
the rank attack. In the following, we discuss the security of the NLPHPV method
against two rank attacks; high rank attack and low rank attack.
High Rank Attack. In the high rank attack against the gSTS, to separate
the part of Step 3 in (2) from the public key, the attacker searches vectors
v = (v1 , . . . , vg )T ∈ Fq g . The vectors form together an invertible matrix whose
row is a row of the secret key B −1 or its linear equivalent copy, since multiplying
B −1 to the public key E , separates their layers. The attacker can find each of
the vectors v with a probability 1/q h by checking whether
g
rank vi Pi ≤ f + k,
i=1
Low Rank Attack. In the low rank attack against the gSTS, the attacker can
find w = (w1 , . . . , wg )T ∈ Fq z with a probability 1/q f by checking whether the
unknown v = (v1 , . . . , vg ) has f solutions in equation
g
vi Pi w = 0,
i=1
Parameters
q p k n z g f l h t Public Key Size
Encryption scheme 256 260 260 8.89 MB
The enhanced encryption scheme 256 256 260 260 420 300 20 20 20 82 26.65 MB
by the NLPHPV method
Signature scheme 256 30 20 9.92 KB
The enhanced signature scheme 256 30 20 50 30 20 39.78 KB
by the NLPHPV method
Nonlinear Piece In Hand Perturbation Vector Method 159
In recently proposed major MPKCs, public key sizes for encryption schemes
are 175 KB in PMI+ [6] and 160.2 KB in IC i+ [7], and for signature schemes 15
KB in Rainbow [4] and 9.92 KB in IC- [7]. The main purpose of these schemes
is to implement them on small devices with limited computing resources. On
the other hand, we assume the situation in the future when quantum comput-
ers appear, and place much more value on the security than the efficiency, such
as the reduction of key size. Let us consider the security level of the quan-
tum computer age where quantum computers are available. Then, the simple
application of the Grover’s algorithm to√exhaustive search of 2N candidates re-
duces the time complexity O(2N ) to O( 2N ). On the other hand, nowadays, the
exhaustive search of 280 candidates is thought to be impossible and the com-
plexity 280 is selected as the standard security level in present cryptographic
community. Therefore, we assume that the security level of the quantum com-
puter age is greater than the complexity 2160 . Note that we omit the evalu-
ation of the size of secret key below. This is because the size of secret key
of a MPKC is much smaller than that of public key and different in various
MPKCs.
7 Concluding Remarks
In this paper, we proposed a new class of PH methods called NonLinear Piece in
Hand Perturbation Vector (NLPHPV) method. NLPHPV is more efficient than
previously known internal perturbation methods in terms of the decryption pro-
cess avoiding redundant repetitive steps. Based on computer experiments, we
have shown the enhancement of the security of the Matsumoto-Imai cryptosys-
tem by the method against the Gröbner basis attack. Then, by considering the
security against known other attacks, we have suggested a secure parameter set-
ting of the NLPHPV method for the quantum computer age. From the practical
view point of current interest, it is also important to evaluate the efficiency of
both encryption and decryption in the cryptosystem enhanced by the method.
However, since the aim of the present paper is mainly to develop the framework
of nonlinear PH matrix methods as a potential countermeasure against the ad-
vent of quantum computers in the future, this practical issue is not considered
in this paper but discussed in another paper. Because of the same reason, we
have not considered some provable security, for example IND-CCA of the class
of PH methods for encryption but considered just the encryption primitive E ,
for an MPKC which is obtained by applying the NLPHPV method. We leave
the consideration of the stronger security to a future study.
Acknowledgments
The authors are grateful to Dr. Tomohiro Harayama and Mr. Masahito Gotaishi
for helpful discussions and comments.
This work is supported by the “Strategic information and COmmunications
R&D Promotion programmE” (SCOPE) from the Ministry of Internal Affairs
and Communications of Japan.
References
1. Coppersmith, D., Stern, J., Vaudenay, S.: Attacks on the birational permutation
signature schemes. In: Stinson, D.R. (ed.) CRYPTO 1993. LNCS, vol. 773, pp.
435–443. Springer, Heidelberg (1994)
2. Courtois, N., Klimov, A., Patarin, J., Shamir, A.: Efficient algorithms for solving
overdefined systems of multivariate polynomial equations. In: Preneel, B. (ed.)
EUROCRYPT 2000. LNCS, vol. 1807, pp. 392–407. Springer, Heidelberg (2000)
3. Ding, J.: A new variant of the Matsumoto-Imai cryptosystem through perturba-
tion. In: Bao, F., Deng, R., Zhou, J. (eds.) PKC 2004. LNCS, vol. 2947, pp. 305–318.
Springer, Heidelberg (2004)
4. Ding, J., Schmidt, D.: Rainbow, a new multivariable polynomial signature scheme.
In: Ioannidis, J., Keromytis, A., Yung, M. (eds.) ACNS 2005. LNCS, vol. 3531, pp.
164–175. Springer, Heidelberg (2005)
5. Ding, J., Gower, J.E., Schmidt, D., Wolf, C., Yin, Z.: Complexity estimates for
the F4 attack on the perturbed Matsumoto-Imai cryptosystem. In: Smart, N. (ed.)
Cryptography and Coding 2005. LNCS, vol. 3796, pp. 262–277. Springer, Heidel-
berg (2005)
Nonlinear Piece In Hand Perturbation Vector Method 161
6. Ding, J., Gower, J.E.: Inoculating multivariate schemes against differential attacks.
In: Yung, M., Dodis, Y., Kiayias, A., Malkin, T. (eds.) PKC 2006. LNCS, vol. 3958,
pp. 290–301. Springer, Heidelberg (2006)
7. Ding, J., Wolf, C., Yang, B.Y.: -Invertible Cycles for Multivariate Quadratic
(MQ) public key cryptography. In: Okamoto, T., Wang, X. (eds.) PKC 2007.
LNCS, vol. 4450, pp. 266–281. Springer, Heidelberg (2007)
8. Faugère, J.C., Joux, A.: Algebraic cryptanalysis of hidden field equation (HFE)
cryptosystems using Gröbner bases. In: Boneh, D. (ed.) CRYPTO 2003. LNCS,
vol. 2729, pp. 44–60. Springer, Heidelberg (2003)
9. Fouque, P.A., Granboulan, L., Stern, J.: Differential cryptanalysis for multivariate
schemes. In: Cramer, R. (ed.) EUROCRYPT 2005. LNCS, vol. 3494, pp. 341–353.
Springer, Heidelberg (2005)
10. Goubin, L., Courtois, N.: Cryptanalysis of the TTM cryptosystem. In: Okamoto, T.
(ed.) ASIACRYPT 2000. LNCS, vol. 1976, pp. 44–57. Springer, Heidelberg (2000)
11. Ito, D., Fukushima, Y., Kaneko, T.: On the security of piece in hand concept
based on sequential solution method. Technical Report of IEICE, ISEC2006-30,
SITE2006-27 (2006-7) (July 2006) (in Japanese)
12. Kasahara, M., Sakai, R.: A new principle of public key cryptosystem and its real-
ization. Technical Report of IEICE, ISEC2000-92 (2000-11) (November 2000) (in
Japanese)
13. Kasahara, M., Sakai, R.: A construction of public key cryptosystem for realizing
ciphertext of size 100 bit and digital signature scheme. IEICE Transactions on
Fundamentals E87-A(1), 102–109 (2004)
14. Kasahara, M., Sakai, R.: A construction of public-key cryptosystem based on singu-
lar simultaneous equations. IEICE Transactions on Fundamentals E88-A(1), 74–80
(2005)
15. Kipnis, A., Patarin, J., Goubin, L.: Unbalanced Oil and Vinegar signature schemes.
In: Stern, J. (ed.) EUROCRYPT 1999. LNCS, vol. 1592, pp. 206–222. Springer,
Heidelberg (1999)
16. Kipnis, A., Shamir, A.: Cryptanalysis of the HFE public key cryptosystem by
relinearization. In: Wiener, M. (ed.) CRYPTO 1999. LNCS, vol. 1666, pp. 19–30.
Springer, Heidelberg (1999)
17. Matsumoto, T., Imai, H., Harashima, H., Miyakawa, H.: A class of asymmetric
cryptosystems using obscure representations of enciphering functions. In: 1983 Na-
tional Convention Record on Information Systems, IECE Japan, pp. S8–5 (1983)
(in Japanese)
18. Matsumoto, T., Imai, H.: Public quadratic polynomial-tuples for efficient signature-
verification and message-encryption. In: Günther, C.G. (ed.) EUROCRYPT 1988.
LNCS, vol. 330, pp. 419–453. Springer, Heidelberg (1988)
19. Moh, T.T.: A public key system with signature and master key functions. Com-
munications in Algebra 27, 2207–2222 (1999)
20. Patarin, J.: Cryptanalysis of the Matsumoto and Imai public key scheme of Euro-
crypt 1988. In: Coppersmith, D. (ed.) CRYPTO 1995. LNCS, vol. 963, pp. 248–261.
Springer, Heidelberg (1995)
21. Patarin, J.: Hidden fields equations (HFE) and isomorphisms of polynomials (IP):
two new families of asymmetric algorithms. In: Maurer, U.M. (ed.) EUROCRYPT
1996. LNCS, vol. 1070, pp. 33–48. Springer, Heidelberg (1996)
∗
22. Patarin, J., Goubin, L., Courtois, N.: C−+ and HM : Variations around two schemes
of T. Matsumoto and H. Imai. In: Ohta, K., Pei, D. (eds.) ASIACRYPT 1998.
LNCS, vol. 1514, pp. 35–49. Springer, Heidelberg (1998)
162 R. Fujita, K. Tadaki, and S. Tsujii
23. Shamir, A.: Efficient signature schemes based on birational permutations. In: Stinson,
D.R. (ed.) CRYPTO 1993. LNCS, vol. 773, pp. 1–12. Springer, Heidelberg (1994)
24. Tadaki, K., Tsujii, S.: On the enhancement of security by piece in hand matrix
method for multivariate public key cryptosystems. In: Proc. SCIS 2007, vol. 2C1-3
(2007)
25. Tsujii, S., Kurosawa, K., Itoh, T., Fujioka, A., Matsumoto, T.: A public-key cryp-
tosystem based on the difficulty of solving a system of non-linear equations. IECE
Transactions (D) J69-D(12), 1963–1970 (1986) (in Japanese)
26. Tsujii, S., Fujioka, A., Hirayama, Y.: Generalization of the public-key cryptosys-
tem based on the difficulty of solving a system of non-linear equations. IEICE
Transactions (A) J72-A(2), 390–397 (1989) (in Japanese) (An English translation
of [26] is included in [29] as an appendix)
27. Tsujii, S.: A new structure of primitive public key cryptosystem based on soldiers
in hand matrix. Technical Report TRISE 02-03, Chuo University (July 2003)
28. Tsujii, S., Fujita, R., Tadaki, K.: Proposal of MOCHIGOMA (piece in hand) con-
cept for multivariate type public key cryptosystem. Technical Report of IEICE,
ISEC2004-74 (2004-09) (September 2004)
29. Tsujii, S., Tadaki, K., Fujita, R.: Piece in hand concept for enhancing the security
of multivariate type public key cryptosystems: public key without containing all the
information of secret key. Cryptology ePrint Archive, Report 2004/366 (December
2004), [Link]
30. Tsujii, S., Tadaki, K., Fujita, R.: Piece in hand concept for enhancing the security
of multivariate type public key cryptosystems: public key without containing all
the information of secret key. In: Proc. SCIS 2005, vol. 2E1-3, pp. 487–492 (2005),
[Link] tsujii/[Link]
31. Tsujii, S., Tadaki, K., Fujita, R.: Proposal for piece in hand (soldiers in hand)
matrix — general concept for enhancing security of multivariate public key cryp-
tosystems — Ver.2. In: Proc. SCIS 2006, vol. 2A4-1 (2006) (in Japanese),
[Link] tsujii/[Link]
32. Tsujii, S., Tadaki, K., Fujita, R.: Proposal for piece in hand matrix ver.2: gen-
eral concept for enhancing security of multivariate public key cryptosystems. In:
Workshop Record of the International Workshop on Post-Quantum Cryptography
(PQCrypto 2006), pp. 103–117 (2006),
[Link]
33. Tsujii, S., Tadaki, K., Fujita, R.: Proposal for piece in hand matrix: general concept
for enhancing security of multivariate public key cryptosystems. IEICE Transac-
tions on Fundamentals E90-A(5), 992–999 (2007),
[Link] tsujii/[Link]
34. Tsujii, S., Tadaki, K., Fujita, R.: Nonlinear piece in hand matrix method for en-
hancing security of multivariate public key cryptosystems. In: Proceedings of the
First International Conference on Symbolic Computation and Cryptography (SCC
2008), pp. 124–144 (2008)
35. Wang, L.C., Hu, Y.H., Lai, F., Chou, C.Y., Yang, B.Y.: Tractable rational map sig-
nature. In: Vaudenay, S. (ed.) PKC 2005. LNCS, vol. 3386, pp. 244–257. Springer,
Heidelberg (2005)
36. Wang, L.C., Yang, B.Y., Hu, Y.H., Lai, F.: A medium-field multivariate public-key
encryption scheme. In: Pointcheval, D. (ed.) CT-RSA 2006. LNCS, vol. 3860, pp.
132–149. Springer, Heidelberg (2006)
37. Wolf, C., Braeken, A., Preneel, B.: Efficient cryptanalysis of RSE(2)PKC and
RSSE(2)PKC. In: Blundo, C., Cimato, S. (eds.) SCN 2004. LNCS, vol. 3352, pp.
294–309. Springer, Heidelberg (2005)
Nonlinear Piece In Hand Perturbation Vector Method 163
38. Wolf, C., Preneel, B.: Taxonomy of Public Key Schemes based on the problem
of Multivariate Quadratic equations. Cryptology ePrint Archive, Report 2005/077
(December 2005), [Link]
Table 4. Comparison between computational times of the GB attack for MI and the
enhanced MI by the NLPHPV method
Table 5. Comparison between computational times of the GB attack for RSE and the
enhanced RSE by the NLPHPV method
1 Introduction
the result looks random, i.e., close to the fully mixed state, R(σ) ≈ I/d, this
cipher can safely be transmitted on an insecure channel. This procedure is called
approximate quantum state randomization or approximate quantum one-time
pad [1, 2, 3] or quantum one-time pad, quantum Vernam cipher or quantum
private channel in the case of perfect security [4, 5, 6], and is the quantum
equivalent of the classical one-time pad.
An encryption scheme which uses such a randomization procedure is called
symmetric, because the same key is used to encrypt and decrypt the message.
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 165–180, 2008.
c Springer-Verlag Berlin Heidelberg 2008
166 A. Kawachi and C. Portmann
of message size and number of usages of the same encryption key to quantum
state randomization schemes which use only classical keys.
2 Encryption Model
2.1 Quantum Encryption Keys
Let us consider a setting in which we have two parties, a sender and a receiver,
who wish to transmit a quantum state, σ, from one to the other in a secure way
over an insecure channel. If they share a secret classical string, k, they can ap-
ply some completely positive, trace-preserving (CPTP) map Ek to the quantum
message and send the cipher Ek (σ). If the key k was chosen with probability pk ,
to any person who does not know this key the transmitted state is
R(σ) = pk Ek (σ), (4)
k
which will look random for “well chosen” maps Ek . This is the most general from
of quantum state randomization [6].
If instead the sender has a quantum state ρk , he can apply some CPTP map
E to both the shared state and the quantum message, and send E(ρk ⊗ σ). So
for someone who does not know ρk the state sent is
R(σ) = pk E(ρk ⊗ σ). (5)
k
On the Power of Quantum Encryption Keys 169
It is clear that Eqs. (4) and (5) produce equivalent ciphers, because for every
set of CPTP maps {Ek }k there exists a map E and set of states {ρk }k such
that for all messages σ, Ek (σ) = E(ρk ⊗ σ), and vice versa. The difference lies
in the knowledge needed to perform the encryption. In the first case (Eq. (4))
the sender needs to know the secret key k to know which CPTP map Ek to
apply. In the second case (Eq. (5)) the sender only needs to hold a copy of the
encryption key ρk , he does not need to know what it is or what secret key k it
corresponds to. This allows us to construct in Section 2.2 a quantum asymmetric-
key cryptosystem in which copies of the same encryption key ρk can be used by
many different users. In this section we focus on the symmetric-key model and
define quantum state randomization (QSR) schemes with quantum encryption
keys and their security in this model.
Definition 2. A QSR scheme given by the tuple T = (PK , {ρk }k∈K , E) is said
to be invertible on the set S ⊆ B(HS ) if for every k ∈ K with PK (k) > 0 there
exists a CPTP map Dk : B(HC ) → B(HS ) such that for all density operators
σ ∈ S,
Dk E(ρk ⊗ σ) = σ.
Furthermore, a QSR scheme must – as its name says – randomize a quantum
state. We define this in the same way as previous works on approximate quantum
state randomization [1, 2, 3], by bounding the distance between the ciphers
averaged over all possible choices of key and some state independent from the
170 A. Kawachi and C. Portmann
message. We however generalize this to encrypt t messages with the same key,
because the asymmetric-key model we define Section 2.2 will need this. It is
always possible to consider the case t = 1 in the symmetric-key model, if multiple
uses of the same key are not desired.
We will use the trace norm as distance measure between two states, because it
is directly related to the probability that an optimal measurement can distinguish
between these two states, and is therefore meaningful in the context of√eaves-
dropping. The trace norm of a matrix A is defined by Atr := tr |A| = tr A† A,
which is also equal to the sum of the singular values of A.
Definition 3. A QSR scheme given by the tuple T = (PK , {ρk }k∈K , E) is said to
be (t, )-randomizing on the set S ⊆ B(HS ) if there exists a density operator τ ∈
⊗t
B HC such that for all t-tuples of message density operators ω = (σ1 , . . . , σt ) ∈
×t
S
R(ω) − τ tr ≤ , (6)
where R(ω) = k PK (k)ρk,σ1 ⊗ · · · ⊗ ρk,σt and ρk,σi = E(ρk ⊗ σi ).
where ρE
ω is the state the adversary obtains as defined in Eq. (7).
On the Power of Quantum Encryption Keys 171
Fig. 1. Quantum asymmetric-key cryptosystem model. Bob and Charlie hold copies of
Alice’s encryption key ρk . To send her a message, they encrypt it with the key and a
given QSR scheme, and send the resulting cipher to her. An eavesdropper, Eve, may
intercept the ciphers as well as possess some copies of the encryption key herself.
Remark 1. Definition 4 is clearly more general than the security criteria of Defi-
nition 3 ((t, )-randomization) as this latter corresponds to the special case t1 = t.
However, for the scheme constructed in Section 4 the two are equivalent, and
proving one proves the other. This is the case in particular if the encryption key
is equal to the cipher of some specific message σ0 , i.e., ρk = ρk,σ0 = E(ρk ⊗ σ0 ),
in which case holding an extra copy of the encryption key does not give more
information about the decryption key than holding an extra cipher state.
St C t
where ρ is the state of the joint systems of t-fold message and cipher Hilbert
t t
spaces, and ρS and ρC are the result of tracing out the cipher respectively
message systems. I.e.,
t t
ρS C = PS t (s)|ss| ⊗ PK (k)ρk,s1 ⊗ · · · ⊗ ρk,st ,
s∈S ×t k∈K
t
S
ρ = PS t (s)|ss|,
s∈S ×t
t
ρC = PS t (s) PK (k)ρk,s1 ⊗ · · · ⊗ ρk,st ,
s∈S ×t k∈K
where s = (s1 , . . . , st ).
This security definition can be interpreted the following way. No matter what
the probability distribution on the secret messages is – let the adversary choose
it – the message and cipher spaces are nearly in product form, i.e., the cipher
gives next to no information about the message.
The following lemma proves that this new security definition is equivalent to
the previous one (Definition 3) up to a constant factor.
Lemma 1. If a QSR scheme is (t, )-randomizing for a set of classical messages
S, then it is (t, 2)-secure for S. If a QSR scheme is (t, )-secure for a set of
classical messages S, then it is (t, 2)-randomizing for S.
Proof. Immediate after writing out the definitions explicitly, using the triangle
inequality for one direction and considering the distribution on the message
tuples PS t (s1 ) = PS t (s2 ) = 1/2 for any s1 , s2 ∈ S ×t for the converse.
and the more insecure the scheme becomes. As it turns out, the number of copies
of the encryption key which can be safely used is directly linked to the size of
the decryption key, i.e., the cardinality of the decryption key set K.
Let us assume a QSR scheme with quantum encryption keys is used to en-
crypt classical messages of size m. Then if t copies of the encryption key state
are released and used, the size of the total message encrypted with the same
decryption key k is tm. We prove in this section that the decryption key has
to be of the same size as the total message to achieve information-theoretical
security, i.e., log |K| tm. In Section 4 we then give a scheme which reaches this
bound asymptotically.
Theorem 1. If a QSR scheme given by the tuple T = (PK , {ρk }k∈K , E) is in-
vertible for the set of classical messages S, then when t messages (s1 , . . . , st ) are
chosen from S with (joint) probability distribution PS t (s1 , . . . , st ) and encrypted
with the same key,
t t H (S t ) − H (K) − 2
SC t t
ρ − ρS ⊗ ρC ≥ , (9)
tr 4t log |S|
t t
where H(·) is the Shannon entropy and ρS C is the state of the t-fold message
and cipher systems:
t t
ρS C = PS t (s)|ss| ⊗ PK (k)ρk,s1 ⊗ · · · ⊗ ρk,st ,
s∈S ×t k∈K
t
S
ρ = PS t (s)|ss|, (10)
s∈S ×t
t
ρC = PS t (s) PK (k)ρk,s1 ⊗ · · · ⊗ ρk,st ,
s∈S ×t k∈K
where s = (s1 , . . . , st ).
Proof in Appendix A.1.
Corollary 1. For a QSR scheme to be (t, )-randomizing or (t, )-indistinguish-
able, it is necessary that
H (K) ≥ (1 − 8)t log d − 2, (11)
where d is the dimension of the message Hilbert space HS and H (K) is the
entropy of the decryption key.
4 Near-Optimal Scheme
To simplify the presentation of the QSR scheme, we first define it for classical
messages in Section 4.1, show that it is invertible and find a bound on t, the
number of copies of the encryption key which can be released, for it to be (t, )-
randomizing for an exponentially small . In Section 4.2 we extend the scheme
to encrypt any quantum message of a given size, and show again that it is
invertible and randomizing. And finally in Section 4.3 we calculate the size of
the key necessary to encrypt a message of a given length, and show that it is
nearly asymptotically equal to the lower bound found in Section 3.
This set has size |K| = 2mn and each key is chosen with uniform probability.
For every decryption key A ∈ K the corresponding encryption key is defined
as
1
ρA := n |Ax, xAx, x|, (13)
2 n
x∈{0,1}
We now show that this scheme is (t, )-randomizing for = 2−δn+1 and t =
(1 − δ)n, 0 < δ < 1.
Theorem 2. For the QSR scheme defined above in Eqs. (12), (13) and (14)
⊗t
there exists a density operator τ ∈ B(HC ) such that for all t-tuples of messages
×t
s = (s1 , . . . , st ) ∈ S , if t = (1 − δ)n, 0 < δ < 1, then
where γs isthe encryption of s with this scheme averaged over all possible keys,
i.e., γs = A∈K PK (A)ρA,s1 ⊗ · · · ⊗ ρA,st .
Proof in Appendix A.3.
Theorem 3. Let a QSR scheme with quantum keys be given by the tuple T1 =
(PK , {ρk }k∈K , E), where E : B(HK ⊗ HS ) → B(HC ), and let a QSR scheme with
classical keys be given by the tuple T2 = (PS , {Fs }s∈S ), where Fs : B(HR ) →
B(HD ). We combine the two to produce the QSR scheme with quantum encryp-
tion keys given by T3 = (PK , {ρk }k∈K , G), where G : B(HK ⊗HR ) → B(HC ⊗HD )
is defined by
G(ρk ⊗ σ) := PS (s)E (ρk ⊗ |ss|) ⊗ Fs (σ). (15)
s∈S
for some (m × n)-matrix decryption key A. Although these keys are written
as quantum states using the bra-ket notation to fit in the framework for QSR
schemes with quantum keys developed in the previous sections, the states from
Eq. (16) are all diagonal in the computational basis. So they are classical and
could have been represented by a classical random variable XA which takes the
value (Ax, x) with probability 2−n .
This scheme meets the optimality bound on the key size from Section 3. This
bound tells us that for a given set of decryption keys K, no matter how the
encryption keys {ρk }k∈K are constructed, the number of copies of the encryp-
tion keys which can be created, t, and the dimension of the messages which
can be encrypted, d, have to be such that t log d H (K) for the scheme to be
information-theoretically secure. But this bound is met by a scheme using clas-
sical keys, hence no scheme using quantum keys can perform better. So using
quantum keys in a QSR scheme has no advantage with respect to the message
size and number of usages of the same key over classical keys.
This result applies to both the symmetric-key and asymmetric-key models
as the optimality was shown with respect to both (t, )-randomization (Defini-
tion 3) and (t, )-indistinguishability (Definition 4), the security definitions for
the symmetric-key and asymmetric-key models respectively.
On the Power of Quantum Encryption Keys 177
References
1. Hayden, P., Leung, D., Shor, P.W., Winter, A.: Randomizing quantum states:
Constructions and applications. Communications in Mathematical Physics 250,
371–391 (2004)
2. Ambainis, A., Smith, A.: Small pseudo-random families of matrices: Derandomizing
approximate quantum encryption. In: Jansen, K., Khanna, S., Rolim, J., Ron, D.
(eds.) RANDOM 2004 and APPROX 2004. LNCS, vol. 3122, pp. 249–260. Springer,
Heidelberg (2004)
3. Dickinson, P., Nayak, A.: Approximate randomization of quantum states with fewer
bits of key. In: AIP Conference Proceedings, vol. 864, pp. 18–36 (2006)
4. Boykin, P.O., Roychowdhury, V.: Optimal encryption of quantum bits. Physical
Review A 67, 42317 (2003)
5. Ambainis, A., Mosca, M., Tapp, A., de Wolf, R.: Private quantum channels. In:
FOCS 2000: Proceedings of the 41st Annual Symposium on Foundations of Com-
puter Science, Washington, DC, USA, vol. 547. IEEE Computer Society, Los
Alamitos (2000)
6. Nayak, A., Sen, P.: Invertible quantum operations and perfect encryption of quan-
tum states. Quantum Information and Computation 7, 103–110 (2007)
7. Nielsen, M.A., Chuang, I.L.: Quantum Computation and Quantum Information.
Cambridge University Press, Cambridge (2000)
8. Harrow, A.W., Winter, A.: How many copies are needed for state discrimination?
quant-ph/0606131 (2006)
9. Hayashi, M., Kawachi, A., Kobayashi, H.: Quantum measurements for hidden sub-
group problems with optimal sample complexity. Quantum Information and Com-
putation 8, 345–358 (2008)
10. Kawachi, A., Koshiba, T., Nishimura, H., Yamakami, T.: Computational indistin-
guishability between quantum states and its cryptographic application. In: Cramer,
R. (ed.) EUROCRYPT 2005. LNCS, vol. 3494, pp. 268–284. Springer, Heidelberg
(2005)
11. Kawachi, A., Koshiba, T., Nishimura, H., Yamakami, T.: Computational indistin-
guishability between quantum states and its cryptographic application. Full version
of [10], quant-ph/0403069 (2006)
12. Alicki, R., Fannes, M.: Continuity of quantum conditional information. Journal of
Physics A: Mathematical and General 37, L55–L57 (2004)
A Proofs
A.1 Proof of Theorem 1 in Section 3 on Page 173
A theorem by Alicki and Fanes [12] tells us that for any two states ρAB and
σ AB on the joint system HAB = HA ⊗ HB with δ := ρAB − σ AB tr ≤ 1 and
dA := dim HA ,
S ρAB ρB − S σ AB σ B ≤ 4δ log dA + 2h (δ) , (17)
where S ρAB ρB := S ρAB − S ρB is the conditional Von Neumann entropy
and h(p) := p log p1 + (1 − p) log 1−p
1
is the binary entropy. h(δ) ≤ 1, so from
Eq. (17) we get
AB S ρAB ρB − S σ AB σ B − 2
ρ −σ AB
≥ .
tr 4 log dA
178 A. Kawachi and C. Portmann
For this we will need the two following bounds on the Von Neumann entropy
(see e.g, [7]):
S p x ρx ≥ px S (ρx ) ,
x∈X x∈X
S p x ρx ≤ H (X ) + px S (ρx ) .
x∈X x∈X
Equality is obtained in the second equation if the states {ρx }x∈X are all mutually
orthogonal. By using these bounds and Eq. (10) we see that
t t
S ρ S C
=H S + t
PS t (s) S PK (k)ρk,s1 ⊗ · · · ⊗ ρk,st
s∈S ×t k∈K
≤H S t
+ H (K) + PK (k)PS t (s) S (ρk,s1 ⊗ · · · ⊗ ρk,st ) ,
×t
s∈S
k∈K
t
S ρS = H St ,
Ct
S ρ ≥ PK (k) S PS t (s)ρk,s1 ⊗ · · · ⊗ ρk,st
k∈K s∈S ×t
= H St + PK (k)PS t (s) S (ρk,s1 ⊗ · · · ⊗ ρk,st ) .
×t
s∈S
k∈K
We have equality in the last line because the scheme is invertible on S, i.e., by
Definition 2 and Remark 2 the states {ρk,s1 ⊗ · · · ⊗ ρk,st }s1 ,...,st ∈S are mutually
orthogonal. By putting this all together we conclude the proof.
for all probability distributions PS t . So for the uniform distribution we get from
Theorem 1 that for a scheme to be (t, )-secure we need
H (K) ≥ (1 − 4)t log |S| − 2.
On the Power of Quantum Encryption Keys 179
for the scheme to be (t, )-randomizing for the classical messages S. And as
classical messages are a subset of quantum messages – namely an orthonormal
basis of the message Hilbert space – this bound extends to the case of quantum
messages on a Hilbert space of dimension dS = |S|.
As (t, )-randomization is a special case of (t, )-indistinguishability, namely
for t1 = t, it is immediate that this lower bound also applies to (t, )-indistin-
guishability.
probability that exactly d of these vectors are linearly independent. The matrix
given in Eq. (19) then has exactly 2tn PDt (d)2dm eigenvectors with eigenvalue
2dm 2tn , for 0 ≤ d ≤ t. The remaining eigenvectors have eigenvalue 0.
1
1 t
1 1
we − =2 2tn PDt (d)2dm − t(m+n)
2t(m+n) 2dm 2tn 2
e∈EVec(ρE
0 )
d=0
t
=2 PDt (d) 1 − 2−(t−d)m
d=0
t−1
≤2 PDt (d) = 2(1 − PDt (t))
d=0
≤2 t−n+1
.
For t = (1 − δ)n, 0 < δ < 1, we have for all s ∈ S t , γs − τ tr ≤ 2−δn+1 .
≤ 1 + t1 2 .
1 Introduction
Class MQ(q, n, m): For given q, n, m, the class MQ(q, n, m) consists of all
systems of m quadratic polynomials in Fq with n variables. To choose a
random system S from MQ(q, n, m), we write each polynomial Pk (x) as
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 181–202, 2008.
c Springer-Verlag Berlin Heidelberg 2008
182 F.-H. Liu, C.-J. Lu, and B.-Y. Yang
aijk xi xj + 1≤i≤n bik xk + ck , where every aijk , bik , ck is chosen
1≤i≤j≤n
uniformly in Fq .
Solving S(x) = b for any MQ system S is known as the “multivariate
quadratic” problem.
It is often claimed that the NP-completeness of this problem [19] is the
basis for multivariate public-key cryptosystems. We could take instead Pi ’s
to be polynomials of degree d instead of quadratic and get the class of “mul-
tivariate polynomial systems” MP (q, d, n, m). This contains MQ(q, n, m)
as a subset, so solving arbitrary S(x) = b for any MP system S would be
no easier. However, it is not easy to base a proof on worst-case hardness; the
premise used in [7] is the following average-case hardness assumption:
Assumption MQ: Given any k and prime power q, for parameters n, m sat-
isfying m/n = k + o(1), no probabilistic polynomial-time algorithm can
solve (in poly(n)-time) any fixed ε > 0 proportion of systems S drawn from
MQ(q, n, m), and a vector b = (b1 , b2 , . . . , bm ) drawn from S(Un ), where Un
is uniform distribution over (Fq )n such that S(x) = b.
With this premise, [7, Theorem 4] proved the QUAD PRNG secure over F2 .
However, a looseness factor in its security argument in the security proof means
that provably secure QUAD instances over F2 are not yet of practical speed. It also
does not work for fields larger than F2 . A similar result over any Fq is non-trivial
to prove, which we do here with different and more involved techniques. However,
instances of QUAD with the same-size state over larger fields are significantly less
secure [33]. To increase the difficulty of solving a system of nonlinear polynomial
equations, we can plausibly change (a) the field size q, (b) the number of variables
n, or (c) the degree d of the system (cf. [3,4,31]). Each costs time and space (for
a reduction from the MQ problem in Fq case to F2 case, see [30]). Even with a
hardware implementation, an increase in resource consumption is inevitable.
A logical next step is to combine all these approaches but find polynomials that
are easier to evaluate. A natural candidate is sparsity in the chosen polynomials.
To our survey, however, there are no prior positive results for provable security
of specialized polynomial systems, and specifically sparse ones.
So the questions we are trying to answer are:
– Can we prove a similar result to [7] allowing for more efficiently evaluated
specialized systems?
– What do we know about how these specializations affect complexity of system-
solving?
nonzero degree-i terms are present for each i ≥ 2. The affine terms (coefficients)
are totally randomly chosen. Also all the operations and coefficients are in Fq .
d (i)
To rephrase, the i-th polynomial we can be written as Pi (x) = j=2 Qj (x)+
(i)
1≤j≤n aij xj + ci where each Qj (x) can be written in the form
1≤σ(1)≤σ(2)≤···≤σ(j)≤n a(σ(1),σ(2),...,σ(j)) xσ(1) xσ(2) . . . xσ(j) , or the sum of ηj
monomials with degree j. “A random system from SMP(q, d, n, m, (η2 , . . . , ηd ))”
then has a probability distribution as follows: all aij , ci are uniformly chosen from
(i)
Fq . To determine each Qj (x), we firstly uniformly choose ηj out of n+j−1 j co-
efficients to be nonzero, then uniformly choose each of these nonzero coefficients
from F∗q := Fq \ {0}. All the others coefficients wil be zero.
We now propose a probabilistic one-wayness assumption to base a security
theorem on.
Assumption SMP : For given q, d, and for n, m, η2 , . . . , ηd such that m/n =
k + o(1) and ηi /n = ki + o(1) (where k, k2 , k3 , . . . are constants) there is
no probabilistic algorithm which can solve (in poly(n)-time) any fixed ε >
0 proportion of instances S(x) drawn from SMP((q, d, n, m, (η2 , . . . , ηd )),
and a vector b = (b1 , b2 , . . . , bm ) drawn from S(Un ), where Un is uniform
distribution over (Fq )n such that S(x) = b.
In Secs. 2–3 Assumption SMP is shown to yield a secure PRNG (and hence a
probably secure stream cipher), for any q. The key to this extension to general
Fq involves a reconstruction over linear polynomials, which is a non-trivial gener-
alization of the Goldreich-Levin hard core bit by Goldreich-Rubinfeld-Sudan [21].
We then check that SMP instances are hard to solve on average (i.e., not
just worst case) via the known fastest generic (cf. Sec. 4 and Appendix B) and
special-purpose algorithms. Finally we discuss their practical use. Preliminary
implementations of our SPELT (Sparse Polynomials, Every Linear Term) can
achieve 5541 and 11744 cycles per byte for a SMP-based secure stream cipher
over F16 (quartic, 108 variables) and F2 (cubic, 208 variables) respectively. The
former is at least twice as fast as any other stream ciphers provably secure at
the same parameters (cf. Sec. 5.2).
There is another possible candidate for the one-wayness assumption, SRQ,
proposed by Prof. Jintai Ding, that is worth studying. We put a brief description
in the Appendix C, and address an interesting potential topic for the future work.
The authors would like to thank Prof. Jintai Ding for the proofreading,
suggestions, and discussions. The full version of this work can be found at
”[Link]
– With [29], the specified security level was 270 , today’s cryptographers usually
aim for 280 (3DES units).
– Similarly with QUAD there is a gap between the “recommended” instances
and the provably secure instances (i.e., the tested instances were unprovable
or unproven [33]).
– PRNGs based on decisional Diffie-Hellman assumption have almost no gap
between the hardness of breaking the PRNG and solving the underlying in-
tractable problem, but known primitives based on DDH and exponentiation
in Zp [22,16] are generally slower than those based on other assumptions.
The generic types of methods for solving polynomial systems — Faugère’s F4 -
F5 and XL-derivatives — are not affected drastically by sparsity. In the former,
sparsity is quickly lost and tests show that there is no substantial difference in
timing when solving SMP instances. Recent versions of XL [33] speeds up pro-
portionally to sparsity. We therefore surveyed the literature for recent results on
solving or attacking specialized systems in crypto, listed below. These results
do not contradict our hardness assumption.
– Aumasson-Meier (ICISC 2007) [1] shows that in some cases sparsity in pri-
marily underdefined — more variables than equations — systems leads to
improved attacks. Results are very intresting and takes more study but do
not apply to overdetermined systems in general.
– Bard-Courtois-Jefferson [2] tests SAT solvers on uniformly sparse F2 equa-
tions, and gives numbers.
– Raddum-Samaev [27,28] attacks “clumped” systems (even though the title
says “sparse”). Similarly the Courtois-Pieprzyk XSL attack [13] requires a
lot of structures (i.e., “clumping”).
PRNG: Let n < L be two integers and K = Fq be a finite field. The function
G : K n → K L is said to be a Pseudorandom Number Generator (PRNG) if
the probability distribution of the random variable G(x), where the vector
x is uniformly random in K n , is computationally indistinguishable (with
distinguisher resource R) from a uniformly random vector in K L . Usually
q = 2 but it is not required.
Linear polynomialn maps: A linear polynomial map R : (Fq )n → (Fq ) means
R(x) = i=1 ai xi , where x = (x1 , x2 , . . . , xn ), and x1 , x2 , . . . , xn are vari-
ables. If we give these variables values in Fq , by setting (x1 , x2 , . . . , xn ) =
(b1 , b2 , . . . , bn ) for bi ∈ Fq , denoted as b, then R(b) = ni=1 ai bi is an element
in Fq .
In the following sections, a “random” linear polynomial map (or form)
has the coefficients ai ’s randomly chosen from Fq . Also, when we mention
R or R(x) refers to the function but when we write R(b), that means the
value of the function R with input vector b.
Instance from SMP (or MQ): If S is an instance drawn from SMP(q, d, n,
m, (η2 , . . . , ηd )), then S(x) = (P1 (x), P2 (x), . . . , Pm (x)) (x = (x1 , x2 , . . . , xn )
are variables) is a function that maps (Fq )n → (Fq )m and each Pi (x) has the
same probability distribution as that mentioned in section 1.2. For example,
if b=(b1 , b2 , . . . , bn ) is a vector in(Fq )n , then S(b)=(P1 (b), P2 (b), . . . , Pm (b)),
a value in (Fq )m .
Note: Heretofore we will also say SMP(n, m) for short, if no confusion is
likely to ensue.
y0 = P(x0 ) y1 = P(x1 ) y2 = P(x2 ) y3 = P(x3 ) ···
If we can distinguish between its first λ blocks of output (y0 , y1 , . . . , yλ−1 ) and
a true random vector in K λr with advantage in time T , then we can distinguish
between the output of a true random vector in K n+r and the output of S = (P, Q)
in time T + λTS with advantage /λ. [Standard Proof is in Appendix A.]
Proposition 2 (an extention of [7]). Let K = Fq . Suppose there is an
algorithm A that given a system S(: K n → K m ) chosen from SMP(q, d, n,
m, (η2 , . . . , ηd )) distinguishing S(Un ) from a uniform random distribution Um ,
(where Ur means uniform distribution over K r for the r,) with advantage at least
in time T . Then there is an algorithm B that, given (1) a system S : K n → K m
from SMP(n, m), (2) any K n → K linear form R, and (3) y = S(b), where b
is an secret input value randomly chosen from K n , predicts R(b) with success
probability at least (1 + /2)/q using at most T + 2TS operations.
Proof. Without loss of generality, we may suppose that A has probability at least
higher to return 1 on an input distribution (S, S(Un )) than on distribution
(S, Um ). Define a recentered distinguisher
A(S, w), probability 12
A (S, w) :=
1 − A(S, u), u ∈ K m uniform random, probabilty 12
Pr(B = R(b)) = Pr(B = v|v = R(b)) Pr(v = R(b)) + Pr(B = R(b)|v = R(b)) Pr(v = R(b))
1 1 q−1 1 1 1
= + + = 1+ .
q 2 2 q 2 q−1 q 2
Secure PRNGs from Specialized Polynomial Maps over Any Fq 187
Note: We see that the reasoning can work this way if and only if S = S + Ru
have the same distribution as S. Otherwise, we cannot guarentee the distinguisher
A will output the same distribution.
theorm gets stuck in this place. Here we show a way to extend the main results
to Fq , by using a generalization of the Goldreich-Levin hard-core bit theorem.
Supposed we are testing the i-th prefix (c1 , c2 , . . . , ci ), we are going to evaluate
the quantity of:
⎡ ⎤
i
Ps (σ) := Pr ⎣f (r, s) = cj rj + σ ⎦
r1 ,r2 ...,ri ∈K
j=1
n
where r = (r1 , r2 , . . . , ri ). The value of σ can be thought as a guess of i+1 pj sj .
For every s, we can estimate the probability by a sample of several r’s, and
the error rate can be controlled by the times of sampling. If such s makes the
probability significantly larger than 1/q, then we accept. If no such s exists, we
reject. The detailed algorithm is stated in the Algorithm 1: TestPrefix.
If a candidate (c1 , c2 , . . . , ci ) passes through the Algorithm 1 for at least one
suffix s, there is a σ such that the estimate of Ps (σ) is greater than 1q +
3 . For a correct candidate (c1 , c2 , . . . , ci ), i.e. (c1 , c2 , . . . , ci ) is the prefix of
p = (p1 , p2 , . . . , pn ) which matches f for at least 1q + , and an arbitrary σ =
n
i+1 pj sj , it satisfies that Es [Ps (σ)] ≥ q + . By Markov’s inequality, for at
1
Pr [ TestPrefix fails ] ≤
1
Pr[no such s is chosen ] + Pr no single element exists more than + fraction
q 3
k1 1
Pr [ no such s is chosen] ≤ (1 − /2)k1 ≤ e− 2 ≤ 2
2
1− 1
q −2 nq
k2 = O( log(n/)
2 ) ≈ 216 log(n/)
2 is sufficient to make the inequality hold. Thus,
we have
Pr [ TestPrefix fails ] ≤ 2 .
1 − 1q −2 nq
Pr [ ] ≤ Pr [ ]≤ Pr [ ]
2
1 −2
≤ 1− nq 2 =
q
1 − 1q −2 nq
192 F.-H. Liu, C.-J. Lu, and B.-Y. Yang
Therefore, the algorithm will work with high probability. The worst case
running time of algorithm 2 should be: k1 k2 (1 − 1q )2 12 nq = O( n5 log2 ( n ))
210 nq5
log2 ( n ).
2
Note: 1 − 1q −2 is the maximum number of candidates which pass in each
round.
To verify that SMP represent one way property, we need to show that
Here “generic” means the ability to handle any multivariate polynomial system
with n variables and m equations in Fq . There are two well-known types of
generic methods for solving polynomial systems, both related to the original
Buchberger’s algorithm. One is Faugère’s F4 -F5 and the other is XL-derivatives.
In the former, sparsity is quickly lost and tests show that there are little difference
in timing when solving SMP instances. With recent versions of XL [33], the
sparsity results in a proportional decrease in complexity. The effect of sparsity
on such generic methods should be predictable and not very drastic, as shown
by some testing (cf. Sec. 4.1). We briefly describe what is known about XL and
F4 -F5 in Appendix B.
m − n DXL Dreg n = 9 n = 10 n = 11 n = 12 n = 13
0 2m m 6.03 46.69 350.38 3322.21 sigmem
1 m m+1
2√
1.19 8.91 53.64 413.34 2535.32
2 2
m+1 m+2− m+2
2
0.31 2.20 12.40 88.09 436.10
Secure PRNGs from Specialized Polynomial Maps over Any Fq 193
n 7 8 9 10 11 12 13
D 5 6 6 7 7 8 8
SMQ(256, n, n + 2, n) 9.34 · 10−2 1.17 · 100 4.04 · 100 6.02 · 101 1.51 · 102 2.34 · 103 5.97 · 103
MQ(256, n, n + 2) 2.06 · 10−1 2.92 · 100 1.10 · 10 1.81 · 102 4.94 · 102 8.20 · 103 2, 22 · 104
so far there are no theoretical analysis especially for when the number of
equations is a few times the number of variables, which is the case for SMP
constructions.
P : Fn+r
2 → Fn2 , P(x) = b + M x + Q(x)
We note that other specialized polynomials can be constructed that are also
easier to evaluate such as the SRQ construction (cf. Appendix C) which also can
carry through the same arguments as SMP, so our process is more general than
it looks.
We hasten to add that our programming is quite primitive, and may not match
the more polished implementations (e.g., [5]). We are still working to improve
our programming and parameter choices. Also, in hardware implementations,
the power of sparsity should be even more pronounced.
References
1. Aumasson, J.-P., Meier, W.: Analysis of multivariate hash functions. In: Nam, K.-
H., Rhee, G. (eds.) ICISC 2007. LNCS, vol. 4817, pp. 309–323. Springer, Heidelberg
(2007)
Secure PRNGs from Specialized Polynomial Maps over Any Fq 197
2. Bard, G.V., Courtois, N.T., Jefferson, C.: Efficient methods for conversion and
solution of sparse systems of low-degree multivariate polynomials over gf(2) via
sat-solvers. Cryptology ePrint Archive, Report 2007/024 (2007),
[Link]
3. Bardet, M., Faugère, J.-C., Salvy, B.: On the complexity of Gröbner basis compu-
tation of semi-regular overdetermined algebraic equations. In: Proceedings of the
International Conference on Polynomial System Solving, pp. 71–74 (2004) (Previ-
ously INRIA report RR-5049)
4. Bardet, M., Faugère, J.-C., Salvy, B., Yang, B.-Y.: Asymptotic expansion of the
degree of regularity for semi-regular systems of equations. In: Gianni, P. (ed.)
MEGA 2005 Sardinia (Italy) (2005)
5. Berbain, C., Billet, O., Gilbert, H.: Efficient implementations of multivariate
quadratic systems. In: Biham, E., Youssef, A.M. (eds.) SAC 2006. LNCS, vol. 4356,
pp. 174–187. Springer, Heidelberg (2007)
6. Berbain, C., Gilbert, H.: On the security of IV dependent stream ciphers. In:
Biryukov, A. (ed.) FSE 2007. LNCS, vol. 4593, pp. 254–273. Springer, Heidelberg
(2007)
7. Berbain, C., Gilbert, H., Patarin, J.: QUAD: A practical stream cipher with prov-
able security. In: Vaudenay, S. (ed.) EUROCRYPT 2006. LNCS, vol. 4004, pp.
109–128. Springer, Heidelberg (2006)
8. Billet, O., Robshaw, M.J.B., Peyrin, T.: On building hash functions from multivari-
ate quadratic equations. In: Pieprzyk, J., Ghodosi, H., Dawson, E. (eds.) ACISP
2007. LNCS, vol. 4586, pp. 82–95. Springer, Heidelberg (2007)
9. Biryukov, A. (ed.): FSE 2007. LNCS, vol. 4593. Springer, Heidelberg (2007)
10. Blum, L., Blum, M., Shub, M.: Comparison of two pseudo-random number gener-
ators. In: Rivest, R.L., Sherman, A., Chaum, D. (eds.) CRYPTO 1982, pp. 61–78.
Plenum Press, New York (1983)
11. Buchberger, B.: Ein Algorithmus zum Auffinden der Basiselemente des Restklassen-
ringes nach einem nulldimensionalen Polynomideal. PhD thesis, Innsbruck (1965)
12. Courtois, N.T., Klimov, A., Patarin, J., Shamir, A.: Efficient algorithms for solving
overdefined systems of multivariate polynomial equations. In: Preneel, B. (ed.)
EUROCRYPT 2000. LNCS, vol. 1807, pp. 392–407. Springer, Heidelberg (2000),
[Link]
13. Courtois, N.T., Pieprzyk, J.: Cryptanalysis of block ciphers with overdefined sys-
tems of equations. In: Zheng, Y. (ed.) ASIACRYPT 2002. LNCS, vol. 2501, pp.
267–287. Springer, Heidelberg (2002)
14. Diem, C.: The XL-algorithm and a conjecture from commutative algebra. In: Lee,
P.J. (ed.) ASIACRYPT 2004. LNCS, vol. 3329. Springer, Heidelberg (2004)
15. Ding, J., Yang, B.-Y.: Multivariate polynomials for hashing. In: Inscrypt. LNCS.
Springer, Heidelberg (2007), [Link]
16. Farashahi, R.R., Schoenmakers, B., Sidorenko, A.: Efficient pseudorandom genera-
tors based on the ddh assumption. In: Public Key Cryptography, pp. 426–441 (2007)
17. Faugère, J.-C.: A new efficient algorithm for computing Gröbner bases (F4 ). Journal
of Pure and Applied Algebra 139, 61–88 (1999)
18. Faugère, J.-C.: A new efficient algorithm for computing Gröbner bases without
reduction to zero (F5 ). In: International Symposium on Symbolic and Algebraic
Computation — ISSAC 2002, pp. 75–83. ACM Press, New York (2002)
19. Garey, M.R., Johnson, D.S.: Computers and Intractability — A Guide to the The-
ory of NP-Completeness. W.H. Freeman and Company, New York (1979)
20. Gennaro, R.: An improved pseudo-random generator based on the discrete loga-
rithm problem. Journal of Cryptology 18, 91–110 (2000)
198 F.-H. Liu, C.-J. Lu, and B.-Y. Yang
21. Goldreich, O., Rubinfeld, R., Sudan, M.: Learning polynomials with queries: The
highly noisy case. SIAM Journal on Discrete Mathematics 13(4), 535–570 (2000)
22. Jiang, S.: Efficient primitives from exponentiation in zp . In: Batten, L.M., Safavi-
Naini, R. (eds.) ACISP 2006. LNCS, vol. 4058, pp. 259–270. Springer, Heidelberg
(2006)
23. Koblitz, N., Menezes, A.: Another look at provable security (part 2). In: Barua,
R., Lange, T. (eds.) INDOCRYPT 2006. LNCS, vol. 4329, pp. 148–175. Springer,
Heidelberg (2006)
24. Lazard, D.: Gröbner-bases, Gaussian elimination and resolution of systems of al-
gebraic equations. In: van Hulzen, J.A. (ed.) ISSAC 1983 and EUROCAL 1983.
LNCS, vol. 162, pp. 146–156. Springer, Heidelberg (1983)
25. Levin, L., Goldreich, O.: A hard-core predicate for all one-way functions. In: John-
son, D.S. (ed.) 21st ACM Symposium on the Theory of Computing — STOC 1989,
pp. 25–32. ACM Press, New York (1989)
26. Matsumoto, T., Imai, H.: Public quadratic polynomial-tuples for efficient signature
verification and message-encryption. In: Günther, C.G. (ed.) EUROCRYPT 1988.
LNCS, vol. 330, pp. 419–545. Springer, Heidelberg (1988)
27. Raddum, H., Semaev, I.: New technique for solving sparse equation systems. Cryp-
tology ePrint Archive, Report 2006/475 (2006), [Link]
28. Semaev, I.: On solving sparse algebraic equations over finite fields (part ii). Cryp-
tology ePrint Archive, Report 2007/280 (2007), [Link]
29. Steinfeld, R., Pieprzyk, J., Wang, H.: On the provable security of an efficient rsa-
based pseudorandom generator. In: Lai, X., Chen, K. (eds.) ASIACRYPT 2006.
LNCS, vol. 4284, pp. 194–209. Springer, Heidelberg (2006)
30. Wolf, C.: Multivariate Quadratic Polynomials in Public Key Cryptography. PhD
thesis, Katholieke Universiteit Leuven (2005), [Link]
31. Yang, B.-Y., Chen, J.-M.: All in the XL family: Theory and practice. In: Park, C.-
s., Chee, S. (eds.) ICISC 2004. LNCS, vol. 3506, pp. 67–86. Springer, Heidelberg
(2005)
32. Yang, B.-Y., Chen, J.-M.: Theoretical analysis of XL over small fields. In: Wang, H.,
Pieprzyk, J., Varadharajan, V. (eds.) ACISP 2004. LNCS, vol. 3108, pp. 277–288.
Springer, Heidelberg (2004)
33. Yang, B.-Y., Chen, O.C.-H., Bernstein, D.J., Chen, J.-M.: Analysis of QUAD. In:
Biryukov [9], pp. 290–307
A Proof of Prop. 1
Proof. We introduce hybrid probability distributions Di (S) over K L (L := λr):
For 0 ≤ i ≤ λ respectively associate with the random variables
ti (S, x) := w1 , w2 , . . . , wi , P(x), P(Q(x)), . . . , P(Qλ−i−1 (x))
where the wj and x are random independent uniformly distributed vectors in K n
and we use the notational conventions that (w1 , w2 , . . . , wi ) is the null string
if i = 0, and that
P(x), P(Q(x)), . . . , P(Qλ−i−1 (x))
is the null string if i = λ. Consequently D0 (S) is the distribution of the L-unit
keystream and Dλ (S) is the uniform distribution over K L . We denote by pi (S)
Secure PRNGs from Specialized Polynomial Maps over Any Fq 199
when q = 2.
2. If the system is regular up to degree D, i.e., if the relations R(D) has no
other dependencies than the obvious ones generated by Pi Pj = Pj Pi
and Piq = Pi , then
(1 − t)n+1 j=1
1−t q dj
(3)
3. For overdefined systems, Eq. 3 cannot hold when D > DXL = min{D :
[tD ]G(t) ≤ 0}. If Eq. 3 holds up for every D < DXL and resolves at DXL ,
we say that the system is q-semiregular. It is generally believed [3,14] that
for random systems it is overwhelmingly likely that D0 = DXL , and
indeed the system is not q-semiregular with very small probability.
4. When it resolves, XL takes CXL (c0 + c1 lg T ) τ T 2 multiplications in Fq ,
using a sparse solver like Wiedemann [31]. Here τ is the average number of
terms per equation.
We cannot describe methods F4 -F5 [17,18], which are just too sophisticated
and complex to present here. Instead, we simply sketch a result that yields their
complexities:
Proposition 8. [3] For q-semiregular systems, F4 or F5 operates at the degree
⎧ ⎛ ⎞ ⎫
⎨ q n 3
m ⎬
(1 − t ) 1 − t dj
D = Dreg := min D : [tD ] ⎝ ⎠<0 ,
⎩ (1 − t)n j=1 1 − tq dj ⎭
P0 (x) = x1 x2 + x3 x4 + · · · xn−1 xn .
10000
Dense Random
Sparse Random (1/10)
Sparse Random (2/n)
Sparse Non-random
Best Fit of Dense Random
1000
Time (Second)
100
10
11 12 13 14 15
n
10000
Dense Random
Sparse Random (1/50)
Sparse Random (1/n)
Best Fit of Dense Random
1000
Time (Second)
100
10
0.1
21 22 23 24 25 26 27 28 29 30 31
n
1 Introduction
Solving systems of multivariate quadratic equations is an important problem in
cryptology. The problem of solving such systems over finite fields is called the
Multivariate Quadratic (MQ) problem. In the last two decades, several cryp-
tosystems based on the MQ problem have been proposed as in [1,2,3,4,5]. For
generic instances it is proven that the MQ problem is NP-complete [6]. However
for some cryptographic schemes the problem of solving the corresponding MQ
system has been demonstrated to be easier, allowing these schemes to be bro-
ken. Therefore it is very important to develop efficient algorithms to solve MQ
systems.
Recently, MutantXL [7] and MutantF4 [8] were proposed at SCC 2008, two
algorithms based on Ding’s mutant concept. Roughly speaking, in algorithms
that operate on linearized representations of the polynomial system by increasing
degree – such as F4 and XL – this concept proposes to maximize the effect
of lower-degree polynomials occurring during the computation. In this paper,
we present MutantXL2 (MXL2 ) – a new algorithm based on MutantXL that
oftentimes allows to solve systems with significantly smaller matrix sizes than
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 203–215, 2008.
c Springer-Verlag Berlin Heidelberg 2008
204 M.S.E. Mohamed et al.
XL and MutantXL. Moreover, experimental results for both HFE systems and
random systems demonstrate that for a significant number of cases we even get
a reduction of the size of the largest matrix when comparing MXL2 against
Magma’s F4 implementation.
The paper is organized as follows. In Section 2 the key ideas of the MXL2
algorithm and the required definitions are presented. A formal description and
explanations of the algorithm are in Section 3. Section 4 contains the experi-
mental results. In Section 5 we conclude our paper.
pj (x1 , . . . , xn ) = 0, 1 ≤ j ≤ m (1)
such as XL and MutantXL are based on finding new elements in the ideal gener-
ated by the polynomials of P that correspond to equations that are easy to solve,
i.e. univariate or linear polynomials. The MutantXL algorithm is an application
of the mutant concept to the XL algorithm. The following definitions explain
the term mutant:
Definition 1. Let g ∈ R be a polynomial in the ideal generated by the elements
of P . Naturally, it can be written as
g= gp p (2)
p∈P
max{deg(gp p) : p ∈ P }.
MXL2 : Solving Polynomial Equations over GF(2) 205
Note that this level depends on P . The level of the polynomial g is defined to be
the minimum level of all of its representations.
k
n
|Sk | = ,1 ≤ k ≤ n (3)
=1
LV(p) = x (5)
3 MXL2 Algorithm
In this Section we explain the MXL2 algorithm. We use the notation of the
previous section. So P is a finite set of polynomials in R. For simplicity, we
assume that the system (1) is quadratic and has a unique solution.
We use a graded lexicographical ordering in the process of linearization and
during the Gaussian elimination. MXL2 creates a multiplication history one
dimension array to store each previous variable multiplier of each polynomial
and for the originals the previous multiplier is 1. The set of solutions of the
system is defined as {x = b : x is variable and b ∈ {0, 1}}. The description of the
algorithm is as follows.
Solve(Roots, X): if there are univariate equations in the roots, then solve them
and return the solutions.
Substitute(Solution, roots): use all the solutions found to simplify the roots.
Reset(history, n): reset history to an array with number of elements equal to n
and initialized by ones.
Extend(history, n): append to history an array with number of elements equal
to n and initialized by ones.
SelectNecessary(M, D, k, n): compute the necessary number of mutants with
degree k as in equation (4), let the mutants be ordered depending on their lead-
ing terms, then return the necessary mutants by ascending order.
Xpartition(P, x): return {p ∈ P : LV (p) = x}.
LargestLeading(P ): return max{y : y = LV (p), p ∈ P, y ∈ X}.
NextSmallerLeading(P, x): return max{y: y = LV (p), p∈P , y∈X and y<x}.
Algorithm1. MXL2
1. Inputs
2. F : set of quadratic polynomials.
3. D: highest system degree starts by 2.
4. X: set of variables.
5. Output
6. Solution: solution of F=0.
7. Variables
8. RP : set of all regular polynomials produced during the process.
9. M : set of mutants.
10. roots: set of all polynomials of degree ≤ 2
11. x: variable
12. ed: elimination degree
13. history: array of length #RP to store previous variable multiplier
14. extended: a flag to enlarge the system
15. Begin
16. RP ← F
17. M ← ∅
18. Solution ← ∅
19. ed ← 2
20. history ← [1,. . .,1]
21. extended ← false
22. repeat
23. Linearize RP using graded lex order
24. Gauss(Extract(RP, ed, ≤), history)
25. roots ← roots ∪ Extract(RP, 2, ≤)
26. Solution ← Solution ∪ Solve(roots, X)
27. if there are solutions then
MXL2 : Solving Polynomial Equations over GF(2) 209
We show that the system is partially enlarged, so MXL2 leads to the original
MutantXL if the system is solved with the last partition enlarged. Whereas
MXL2 outperforms the original MutantXL if it solves the system by earlier
partition enlarged. This will be clarified experimentally in the next section.
4 Experimental Results
In this section, we present the experimental results for our implementation of the
MXL2 algorithm. We compare MXL2 with the original MutantXL, Magma’s
implementation of F4 , and the XL algorithm for some random systems (5-24
equations in 5-24 variables). The results can be found in Table 1. Moreover,
we have another comparison for MXL2, original MutantXL, and Magma for
some HFE systems (25-55 equations in 25-55 variables) in order to clarify that
mutant strategy has the ability to be helpful with different types of systems. See
the results in Table 2. For XL and MutantXL, all monomials up to the degree
bound D are computed and accounted for as columns in the matrix, even if they
did not appear in any polynomial. For MXL2 on the other hand, we omitted
columns that only contained zeros.
Random systems were taken from [9], HFE systems (30-55 equations in 30-
55 variables) were generated with code contained in [10], and one HFE sys-
tem (25 equations in 25 variables) was taken from the Hotaru distribution [11].
The results for F4 were obtained using Magma version 2.13-10; the parameter
MXL2 : Solving Polynomial Equations over GF(2) 211
HFE:=true was used to solve HFE systems. The MXL2 algorithm has been im-
plemented in C/C++ based on the latest version of M4RI package [12]. For each
example, we give the number of equations (#Eq), number of variables (#Var),
the degree of the hidden univariate high-degree polynomial for HFE (HUD) and
the size of the largest linear system to which Gauss is applied. The ’*’ in the first
column for random systems means that, there are some mutants in this system.
In all experiments, the highest degree of the polynomials generated by Mu-
tantXL and MXL2 is equal to the highest degree of the S-polynomial in Magma.
In MXL2 implementation, we use only one matrix from starting to the end of
the process by enlarging and extending the initial matrix, the largest matrix is
the accumulative of all polynomials that are held in the memory. unfortunately,
in Magma we can not know the total accumulative matrices size because it is
not an open source.
In Table 1, we see that in practice MXL2 is an improvement for memory effi-
ciency over the original MutantXL. For systems for which mutants are produced
during the computation, MutantXL is better than XL. If no mutants occur,
MutantXL behaves identically to XL. Comparing XL, MutantXL, and MXL2 ;
MXL2 is the most efficient even if there are no mutants. In almost all cases
MXL2 has the smallest number of columns as well as a smaller number of rows
compared to the F4 implementation contained in Magma. We can see easily that
70% of the cases MXL2 is better, 5% is equal, and 25% is worse.
212 M.S.E. Mohamed et al.
In Table 2, we also present HFE systems comparison. In all these seven ex-
amples for all the three algorithms (Magma’s F4 , MutantXL, and MXL2 ), all
the monomials up to degree bound D appear in Magma, MutantXL, and MXL2.
therefore, the number of columns are equal in all the three algorithms. It is clear
that MXL2 has a smaller number of rows in four cases of seven. In all cases
MXL2 outperforms MutantXL.
A time comparison in seconds for random systems between MutantXL and
MXL2 can be found in Table 3. We use in this comparison a Sun Fire X2200
M2 server with 2 dual core Opteron 2218 CPU running at 2.6GHz and 8GB
of RAM. We did not make such a comparison between Magma and MXL2 for
HFE instances. This is due to the following reasons: we use a special Magma
MXL2 : Solving Polynomial Equations over GF(2) 213
implementation for HFE systems by using the HFE:=true parameter, the MXL2
implementation is based on M4RI package which is not in its optimal speed
as claimed by M4RI contributors and the MXL2 implementation itself is not
optimal at this point. From Table 3, it is clear that the MXL2 has a good
performance for speed compared to MutantXL.
In order to shed light on which strategy (necessary mutants or partitioned
enlargement) worked more than the other in which case, we make another com-
parison for random systems. In this comparison, we have 4 methods that cover
all possibilities to use the two strategies. Method1 is for multiplying all lower
degree mutants that are extracted at certain level, non of the two strategies are
used. Method2 is for multiplying only our claimed necessary number of mutants,
necessary mutant strategy. We use Method3 for partitioned enlargement strat-
egy, multiplications are for all lower degree mutants. For both the two strategies
which is MXL2 too, we use Metod4. See Table 4.
In Table 4, comparing Method1 and Method2, we see that practically the
necessary mutant strategy sometimes has an effect in the cases which have a
large enough number of hidden mutants (cases 7, 8, 14, 15, 22 and 23). In a case
that has less mutants (cases 6, 21 and 24) or no mutants at all (cases 5, 9, 10-13,
and 16-20), the total number of rows is the same as in Method1. Furthermore,
in case 22 because of not all mutants were multiplied, the number of columns
is decreased. By comparing Method1 and Method3, most of the cases in the
partitioned enlargement strategy have a smaller number of rows except for case
214 M.S.E. Mohamed et al.
5 Conclusion
Experimentally, we can conclude that the MXL2 algorithm is an efficient im-
provement over the original MutantXL in case of GF(2). Not only can MXL2
solve multivariate systems at a lower degree than the usual XL but also can
solve these systems using a smaller number of polynomials than the original
MutantXL, since we produce all possible new equations without enlarging the
number of the monomials. Therefore the size of the matrix constructed by MXL2
is much smaller than the matrix constructed by the original MutantXL. We did
not claim that we are absolutely better than F4 but we are going in this direction.
We apply the mutant strategy into two different systems, namely random and
HFE. We believe that mutant strategy is a general approach that can improve
most of multivariate polynomial solving algorithms.
In the future we will study how to build MXL2 using a sparse matrix represen-
tation instead of the dense one to optimize our implementation. We also need
to enhance the mutant selection strategy to reduce the number of redundant
polynomials, study the theoretical aspects of the algorithm, apply the algorithm
to other systems of equations, generalize it to other finite fields and deal with
systems of equations that have multiple solutions.
Acknowledgment
We would like to thank Ralf-Philipp Weinmann for several helpful discussions
and comments on earlier drafts of this paper.
References
1. Matsumoto, T., Imai, H.: Public Quadratic Polynomial-Tuples for Efficient
Signature-Verification and Message-Encryption. In: Günther, C.G. (ed.) EURO-
CRYPT 1988. LNCS, vol. 330, pp. 419–453. Springer, Heidelberg (1988)
2. Patarin, J.: Hidden Fields Equations (HFE) and Isomorphisms of Polynomials (IP):
two new families of Asymmetric Algorithms. In: Maurer, U.M. (ed.) EUROCRYPT
1996. LNCS, vol. 1070, pp. 33–48. Springer, Heidelberg (1996)
MXL2 : Solving Polynomial Equations over GF(2) 215
∗
3. Patarin, J., Goubin, L., Courtois, N.: C−+ and HM: Variations Around Two
Schemes of T. Matsumoto and H. Imai. In: Ohta, K., Pei, D. (eds.) ASIACRYPT
1998. LNCS, vol. 1514, pp. 35–50. Springer, Heidelberg (1998)
4. Moh, T.: A Public Key System With Signature And Master Key Functions. Com-
munications in Algebra 27, 2207–2222 (1999)
5. Ding, J.: A New Variant of the Matsumoto-Imai Cryptosystem through Pertur-
bation. In: Bao, F., Deng, R., Zhou, J. (eds.) PKC 2004. LNCS, vol. 2947, pp.
305–318. Springer, Heidelberg (2004)
6. Courtois, N.T., Klimov, A., Patarin, J., Shamir, A.: Efficient Algorithms for Solving
Overdefined Systems of Multivariate Polynomial Equations. In: Preneel, B. (ed.)
EUROCRYPT 2000. LNCS, vol. 1807, pp. 392–407. Springer, Heidelberg (2000)
7. Ding, J., Buchmann, J., Mohamed, M.S.E., Moahmed, W.S.A., Weinmann, R.P.:
MutantXL. In: Proceedings of the 1st international conference on Symbolic Com-
putation and Cryptography (SCC 2008), Beijing, China, LMIB, pp. 16–22 (2008),
[Link]
MutantXL [Link]
8. Ding, J., Cabarcas, D., Schmidt, D., Buchmann, J., Tohaneanu, S.: Mutant
Gröbner Basis Algorithm. In: Proceedings of the 1st international conference on
Symbolic Computation and Cryptography (SCC 2008), Beijing, China, LMIB, pp.
23–32 (2008)
9. Courtois, N.T.: Experimental Algebraic Cryptanalysis of Block Ciphers (2007),
[Link]
10. Segers, A.: Algebraic Attacks from a Gröbner Basis Perspective. Master’s thesis,
Department of Mathematics and Computing Science, TECHNISCHE UNIVER-
SITEIT EINDHOVEN, Eindhoven (2004)
11. Shigeo, M.: Hotaru (2005), [Link]
hotaru/hotaru/hfe25-96?view=markup
12. Albrecht, M., Bard, G.: M4RI – Linear Algebra over GF(2) (2008),
[Link]
Side Channels in the McEliece PKC
1 Introduction
J. Buchmann and J. Ding (Eds.): PQCrypto 2008, LNCS 5299, pp. 216–229, 2008.
c Springer-Verlag Berlin Heidelberg 2008
Side Channels in the McEliece PKC 217
well-studied regarding its security against algorithm attacks, to the best of our
knowledge, the McEliece PKC has never been analyzed with respect to side
channel attacks. Side channel attacks target a cryptographic system taking ad-
vantage of its implementation [13,14,15,16]. Algorithm execution is associated
with measurable quantities such as power consumption and execution time. The
amounts of these quantities depend on the data processed by the algorithm. If
the processed data is secret such as a private key, then the measured quanti-
ties may disclose the secret totally or partially. To prevent side channel attacks,
countermeasures must be included during the implementation of the algorithm.
Our contribution
This paper addresses side channel attacks on the McEliece PKC and corre-
sponding countermeasures. It is constructed as follows. Section 2 presents as
preliminaries the Goppa code and the McEliece PKC in brief. Section 3 details
a timing attack on the degree of error locator polynomial, which is used in the
error correction step in the decryption algorithm. A theoretical justification for
this attack is presented as well as experimental results of the execution of the
attack against a software implementation. Also, countermeasures are addressed.
Section 4 outlines two other side channel attacks and related countermeasures:
a power attack on the construction of the parity check matrix during key gener-
ation and a cache attack on the permutation of code words during decryption.
Section 5 concludes the paper.
2 Preliminaries
In this section we assume that the reader is familiar with the basics of error
correction codes. We use the notation given e.g. in [17].
t
g(Y ) = gi Y i ∈ F2m [Y ] (1)
i=0
be monic and irreducible over F2m [Y ], and let m, t be positive integers. Then
g(Y ) is called a Goppa polynomial (for an irreducible binary Goppa code).
Then an irreducible binary Goppa code is defined as
n−1
ci
G(F2m , g(Y )) = {c ∈ Fn2 |Sc (Y ) := = 0 mod g(Y )} (2)
i=0
Y − γi
218 F. Strenzke et al.
Key Generation
The private key. The secret key consists of two parts. The first part of the
secret key in the McEliece PKC is a Goppa polynomial g(Y ) of degree t over
F2m according to definition 1, with random coefficients. The second part of the
private key is a randomly created n × n permutation matrix P.
The public key. The public key is generated from the secret key as follows. First,
compute H on the basis of g(Y ). Then take Gpub = [Ik | R] as the generator
in systematic form corresponding to the parity check matrix HP (refer to
Appendix A for the creation of the parity check matrix and the generator of a
Goppa code).
Encryption. Assume Alice wants to encrypt a message v ∈ Fk2 . Firstly, she has
to create a random binary vector e of length n and Hamming weight wt (e) = t.
Then she computes the ciphertext z = vGpub ⊕ e.
Decryption. In order to decrypt the ciphertext, Bob computes zP. Then he
applies error correction by executing an error correction algorithm, such as the
Patterson Algorithm described in Section 2.3, to determine eP. Afterwards, he
recovers the message v as the first k bits of z ⊕ ePP−1 .
Side Channels in the McEliece PKC 219
where Te = {i|ei = 1} and e is the error vector of the distorted code word to
be decoded. Once the error locator polynomial is known, the error vector e is
determined as
Then, assuming that no more than t errors occurred, Equation 6 can be solved
by applying the Euclidean algorithm with a breaking condition concerning the
degree of the remainder [19]. Specifically, the remainder in the last step is taken
as α(X) and the breaking condition is deg (α(X)) 2t . It can be shown that
then, deg (β(X)) t−1
2 .
From this, it follows that the polynomial σ̄e (X) defined over Equation 5 will
be of degree t. In the case that the number of errors is no larger than t, from
Equation 3 it follows that deg (σ̄e (X)) = wt (e) since then σ̄e (X) = σe (X)
For the case of more than t errors, we give the following remark.
Remark 1. If wt (e) > t, then the deg (σ̄e (X)) = t with probability 1 − 2−m .
This remark can be justified easily: Since the σe (X) computed via Equation 3
would yield deg (σe (X)) = wt (e), we find that the calculation mod g(X) in
Equation 6 leads to polynomials σ̄e (X) of degree t with coefficients that we
can assume to be almost randomly distributed, where the leading coefficient is
220 F. Strenzke et al.
not necessarily non zero. But clearly, for random coefficients out of F2m , the
probability that the leading coefficient is not zero is 1 − 2−m , which is amounts
to 0.9995 for m = 11. Furthermore, experimental results confirm the claim of
the remark.
through all its steps regardless of whether the ciphertext has been manipulated
or not. Only afterwards the algorithm will detect the manipulation and refuse
decryption.
g3 1 g2 1 g3 γ0 g1 1 g2 γ0 g3 γ02 g3 1 g2 1 g3 γ1 g1 1 g2 γ1 g3 γ12
time
Inspecting this relation, two operations may be critical for power attacks [16].
These are the polynomial evaluation for the field elements g(γj ) and the multiplica-
s−t+i−1
tion of the polynomial coefficients with the powers of the field elements gs γj−1 .
Polynomial multiplication. Figure 1 shows schematically the multiplication
steps executed to calculate the first and second column of H. Here, we use t = 3
for simplicity. Remember that H has t rows and n columns.
From this figure it is evident that the multiplication steps and, thus, their
power traces reveal high regularity. An exact application of the above relation
results in multipliying g3 by 1 once for each column of H. Obviously, the power
trace of these products may be used to indicate the start of the processing of
a new column, which is essential for power attacks. Furthermore, it is highly
probable that the power traces of g2 γ0 and g2 γ1 can be used to estimate the
secret coefficient g2 as the γi are public.
To complicate this attack, the multiplications gs γj−1 must be performed in a
manner, which does not leak information on gs . This can be achieved (at least
partially) by masking. Each gs is multiplied by a random value ri ∈ F2m before
multiplying it by the field element γj−1 . The de-masking using ri−1 is performed
after calculating the sum:
t
−1 −1 s−t+i−1
hi,j = g(γj−1 ) ri (ri gs ) γj−1 . (8)
s=t−i+1
In the above equation, the parentheses denote in which order the evaluation shall
be performed.
This masking will be even more profitable if it is combined with a random-
ization of the order of term estimations. By this means the association of power
traces with time is blurred considerably.
Polynomial evaluation. This operation is highly time-consuming and is per-
formed in a pre-estimation phase, as a rule. The description in this section relates
to this pre-estimation. Referring to the definition of the generator polynomial
t
g(Y ), its evaluation for a field element γj can be written as i=0 gi γji . This means
that polynomial evaluation amounts to multiplication over F2m with highly reg-
ular patterns, which again presents a possible side channel for power attacks.
Fig. 2 depicts the chronological sequence of evaluating a polynomial of degree
t = 3 for two field elements in a straightforward implementation. Similar to
the case presented previously, countermeasures of masking and randomization
should be employed.
224 F. Strenzke et al.
g(γ0 ) g(γ1 )
time
Algorithm 2. Permutation of z = zP
Require: Private permutation matrix P lookup-table tP and ciphertext vector z ∈ Fn
2.
Ensure: The permutation z = zP.
1: for i = 1 to n do
2: Lookup j = tP i .
3: Set zi = zj .
4: end for
5: return permutated vector z .
From these timings, gathered while the decryption process was running in
parallel, the attacker will be able to judge with certain precision which part
of z was accessed during which iteration. Specifically, assume that for a certain
iteration the time taken by the memory access of the spy process to a certain date
indicates a cache miss. Then the attacker knows that the decryptions process
accessed just that part of z, which was stored in the same cache block. Note that
the rule relating main memory addresses to cache blocks is system dependent
and thus known to the attacker.
Due to the fact that in general the size of a cache block will be larger than
one entry zi , usually the attacker will not be able to get the exact index of the
entry of z which has been accessed. Instead he will find out that for example an
entry between z0 and z31 must have been accessed. If the memory location of
z differs in different executions and does not always have the same offset from
the beginning of a cache block, the attacker might be able to narrow the access
down to a single entry of z.
In a weaker scenario, where the system running the decryption process does
not support simultaneous multithreading, the attacker will not be able to peek
into the decryption routine at every iteration, but with some probability the
operating system will perform a context switch, interrupting algorithm 2 and
continuing the spy process. In such a scenario the attack would be much harder,
but still not impossible, assuming the attacker can repeat the measurement often
enough.
5 Conclusion
In this paper we have shown that the McEliece PKC like most known public
key cryptosystems, bears a high risk of leaking secret information through side
channels if the implementation does not feature appropriate countermeasures.
We have detailed a timing attack, which was also implemented and executed
against an existing software implementation of the cryptosystem. Our results
show the high vulnerability of an implementation without countermeasures.
Furthermore, we presented a feasible power attack against the key generation
phase, where certain operations involve the same secret value repeatedly. In
general, key generation is a more difficult target for a side channel attack than
decryption, because in contrast to that operation the attacker can only perform
one measurement. But our considerations show, that without countermeasures,
an implementation of the key generation might be vulnerable to a sophisticated
power attack.
Side Channels in the McEliece PKC 227
The cache attack designed to reveal the permutation that is part of the secret
key, again benefits from the fact that the number of measurements the attacker
may perform is in principle without any restraint. Thus the proposed secure al-
gorithm seems to be an important countermeasure for software implementations
intended for use in a multi user operating system.
Clearly, other parts of the cryptosystem require to be inspected with the same
accuracy. This is especially true for the decryption phase, where the secret Goppa
polynomial is employed in different operations.
The McEliece PKC, though existing for 30 years, has not experienced wide
use so far. But since it is one of the candidates for post quantum public key
cryptosystems, it might become practically relevant in the near future. With
our work, besides the specific problems and solutions we present, we want to
demonstrate that with the experience gathered in recent work exposing the vul-
nerabilities of other cryptosystems, it is possible to identify the potential side
channels in a cryptosystem before it becomes commonly adopted.
References
1. Diffie, W., Hellman, M.: New directions in cryptography. IEEE Transactions on
Information Theory 22(6), 644–654 (1976)
2. Rivest, R.L., Shamir, A., Adleman, L.: A method for obtaining digital signatures
and public-key cryptosystems. Communications of the ACM 21(2), 120–126 (1978)
3. Miller, V.S.: Use of Elliptic Curves in Cryptography. In: Williams, H.C. (ed.)
CRYPTO 1985. LNCS, vol. 218, pp. 417–426. Springer, Heidelberg (1986)
4. ElGamal, T.: A Public Key Cryptosystem and A Signature Based on Discrete
Logarims. IEEE Transactions on Information Theory (1985)
5. Shor, P.W.: Algorithms for quantum computation: discrete logarithms and factor-
ing. In: Proceedings, 35-th Annual Symposium on Foundation of Computer Science
(1994)
6. Shor, P.W.: Polynomial time algorithms for prime factorization and discrete log-
arithms on a quantum computer. SIAM Journal on Computing 26(5), 1484–1509
(1997)
7. Proos, J., Zalka, C.: Shor’s discrete logarithm quantum algorithm for elliptic curves,
Technical Report quant-ph/0301141, arXiv (2006)
8. Merkle, R.: A Certified Digital Signature. In: Proceedings of the 9th Annual Inter-
national Cryptology Conference on Advances in Cryptology, pp. 218–238 (1989)
9. Buchmann, J., Garcia, L., Dahmen, E., Doering, M., Klintsevich, E.: CMSS-An Im-
proved Merkle Signature Scheme. In: 7th International Conference on Cryptology
in India-Indocrypt, vol. 6, pp. 349–363 (2006)
10. McEliece, R.J.: A public key cryptosystem based on algebraic coding theory. DSN
progress report 42-44, 114–116 (1978)
11. Korbara, K., Imai, H.: Semantically secure McEliece public-key cryptosystems -
conversions for McEliece PKC. In: Kim, K.-c. (ed.) PKC 2001. LNCS, vol. 1992.
Springer, Heidelberg (2001)
12. Menezes, A., van Oorschot, P., Vanstone, S.: Handbook of Applied Cryptography.
CRC Press, Boca Raton (1996)
13. Kocher, P.: Timing Attacks on Implementations of Diffie-Hellman, RSA, DSS, and
Other Systems. In: Proceedings of the 16th Annual International Cryptology Con-
ference on Advances in Cryptology, pp. 104–113 (1996)
228 F. Strenzke et al.
14. Kocher, P.: Differential Power Analysis. In: Wiener, M. (ed.) CRYPTO 1999.
LNCS, vol. 1666, pp. 388–397. Springer, Heidelberg (1999)
15. Tsunoo, Y., Tsujihara, E., Minematsu, K., Miyauchi, H.: Cryptanalysis of Block
Ciphers Implemented on Computers with Cache. In: International Symposium on
Information Theory and Applications, pp. 803–806 (2002)
16. Schindler, W., Lemke, K., Paar, C.: A Stochastic Model for Differential Side Chan-
nel Cryptanalysis. In: Rao, J.R., Sunar, B. (eds.) CHES 2005. LNCS, vol. 3659,
pp. 30–46. Springer, Heidelberg (2005)
17. MacWilliams, F.J., Sloane, N.J.A.: The theory of error correcting codes. North-
Holland, Amsterdam (1997)
18. Goppa, V.D.: A new class of linear correcting codes. Problems of Information
Transmission 6, 207–212 (1970)
19. Engelbert, D., Overbeck, R., Schmidt, A.: A Summary of McEliece-Type Cryp-
tosystems and their Security. Journal of Mathematical Cryptology (2006) (accepted
for publication)
20. Canteaut, A., Chabaud, F.: A new algorithm for finding minimum-weight words
in a linear code: application to primitive narrow-sense BCH-codes of length 511.
IEEE Transactions on Information Theory 44(1), 367–378 (1998)
21. Pointcheval, D.: Chosen-chipertext security for any one-way cryptosystem. In: Imai,
H., Zheng, Y. (eds.) PKC 2000. LNCS, vol. 1751, pp. 129–146. Springer, Heidelberg
(2000)
22. Percival, C.: Cache missing for fun and profit,
[Link]
23. Schindler, W., Acıiçmez, O.: A Vulnerability in RSA Implementations due to In-
struction Cache Analysis and its Demonstration on OpenSSL. In: Malkin, T. (ed.)
CT-RSA 2008. LNCS, vol. 4964, Springer, Heidelberg (2008)
24. Acıiçmez, O., Seifert, J.P., Koç, Ç.: Predicting secret keys via branch prediction.
In: Abe, M. (ed.) CT-RSA 2007. LNCS, vol. 4377. Springer, Heidelberg (2007)
1 1 1
Z = diag , ,..., .
g(γ0 ) g(γ1 ) g(γn−1 )
Here diag (. . .) denotes the diagonal matrix with entries specified in the argu-
ment. H is t × n matrix with entries in the field F2m .
As for any error correcting code, the parity check matrix allows for the com-
putation of the syndrome of a distorted code word:
Sz (Y ) = zH Y t−1 , · · · , Y, 1 .
Side Channels in the McEliece PKC 229