IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the...

12
http://iaeme.com/Home/journal/IJEET 178 [email protected] International Journal of Electrical Engineering and Technology (IJEET) Volume 11, Issue 2, March-April 2020, pp. 178-189, Article ID: IJEET_11_02 22 _0 Available online at http://iaeme.com/Home/issue/IJEET?Volume=11&Issue=2 ISSN Print: 0976-6545 and ISSN Online: 0976-6553 Journal Impact Factor (2020 10.1935 (Calculated by GISI) www.jifactor.com ): © IAEME Publication IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY Monika Department of Applied Mathematics, Delhi Technological University, Delhi, India Tanya Tomar Department of Applied Mathematics, Delhi Technological University, Delhi, India Vineet Kumar Department of Applied Mathematics, Delhi Technological University, Delhi, India Yogesh Kumar Department of Applied Mathematics, Delhi Technological University, Delhi, India ABSTRACT Elliptic curve cryptography (ECC) is a procedure to generate public key between two distant partners namely, Alice and Bob used in public key cryptography. This method is based on the algebraic structure of elliptic curves over finite fields. ECC is important in the sense that it involve keys of smaller length in comparison to other non-Elliptic curve cryptography to provide equivalent security. During this work, we implement an algorithm in python programming language to generate public key using the method of ECC. Keywords: Diophantine Equation, Elliptic - Curve Cryptography, Elliptic Curve Diffie Hellman Key Exchange, Elliptic Curve Integrated Encryption Scheme. Cite this Article: Monika, Tanya Tomar, Vineet Kumar and Yogesh Kumar, Implementation of Elliptic - Curve Cryptography, International Journal of Electrical Engineering and Technology, 11(2), 2020, pp. 178-189. http://iaeme.com/Home/issue/IJEET?Volume=11&Issue=2 1. INTRODUCTION A finite field is defined as a field with finite number of elements. It is also known as Galois field. The number of elements in a finite field is always prime p or a power of a prime p n. For each prime power q where q = p n, there exists one finite field Fq (up to an isomorphism). These finite fields form an abelian group with respect to the binary operation , and therefore,

Transcript of IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the...

Page 1: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

http://iaeme.com/Home/journal/IJEET 178 [email protected]

International Journal of Electrical Engineering and Technology (IJEET) Volume 11, Issue 2, March-April 2020, pp. 178-189, Article ID: IJEET_11_02 22 _0Available online at http://iaeme.com/Home/issue/IJEET?Volume=11&Issue=2 ISSN Print: 0976-6545 and ISSN Online: 0976-6553 Journal Impact Factor (2020 10.1935 (Calculated by GISI) www.jifactor.com ): © IAEME Publication

IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY

Monika Department of Applied Mathematics,

Delhi Technological University, Delhi, India

Tanya Tomar Department of Applied Mathematics,

Delhi Technological University, Delhi, India

Vineet Kumar Department of Applied Mathematics,

Delhi Technological University, Delhi, India

Yogesh Kumar Department of Applied Mathematics,

Delhi Technological University, Delhi, India

ABSTRACT Elliptic curve cryptography (ECC) is a procedure to generate public key between two distant partners namely, Alice and Bob used in public key cryptography. This

method is based on the algebraic structure of elliptic curves over finite fields. ECC is important in the sense that it involve keys of smaller length in comparison to other non-Elliptic curve cryptography to provide equivalent security. During this work, we

implement an algorithm in python programming language to generate public key using the method of ECC. Keywords: Diophantine Equation, Elliptic - Curve Cryptography, Elliptic Curve Diffie Hellman Key Exchange, Elliptic Curve Integrated Encryption Scheme. –

Cite this Article: Monika, Tanya Tomar, Vineet Kumar and Yogesh Kumar, Implementation of Elliptic - Curve Cryptography, International Journal of Electrical Engineering and Technology, 11(2), 2020, pp. 178-189. http://iaeme.com/Home/issue/IJEET?Volume=11&Issue=2

1. INTRODUCTION A finite field is defined as a field with finite number of elements. It is also known as Galois field. The number of elements in a finite field is always prime p or a power of a prime p n. For each prime power q where q = p n, there exists one finite field Fq (up to an isomorphism). These finite fields form an abelian group with respect to the binary operation , and therefore, ∗

