Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
17 views4 pages

Encryption Decryption Using Elliptical C

Uploaded by

dianec0304
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views4 pages

Encryption Decryption Using Elliptical C

Uploaded by

dianec0304
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

DOI: http://dx.doi.org/10.26483/ijarcs.v8i7.

4208
ISSN No. 0976-5697
Volume 8, No. 7, July – August 2017
International Journal of Advanced Research in Computer Science
REVIEW ARTICLE
Available Online at www.ijarcs.info

ENCRYPTION/DECRYPTION USING ELLIPTICAL CURVE CRYPTOGRAPHY

Ansah Jeelani Zargar Mehreen Manzoor


Student, Computer Science Engineering, Student, Computer Science Engineering,
SSM College of Engineering and Technology, SSM College of Engineering and Technology,
Kashmir, India Kashmir, India,

Taha Mukhtar
Assistant Professor, Computer Science Engineering,
SSM College of Engineering and Technology, Kashmir, India,

Abstract: One of the buzzwords in network security nowadays is the ECC-Elliptical Curve Cryptography. It is one of the best cryptography
techniques that provide security to our personal as well as professional data over the network. In our day to day life the need of data sharing has
increased exponentially. We like to stay updated with every events occurring around and love to be a “know-it-all”. With the upswing of social
networking people stay connected all the time. They make their social media profiles and use them to communicate by sharing their information
over the network. It has become a necessary part of our life. The need for securing that data has also increased, in order to prevent attacks that
may cause unauthorized access to our data, misuse of our data or modification of our data and also to maintain privacy over the network. Thus
sharing the data has to be done in such a way such that only the sender and the receiver understands it and no one else on the network does. It is
done by using methods of encryption and decryption, wherein we change our data in a way that it becomes senseless to everyone, until it is
changed back to its original form in order to make sense out of it. We have many techniques for doing the same. In this paper we will be
discussing about two such techniques that encompass not only server and desktop systems, but also large numbers of small devices ranging from
PDAs and cell phones to appliances and networked sensors. To the end we will be making a necessary comparison between the techniques
explaining why ECC is better than any other cryptographic techniques recent to it.

Keywords: Efficiency, Elliptical Curve Cryptography (ECC), Personal Digital Assistant (PDA),Ron Rivest, Adi Shamir and Leonard Adleman
(RSA), Signature Verification.
However it is very tough to do so in the exposed
environments where wireless sensing networks are used to
1. INTRODUCTION
achieve safety requirements. Several researchers have
Cryptography [1] has been derived from Greek word concentrated on evaluating cryptographical algorithms in
“krptos” meaning “hidden or secret” and “graphy” means
“writing or study”. It is the practice and study of techniques wireless sensing networks and are offering energy efficient
that allow us to make secure communication possible in ciphers as well. Symmetric key algorithms are much faster
presence of third parties called adversaries. It constructs and computationally than asymmetric algorithms as the
analyses protocols that prevent third parties from reading encryption process is less intricate. Examples are AES, etc.
private messages or confidential data. Confidentiality, data Asymmetric encryption (also called public-key
integrity, authentication, and non-repudiation are central to cryptography) uses two associated keys (public and private)
cryptography. Modern cryptography exists in almost every for data encryption and decryption, and takes away the
disciplines like mathematics, computer science and security risk of key allotment. The secretive key is never
electrical engineering. Cryptography involves two methods exposed. A message that is encrypted by using the public
called encryption and decryption. Encryption changes the key can only be decrypted by applying the same process and
plain text to cipher text using encryption algorithms such using the identical private key. Likewise, a message that is
that no one other than the sender can make sense out of it encrypted by using the secretive key can only be decrypted
using a key generated by the algorithm during the by using the identical public key. Examples are RSA, ECC
encryption process. Decryption is the reverse of encryption etc.
that is done on the receiving end. But in order to do it the 2. EXISTING SYSTEM
receiver must have the knowledge of key otherwise he will
not be able to make sense out of the received encrypted RSA ALGORITHM:-
message. Cryptography is of two types, Symmetric
Cryptography and Asymmetric Cryptography. Symmetric It is the widely used encryption algorithm in the world.
encryption (also called as secret-key cryptography) uses a Originally RSA [2] came from three MIT professors Ron
single undisclosed key for both encryption and decryption. Rivest, Adi Shamir and Leonard Adelman. The acronym
We need to keep this key as a secret in the network. RSA has been derived from the initials of their last names.

