SlideShare a Scribd company logo
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 
__________________________________________________________________________________________ 
Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 143 
IMPLEMENTATION OF AES AND BLOWFISH ALGORITHM 
Chaitali Haldankar1, Sonia Kuwelkar2 
1Electronics and Telecommunication, GEC, Goa, India 
2Electronics and Telecommunication, GEC, Goa, India 
Abstract 
Small embedded devices (including smart cards, RFID, sensor nodes) are now deployed in many applications. They are usually 
characterized by strong cost constraints. Yet, as they may manipulate sensitive data, they also require cryptographic protection .As a 
result, many algorithms have been proposed in order to allow strong security at lower cost than standard solution and lack of 
comparative studies prevent a good understanding for these cryptographic algorithms. Thus in this thesis we study the cryptographic 
algorithms like AES and Blowfish and compare different parameters and then do further implementation as the implementation of 
encryption/decryption algorithm is the most essential part of the secure communication. The algorithms are further considered for 
VLSI implementation. The evaluation is performed in terms of encryption speed, the CPU utilization with time and the battery power 
consumption. The experimental results specify the efficiency of the algorithms. 
Keywords: Plain text, Cipher text, Encryption, and Decryption 
----------------------------------------------------------------------***----------------------------------------------------------------------- 
1. INTRODUCTION 
Cryptography is the science of information and 
communication security. It entered in mass product markets 
quite recently and every citizen from developed countries uses 
it daily. It is used for authentication and encryption(bank card, 
e-commerce, pay-TV), access control (carlock systems, ski 
lifts), payment (prepaid telephone cards, e-cash), and may 
become the fundamental instrument of democracy with the 
advent of e-voting systems. To master cryptographic tools 
becomes a requirement for most engineers Cryptographic 
Algorithms plays a major role in implementation of encrypting 
the data. As the complexity of algorithm is high the risk of 
breaking the original plaintext from that of cipher text is less. 
Greater complexity means greater security. 
Cryptography algorithms are divided into Symmetric and 
Asymmetric key cryptography [1]. Symmetric key encryption 
use only key to encrypt and decrypt data. Key plays an 
important role in encryption and decryption. If a weak key is 
used in the algorithm then easily data can be decrypted. The 
size of the key determines the strength of Symmetric key 
encryption. Symmetric algorithms are of two types: block 
ciphers and stream ciphers. The block ciphers are operating on 
data in groups or blocks. .Examples are of Data Encryption 
Standard (DES), Advanced Encryption Standard (AES) and 
Blowfish. Stream ciphers are operating on a single bit at a 
time. RC4 is stream cipher algorithm. In Asymmetric key 
encryption, two keys are used; private keys and public keys. 
Public key is used for encryption and private key is used for 
decryption Fig.1 shows the overview field of cryptography. 
Fig -1: Overview of field of cryptography 
1.1 Various Goals 
1) Confidentiality 
Information in computer is transmitted and has to be a 
accessed only by the authorized party and not by anyone else. 
2) Authentication 
The information received by any system has to check the 
identity of the sender that whether the information is arriving 
from a authorized person or a false identity. 
3) Integrity 
Only the authorized party is allowed to modify the transmitted 
information. No one in between the sender and receiver are 
allowed to alter the given message. 
4) Non Repudiation 
Ensure that neither the sender, nor the receiver of message 
should be able to deny the transmission.
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 
__________________________________________________________________________________________ 
Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 144 
5) Access control Only the authorized parties are able to access the given information. 1.2 Basic Terms 1) Plain Text The original message that the person wishes to communicate with the other is defined as Plain Text. For example, Alice is a person wishes to send “Hello Friend how are you” message to the person Bob. Here “Hellow Friend how are you” is a plain text message. 2) Cipher Text The message that cannot be understood by any one or a meaningless message is what we call as Cipher text. For Example, “Ajd672#@91ukl8*^5%” is a Cipher Text produced for “Hello Friend how are you”. 3) Encryption A process of converting plain text into cipher text is called as Encryption. The process of encryption requires two things- an encryption algorithm and a key. An encryption algorithm means the technique that has been used in encryption. Encryption takes place at the sender side. 4) Decryption A reverse process of encryption is called as Decryption. It is a process of converting Cipher text into Plain text. The process of decryption requires two things- a decryption algorithm and a key. A decryption algorithm means the technique that has been used in Decryption. Generally the encryption and decryption algorithm are same. 5) Key A key is a numeric or alpha numeric text or may be a special symbol. The key is used at the time of encryption takes place on the plain text and at the time of decryption takes place on the cipher text. For example, if the Alice uses a key of 3 to encrypt the plain text “President” then cipher text produced will be “Suhylghqw". 2. CRYPTOGRAPHIC ALGORITHMS 
There are number of cryptographic algorithms used for encryption data and most of all fall into two generic categories Public key system and secret key system. Symmetric key algorithm is known as secrecy key or shared key algorithm. Because in symmetric key algorithm a shared key does both the encryption and decryption. Only one key is used for doing everything, so the success of algorithm depends on two factors-secrecy of the key and its distribution. Symmetric algorithms are: Data Encryption Standard (DES), Triple DES (3DES), International Data Encryption algorithm (IDEA), Blowfish, Advanced Encryption Standard (AES). Asymmetric key algorithm is also known as public key algorithm. In this algorithm, there are two keys public and private used for encryption and decryption. Public key is used to encrypt the message and private key is used to decrypt the message. Asymmetric algorithms are Diffe-Hellman and RSA Public Key Encryption. Symmetric key technique uses a single key called secret key which uses less mathematics, results in less computation, on the other hand asymmetric key technique uses both public and private keys, results in more processing and consumes more energy. Symmetric key techniques offer better energy efficiency as compared to public key that is why most researches use it for creating MAC in WSN. 
2.1 AES The NIST [1] selected the Rijndael algorithm, which was developed by Joan Daemen and Vincent Rijmen, to replace the dataencryption standard (DES) algorithm [2] as the new advanced encryption standard (AES) algorithm [3]. AES is based on a design principle known as a substitution- permutation network. AES has 128-bit block size and a key size of 128,192 or 256 bits [1].AES operates on a 44 column- major order matrix of bytes, termed the state. Most AES calculations are done in a special finite field. The AES cipher is specified as a number of repetitions of transformation rounds that convert the input plaintext into the final output of cipher text. The number of cycles of repetition are as follows: a. 10 cycles of repetition for 128 bit keys. b. 12 cycles of repetition for 192 bit keys. c. 14 cycles of repetition for 256 bit keys. Each round of encryption process requires the following four types of operations: SubBytes , ShiftRows , MixColumns, XorRoundkey. Decryption is the reverse process of encryption and using inverse functions: InvSubBytes, InvShiftRows, InvMixColumns[4]. A simpler way to view the AES function order is: 16 1. Scramble each byte (SubBytes). 2. Scramble each row (ShiftRows). 3. Scramble each column (MixColumns). 4. Encrypt (AddRoundKey). 2.2 Blowfish 
Blowfish is a 64-bit symmetric block cipher with variable length key. The algorithm operates with two parts: a key expansion part and a data encryption part. The role of key expansion part is to converts a key of at most 448 bits into several sub key arrays totalling 4168 bytes. The data encryption occurs via a 16-round Feistel network . It is only suitable for application where the key does not change often, like communications link or an automatic file encryption. It is significantly faster than most encryption algorithms when implemented on 32-bit microprocessors with large data caches .The nature of encryption algorithms is that, once any significant amount of security analysis is done, it is very undesirable to change the algorithm for performance reasons, thereby invalidating the results of the analysis. Thus, it is imperative to consider both security and performance together during the design phase. While it is impossible to take all
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 
__________________________________________________________________________________________ 
Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 145 
future computer architectures into consideration, an 
understanding of general optimization guidelines, combined 
with exploratory software implementation on existing 
architectures to calibrate performance, should help achieve 
higher speed in future encryption algorithms. 
2.2.1 Subkeys 
Blowfish uses a large number of subkeys. These keys must be 
precomputed before any data encryption or decryption. 
The P-array consists of 18 32-bit subkeys: P1, P2,..., P18. 
There are four 32-bit S-boxes with 256 entries each: 
S1,0, S1,1,..., S1,255; 
S2,0, S2,1,..,, S2,255; 
S3,0, S3,1,..., S3,255; 
S4,0, S4,1,..,, S4,255. 
2.2.2 Pseudo Code of Blowfish Algorithm 
begin itemize 
Blowfish has 16 rounds. 
The input is a 64-bit data element, x. 
Divide x into two 32-bit halves: xL, xR. 
Then, for i = 1 to 16: 
xL = xL XOR Pi 
xR = F(xL) XOR xR 
Swap xL and xR 
After the sixteenth round, swap xL and xR again to undo the 
last swap. 
Then, xR = xR XOR P17 and xL = xL XOR P18. 
Finally, recombine xL and xR to get the ciphertext. 
Decryption is exactly the same as encryption, except that P1, 
P2,..., P18 are used in the reverse order. Implementations of 
Blowfish that require the fastest speeds should unroll the loop 
and ensure that all subkeys are stored in cache. 
3. COMPARISON OF ALGORITHMS 
Table -1: Comparison of algorithms 
Algorithm Block Size Rounds Key 
AES 128,192,256 
Bits 
10,12,14 
Rounds 
128 
Bits 
BLOWFISH 32-448 
Bits 
16 
Rounds 
64 
Bits 
4. SIMULATION RESULTS 
The calculation for Encryption and Decryption speed of each 
algorithm for different packet sizes is done. Their 
implementation has tried to optimize the maximum 
performance for the algorithm. The throughput for encryption 
as well as decryption is calculated one by one. Encryption 
time is used to calculate the throughput of an encryption 
scheme The performance metrics are analyzed in matlab by 
(a) Encryption/decryption time. 
(b) CPU process time 
Table -2: Comparison of algorithms with respect to time in 
seconds 
algorithm Encryption/decryption 
For 64 bits 
CPU Time 
AES 1.261816 1.54440990 
BLOWFISH 0.850568721 0.07800050 
0 
0.2 
0.4 
0.6 
0.8 
1 
1.2 
1.4 
1.6 
AES BLOWFISH 
CPU TIME 
ENCRYPTION 
/DECRYPTION 
TIME 
Chart -1: Comparison of AES and Blowfish 
Fig -1: Simulation results of AES-128 bits using Modelsim 
Figure 3 shows the simulation results using ModelSim for 
AES-128 bit by considering the following inputs. 
Plain Text – 00112233445566778899aabbccddeeff 
Key Input – 000102030405060708090a0b0c0d0e0f 
The following Encrypted output obtained is as shown. 
Cipher Key –13111d7fe3944a17f307a78b4d2b30c5 
Cipher Text –69c4e0d86a7b0430d8cdb78070b4c55a
IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 
__________________________________________________________________________________________ 
Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 146 
5. CONCLUSIONS The above results show the superiority of Blowfish algorithm with AES in terms of the throughput, processing time. More the throughput, more the speed of the algorithm & less will be the power consumption. Finally we can conclude that Blowfish is the best of all. In future we can perform Hardware Implementation to compare different parameters REFERENCES [1]. Jawahar Thakur, Nagesh Kumar,“DES,AES and Blowfish: Symmetric Key Cryptography Algorithms Simulation Based Performance Analysis,“ in International Journal of Emerging Technology and Advanced Engineering (ISSN 2250-2459, Volume 1, Issue 2, December 2011), pp.6- 12 [2]. E. Thambiraj,G. Ramesh,Dr. R. Umarani , “A survey on Various Most Common Encryption Technique “ International Journal of Advanced Research in Computer Science and Software Engineering , Volume 2, Issue 7, July 2012,pp226- 233 I.S. [3]. S.Pavithra, Mrs. E. Ramadevi “STUDY AND PERFORMANCE ANALYSIS OF CRYPTOGRAPHY ALGORITHMS ” International Journal of Advanced Research in Computer Engineering & Technology Volume 1, Issue 5, July 2012 14, pp.82-86 K. Elissa, “Title of paper if known,” unpublished. [4]. J.Daemenand V.rijmen,"AES submission document on Rijndael", version 2, September 1999Role,

