The Use of Elliptic Curves in Cryptography
Total Page:16
File Type:pdf, Size:1020Kb
Master's thesis in Mathematics The use of elliptic curves in cryptography by Gijsbert van Vliet Nijmegen, June 2015 Supervisors: Prof. dr. B.J.J. Moonen Dr. W. Bosma Acknowledgements First of all I would like to express my sincerest gratitude to my supervisor prof. dr. Ben Moonen for all his support throughout the learning process of this master's thesis. Without his patience, encouragement and all insightful conversations we shared, this thesis would have never been completed. Also I would like to thank dr. Wieb Bosma for putting so much of his precious time into helping me and for providing numerous useful remarks. Furthermore I would like to thank my family and loved ones, who supported me throughout the entire process, both financially and emotionally. Special thanks goes out to my father, Frans van Vliet. He always supported my dreams and aspirations and, if I say so myself, did a fine job raising me. Without him I would have never started this study, let alone finish it. 2 Contents 1 Introduction to Cryptography 6 1.1 The Objectives of Cryptography . 6 1.2 Symmetric vs Public-Key Cryptography . 6 1.3 Complexity . 7 1.4 The Discrete Logarithm Problem . 10 2 Elliptic Curves 12 2.1 Elliptic Curves and the Group Structure . 12 2.2 Weierstrass Equations . 13 2.3 The Geometric Group Law . 16 2.4 Isogenies . 19 2.5 The Frobenius Morphism . 21 2.6 The Dual Isogeny . 23 2.7 The Tate Module . 25 2.8 The Weil Pairing . 26 2.9 The Endomorphism Ring . 28 3 Elliptic Curves over Finite Fields 30 3.1 The Number of Rational Points . 30 3.2 The Group Structure of Elliptic Curves . 33 3.3 The Endomorphism Ring . 35 3.4 Determining the Hasse Invariant . 36 4 Schoof's Algorithm 39 4.1 General Description and the Division Polynomials . 39 4.2 Detailed Description of the Algorithm . 41 4.2.1 Case 1 . 43 4.2.2 Case 2 . 43 4.3 Efficiency of Schoof's algorithm . 45 5 Protocols 48 5.1 Diffie-Hellman Key Exchange . 48 5.2 Two ElGamal Protocols . 50 5.2.1 ElGamal Public-Key Encryption . 51 5.2.2 ElGamal Digital Signature Scheme . 52 6 General Attacks on the DLP 54 6.1 The Pohlig-Hellman Method . 54 6.2 The Baby-Step Giant-Step Algorithm . 57 6.3 The Pollard ρ Method . 59 7 The MOV Attack 61 7.1 The Index Calculus Method . 61 7.2 Computing the Weil Pairing . 63 7.3 The Reduction . 67 7.4 Supersingular Curves . 70 8 The Frey-R¨uck Attack 73 8.1 The Tate Pairing . 73 8.2 The Attack . 76 3 9 Anomalous Curves 82 9.1 The Isomorphism . 82 9.2 Computing the Isomorphism . 86 10 Conclusion 90 A Schoof's Algorithm 95 4 Introduction Elliptic curves have been a subject of research for a long time. They naturally occur in the study of Diophantine equations as well as the study of certain complex line integrals, e.g., complex integrals of the form Z d t=pt(t − 1)(t − λ); which arise when one attempts to compute the arc length of an ellipse. In fact, this is where elliptic curves originally acquired their name from. Around the year 1985 elliptic curves over finite fields, which at first seem to have the structure of rather boring abelian groups, found a new application in cryptography. At that time, discrete logarithm based cryptosystems already played an important role in cryptography. In short, these systems rely on the supposed `hardness' of the discrete logarithm problem for abelian groups. The discrete logarithm problem is the problem of, given a finite abelian group (G; ⊕), a point P 2 G and a point Q 2 hP i, finding an integer k such that [k]P = Q, i.e., such that P ⊕ ::: ⊕ P = Q. Victor S. Miller | {z } k times [35] and Neal Koblitz [27] independently realized that using elliptic curves as groups for these systems might be more efficient than the conventional groups, used at that time. They figured that using elliptic curves in cryptosystems could reduce key sizes, while retaining a similar level of security. However, not all elliptic curves are suitable for cryptography, since in some cases the internal structure of an elliptic curve can be used to solve the discrete logarithm problem efficiently. The main question of this thesis is: What requirements does an elliptic curve need to meet in order to be considered `safe for cryptographic purposes'? In order to answer this question, first elliptic curves have to be defined and their basic properties explained. After that I will explain which requirements an elliptic curve should have in order to provide security for discrete logarithm based cryptosystems and why these requirements have to be met. In short, this thesis consists of the following three parts: Part 1: This part consists only of chapter 1. In this chapter I will give a short introduction to the subject of cryptography and the role of the discrete logarithm problem in this subject. Part 2: The second part of this thesis consists of chapters 2 to 4. In this part I will define elliptic curves and give its basic arithmetic properties. Chapter 2 will give the basic properties of elliptic curves over arbitrary algebraically closed fields, while chapter 3 will deal with elliptic curves over finite fields. In section 4 an algorithm will be given that computes the most important quantity of elliptic curves over finite fields, i.e., its number of rational points. Part 3: In the last part I will focus on the role of elliptic curves in cryptography. First, in chapter 5, I will give a few explicit examples of how elliptic curves can be used in cryptography. After that I will explain the most important attacks on the discrete logarithm problem. These include attacks on the discrete logarithm problem for general groups in chapter 6 and three attacks on this problem for certain specific elliptic curves in chapter 7 to 9. In this thesis I will assume that the reader has some basic mathematical maturity. For example, some knowledge about abelian groups, rings and (general and finite) fields is necessary. Also I will use Cayley- Hamilton's theorem and the Chinese remainder theorem without stating them. In addition I will assume the reader to be familiar with the notion `algebraic varieties' and `algebraic curves'. Some basic knowledge about objects like the divisor group of a curve or the vector space of differential forms on a curve will be very useful. For a reader who is unfamiliar with the subject, reading the first two chapters of Silverman's beautifully written book [45] might suffice. 5 1 Introduction to Cryptography 1.1 The Objectives of Cryptography Suppose someone wants to send a message to a receiver, but he wants to be sure that no-one else can read it, even though the message might be intercepted by a third party. The solution to this problem is cryptography. Cryptography uses mathematics to enable us to transmit sensitive information safely over a potentially insecure network. It is a very interesting field of research where security and computer science meet mathematics. However even before computers existed, cryptography was already used. For example in the first and second world war, the government as well as the military relied on cryptography to safely send sensitive information to one another. Later, with the upcoming of computers and the ienternet, the demand for cryptography from the private sector rose. Nowadays cryptography is widely used by businesses and banks all over the world. We will assume a situation where Alice and Bob (commonly used in cryptography because of their handy abbreviations A and B) want to communicate in a secure manner over an insecure channel. That is, if an eavesdropper Eve (E) were to listen to the conversation, he or she should not be able to extract the original message. In cryptographic terminology the original message is called plaintext or cleartext, encoding the message in such a way that the content is hidden for Eve is called encryption, the encrypted message is called cyphertext and the process of retrieving the plaintext from the cyphertext is called decryption. The manner in which the cleartext is encrypted is called the cryptographic system or cryptosystem. The secret information used to encrypt the the cleartext is called the key of the cryptosystem. Thus being in possession of the key should make decrypting the cyphertext `easy'. Cryptography in general is concerned with a number of problems. The most important ones are listed below: • Confidentiality, which is the process of keeping information secret so that only the intended recipient is able to understand it. • Authentication, which is the process of providing proof of identity of the sender to the recipient, so that the recipient can be assured that the sender is who he claims to be. • Integrity, which is the problem of ensuring that the send information is not altered or otherwise tampered with during its transit or its storage on a network. • Non-repudiation, which prevents an entity from denying having send a certain message. For example, the sender might have send authorization for the purchase of property to someone else and later deny having given such authorization. Adequately addressing these problems is the main goal of cryptography. 1.2 Symmetric vs Public-Key Cryptography Roughly speaking there are two kinds of cryptosystems; symmetric and Public-key or asymmetric cryptosys- tems. In a symmetric cryptosystem Alice and Bob need to have access to the same secret key, which is used to encrypt the plaintext as well as decrypt it.