© 2015-19, IJARCS All Rights Reserved 48


Ansah Jeelani Zargart et al, International Journal of Advanced Research in Computer Science, 8 (7), July-August 2017,48-51

This algorithm was invented in 1977 and was published the and also satisfies equation. Thus here we
following year in communications of ACM. It was a ground have a public key which is the combination of (n,e) where n
breaking piece of research and the ground breaking about is the product of prime numbers called as modulus and e is
this algorithm was that for the first time we had a system to the random coprime number called as public exponent,
encrypt with one key and decrypt with another and its including a private key which is a combination of (d,p,q)
inverse was also true. In order to understand RSA we must where d, p, q are the randomly selected values where p and q
have a good knowledge about prime numbers, number are prime numbers and d is known as secret exponent.
factorization, Euler’s phi function and Euler’s totient
theorem. ENCRYPTION IN RSA:-

The intuition behind RSA is that suppose we would like to Let’s assume we have two communication ends one as a
receive a secret message or secret information from other sender X and other as a receiver Y. The idea behind RSA is
people, so what we need is a key and a decoder. We will that the receiver publishes it public key over the network
keep key as public so that anyone can access it and we will which is actually a combination of product of prime
keep decoder as private so that no one other than the numbers (modulus) and random coprime number (public
recipient of the message (to be decoded) can access it. In exponent) and keeps its secret key to itself. Now say X has a
this way when people try to send receiver a message they plain text message and it wants to communicate it with Y.
can use its public key and change the secret message by it. Say the plain text message of X is represented by an integer
In this way the message will makes no sense at all unless, m such that m lies between 1 and n. For example we have a
the recipient uses the decoder that will change the message text message then we convert it into ASCII values such that
such that it starts making sense again. Thus providing high if their ASCII value exceeds n then we split them into two or
end security to our data because even if anyone has our more using some operations over it so that the value of m
received message still without our decoder no one can make stays less than n. Once the X receives the public key of Y, it
use of our data. Thus, key is public key and decoder is the is now capable of communicating securely over the network
private key that provides security to our messages. Example, by simply encrypting the m with the public key of the
we use online banking where we buy a product using its receiver using equation . In this equation at
public key which encrypts our information and sends it to first we calculate the value of m raised to power e and then
server. There on the server they use private key to decode divide it with n which yields us with a remainder c which is
the encrypted data. our encrypted message or cipher text message. It’s this c that
is then transferred over the network to the receiver Y.
RSA ALGORITHM:-
DECRYPTION IN RSA:-
Step 1. Generate two large prime numbers p and q.
Step 2. Calculate the product of these two prime numbers At the receiving end the receiver is having its private key for
decoding the messages meant for it. So once the receiver
such that the product is represented by n i.e
receives c then it will do the opposite of the encryption
Step 3. Calculate the value of phi for n such that process and compute which will yield the
it’s called the Euler’s totient function. original message. Here cipher message is raised to the power
The value of phi should satisfy and φ of d and once it’s resolved the value is then divided by n
must not share a factor with e. whose remainder is evaluated as to be the original message
Step 4. Select a random integer e such that it lies between 1
If we look at both the equations together
and φ and e, φ are coprime i.e . Also e then we can clearly see that one is
should be very small but greater than 2. the undoing of another.
Step 5. Calculate inverse of e i.e d such that d lies between
1 and φ and . By using Euclid’s WHY WE PREFER RSA?
Extended Greatest Common Divisor Algorithm.
RSA is called a one way trapdoor function, what it actually
Step 6. The public key formed will be (n,e) and the private means is that there is no way of undoing encryption unless
key formed will be (d,p,q) where all the values of d, p, we know the trapdoor. In this case trapdoor is the n. In RSA
q, and phi are kept secret. we have 2 large prime numbers such that a composite
number can be computed from them i.e. n=p*q where p and
We need to first select two large random prime numbers say q are prime and n is composite number. But it’s difficult to
p and q with maximum size of 2048 bits each. They must be find this trapdoor because from the prime number
extremely large. Then in next step we multiply them both factorization, and according to the fundamental theorem of
and evaluate a new value n that is the product of p and q arithmetic we know that any number greater than 1 can be
which intern is extremely large as well, with the size of 4096 written in exactly one way as a product of prime numbers. It
bits. Then we use Euler’s phi function is easy to calculate the product of two large prime numbers
and calculate the phi value from this function. but it’s very hard to take a very large product and factor it to
Afterwards we select a random integer e such that it ranges find the two prime numbers that composed it. It’s very
between 1 and phi. e and phi need to be coprime or difficult but not impossible it might take us just 50 years to
relatively prime such that . In the next step we find out. Thus factors of the n are the actual trapdoor. If
continue with selecting another random number d which is know the factors of n only then we can decrypt our
actually the inverse of e such that d lies between 1 and phi encrypted messages.