More Related Content

PDF
Simulated Analysis and Enhancement of Blowfish Algorithm
PPTX
Blow fish final ppt
PPTX
RC 4
PDF
Advanced Encryption Standard (AES)
PDF
Advanced Encryption Standard (AES) Implementaion using Java
PPTX
DATA SECURITY WITH AES ENCRYPTION, ELLIPTIC CURVE ENCRYPTION AND SIGNATURE
PDF
Hybrid AES DES
PPT
RC4&RC5
Simulated Analysis and Enhancement of Blowfish Algorithm
Blow fish final ppt
RC 4
Advanced Encryption Standard (AES)
Advanced Encryption Standard (AES) Implementaion using Java
DATA SECURITY WITH AES ENCRYPTION, ELLIPTIC CURVE ENCRYPTION AND SIGNATURE
Hybrid AES DES
RC4&RC5

What's hot (20)

PDF
Implementation of-hybrid-cryptography-algorithm
PDF
Block Ciphers Modes of Operation
PPTX
I mage encryption using rc5
PDF
cns 2marks
PDF
An Efficient VLSI Architecture for AES and It's FPGA Implementation
PDF
FPGA and ASIC Implementation of Speech Encryption and Decryption using AES Al...
PPT
Minor Project- AES Implementation in Verilog
PDF
Advanced Encryption Standard (AES) with Dynamic Substitution Box
PDF
A Tutorial on Linear and Differential Cryptanalysis by Howard M. Heys
PPTX
Seminar on Encryption and Authenticity
PPTX
Hybrid encryption ppt
PDF
Advanced encryption standard (aes) epul
PDF
New Technique Using Multiple Symmetric keys for Multilevel Encryption
PDF
Comparative Analysis of Cryptographic Algorithms and Advanced Cryptographic A...
PPTX
Information and data security block cipher and the data encryption standard (...
PPTX
Network security Encryption
PPTX
Cryptography and network security
PPTX
Encryption
PPTX
Encryption/Decryption Algorithm for Devanagri Script(Affine Cipher)
PPT
Encryption
Implementation of-hybrid-cryptography-algorithm
Block Ciphers Modes of Operation
I mage encryption using rc5
cns 2marks
An Efficient VLSI Architecture for AES and It's FPGA Implementation
FPGA and ASIC Implementation of Speech Encryption and Decryption using AES Al...
Minor Project- AES Implementation in Verilog
Advanced Encryption Standard (AES) with Dynamic Substitution Box
A Tutorial on Linear and Differential Cryptanalysis by Howard M. Heys
Seminar on Encryption and Authenticity
Hybrid encryption ppt
Advanced encryption standard (aes) epul
New Technique Using Multiple Symmetric keys for Multilevel Encryption
Comparative Analysis of Cryptographic Algorithms and Advanced Cryptographic A...
Information and data security block cipher and the data encryption standard (...
Network security Encryption
Cryptography and network security
Encryption
Encryption/Decryption Algorithm for Devanagri Script(Affine Cipher)
Encryption
Ad

Viewers also liked (20)

PPTX
High throughput implementations of cryptography algorithms on GPU and FPGA
PPTX
Blowfish
PDF
PDF
Encryption: It's For More Than Just Passwords
PDF
hardware implementation of aes encryption and decryption for low area & low p...
PDF
A Steganography LSB technique for hiding Image within Image Using blowfish En...
PDF
Performance evaluation of bituminous concrete incorporating crumb rubber and ...
PDF
Identity based cryptography for client side security in web applications (web...
PDF
Fine–grained analysis and profiling of software bugs to facilitate waste iden...
PDF
Seismic evaluation of mutistorey building with soft storey
PDF
Estimation of morphometric parameters and
PDF
Migrating from a legacy enterprise resource planning (erp) system to a new er...
PDF
Development of mathematical model on gas tungsten arc welding process parameters
PDF
License plate recognition for toll payment application
PDF
Influence of reinforcement on the behavior of hollow
PDF
Seismic analysis of low to medium rise building for base
PDF
A study of seismic pounding between adjacent buildings
PDF
Latent fingerprint and vein matching using ridge feature identification
PPT
Blowfish Cryptosystem
PPSX
Advanced Encryption Standard (AES)
High throughput implementations of cryptography algorithms on GPU and FPGA
Blowfish
Encryption: It's For More Than Just Passwords
hardware implementation of aes encryption and decryption for low area & low p...
A Steganography LSB technique for hiding Image within Image Using blowfish En...
Performance evaluation of bituminous concrete incorporating crumb rubber and ...
Identity based cryptography for client side security in web applications (web...
Fine–grained analysis and profiling of software bugs to facilitate waste iden...
Seismic evaluation of mutistorey building with soft storey
Estimation of morphometric parameters and
Migrating from a legacy enterprise resource planning (erp) system to a new er...
Development of mathematical model on gas tungsten arc welding process parameters
License plate recognition for toll payment application
Influence of reinforcement on the behavior of hollow
Seismic analysis of low to medium rise building for base
A study of seismic pounding between adjacent buildings
Latent fingerprint and vein matching using ridge feature identification
Blowfish Cryptosystem
Advanced Encryption Standard (AES)
Ad

Similar to Implementation of aes and blowfish algorithm (20)

PDF
Comparative study of private and public key cryptography algorithms a survey
PDF
Overview on Symmetric Key Encryption Algorithms
PDF
A New Method for Encrypting Digital Data Using Symmetric Key in Information E...
PDF
Different date block size using to evaluate the performance between different...
PDF
L017136269
PDF
Comparison of Various Encryption Algorithms and Techniques for improving secu...
PDF
A Survey on Generation and Evolution of Various Cryptographic Techniques
PDF
A Survey on Cryptographic Techniques for Network Security.pdf
PDF
Public key cryptography
PDF
A REVIEW STUDY OF CRYPTOGRAPHY TECHNIQUES
PDF
Implement a novel symmetric block
PDF
CH2 Stallings,_William_Computer_Security_Principles_and_Practice_Pearson [54-...
PDF
IMPLEMENT A NOVEL SYMMETRIC BLOCK CIPHER ALGORITHM
PDF
IMPLEMENT A NOVEL SYMMETRIC BLOCK CIPHER ALGORITHM
PDF
International Journal of Engineering Research and Development (IJERD)
PDF
State of the art realistic cryptographic
PDF
CNS_Solutions-Adi.pdf
PDF
CNS Solutions-Adi.pdf
PDF
CNS_Solutions-Adi.pdf
PDF
A Review on Various Most Common Symmetric Encryptions Algorithms
Comparative study of private and public key cryptography algorithms a survey
Overview on Symmetric Key Encryption Algorithms
A New Method for Encrypting Digital Data Using Symmetric Key in Information E...
Different date block size using to evaluate the performance between different...
L017136269
Comparison of Various Encryption Algorithms and Techniques for improving secu...
A Survey on Generation and Evolution of Various Cryptographic Techniques
A Survey on Cryptographic Techniques for Network Security.pdf
Public key cryptography
A REVIEW STUDY OF CRYPTOGRAPHY TECHNIQUES
Implement a novel symmetric block
CH2 Stallings,_William_Computer_Security_Principles_and_Practice_Pearson [54-...
IMPLEMENT A NOVEL SYMMETRIC BLOCK CIPHER ALGORITHM
IMPLEMENT A NOVEL SYMMETRIC BLOCK CIPHER ALGORITHM
International Journal of Engineering Research and Development (IJERD)
State of the art realistic cryptographic
CNS_Solutions-Adi.pdf
CNS Solutions-Adi.pdf
CNS_Solutions-Adi.pdf
A Review on Various Most Common Symmetric Encryptions Algorithms

More from eSAT Publishing House (20)

PDF
Likely impacts of hudhud on the environment of visakhapatnam
PDF
Impact of flood disaster in a drought prone area – case study of alampur vill...
PDF
Hudhud cyclone – a severe disaster in visakhapatnam
PDF
Groundwater investigation using geophysical methods a case study of pydibhim...
PDF
Flood related disasters concerned to urban flooding in bangalore, india
PDF
Enhancing post disaster recovery by optimal infrastructure capacity building
PDF
Effect of lintel and lintel band on the global performance of reinforced conc...
PDF
Wind damage to trees in the gitam university campus at visakhapatnam by cyclo...
PDF
Wind damage to buildings, infrastrucuture and landscape elements along the be...
PDF
Shear strength of rc deep beam panels – a review
PDF
Role of voluntary teams of professional engineers in dissater management – ex...
PDF
Risk analysis and environmental hazard management
PDF
Review study on performance of seismically tested repaired shear walls
PDF
Monitoring and assessment of air quality with reference to dust particles (pm...
PDF
Low cost wireless sensor networks and smartphone applications for disaster ma...
PDF
Coastal zones – seismic vulnerability an analysis from east coast of india
PDF
Can fracture mechanics predict damage due disaster of structures
PDF
Assessment of seismic susceptibility of rc buildings
PDF
A geophysical insight of earthquake occurred on 21 st may 2014 off paradip, b...
PDF
Effect of hudhud cyclone on the development of visakhapatnam as smart and gre...
Likely impacts of hudhud on the environment of visakhapatnam
Impact of flood disaster in a drought prone area – case study of alampur vill...
Hudhud cyclone – a severe disaster in visakhapatnam
Groundwater investigation using geophysical methods a case study of pydibhim...
Flood related disasters concerned to urban flooding in bangalore, india
Enhancing post disaster recovery by optimal infrastructure capacity building
Effect of lintel and lintel band on the global performance of reinforced conc...
Wind damage to trees in the gitam university campus at visakhapatnam by cyclo...
Wind damage to buildings, infrastrucuture and landscape elements along the be...
Shear strength of rc deep beam panels – a review
Role of voluntary teams of professional engineers in dissater management – ex...
Risk analysis and environmental hazard management
Review study on performance of seismically tested repaired shear walls
Monitoring and assessment of air quality with reference to dust particles (pm...
Low cost wireless sensor networks and smartphone applications for disaster ma...
Coastal zones – seismic vulnerability an analysis from east coast of india
Can fracture mechanics predict damage due disaster of structures
Assessment of seismic susceptibility of rc buildings
A geophysical insight of earthquake occurred on 21 st may 2014 off paradip, b...
Effect of hudhud cyclone on the development of visakhapatnam as smart and gre...

Recently uploaded (20)

PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PDF
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
PPTX
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PPTX
web development for engineering and engineering
PDF
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
PPTX
Foundation to blockchain - A guide to Blockchain Tech
PPTX
OOP with Java - Java Introduction (Basics)
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PDF
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
PPT
Project quality management in manufacturing
PDF
composite construction of structures.pdf
PPTX
Geodesy 1.pptx...............................................
PDF
Well-logging-methods_new................
PDF
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
PPTX
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
PPT
Mechanical Engineering MATERIALS Selection
PPTX
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
PPTX
Lecture Notes Electrical Wiring System Components
PPTX
bas. eng. economics group 4 presentation 1.pptx
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
MCN 401 KTU-2019-PPE KITS-MODULE 2.pptx
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
web development for engineering and engineering
Evaluating the Democratization of the Turkish Armed Forces from a Normative P...
Foundation to blockchain - A guide to Blockchain Tech
OOP with Java - Java Introduction (Basics)
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
Mitigating Risks through Effective Management for Enhancing Organizational Pe...
Project quality management in manufacturing
composite construction of structures.pdf
Geodesy 1.pptx...............................................
Well-logging-methods_new................
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
Infosys Presentation by1.Riyan Bagwan 2.Samadhan Naiknavare 3.Gaurav Shinde 4...
Mechanical Engineering MATERIALS Selection
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
Lecture Notes Electrical Wiring System Components
bas. eng. economics group 4 presentation 1.pptx

Implementation of aes and blowfish algorithm

  • 1. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 143 IMPLEMENTATION OF AES AND BLOWFISH ALGORITHM Chaitali Haldankar1, Sonia Kuwelkar2 1Electronics and Telecommunication, GEC, Goa, India 2Electronics and Telecommunication, GEC, Goa, India Abstract Small embedded devices (including smart cards, RFID, sensor nodes) are now deployed in many applications. They are usually characterized by strong cost constraints. Yet, as they may manipulate sensitive data, they also require cryptographic protection .As a result, many algorithms have been proposed in order to allow strong security at lower cost than standard solution and lack of comparative studies prevent a good understanding for these cryptographic algorithms. Thus in this thesis we study the cryptographic algorithms like AES and Blowfish and compare different parameters and then do further implementation as the implementation of encryption/decryption algorithm is the most essential part of the secure communication. The algorithms are further considered for VLSI implementation. The evaluation is performed in terms of encryption speed, the CPU utilization with time and the battery power consumption. The experimental results specify the efficiency of the algorithms. Keywords: Plain text, Cipher text, Encryption, and Decryption ----------------------------------------------------------------------***----------------------------------------------------------------------- 1. INTRODUCTION Cryptography is the science of information and communication security. It entered in mass product markets quite recently and every citizen from developed countries uses it daily. It is used for authentication and encryption(bank card, e-commerce, pay-TV), access control (carlock systems, ski lifts), payment (prepaid telephone cards, e-cash), and may become the fundamental instrument of democracy with the advent of e-voting systems. To master cryptographic tools becomes a requirement for most engineers Cryptographic Algorithms plays a major role in implementation of encrypting the data. As the complexity of algorithm is high the risk of breaking the original plaintext from that of cipher text is less. Greater complexity means greater security. Cryptography algorithms are divided into Symmetric and Asymmetric key cryptography [1]. Symmetric key encryption use only key to encrypt and decrypt data. Key plays an important role in encryption and decryption. If a weak key is used in the algorithm then easily data can be decrypted. The size of the key determines the strength of Symmetric key encryption. Symmetric algorithms are of two types: block ciphers and stream ciphers. The block ciphers are operating on data in groups or blocks. .Examples are of Data Encryption Standard (DES), Advanced Encryption Standard (AES) and Blowfish. Stream ciphers are operating on a single bit at a time. RC4 is stream cipher algorithm. In Asymmetric key encryption, two keys are used; private keys and public keys. Public key is used for encryption and private key is used for decryption Fig.1 shows the overview field of cryptography. Fig -1: Overview of field of cryptography 1.1 Various Goals 1) Confidentiality Information in computer is transmitted and has to be a accessed only by the authorized party and not by anyone else. 2) Authentication The information received by any system has to check the identity of the sender that whether the information is arriving from a authorized person or a false identity. 3) Integrity Only the authorized party is allowed to modify the transmitted information. No one in between the sender and receiver are allowed to alter the given message. 4) Non Repudiation Ensure that neither the sender, nor the receiver of message should be able to deny the transmission.
  • 2. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 144 5) Access control Only the authorized parties are able to access the given information. 1.2 Basic Terms 1) Plain Text The original message that the person wishes to communicate with the other is defined as Plain Text. For example, Alice is a person wishes to send “Hello Friend how are you” message to the person Bob. Here “Hellow Friend how are you” is a plain text message. 2) Cipher Text The message that cannot be understood by any one or a meaningless message is what we call as Cipher text. For Example, “Ajd672#@91ukl8*^5%” is a Cipher Text produced for “Hello Friend how are you”. 3) Encryption A process of converting plain text into cipher text is called as Encryption. The process of encryption requires two things- an encryption algorithm and a key. An encryption algorithm means the technique that has been used in encryption. Encryption takes place at the sender side. 4) Decryption A reverse process of encryption is called as Decryption. It is a process of converting Cipher text into Plain text. The process of decryption requires two things- a decryption algorithm and a key. A decryption algorithm means the technique that has been used in Decryption. Generally the encryption and decryption algorithm are same. 5) Key A key is a numeric or alpha numeric text or may be a special symbol. The key is used at the time of encryption takes place on the plain text and at the time of decryption takes place on the cipher text. For example, if the Alice uses a key of 3 to encrypt the plain text “President” then cipher text produced will be “Suhylghqw". 2. CRYPTOGRAPHIC ALGORITHMS There are number of cryptographic algorithms used for encryption data and most of all fall into two generic categories Public key system and secret key system. Symmetric key algorithm is known as secrecy key or shared key algorithm. Because in symmetric key algorithm a shared key does both the encryption and decryption. Only one key is used for doing everything, so the success of algorithm depends on two factors-secrecy of the key and its distribution. Symmetric algorithms are: Data Encryption Standard (DES), Triple DES (3DES), International Data Encryption algorithm (IDEA), Blowfish, Advanced Encryption Standard (AES). Asymmetric key algorithm is also known as public key algorithm. In this algorithm, there are two keys public and private used for encryption and decryption. Public key is used to encrypt the message and private key is used to decrypt the message. Asymmetric algorithms are Diffe-Hellman and RSA Public Key Encryption. Symmetric key technique uses a single key called secret key which uses less mathematics, results in less computation, on the other hand asymmetric key technique uses both public and private keys, results in more processing and consumes more energy. Symmetric key techniques offer better energy efficiency as compared to public key that is why most researches use it for creating MAC in WSN. 2.1 AES The NIST [1] selected the Rijndael algorithm, which was developed by Joan Daemen and Vincent Rijmen, to replace the dataencryption standard (DES) algorithm [2] as the new advanced encryption standard (AES) algorithm [3]. AES is based on a design principle known as a substitution- permutation network. AES has 128-bit block size and a key size of 128,192 or 256 bits [1].AES operates on a 44 column- major order matrix of bytes, termed the state. Most AES calculations are done in a special finite field. The AES cipher is specified as a number of repetitions of transformation rounds that convert the input plaintext into the final output of cipher text. The number of cycles of repetition are as follows: a. 10 cycles of repetition for 128 bit keys. b. 12 cycles of repetition for 192 bit keys. c. 14 cycles of repetition for 256 bit keys. Each round of encryption process requires the following four types of operations: SubBytes , ShiftRows , MixColumns, XorRoundkey. Decryption is the reverse process of encryption and using inverse functions: InvSubBytes, InvShiftRows, InvMixColumns[4]. A simpler way to view the AES function order is: 16 1. Scramble each byte (SubBytes). 2. Scramble each row (ShiftRows). 3. Scramble each column (MixColumns). 4. Encrypt (AddRoundKey). 2.2 Blowfish Blowfish is a 64-bit symmetric block cipher with variable length key. The algorithm operates with two parts: a key expansion part and a data encryption part. The role of key expansion part is to converts a key of at most 448 bits into several sub key arrays totalling 4168 bytes. The data encryption occurs via a 16-round Feistel network . It is only suitable for application where the key does not change often, like communications link or an automatic file encryption. It is significantly faster than most encryption algorithms when implemented on 32-bit microprocessors with large data caches .The nature of encryption algorithms is that, once any significant amount of security analysis is done, it is very undesirable to change the algorithm for performance reasons, thereby invalidating the results of the analysis. Thus, it is imperative to consider both security and performance together during the design phase. While it is impossible to take all
  • 3. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 145 future computer architectures into consideration, an understanding of general optimization guidelines, combined with exploratory software implementation on existing architectures to calibrate performance, should help achieve higher speed in future encryption algorithms. 2.2.1 Subkeys Blowfish uses a large number of subkeys. These keys must be precomputed before any data encryption or decryption. The P-array consists of 18 32-bit subkeys: P1, P2,..., P18. There are four 32-bit S-boxes with 256 entries each: S1,0, S1,1,..., S1,255; S2,0, S2,1,..,, S2,255; S3,0, S3,1,..., S3,255; S4,0, S4,1,..,, S4,255. 2.2.2 Pseudo Code of Blowfish Algorithm begin itemize Blowfish has 16 rounds. The input is a 64-bit data element, x. Divide x into two 32-bit halves: xL, xR. Then, for i = 1 to 16: xL = xL XOR Pi xR = F(xL) XOR xR Swap xL and xR After the sixteenth round, swap xL and xR again to undo the last swap. Then, xR = xR XOR P17 and xL = xL XOR P18. Finally, recombine xL and xR to get the ciphertext. Decryption is exactly the same as encryption, except that P1, P2,..., P18 are used in the reverse order. Implementations of Blowfish that require the fastest speeds should unroll the loop and ensure that all subkeys are stored in cache. 3. COMPARISON OF ALGORITHMS Table -1: Comparison of algorithms Algorithm Block Size Rounds Key AES 128,192,256 Bits 10,12,14 Rounds 128 Bits BLOWFISH 32-448 Bits 16 Rounds 64 Bits 4. SIMULATION RESULTS The calculation for Encryption and Decryption speed of each algorithm for different packet sizes is done. Their implementation has tried to optimize the maximum performance for the algorithm. The throughput for encryption as well as decryption is calculated one by one. Encryption time is used to calculate the throughput of an encryption scheme The performance metrics are analyzed in matlab by (a) Encryption/decryption time. (b) CPU process time Table -2: Comparison of algorithms with respect to time in seconds algorithm Encryption/decryption For 64 bits CPU Time AES 1.261816 1.54440990 BLOWFISH 0.850568721 0.07800050 0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 AES BLOWFISH CPU TIME ENCRYPTION /DECRYPTION TIME Chart -1: Comparison of AES and Blowfish Fig -1: Simulation results of AES-128 bits using Modelsim Figure 3 shows the simulation results using ModelSim for AES-128 bit by considering the following inputs. Plain Text – 00112233445566778899aabbccddeeff Key Input – 000102030405060708090a0b0c0d0e0f The following Encrypted output obtained is as shown. Cipher Key –13111d7fe3944a17f307a78b4d2b30c5 Cipher Text –69c4e0d86a7b0430d8cdb78070b4c55a
  • 4. IJRET: International Journal of Research in Engineering and Technology eISSN: 2319-1163 | pISSN: 2321-7308 __________________________________________________________________________________________ Volume: 03 Special Issue: 03 | May-2014 | NCRIET-2014, Available @ http://www.ijret.org 146 5. CONCLUSIONS The above results show the superiority of Blowfish algorithm with AES in terms of the throughput, processing time. More the throughput, more the speed of the algorithm & less will be the power consumption. Finally we can conclude that Blowfish is the best of all. In future we can perform Hardware Implementation to compare different parameters REFERENCES [1]. Jawahar Thakur, Nagesh Kumar,“DES,AES and Blowfish: Symmetric Key Cryptography Algorithms Simulation Based Performance Analysis,“ in International Journal of Emerging Technology and Advanced Engineering (ISSN 2250-2459, Volume 1, Issue 2, December 2011), pp.6- 12 [2]. E. Thambiraj,G. Ramesh,Dr. R. Umarani , “A survey on Various Most Common Encryption Technique “ International Journal of Advanced Research in Computer Science and Software Engineering , Volume 2, Issue 7, July 2012,pp226- 233 I.S. [3]. S.Pavithra, Mrs. E. Ramadevi “STUDY AND PERFORMANCE ANALYSIS OF CRYPTOGRAPHY ALGORITHMS ” International Journal of Advanced Research in Computer Engineering & Technology Volume 1, Issue 5, July 2012 14, pp.82-86 K. Elissa, “Title of paper if known,” unpublished. [4]. J.Daemenand V.rijmen,"AES submission document on Rijndael", version 2, September 1999Role,