Page 2: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Implementation of Elliptic - Curve Cryptography

http://iaeme.com/Home/journal/IJEET 179 [email protected]

every finite field has a generator G. It is a very well known fact that computer stored every number in binary form and they are the components in finite field whose order is two. Also

data can be stored in a computer as a vector in a finite field that allows mathematical operations to remove data easily and effectively. Finite Field has widespread application in

Cryptography. Since each byte of data can be represented as a vector in a finite field so encryption and decryption schemes using basic mathematical operation is easily manipulable.

Data Encryption Standard (DES) developed by IBM uses only 56-bit key. Since the advancement of technology break the 56-bit key in less than 24 hours so revolutionary

algorithm is needed [1 4]. In 2001, Vincent Rijmen and John Daemon discovered a more –complicated encryption algorithm to cater the need of advanced encryption algorithm, now

known as Advanced Encryption Standard (AES). Elliptic-curve cryptography (ECC) is a public-key cryptography whose working is based on elliptic curves over the finite fields. The algorithm of ECC mainly works on Elliptic Curve Discrete Logarithm Problem (ECDLP) that is very hard to solve quickly. If some mathematical problem is posed in terms of elliptic curve then there is no straight method that gives the solution of the posed problem. So the only way to find the solution is to try with random numbers. Since each bit size provides more options

than RSA so there is more room for growth. The amount of data which is necessary to exchange or transfer for validation is less than RSA. ECC requires less computing power and battery resource. Despite of many advantages of ECC, there are only a few implementation of ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical protocols based on elliptic curve and then we have generated code in python programming language to implement ECC.

Figure 1 Asymmetric Encryption

This is often however most hybrid encryption schemes works (the encryption process)

Figure 2 Encryption process

Page 3: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Monika, Tanya Tomar, Vineet Kumar and Yogesh Kumar

http://iaeme.com/Home/journal/IJEET 180 [email protected]

This is often however most hybrid decryption schemes works (the decryption process)

Figure 3 Decryption process

1.1. Elliptic - curve An elliptic curve E over finite field Fq is the set of all points (x, y) lying on the curve

y² = x³ + ax + b (1) where a ,b ∈ Fq and 4a³ + 27b² ≠ 0, together with a point at infinity (∞).

E forms an abelian group with the identity element e addition of two ∞.The rule for thpoints on the curve is given below:

If P = (x , y ₁ ₁) ∈ E then −P = x ,−y₁ ₁