© 2015-19, IJARCS All Rights Reserved 49


Ansah Jeelani Zargart et al, International Journal of Advanced Research in Computer Science, 8 (7), July-August 2017,48-51

STEPSINVOLVED IN ECC ALGORITHM [5] [6]:-

ECC is a public key cryptosystem where every user


possesses two keys: public key and private key. Public key
3. PROPOSED SYSTEM is used for encryption and signature verification while as
private key is used for decryption and signature generation.
ELLIPTICAL CURVE CRYPTOGRAPHY
KEY GENERATION:-
Elliptical curve cryptography [3] [4] is a public key
encryption technique which is based on the theory of It is the most important step in which an algorithm is used to
elliptical curves. This encryption technique uses the generate both public and private keys. Sender encrypts the
properties of elliptic curve in order to generate keys instead message data with the help of receiver’s public key and
of using the traditional methodology of generation of keys receiver decrypts the data using its private key.
using the product of two very large prime numbers. Initially
the elliptic curves for cryptography was used in H.W. Step 1. The sender selects a random number dA between
Lenstra’s elliptical curve factoring algorithm. Inspired by the range [1 , n-1].This is the private key of the sender.
this unpredictable use of elliptic curves, the elliptical curve Step 2. Then the sender generates the public key using the
cryptography was proposed by N.Kobiltz and V.Miller formula PA = dA*G
independently in 1985. The most important advantage of Step 3. Similarly receiver selects a private key dB and
elliptical curve cryptography is the use of smaller keys generates its public key PB =dB*G.
providing the same level of security. ECC can provide the Step 4. The sender generates the security key “ K=
same security with 164-bit key that other systems provide dA*PB” and the receiver also generates the security key
with 1024- bit key. It is mostly useful for mobile “ K= dB*PA”
applications as it has the capability to provide high level
security with low computing power and battery resource. SIGNATURE GENERATION:-
ECC is a public key cryptosystem which is used to generate
the public key and the private key in order to encrypt and To sign a message m by the sender, it performs the
decrypt the data. It is based on the mathematical complexity following steps:-
of solving the elliptic curve discrete logarithm problem
Step 1. It calculates a cryptographic hash function
which deals with the problem of calculating the number of
steps or hops it takes to move from one point to another
Step 2. The sender then selects a random integer k from
point on the elliptic curve.
[1,n-1]
Elliptic curves are the binary curves and are symmetrical Step 3. The it computes a pair (r,s)
over x- axis. These are defined by the function: Step 4. r= x1 (mod n ) where (x1,y1) =k*G
Step 5. s= k-1(e+ dA*r)
Step 6. This pair (r,s) defines the signature
Step 7. This signature is sent to the receiver.
where x and y are the standard variables that define the
function while as a and b are the constant coefficients that ENCRYPTION ALGORITHM:-
define the curve .As the values of a and b change, elliptical
curve also alters. For elliptical curves, the discriminant Suppose sender wants to send a message m to the receiver
is non zero. The operations used on Step 1. Let m has any point M on the elliptic curve
elliptical curves in cryptography are point addition, point
Step 2. The sender selects a random number k from [1,n-1]
multiplication and point doubling. The important Step 3. The cipher texts generated will be the pair of points
characteristic of elliptic curve is the finite field concept. This (B1,B2) where
means that there is a way to limit the values on the curve. B1= k*G
This “max” value established on the x-axis is represented by
B2= M + (k*G)
“p”. It is also called “modulo value” for any ECC
cryptosystem. This point depicts the finite length upon DECRYPTION ALGORITHM:-
which the operations can be performed on the curve. In
ECC, the modular value depicts the key size for the system. To decrypt the cipher text, following steps are performed:-
Thus the parameters that fully define the ECC cryptosystem
are: Step 1. The receiver computes the product of B1 and its
private key
P :- Specification of the finite field Step 2. Then the receiver subtracts this product from the
second point B2
a,b :- Coefficients for defining curve M = B2- (dB * B1)
M is the original data sent by the sender
G :- Generator point on the curve where the operation starts
SIGNATURE VERIFICATION:-
n :- Order of G
To authenticate the sender’s signature, the receiver must
h :- Division of the total points on the curve and he order of
have the knowledge about sender’s public key PA
G.
© 2015-19, IJARCS All Rights Reserved 50
Ansah Jeelani Zargart et al, International Journal of Advanced Research in Computer Science, 8 (7), July-August 2017,48-51

