You are on page 1of 6

Chapter 39

Mutation Operator-Based Image


Encryption Algorithm for Securing IoT

Rashmi Rajput and Manish Gupta

1 Introduction

In current scenario, Internet of things becomes a latest research area, and most of
the researchers are doing research in this field because of increasing demand of IoT
devices in near future [1]. The uses of IoT-enabled devices such as smartphones are
increasing day by day, and a lot of images are transmitted regularly to thousands
of people via social media Web sites and apps. So an exchange of secure images
over the communication network becomes a serious issue [2]. Various traditional
encryption algorithms such as RSA, AES, IDEA, and Diffie-Hellman have been
developed, but the efficiency of these algorithms for image encryption is less due to
higher redundancy and higher correlation among pixels.
Traditional image encryption algorithms based on symmetric key cryptography
are generally more expensive due to algorithmic complexity and require more number
of rounds for encryption. So work [3] proposed a less complex algorithm that uses
a 64-bit block cipher and uses 64-bit key for image encryption, which requires
less memory and less number of rounds as compared to other encryption algo-
rithms for encryption. Various algorithms of image encryption-based 4-D chaotic
map [4], hyperchaotic and genetic algorithm [3], hash key using mutation operator
and chaos [5], chaos using mutation and mutation operator [6], based on a fractional-
order hyperchaotic system [7], hyperchaotic [8], chaotic dynamic S-box and DNA
sequence operation [9], and 3-D logistic map [13] have been proposed for image
encryption.

R. Rajput (B) · M. Gupta


VITM, Gwalior, MP, India
e-mail: rashmirajput978@gmail.com
M. Gupta
e-mail: manishgupta.2007@gmail.com

© The Author(s), under exclusive license to Springer Nature Singapore Pte Ltd. 2021 457
S. Agrawal et al. (eds.), Machine Intelligence and Smart Systems,
Algorithms for Intelligent Systems,
https://doi.org/10.1007/978-981-33-4893-6_39
458 R. Rajput and M. Gupta

This work uses a mutation operator for both image encryption and key generation
phase that increases the difficulty level for the attackers.
Rest of the sections of this paper is organized as follows: Sect. 2 describes the
proposed work, Sect. 3 describes the experimental results on various parameters, and
finally, Sect. 4 concludes the overall work.

2 Proposed Methodology

This section describes the proposed methodology used in this work. The proposed
methodology works on three different phases: The first one is key generation phase,
the second one is encryption phase, and the third one is decryption phase.
(a) Key Generation phase: In this phase, a secure unique key is generated by
using a random function, named as a mutation operator. In this type of mutation
operator, randomly select the single mutation point in a parent string and mutate
the value (0–1 or 1–0) of the parent string. Figure 1 shows the process of mutation
operator.
The following steps show the process of mutation operator-

Steps of Mutation Process


Step 1: Select mutation probability (Pm ), and here, the value of Pm = 0.01 is taken
for experiment.
Step 2: Find out the length of binary string on which mutation operator is applied.
Step 3: Repeat K = 1 to length of binary string
R = rand ();
If R < Pm
binarystring (k) = ~ binarystring(k);
End

(b) Encryption phase: This phase is used to encrypt the image information. In this
phase, the encryption process completes four different rounds and two different
swaps. Each round contains XOR, XNOR logical function, and one random
function in the form of mutation operator. The first swap operation is performed

Fig. 1 The concept of mutation operator


39 Mutation Operator-Based Image Encryption Algorithm for Securing … 459

after the first encryption round, and the second swap is performed after the third
encryption round.
The following steps show the working of encryption process:
Step 1: Divide the 64 bits of binary data into 4 blocks, each having 16 bits in size.
Step 2: Perform XNOR operation on the first 16-bit block with key K1
Step 3: Apply random function (f) on a 16-bit block collected from step 2 and then
perform XOR operation on 16-bit block taken after the f-function operation
and third 16-bit block.
Step 4: Perform XNOR operation on last 16-bit block with key K1
Step 5: Apply random function (f) on a 16-bit block collected from step 4 and
then perform XOR operation on a 16-bit block taken after the f-function
operation and second 16-bit block.
Step 6: Repeat steps 2 to 5 for K2, K3, K4, and K5 keys, each having 16 bits in
size.
(c) Decryption Phase: This phase contains the reverse process of the
encryption phases described above.

3 Experimental Results

This section contains the experimental results performed on various parameters such
as NPCR, entropy, correlation, and histogram analysis. Here, MATLAB 2015 version
software, a system having Core i3 processor and 2 GB RAM i is used for performing
proposed work. The following Lenna image is used for performing operations.
Figure 4 shows the encrypted and decrypted Lenna image.

(a) NPCR: The following formulas are used for performing NPCR operation.
The NPCR of the two images is given below

i, j D(i, j)
NPCR = ∗ 100%
W×H