If Q = (x , y , y ), ₂ ₂) ∈ E, Q = −P, then P + Q = (x₃ ₃

where x , y (2) ₃ = λ² −x₁ −x₂ ₃ = λ(x )−y₁−x₃ ₁

and

, if P ≠ Q

, if P=Q (3) Example: Consider the elliptic curve E : y² = x³ + x + 1 defined over Z₁₃. Generator of

E(Z ) is P = (0,1). The points on the curve E can be expressed in terms of P as: ₁₃ P = (0,1) = , y 2P = , y ) (4) (x₁ ₁), (x₃ ₃

Considering equation 3: , if P =Q

x = ²- 2x ₃ ₁

= (3)² - 2(0) = 9 Considering equation 2: y = ₃ λ(x₁ −x₃)−y₁ = ((3(0−0)−1)mod11

= −1mod11 = 10

Page 4: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Implementation of Elliptic - Curve Cryptography

http://iaeme.com/Home/journal/IJEET 181 [email protected]

Figure 4 Elliptic curve

It is known that every elliptic curve is not useful in cryptography. So it is important to know what type of elliptic curve is useful in Cryptography. The elliptic curves that form

cyclic groups and the elliptic curve point that generates all the points of the cyclic subgroup are useful in cryptography. Cryptography based on Elliptic curve is known as Elliptic curve cryptography (ECC). A 160-bit ECC key is roughly equivalent to a 1024-bit RSA key.

2. ELLIPTIC CURVE DIFFIE-HELLMAN KEY EXCHANGE PROTOCOL In this section, we will discuss the Diffie Hellmann key – ex- change protocol on elliptic curves.

The Elliptic Curve Diffie- Hellmann (ECDH) protocol is a secret key generation protocol between two distant parties Alice and Bob and the secret key is one of the point on the elliptic curve. There are also some practical implementations of ECDH that can be found in [6 9]. –

The ECDH protocol can be described as follows: Suppose denote the elliptic curve over E Fq. Before starting the protocol, let us assume that the two distant partners Alice and Bob

mutually agreed upon a point on the elliptic curve. Alice secretly chooses a randomly Q

generated integer KA X Kand calculate the point = A Q. Then Al- ice send to Bob. X

Likewise, Bob also generate an integer KB randomly and compute the point Y K= BQ. Bob then send to Alice. After obtaining from Alice, Bob compute Y X KBX = KBKAQ and in a similar fashion, Alice compute KAY = KAKBQ K. Since A Kand B Kare integers so BKAQ =

KAKBQ. Thus the common shared key between Alice and Bob is KS K= AKBQ. If there is any eavesdrop- per in the middle who wanted to steal the information contained in the

encoded text then the eavesdropper should have knowledge about the secret key KA Kand B of Alice and Bob. But since the secret key KA Kand B is known only to Alice and Bob

respectively not possible for any eavesdropper to gain information about the encoded so it ismessage.

2.1. Implementation of ECDH in Python Programming Language We are now in a position to implement ECDH protocol in python programming language. We use the tinyec library for ECC in Python. pip install tinyec from tinyec import registry import secrets def compress(publicKey): return hex(publicKey.x) + hex(publicKey.y % 2)[2:] curve = registry.ge t_curve(’brainpoolP256r1’)

Page 5: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Monika, Tanya Tomar, Vineet Kumar and Yogesh Kumar

http://iaeme.com/Home/journal/IJEET 182 [email protected]

Ka = secrets.randbelow(curve.field.n) X = Ka * curve.g print("X:", compress(X)) Kb = secrets.randbelow(curve.field.n) Y = Kb * curve.g print("Y:", compress(Y)) print("Currently exchange the publickey (e.g. through Internet)") aliceSharedKey = Ka * Y print("Alice shared key :",compress(aliceSharedKey)) bobSharedKey = Kb * X print("Bob shared key :",compress(bobSharedKey)) print("Equal shared keys:", aliceSharedKey == bobSharedKey)

2.2. Example We consider here that the secret keys KA Kand B are generated randomly by sender Alice and receiver Bob using the code explained in the previous section. Therefore, the randomly generated keys KA Kand B are given by KA = 0 66 808 6 5 6 6620934 6 2 8 47 9786 00 2 06 53 0 27535641 5 1x c e b be d bc ffa b b f c bfb d a c a d (5) KB = 0 7x d15195432 1 7d ac f 38 054 07 9 2aeb d d b e1 913faa b7

d a d efdd a08 4 5 4 1ee8d a9 31916 0 27535641 5 0 1 (6) d53a c a d d

Let us assume that Alice and Bob pre-agreed with the point Q given by Q = (0xd458 7 127 671 0 330266 246769353 012073 97 8e d ae b c d a e acf ,

x d bddc cf b a df b0 325930500 851f 336 050 7fb11 5673 1645086 3 ) (7) When Alice send the point X = KAQ to Bob and Bob shared the point Y = KB Q with Alice

then the generated secret key is shared between Alice and Bob . This secret key is common for both the users and is given by KS=0x f a dbb df bb dd c b a e e a90 5 1cf2ed1 0322178 6 0 72 541884618 2989 3 5 663198 667 621 (8)

The elliptic curve which is being used for the ECDH calculations is 256-bit named curve brainpoolP256r1 [14] (uses Diophantine equation for the generation of points). The private keys are randomly 256-bit (64 hexadecimal digits) . The public keys and shared keys are 257 bits (65 hexadecimal digits 256 bit due to key compression). Due to randomization the secret , keys KA Kand B are different but the calculated shared secret key between Alice and Bob will always be same.

3. ECC-BASED SECRET KEY DERIVATION (USING ECDH) In this section will derive the shared secret key which is used for symmetric encoding with wethe help of same rule as in ECDH mentioned above some modification. The discussion withover secret key generation protocol is as follows: Assume we have a cryptographic elliptic curve over finite field E Fq and its generator point Q on the elliptic curve .Con- template we have a EC private-public key pair We would like to encrypt and decrypt data using these keys. . Working of Asymmetric encryption can be given as : if we encrypt the plain text by a private key KP Kand calculate X = P Q which is the public key known in the medium for transfer of data, then likewise we will decrypt the cipher text later by the - sociated ciphertext public askey Y = KC KQ which is calculated by considering the private key of cipher text C . We will use the subsequent two functions to calculate a shared ECC secret key : S

Page 6: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Implementation of Elliptic - Curve Cryptography

http://iaeme.com/Home/journal/IJEET 183 [email protected]

Calculate Encryption Key(KP Q > ) – (S, KC Q)

1. Generate new random private key = KC . 2. Calculate Y = KC Q. 3. Calculate = (S KP Q) ∗ KC . 4. Return each the + (S KC Q S K) . Use the for symmetric encryption. Use the ( C Q)

to calculate the decryption key Calculate Decryption Key(KP , KC Q > S ) –

1. Calculate = (S KC Q) ∗ KP . 2. Return the and further use it for the decoding. S

The equation takes the subsequent form: (KP Q K∗ ) ∗ C K= ( C Q K∗ ) ∗ P S = This is what these two functions calculate, following the ECDH key derivation scheme.

Within the hybrid encryption schemes the encapsulated (KC Q) is referred to as ”ephemeral key” , as it is employed temporary, to derive the symmetric encryption key, using the ECDH key agreement scheme.

3.1. Implementation of ECC-Based Secret Key Python Programming inLanguage The below Python programming language code uses the tinyec library to urge a ECC private-public key pair for the message recipient (based on the brainpoolP256r1 curve) so derive a S (for encryption) and (KC Q) (for ECDH) from the public key and later derive same recipient’s

S (for decryption) from the recipient’s private key and thus the generated earlier (KC ∗ Q) : from tinyec import registry import secrets

curve =registry.get_curve(’brainpoolP256r1’)

def compress_point(point): return hex(point.x) + hex(point.y % 2)[2:] def ecc_calc_encryption_keys(X):

= secrets.randbelow(curve.field.n) Y = Kc Kc * curve.g

S = X * Kc return (S, Y)

def ecc_calc_decryption_key(Kp, Y): S = Y * Kp

return S = crets.randbelow(curve.field.n) Kp se

X = Kp * curve.g

print("Kp:", hex(Kp)) print("X:", compress_point(X))

(encryptKey, = ecc_calc_encryption_keys(X) Y)

Page 7: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Monika, Tanya Tomar, Vineet Kumar and Yogesh Kumar

http://iaeme.com/Home/journal/IJEET 184 [email protected]

print("Y:",compress_point(Y))

print("encryption key:",compress_point(encryptKey)) decryptKey = ecc_calc_decryption_key (Kp, Y)

print("decryption key:",compress_point(decryptKey))

3.2. Example We consider here that the private secret key KP is generated randomly by medium for plain and cipher text in Asymmetric encryption using the code explained in the previous section. Therefore, the randomly generated keys KP is given by:

KP=0x e b cde cdf e a a abd b2 2921 4 59 01 7 014 322 530 30 15085 31 6 59502 761 29 9 (9) c cb e da d e

Let us assume that the generator point Q the protocol given in is by Q e d ae b c d a e acf , =(0xd458 7 127 671 0 330266 246769353 012073 97 8 x d f bddc b a df b 0 325930500 851 336 050cf7fb11 5673 1645086 3 ) (10)

The public keys which are known in the medium for the transfer of data are denoted by X and for plain text and cipher text respectively Y

X=0x850d3873cf4ac50ddb54ddbd27f8225fc43bd3f4c2cc0a4f9d1f 9ce15fc4eb711 (11)

Y x f d bc c d c =0 71586 9999 3ee050005054 681 1 96 5eb054ca b ba e b15 080 245 495627003 0 (12)

The generated common key shared for encryption and decryption in symmetric encryption Encryptionkey x d d f f f b a f =0 9 13 3 8 9747669432 575731926 5ed99 6883

cbd ffa b ae00146 3203 7ff 8 1 1 (13) Decryptionkey x d d f f f b a f =0 9 13 3 8 9747669432 575731926 5ed99 6883

00146 3203 7 8 1 1 (14)cbd ffa ff b ae Encryptionkey Decryptionkey S = = (15)

The code demonstrates that we are able to generate a pair {S +(KC Q∗ ) } from given EC public key and later we are able to recover the similar secret

key from the pair { (KC Q K∗ )+ P}. It is clear that encryption key (derived from the public key) and the decryption key

(derived from the corresponding private key) are the equivalent. The above mentioned keys are going to be used for encoding and decoding in an integrated encryption scheme.

4. ELLIPTIC CURVE INTEGRATED ENCRYPTION SCHEME The expanded version of encryption and decryption scheme is the Elliptic Curve Integrated Encryption Scheme (ECIES). This scheme may be considered as another form of the ElGamal scheme proposed by Abdalla, Bellare, and Rogaway in [10] and can be considered as a hybrid

encrytion scheme. It is using Diffie-Hellmann protocol followed by symmetric encryption scheme. A standard symmetric key which is encoded with a 1024 bits RSA key mainly

produces an output of 128 bytes as compared with the output of 84 bytes if the encryption is performed with ECIES [11].The scheme ECIES can be implemented using following three algorithms:

Page 8: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Implementation of Elliptic - Curve Cryptography

http://iaeme.com/Home/journal/IJEET 185 [email protected]

Key generation algorithm, Encryption algorithm and Decryption algorithm.

ECIES can be shown by the following diagram:

Figure 5 ECIES

1. Algorithm for key generation is as follows: Choose a shared secret Q є [1, p] as a private key. Generate a public key KB Q= [ ]P , where P is a point on the elliptic curve. Return key pair (KB , Q).

2. Encryption scheme algorithm can be described as follows: In this encryption scheme, let us assume that Alice wants to send a message to Bob. Bob

possesses public key KB. Alice and Bob both knew the private key . Q Alice generates a random number k є [1, p]. Alice then calculates = [ ] and = [ ]U k P V k KB. Alice uses a key derivation function (KDF) to compute two keys and om . k₁ k₂ fr V

o uses SHA-256 hash 192-bit x coordinate of Point V into 256 bit code. to o breaks it into 128-bit key 1 and 128-bit key k k₂.

Alice uses 128-bit AES encryption algorithm for encoding her message m with key k₁, and further obtain cipher text c.

Alice then chooses HMAC-SHA 256 to calculate a MAC (message authentication) code denoted by with key . r k₂

Alice sends (U, c, r) as the cipher text to Bob. 3. Decryption scheme algorithm can be explained in the following way:

Bob split the cipher text e into three components (U, c, r). Bob uses his secret private key Q, so he can computes V= [Q]U. Bob uses the same key derivation function to obtain and k1, k2. Bob computes MAC using k2 and compares the result with r. If they are different, then he declare that the message is fake. Lastly, Bob uses the 128-bit AES decryption algorithm to decrypt c.

In this way, Bob is able to decode the original message m.

Page 9: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Monika, Tanya Tomar, Vineet Kumar and Yogesh Kumar

http://iaeme.com/Home/journal/IJEET 186 [email protected]

The ECIES encoding scheme is a framework, not a concrete formula. It may be enforced by plugging totally different algorithms, e.g. the secp256k1 elliptic curve for the public-key

calculations + Scrypt (Password based KDF) + AES(Advanced Encryption Standard) for symmetric cipher and authentication tag + HMAC-SHA512 for MAC (unauthenticated

encryption).

4.1. Implementation of ECIES in Python Programming Language In this section, we have presented a code python programming language implement in toECIES protocol. The code given below. is

pip install eciespy from ecies.utils import generate_eth_key

from ecies import encrypt, decrypt import binascii = generate_eth_key() Kp privateKeyHexadecimal = privKey.to_hex() publicKeyHexadecimal =privKey.public_key.to_hex() print("Encryption publickey:",publicKeyHexadecimal) print("Decryption privatekey:",privateKeyHexadecimal) m = plaintext for b’Some encryption’

print("Message:", m) encrypted = encrypt(publicKeyHexadecimal,m)

print("Encrypted:",binascii.hexlify(encrypted)) decrypted = decrypt(privateKeyHexadecimal,encrypted) print("Original Message:", decrypted)

The python code above generate ECC public + private key pair using ecies.utils.generate eth key() and call the ecies.encrypt((KB Q K), msg) and decrypt( B, encryptedMsg) functions from the eciespy library.

4.2. Example As discussed earlier the input which is needed to proceed with ECIES are public key which is used in encryption and the message which is encrypted and then transferred to the receiver m so that it is not eavesdropped in between the secured channel. Finally at the senders end the encrypted text is con- verted back to original message using private key. So the pair of public-private key generated by using code above are : Encryptionpublickey x dc e c b c b bd f=0 0 8 06 055 45ecf110258ed5 0261ce2019 1 0 8f 226 010 448 8 304 0915 68 7 8 4021 28 92 27 08 695dcd dade b f a c cdf ddded e d fb e d df f

48 0 2 41 750 7 (16)a d c ddee fc Decryptionprivatekey= x b c e c a fbe ace a e b b0 487fd8 53 471 3 38484 0 4751 67 9ed28 60ea6 0 4

4 445 881 99 (17) c b f d Consider the message over which the ECIES protocol is applied for further m

understanding: Message: b’Some plaintext for encryption’

Page 10: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Implementation of Elliptic - Curve Cryptography

http://iaeme.com/Home/journal/IJEET 187 [email protected]

Before the message is sent to the sender this is the encrypted text formed using the code above : Encrypted b= J045699078 101 270572 0 68 8 7 6 377 60 2 5 7 86 2bbd e d d e87a f b cc ebeeffb d fcac dc bdd a6 7 79 13 92 923 0 2 418 7856 27157 150 5 72 4 8 312467 13221 7049 7 2 0d f d b e a e cdbe a b ef d c f f f d ebe b ed fed253 13117129 7 881 8 004bce a b01bb b dfbf ff11 3f ebed c bc c d b e4 732744 49ea03230 2 1 2ec80774 79 075431 2019464 3 97 96c d d de ceb J (18)

At the sender’s side the encrypted text is decrypted to its original message: Original Message: b’Some plaintext for encryption’

The Python eciespy library uses ECC cryptography over the curve + AES authenticated encoding. Note that the above encrypted message holds these values: {KC Q, AES nonce,

authentication Tag, Advanced Encryption Standard-ciphertext} , packed in binary form.

5. DISCUSSION Some browsers support certificates. Microsoft - signed support for EC into don’t EC de

Windows Vista, however earlier versions together with Windows XP do not support EC C.Re- liable information for supporting ECC mobile platforms - not presently offered. ECC in is

signature verification may a - tensive task carrying computation and may be slower be in in it than RSA on the devices which contain slower processors. Still has some patent issues,

particularly for binary curves.

6. CONCLUSION Encryption is defined as the process of converting plain- text into randomly generated

meaningless text referred to as cipher text. Decryption is defined as converting the cipher text to its original form. The aim of every encryption and decryption algorithm is to make it

difficult to attack on the data and hence the transfer of data from sender to receiver is un- interrupted because we come across many incidents involving cybercrime (computer -oriented crime) which attacks data or network. We have implemented ECC, and its modified algorithm (ECIES) and (ECDH) in python explaining each step of every algorithm via computer code.

Initially considering brain poolP256r1 elliptic curve and applying the EC multiplication property to the points (public and private key) , which returned encrypted data, decrypted data

and shared keys. Security benefit of ECC is much more than RSA and DSA. A serious weakness in RSA is sharp increase in key size is remunerated by smaller keys in EC. ECC is additionally quicker for a variety of reasons. Firstly, smaller keys means that there is less data which needs to be transmitted from the server to the client during an SSL handshake [17]. Moreover, EC needs less process power (CPU) and memory, leading to consider- ably quicker response times and throughput on Web servers once it is in use. A essential benefit of using ECC is Perfect Forward Secrecy (PFS) [18]. The cipher suites which is being supported by modern Web servers and browsers which implement PFS also implement ECC. Web servers which prefer Ephemeral ECDH (ECDHE) using cipher suites gain the advantage of each EC and PFS. ECIES uses the most secure way to calculate a key is by employing a secure ”key

derivation function” (KDF) [19]; the output of KDF is a ”derived key.” [20] Derived keys are even as secure as random keys.

Particularly, they create it less expensive to buy, use, and maintain systems that uses them.

Page 11: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Monika, Tanya Tomar, Vineet Kumar and Yogesh Kumar

http://iaeme.com/Home/journal/IJEET 188 [email protected]

REFERENCES [1] U.S. National Security Agency. Archived from ”Fact Sheet NSA Suite B Cryptography”.

the original on 2009.

[2] “Commercial National Security Algorithm Suite “.www.nasa.gov 19 August 2015. Archieved from the original on 2091-06-04. Retrived 2020.

[3] cryptosystems RSA Laboratories. ”6.3.4 Are elliptic curve patented?”. Archived from the original on 2016.

[4] Bernstein, D. J. ”Irrelevant patents on elliptic curve cryptography”.-

[5] https://eprint.iacr.org/2011/283.pdf.

[6] Certicom Research, Standards for efficent cryptography, SEC 1: Elliptic Curve Cryptography, Version 2.0, May 21, 2009.

[7] American National Standards Institute (ANSI), Public Key Cryptography for the Financial Services Industry: Key Agreement and Key Transport Using Elliptic Curve Cryptography, X9.63, 2001.

[8] National Institute of Standards and Technology (NIST), Recommendation for Pair-wise Key Establishment Schemes Using Discrete Logarithm Cryptography, SP 800-56A, 2005.

[9] Institute of Electrical and Electronics Engineers (IEEE), Standard Specifications for Public Key Cryptography, Std. 1363, 2000.

[10] M. Abdalla, M. Bellare, P. Rogaway, DHAES: An cryption scheme based on the en DiffieHellman problem. Submission to IEEE P1363, November 1998.

http://grouper.ieee.org/groups/1363/StudyGroup/; M. dalla, M. Bellare, P. Rogaway, Ab DHIES: An encryption scheme based on the DiffieHellman problem, in IEEE P1363a,

1998.

[11] V.G. MAtnez, L.H. Encians, and C.S. Avila, Journal of computer science and engineering 2,7, 2010.

[12] Commercial National Security Algorithm Suite and Quantum Computing FAQ U.S. National Security Agency, Janua ry2016.

[13] NSA Suite B Cryptography, Sutie B Implementers’ Guide to NIST SP 800-56A Archived 2016-03-06 at the wayback Machine, July 28, 2009.

[14] ECCurveRegistry. https://github.com/alexmgr/tinyec/blob/master/tinyec/registry.py [15] HybridSystem.

https://www.cryptopp.com/wiki/Elliptic_Curve_Integrated_Encryption_Scheme.

[16] Library. https://pypi.org/project/eciespy/ [17] https://casesecurity.org/2014/06/10/benefits-of-elliptic-curve-cryptography/ [18] https://whatis.techtarget.com/defination/perfect-forward-secracy [19] d Hashing “Salted Passwor – Doing it Right”. CrackStation.net. Retrieved 29 January 2015.

[20] “Password Hashing Competition”

[21] Akshatha M M, Lokesh B, Nuthan A C, A Novel Technique of Visual Cryptography for Maintaining the Security of Visual Information Transaction, International Journal of Electronics and Communication Engineering & Technology, 5(8), pp. 194 199. 2014. –

[22] Arun Kumar Gandhi, Dr. S.S. Tyagi , A Survey of Elliptic Curvecryptography Using Character Conversion Method, , 1(1), pp. Journal of Computer Engineering & Technology10 17. 2013. –

Page 12: IMPLEMENTATION OF ELLIPTIC - CURVE CRYPTOGRAPHY...ECC. This motivate us to work on the implementation of Elliptic Curve cryptography. In this work, we have studied few cryptographical

Implementation of Elliptic - Curve Cryptography

http://iaeme.com/Home/journal/IJEET 189 [email protected]

[23] Dr. Mala and Karthikeyan. Artificial Neural Cryptography Datagram Hiding R. K.Techniques For Computer Security Objects Register, International Journal of Computer Engineering and Technology, 7(2), pp. 36 43. 2016. –

[24] Ahmed Tariq Sadiq, Amjed Abbas Ahmed, Sura Mazin Ali, Attacking Classical Cryptography Method Using Pso Based On Variable Neighborhood Search, International Journal of Computer Engineering and Technology, 5(3), pp. 34 49. 2014. –

[25] Devasena and Dr. Nageswara Rao, Collaboration Pattern in Cryptography Research T. P. Output (1976 2015): A Scientometric Study. – International Journal of Library &

Information Science, 7(2), pp.18 29. 2018. –