Step 1. For authentication the receiver needs to verify the which provides security and authentication. Authentication
pair (r,s) are in the range of [1,n-1] to the data is provided with the help of smaller keys. The
Step 2. The receiver again then calculates the hash function computational cost as well as the speed of this algorithm is
e as in signature generation comparatively better. It also makes use of the good
Step 3. Then the receiver calculates w =s-1 mod(n) exchange protocols giving another mark to the security. In
Step 4. Then calculate u1= e*w (mod n) and u2 = r*w future, we emphasise the use of elliptical curve
(mod n) cryptography for providing high data security in almost all
Step 5. Calculate (x1,y1)= u1*G + u2*PA low power devices.
Step 6. If x1 = r (mod n), then the signature is valid.
6. REFERENCES
4. COMPARISON BETWEEN RSA AND ECC
[1]. https://en.wikipedia.org/wiki/Cryptography
The encryption algorithms ECC and RSA both provide same [2]. https://en.wikipedia.org/wiki/RSA_(cryptosystem)
level of security especially at higher levels but the most [3]. http://www.sciencedirect.com/science/article/pii/S0022314X0
important advantage of ECC is the use of smaller keys. ECC 9000481
[4]. https://en.wikipedia.org/wiki/Elliptic_curve_cryptography
generates smaller cipher texts and signatures as compared to [5]. http://www.academia.edu/download/32863696/Data_Security
the linear cryptosystems. The ECC algorithms promises a _in_Cloud_Architecture_Cryptography.pdf
faster key generation which is contradictory to the RSA [6]. https://www.researchgate.net/profile/Veerraju_Gampala3/publ
algorithm which has a slow key generation algorithm. ECC ication/265359508_Data_Security_in_Cloud_Computing_wit
can provide the same security with 164-bit key that RSA h_Elliptic_Curve_Cryptography/links/587c313308ae9275d4e
systems provide with 1024- bit key. The RSA algorithm 019eb/Data-Security-in-Cloud-Computing-with-Elliptic-
provides slow signing and decryption and thus can be Curve-Cryptography.pdf
replaced by ECC which is computationally faster in
encryption and decryption processes. The ECC signatures 7. BIOGRAPHIES
can be computed in two stages and are thus more secured
Ansah JeelaniZargar, is pursuing B.E Degree from SSM
than RSA in which signatures are difficult to implement
College of Engineering & Technology in Department of
securely. ECC provides excellent protocols for the key
Computer Science Engineering, University of Kashmir,
exchange while as the two-part key in RSA is very
J&K, India. Fields of interest are JAVA and Network
vulnerable to attacks. The elliptical curve cryptography has
Security.
another plus on its sides as the binary curves are really fast
to implement in hardware. Thus paving the way for ECC to MehreenManzoor, is pursuing B.E Degree from SSM
become a household name in future. College of Engineering & Technology in Department of
Computer Science Engineering, University of Kashmir,
5. CONCLUSION
J&K, India. . Fields of interest are JAVA and Network
Data security is a major issue to be dealt with from a few Security.
decades. In this paper we have reasoned the use of
Ms. Taha Mukhtar, is working currently as Assistant
cryptographic techniques for securing the data. We have
Professor at SSM College and Engineering and Technology
discussedthe two efficient data security algorithms- ECC
in Department of Computer Science Engineering, University
and RSA. These algorithms help in securing in transit data.
of Kashmir, J&K, India. Fields of interest are Network
Since RSA is a linear cryptographic algorithm and is slow in
Security, Cryptography and Implantable Biosensor Security,
the encryption and decryption processes, it can put the user’s
Distributed Systems.
security at risk. Thus ECC is the cryptographic algorithm

© 2015-19, IJARCS All Rights Reserved 51

You might also like