where H and W are the height and width of the input image, and the value of D(i, j)
is calculated as
460 R. Rajput and M. Gupta

0, if C1(i, j) = C2(i, j)
D(i, j) =
1, 1, Otherwise

(b) Entropy: It is a statistical measure of randomness that can be used to characterize


the texture of the input image. For calculating entropy, the following formula is
used,


M−1
1
E(m) = p(m j ) log  
j=0
p mj

(c) Correlation: The following formulas are used to calculate vertical, horizontal,
and diagonal correlation,

Cov (x, y) = E(x − E(X ))(y − E(y))

Cov(x, y)
Rx y = √ √
D(x) D(y)

The following three formulas are used in numerical computations, where y and x
are the two adjacent pixels value in the image (Figs. 2, 3 and 4; Table 1).

1 
N
E(x) = xi
N i=1

1 
N
D(x) = (xi −E(x))(y − E(y))
N i=1

Fig. 2 The horizontal,


vertical, and diagonal
correlation of original and
encrypted Lenna image
39 Mutation Operator-Based Image Encryption Algorithm for Securing … 461

Fig. 3 The original and encrypted Lenna image histogram

Fig. 4 The encrypted and decrypted Lenna image

Table 1 The comparison between existing techniques and proposed work on the parameter NPCR
and entropy
Encryption techniques NPCR Entropy
Enayatifar et al. [10] 99.54 7.9339
Enayatifar et al. [11] 99.56 7.8753
Talarposhti et al. [12] 99.63 7.8702
Proposed work using single-point mutation (Max.) 99.62 7.9965

1 
N
Cov(x, y) = (xi −E(x))(yi − E(y))
N i=1

(d) Histogram: statistical similarities between the original and cipher image are
measured with the help of histogram analysis.
462 R. Rajput and M. Gupta

4 Conclusion

Since most of the communications are in the form of images in IoT-enabled devices
and due to the increasing use of mobile phones, there is a need for a secure image
encryption algorithm that is fast and secure in nature. This work proposed an image
encryption technique based on random function, known as mutation operator of
genetic algorithm. For checking the efficiency of the proposed algorithm, experiments
are performed on various parameters that show the proposed algorithm is better than
the existing techniques described in this paper.

References

1. Liu B, Li Y, Zeng B, Lei C (2016) An efficient trust negotiation strategy towards the resource-
limited mobile commerce environment. Front Comput Sci 10(3):543–558
2. Usman M, Ahmed I, Aslam M, Khan S, Shah U (2017) SIT: a lightweight encryption algorithm
for secure Internet of Things. Int J Adv Comput Sci Appl (IJACSA) 8(1)
3. Zhang X, Zhou H, Zhou Z, Wang L, Li C (2018) An image encryption algorithm based on hyper-
chaotic system and genetic algorithm. Qiao J et al (eds) Bio-inspired computing: theories and
applications. BIC-TA 2018. Communications in computer and information science, vol 952.
Springer, Singapore
4. Stalin S, Maheshwary P, Shukla PK, Maheshwari M, Gour B, Khare A (2019) Fast and
secure medical image encryption based on non linear 4D logistic map and DNA sequences
(NL4DLM_DNA). J Med Syst 43(8):267
5. Guesmi R, Farah M, Kachouri A, Samet M (2016) Hash key-based image encryption using
mutation operator and chaos. Multi Tools Appl 75(8):4753–4769
6. Samhita P, Prasad P, Patro K, Acharya B (2016) A secure chaos-based image encryption and
decryption using mutation and mutation operator. Int J Control Theor Appl 9(34):17–28
7. Huang X, Sun T, Li Y, Liang J (2015) A color image encryption algorithm based on a fractional-
order hyperchaotic system. Entropy 17:28–38 (MDPI)
8. Tong X, Yang L, Zhang M, Xu H, Zhu W (2015) An image encryption scheme based on
hyperchaotic Rabinovich and exponential Chaos maps. Entropy 17:181–196 (MDPI)
9. Tian Y, Lu Z (2017) Novel permutation-diffusion image encryption algorithm with chaotic
dynamic S-box and DNA sequence operation. AIP Adv 1–23
10. Enayatifar R, Abdullah AH, Lee M (2013) A weighted discrete imperialist competitive
algorithm (WDICA) combined with chaotic map for image encryption. Opt Lasers Eng
51:1066–1077
11. Enayatifar R, Abdullah AH, Isnin IF (2014) Chaos-based image encryption using a hybrid
genetic algorithm and a DNA sequence. Opt Lasers Eng 56:83–93
12. Talarposhti KM, Jamei MK (2016) A secure image encryption method based on dynamic
harmony search (DHS) combined with chaotic map. Opt Lasers Eng 81:21–34
13. Ye G, Jiao K, Pan C, Huang X (2018) An effective framework for chaotic image encryption
based on 3D logistic map. Hindawi Sec and Commun Netw 1–11

You might also like