Encrypted File Distribution System Using Hybrid Cryptography of Symmetric AES and Asymmetric ECC
Encrypted File Distribution System Using Hybrid Cryptography of Symmetric AES and Asymmetric ECC
Cyber Security
CSE4003
SLOT:
E1+E2
FACULTY:
PROF. LAVANYA
SENDHILVEL
Group Members:
Data security has become the need of the hour in today’s world and especially in the case
when it is travelling through an insecure communication network . There are mainly
two types of techniques for data encryption i.e symmetric and asymmetric key
encryption techniques. In symmetric key encryption only one key is used for encryption and
decryption whereas asymmetric key encryption technique used two keys which are public
and private keys.Public is used for encryption and private is used for
decryption .Asymmetric key encryption technique is more secure as compared to symmetric
but the problem is that former is not time efficient . This project aims at implementation of a
model capable of performing encryption and decryption on multimedia data like
images,videos,audios and etc. using a hybrid model which is hybridisation of symmetric
AES and asymmetric ECC. ECC is based on the discrete logarithm problem (DLP), whose
public key is short, network bandwidth is little and ability to resist attack hereby making it
really difficult to guess the keys.It will take a hacker infinite amount of time to decrypt the
cypher.
1. Introduction:
Data security is of maximal importance in today's world specially with data travelling
through transmission networks which are not secure. Therefore, cryptography has now
become a very important aspect in data security for privacy of information.
Cryptography mainly deals with two algorithms, symmetric key encryption techniques which
use only one key for both encryption and decryption of the data and asymmetric techniques
that use more keys.
This paper primarily focuses on the implementation of a system that is capable of encryption
and decryption of multimedia data which include text, images, videos, and more. For this our
project focuses on a hybrid system based on the combination of symmetric encryption
technique AES and asymmetric technique that is ECC. ECC has a short public key,
little network bandwidth and strong ability to resist attack which makes it almost
impossible to guess the keys.
2. Literature Review:
The following section is focused on the following studies being done by a group of scholars
and researchers from the field of data security and computer science. The following papers
have been selected for review trying to compare traditional and conventional methods
of cryptography along with new emerging techniques.
2.2 Research on Design Principles of Elliptic Curve Public Key Cryptography and its
Implementation
As high performance computing technology has developed, along with it has developed the
importance of cryptography. The cryptography based on elliptic curve discrete
logarithm problem is seen, whose public key is short, network bandwidth is little and ability
to resist to attack is strong. The paper analyses the design principles of elliptic curve
public key cryptography, research of important contents in the system, selection of the elliptic
curve and the implementation process in detail.
3. PROBLEM STATEMENT
A better model for encryption of multimedia data with better security and less time is needed.
So keeping all the limitations of existing technologies in mind, a system is proposed which
addresses the following problems:
● Key Size
The size of the key should be large so that it cannot be guessed by anyone using brute
force attacks because Symmetric ciphers only use a single key for encryption
and decryption. Asymmetric ciphers use two keys for this which impacts the memory
but provides better security.
● Time complexity
Simple methodologies provide better time complexity whereas complex ones add up
to the time complexity. So a trade-off between these two needs to be established.
● Memory Efficiency
Multimedia encryption requires a lot of memory to store the input files, keys, output
files and ciphered files whereas text encryption offers a better memory efficiency but
lacks in terms of variety. So again a trade-off between these two needs to be
established.
2 3
E: y = x + ax + b …….. (1)
3 2
4a +27b ≠ 0(mod p) …… (2)
Point addition and point doubling are basic ECC operations. In the case of elliptic curves,
simple multiplication could not be found. A single point suppose A(x,y) on the elliptic
curve yields a resultant point B(x’,y’) by following a series of point addition and
point doubling instead of directly multiplying point A with a scalar, hence A=zB , where
z is a scalar multiple.
Advanced Encryption Standard a) ECC Point Addition b) ECC Point Doubling
Fig 2.(a) and Fig 2.(b) show elliptic curve addition and doubling respectively. In
Elliptic addition, a straight line joining the two points falls on the curve in the x-y plane at a
point R. To produce the final result, the negative equivalent is obtained on the other side of
the plane. In point doubling, the point P is doubled by a tangent on P which falls in the x-y
plane and takes a negative intercept of it. ECC is emerging as a replacement for RSA
in some environments because it provides a similar type of security but with significantly
reduced key sizes.
5. Proposed Idea and Methodology
Proposed Architectural Diagram
AES and ECC are two cypher technologies used in the hybrid encryption scheme.
The proposed paradigm is based on the ECC's robustness and AES's simplicity.
The system is designed to secure a wide range of multimedia data, including text documents,
photos, music, video, and so on, by first converting them to a base64 encoded text format.
The data is then encrypted for the first time using AES, with the keys created at random. The
technology generates a QR code equivalent of the keys in image form, which is then utilised
to extract the key in text form. The AES keys gain an extra layer of security as a result of this.
The AES keys are encrypted using an ECC public key derived from the input base64 encoded
text file for the second degree of protection. ECC key pairs are kept in specific file-system
folders. After that, the encrypted AES key is used to encrypt the base64 encoded plaintext
and transform it to a ciphertext.
The ciphertext that results has already been compressed and has gone through two layers of
mixed encryption using ECC and AES. When compared to a single model used alone,
a hybrid form of encryption gives a far higher level of security. The decryption process is the
inverse of the encryption process, and it uses a little more complicated methodology.
def fileToBase64(filename):
def makeListFromString(longString):
retData = []
data = longString.split('$')
for item in data:
if len(item) > 0:
retData.append(int(item))
return retData
class ClientThread(Thread):
def run(self):
filename='cipher.json'
f = open(filename,'rb')
while True:
l = f.read(BUFFER_SIZE)
while (l):
self.sock.send(l)
#print('Sent ',repr(l))
l = f.read(BUFFER_SIZE)
if not l: f.close()
self.sock.close()
Break
The research targeted encrypting multimedia data, such as audio, video, photos, text,
graphics, and PDF files, and saving it as an encrypted file in the receiver's directory. The
recipient then uses his or her private key components to decrypt the encrypted data
and restore it to its original state.
The overall expected results are as follows:
a) Time taken for encryption and decryption is marginally more since a hybrid model is
used. Therefore it lies between asymmetric and symmetric ciphers.
b) Because multimedia files are compressed before encryption and the keys used
are lower, the overall space complexity for storing encrypted files and source
files is predicted to be reduced.
7. Conclusion
The implementation has been tested on all types of files including audio and video.It
was working fine on text and image data.It was also working fine on video and audio but it
was taking more time as compared to text and images due to the size of the input
data . The implementation can be included in the application which requires encryption of
multimedia at a rapid rate . The same implementation could be used in a network to
encrypt the files travelling through it .Like attachments travelling through an email could be
secured using the hybrid encryption along with the existing email security provided by the
mail server or it can be used alone. Because of its high speed as compared to the existing
techniques, the same implementation could be used for handheld devices which can be
implemented with some minor changes in the implementation framework.
8. References
2. Jawahar Thakur, Nagesh Kumar. DES, AES and Blowfish: Symmetric Key
Cryptography Algorithms Simulation Based Performance Analysis. International
Journal of Emerging Technology and Advanced Engineering December 2011;
vol
1(2), p.6-12
3. R.L. Rivest, A. Shamir, and L. Adleman. A Method for Obtaining Digital Signatures
and Public-Key Cryptosystems.Communications of the ACM 1977; p. 120-126