Next Article in Journal
Ostrowski Type Inequalities via Some Exponentially s-Preinvex Functions on Time Scales with Applications
Previous Article in Journal
On Some Regular Two-Graphs up to 50 Vertices
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Image Encryption Using Dynamic Image as a Key Based on Multilayers of Chaotic Permutation

by
Seerwan W. Jirjees
*,
Farah F. Alkalid
and
Waleed F. Shareef
Control and Systems Engineering Department, University of Technology-Iraq, Baghdad 10066, Iraq
*
Author to whom correspondence should be addressed.
Symmetry 2023, 15(2), 409; https://doi.org/10.3390/sym15020409
Submission received: 10 January 2023 / Revised: 26 January 2023 / Accepted: 30 January 2023 / Published: 3 February 2023
(This article belongs to the Section Computer)

Abstract

:
With the rapid expansion of electronic data transmission, unauthorized data access is growing. Information security against unwanted access is becoming increasingly essential in data storage and data transfer. Images are a common type of information that is used in almost every aspect of life, so the security of image data against unwanted access is critical. In this article, we propose an encryption technique that uses a symmetric encryption method based on XOR operation between the plain image and another image that will be used as a key agreed upon by both the sender and recipient. To ensure the security of the plain images, the scheme performs pixel permutation procedures dynamically using random numbers on the key image and plain image in each encryption process, which renders the encryption algorithm strong and brute-force resistant. Simulation results on several standard images showed a random distribution of pixel values and a higher pass rate correlated with entropy and ideal values for analysis parameters. Thus, through the use of randomization, the proposed algorithm is resistant to various attacks and offers promising security measurements while maintaining efficient and fast execution.

1. Introduction

Transferring images via the internet makes the images more vulnerable to attacks; however, researchers continually propose new ways to enhance image security against attacks while keeping it easily accessible to authorized users. To save sensitive data in different fields (political, military intelligence, financial, medical, personal information, and so on), some researchers looked towards securing the tunnel media of transferring data, while others looked towards data encryption [1,2,3,4].
The fours basic fields of cryptography are authentication, confidentiality, non-repudiation, and data integrity [5,6]. Images might be encrypted in several ways to guarantee that only authorized people can access them. However, plain image pixels are always associated with one another, making it easy for an attacker to estimate secret information by comparing the image pixels to the adjacent pixels [7,8]. Image encryption algorithms use two sorts of methods: scrambling and diffusion. Scrambling is performed by changing pixel positions by shifting them to decrease the association between neighboring pixels and achieve encryption. Diffusion is accomplished by altering the pixel contrasts and is achieved by changing the pixel values. Diffusion encoding increases the randomness of the encoded images while breaking their statistical properties. The substitution phase can be implemented utilizing a pseudo-random number generator founded on discrete or continuous chaotic approaches [9,10,11,12].
This research presents a dynamically permutated image as a key for encrypting the plain image. The key image is generated from random numbers and with specifications close to the optimal state of the encrypted image specifications. In addition, the key image is characterized by its large size, which gives it strength against brute force attacks. The permutation scheme will be used dynamically on the two images, using random numbers to present the encrypted image. The large key size used with the permutation algorithm, and the simplicity of the algorithm in implementing the encryption and decryption process gives the proposal a high speed of execution. The experimental results show that the proposed method achieves a random distribution of pixel values and a higher pass rate of entropy. The remainder of the research is planned as follows: Section 2 covers the past works focused in this area, while Section 3 presents a case study example for the proposed algorithm. Section 4 describes the final results and security measurements. Finally, in Section 5, the conclusions and discussions are presented.

2. Literature Review

Generally, the key is either sent in a different secure channel or changed periodically in a pre-predetermined way agreed upon by the sender and the receiver [13].
Congxu Zhu and et al. [14] used chaos to create S-Box (Substitution box) for various encrypted images, where the encrypted key is not associated with the plain image. Thus, they only need S-Box, not a key, for decryption, thereby making it difficult to be discovered by attackers. The authors in [15] proposed a model utilizing a shuffling procedure using a Julia fractal key end-to-end with a three-dimensional Lorenz chaotic map; in addition, a 3-D Lorenz chaotic map was employed for a dispersion procedure for all pixels of the image. In [2], the authors proposed encrypting the image using a chaotic attractor in the frequency domain using numeral wavelet transform. The suggested algorithm used a chaotic 3-D Lorenz attractor and logistic map to create pseudo-random keys for the encryption process. In [16], the authors developed a symmetric system combination of a 6-D cellular neural network (CNN) and a chaotic map. First, the key is generated by plain text image, after which the chaotic map is used on two levels to diffuse the image to provide high security. The authors in [17] suggested a new procedure of universal pixel dispersion with two chaotic classifications. They segmented the key into four clusters, each with 32 bits, then converted each cluster into decimal form. In [18], the authors used a five-dimensional chaotic map, where the entered image was disintegrated into clusters using a dual three-composite wavelet transform. These clusters were then used as the secret key that they obtained from the optimized 5-D chaotic map. Lastly, the inverse was used to obtain the final encrypted image X. Chen et al. [19] studied a way to model the pseudo-random number generator by three types of four clusters of hyperchaotic systems, with different dimensions as multiple entropy bases. This model performed the replacement in a row and then joined the XOR operation on the three types of the proposed model with different dimensions to present complex encryption images. In [20], the authors proposed an image encryption method based on a global Arnold map and Rivest–Shamir–Adleman (RSA) algorithm. The arguments of the global Arnold map are created by an asymmetric encryption system RSA algorithm, and the secret key is generated continuously. Patel et al., in [21], used a 3-D chaotic map with three symmetrical keys to create primary situations; these situations were then reused in image row and column transformations to generate arbitrariness in the pixels. In [22], a permutation with a multi-level approach was proposed, which consists of triple stages: replacement of the plain images’ associated rows and columns, shift and roll stage of the pixels, and finally, a multi-level cyclic shift stage. Firstly, the information of the plain image is saved to create a regulator order by using a twist tent model to guarantee that the association among triple colour values are completely split. In [23], the authors presented a video stream technique in which watermark data were encrypted depending on new chaotic map encryption, which involved the key edges extracted from the video stream. In this technique, a simple and fast key edge extraction algorithm by Amira et al. [24] suggested a hash model to maintain the information by relying on accomplished structures from the united frequency domains of the Slantlet Transformation (SLT) and the Discrete Cosine Transform (DCT); the hash code is enciphered to preserve security by using a secure Chaotic Shift Keying (CSK).
In [25], the authors proposed a new combination of the chaotic map with delay and cascade, which enlarged the primary rate sensitivity and inside randomness. They used symmetric structure for image encryption for achieving confusion and diffusion simultaneously. Atyaf et al. [26] projected additional confusion in encryption technique in two phases. In the first phase, the S-box algorithm was used. In the second phase, shifting, rotation, and a 2-D logistic map were used. The authors in [27] considered the encryption model using integer wavelet transform blended with deoxyribonucleic acid (DNA) and chaotic algorithm to secure digital medical images. Israa, in [28], studied how the image of an e-passport holder is used to encrypt biomedical images using multilevel encryption; here, it is used as a cover image to hide the fingerprint inside it. In [29], the authors used the chaos sequence and wavelet transform value to find gaps by using random chaos sequences for encrypting images. In [30], a complex map of a fractal was proposed, which was used to create a chaotic series of symmetric image. Here, they derived equilibria and behavior from the fractal map then used this map to update image pixels in order to increase security against decryption attacks. In [31], a dynamic key for encryption was proposed to increase the complexity of the encryption system. The proposed model consisted of three steps: firstly, generating a random key and chaotic map, followed by a shifting in the time domain and DCT coding, and finally, quantifying the blocks of the previous step. In [32], the authors presented an image encrypting system by using a pseudo-random generator of numbers and performed a summation of all pixels to generate the initial rate of controlling the encryption. To overcome the probability of possessing the same pseudo-random sequences, they used many attacking encryption levels. In [33], A multiparameter cosine number transform was proposed by the authors.. Such a transform is obtained using the fact that the basis vectors of the three-dimensional cosine number transform (3D-CNT) constitute a possible eigenbasis for the Laplacian of the cubical lattice graph evaluated in a finite field.
This work presents a method of using a relatively large dynamic key, the same as the image size, which provides high resistance to brute force since the time needed to break it is extremely high. This provides a very high resistance to brute force attacks; therefore, the time taken to break the algorithm is much higher than in previous research. With the aid of chaotic theory on the byte level and randomized permutation, the simple XOR operation provides the proposed algorithm with sufficient security while maintaining an easy program and fast execution code. The encryption process for each new image is different due to the use of random numbers to mix the pixels values; hence, the proposed algorithm is immune to both frequency and entropy analyses.

3. Proposed Algorithm

The proposed work depends on an image that will be a key for encrypting the plain image, and this key image must be stored by the sender and the recipient for encryption and decryption processes. The magnitude of the key images will be relatively large, as it depends on the maximum size of the images to be encrypted. The key image specifications are described below and illustrated in Figure 1.
  • The content information randomness in the image is very high.
  • The histogram is very close to flat pixels for all level values.
  • Correlations among adjacent image pixels in the key image are kept to a minimum.
  • The dimensions of the image will be determined by the system designer and according to the dimensions of the images to be encrypted.
Figure 2 shows the process of encryption for colour images. The process is applied to the three layers R, G, and B of the normal colour image independently. The rotation method is used at the level of rows and columns for the main image as well as for the original image based on random numbers generated in each new encoding process.

3.1. Encryption Process

The encryption process contains three levels, as shown in Figure 3. The size of the key image is first to be determined on the basis of the size of the plain image. The three levels of the encryption process are pixel permutation, XOR, and permutation number appending. These levels are described in the next subsections.

3.1.1. Pixel Permutation (Level 1)

The permutation is a process in which the locations of pixels are changed. The proposed permutation approach is a random number permutation of two-dimensional rows and columns, i.e., six permutation sequences of the colour image. As illustrated in Figure 4, the six sub-random numbers are employed to switch the rows and columns of the red, green, and blue sub-bands of the colour image I in a byte-level switch, and it will be carried out using randomly generated vectors for rows and columns in each encryption process. Figure 4 shows the proposed scheme of the permutation process. The methods’ steps are denoted in Algorithm 1.
Algorithm 1: Proposed Pixel Permutation
Input: Plain image I and key image k of size r × c.
Output: The permutation plain image IR and the permutation key image KR.
1:
Create a vector for permutation sequences for the row (VR), where the length of the VR = r and the range of VR = 1 to c.
2:
Create a vector for permutation sequences for the column (VC), where the length of the VC = c and the range of VC = 1 to r.
3:
Create two matrices, KR and IR, of size r × c.
4:
for I = 1 to r
5:
IR [i,:] = rotation row by VR[i]
6:
end for
7:
for j = 1 to C
8:
IR [:,j] = rotation column by VC[j]
9:
end for
10:
Repeat Step 4 and Step 9 for K matrix to create matrix KR.

3.1.2. XOR Logical Operation (Level 2)

An XOR formula is applied between the key image and the main image to render the pixels unpredictable and implement the concept of confusion, as described in Algorithm 2.
Algorithm 2: XOR Logical Operation
Input: Permutation plain image IC and permutation key image KR.
Output: Permuted XOR image X
1:
Create matrix X
2:
for i = 1 to r
3:
for j = 1 to c
4:
X[i,j] = M[i,j] ⊕ N[i,j]
5:
end for j
6:
end for i

3.1.3. Append Random Numbers to Encrypted Image (Level 3)

The vectors of random numbers for the row and column level are appended to the image generated by the XOR operation that was created in the second level, then the pixels are permutated at the row level using the values of the first column in the key image as well as at the column level using the values in the first row of the key image, as described in Algorithm 3.
Algorithm 3: Append Random Numbers
Input: Permuted XOR image X, key image K, and vectors that were created from Algorithm 1 (VR,VC)
Output: Cipher image XC of size (r + 1, c + 1)
1:
Append VR to the last row of X and VC to the last column of X
2:
VL = first row from key image
3:
for i = 1 to r + 1
4:
XC [i,:] = rotation column by VL[i]
5:
end for
6:
VM = first column from key image
7:
for j = 1 to c + 1
8:
XC[:,j] = rotation column by VM[j]
9:
end for
Figure 5 demonstrates the encryption approach more clearly. Let I [6,8] be the input image and K [6,8] be the key. The process begins to create two random vectors to carry out permutations in rows and columns, which are utilized to permute the key and plain image; they then use the XOR formula between the permutation key and the permutation plain image, and finally, append the permutation vectors and permute the gained image again.
  • Pixel Bytewise Permutation:
    Create random values vector for row permutation of size 6, where the range of each location is 1–8: VR [6] = [2,4,7,1,3,0]; create a second vector for column permutation of size 8, where the range of each location is 1–6: VC [8] = [5,1,0,2,5,3,1,4].
    Depending on the random vector generated VR [6], rotate each row in key image k [6,8]. For the first row r1, rotate in a circular fashion by 2 positions, rotate r2 to the right 4 times, rotate r3 7 times, rotate r4 once to the right, and rotate r5 3 times. At the conclusion of this operation, a matrix called KR [r, c] is generated. Then, repeat the permutation for columns with respect to VC [8]; rotate c1 5 times, rotate c2 once, rotate c4 two times, rotate c5 5 times, rotate c6 3 times, rotate c7 once, and rotate c8 4 times; thus, a matrix KC [r, c] is generated. Row and column permutation is repeated on the plain image I [r, c] to obtain IC [r, c]. Figure 2 denotes the permutation of the plain and key image.
  • XOR Operation:
    In general, in this process, the XOR operation is applied to the two matrices KC [6,8] and IC [6,8], then the two random vectors generated in Section 3.1 are appended as a new row and column for the XOR-manipulated matrix to obtain X [n + 1,m + 1].
  • Permutation XOR-manipulated Image:
    The second round of permutation applies to the XOR-manipulated matrix and depends on first the row and first column of the key image by creating new two vectors VKr [r] and VKc [c]. The first column of the key image is [22,45,231,106,108,22,25], obtained by using modulo operation to return the remainder of 6 division and keep the range 0-5. The new generated vector is called VKr [7] = [4,3,3,4,0,4,1]. The first row of the key image is [22,166,161,115,129,163,57,66,248], obtained by using modulo 8, generating a new vector in the range 0–7 called VKc [9] = [6,6,1,4,1,3,1,2,2].

3.2. Decryption Process

Decryption is the process of reversing the order of an encryption process, whereby the iteration and operations are reversed. The approach performs three major levels to decrypt an image as shown in Figure 6:
  • Level 1. Reading the first row and first column vectors (VKr,VKc) from the key image and using them to permutate the cipher image.
  • level 2. Reading the row and column vectors (VR,VC) from the image generated from level 1 and using them in the process of permutate the key image and then applying the XOR process.
  • level 3. Permuting the image that was produced from Level 2 by (VR,VC) to obtain the plain image.

4. Experimental Results and Security Analysis

To test the proposed system’s security and effectiveness, the suggested approach is implemented in Python 3. Figure 7 illustrates encryption and decryption results of the proposed images using three standard images (Lena, Baboon, and the letter A). Table 1 lists the encryption and decryption times for three different sizes of colour images. These results indicate that the proposal has a very high speed of encryption and decryption and can be used in real time.

4.1. Statistical Cryptanalysis

The histogram, entropy, and correlation tests are used to assess the image encryption techniques’ resistance to statistical attacks. The following subsections describe the results in detail.

4.1.1. Histogram Analysis

The histogram represents the exact distribution of pixel values. The encrypted image’s histogram must be consistently uniform to achieve the necessary encoding [34]. In Figure 8b, the distribution of pixels of the normal image is shown uniformly in the numerical range from 0 to 255, and this may be vulnerable to statistical attacks. In Figure 8c, after applying the proposed algorithm, the scheme shows the uniform distribution of pixels, and therefore, the attackers are able to distinguish between pixels or guess the amount of information.

4.1.2. Correlation Analysis

Most of the original image area has a similar grayscale value, so the encryption process should have a noticeable effect to minimize the correlations between neighboring pixels in the original image. Correlation coefficients are computed for all adjacent pixels in the diagonal, vertical, and horizontal directions using the Equation below [35].
C xy = cov ( x , y ) D ( x ) × D ( y )
cov ( x , y ) = 1 M 0 N ( x i E ( x ) ) )
D ( x ) = 1 M 0 N x i E ( x ) 2
E ( x ) = 1 M x i
where the total number of pixels is M. E ( x ) ,   D ( x ) , and cov ( x , y ) are the mean, variance, and covariance, respectively. The value of correlation is close to 1 if the sequenced pixel values are closely related, but if they are less closely related to each other, then the value is close to 0. Figure 9 demonstrates the correlation results between plain and cipher images. The plain images have a substantial correlation in all three directions, but following encryption by the proposed algorithm method, the correlations are greatly decreased. According to Table 2, the proposed technique is resistant to hacker attacks since the correlation coefficient is insignificant (approximately zero) for the encrypted image and close to one for the plain image. The proposed image encryption algorithm has a low value and little volatility. As a result, the suggested algorithm is both safe and trustworthy.

4.1.3. Entropy

The material entropy is a significant quantity that indicates the arbitrariness of data, which refers to the smallest average coding length in bits per pixel that may be obtained without any information loss using an encryption scheme. The material entropy E is calculated through Equation (5) [36]:
E ( m ) = i = 0 N P ( m i ) log 2 P ( m i )
Here, N is the number of all samples for the image, m is the information source, and P ( mi ) represents the probability of sample mi. The probability of leakage decreases when the entropy value reaches 8. Table 3 displays the information entropy of our original test photographs as well as the encrypted information entropy. The absolute entropy of the entropy values of the R, G, and B components of Lena’s colour image are 7.9981, 7.9980, and 7.9978, respectively, which are quite near to the typical value of 8. The entropy statistics show that the cipher images contain an extreme level of randomness in the values of adjacent pixels.

4.2. Statistical Cryptanalysis

The standardized tests, number of pixels change rate (NPCR) and unified average changing intensity (UACI), are used to analyze the sensitivity of a plain image so that an attack can be resisted.
When a single pixel in the input image is modified, the parameter NPCR relays the rate at which the encrypted image’s pixels change. The NPCR should be closer to 100, which is the percent in a solid cryptosystem. The UACI indicates the average change in pixel intensity between the encrypted and original images and should be greater than 30% [37]. NPCR and UACI can be calculated as follows:
NCPR = i = 0 M 1 j = 0 N 1 D ij M × N × 100 %
UACI = 1 M × N i = 0 M 1 j = 0 N 1 | C 1 ( i , j ) C 2 ( i , j ) | 255 × 100 %
D ij = { 1             C i ( i , j ) C 1 ( i , j )   0             C i ( i , j ) = C 1 ( i , j )
where M and N represent the width and height of the image, respectively, and C1 and C2 denote the two cipher images which have a one-bit change corresponding to same plain image. By applying the proposed algorithm illustrated in Table 4, the test results extremely coincide with the theoretical maximum, confirming the proposed system immunity to differential attacks.

4.2.1. Robustness for Mitigating Data Losses and Noise

During transmission, the image may be subject to cropping attacks, blurring, or a loss of part of it. As a result, a secure encryption algorithm must be robust and able to retrieve the majority of image information when encrypted images suffer data loss or blurring [38]. In Figure 10, the experimental results showed that the proposed algorithm has good cutting and noise-resistance capabilities. Figure 10a–c display the size of data cutting as 6.25%, 12.5%, and 25% from the encrypted image, respectively, and Figure 10f–h show decrypted images recovered after the cropping attack. Figure 10d shows the encrypted image with 0.1 noise added, and Figure 10i provides the decrypted picture after adding 0.1 noise to the encrypted image. The proposed algorithm shows good results in data loss resistance and noise resistance.

4.2.2. Key Magnitude

The size of the key magnitude refers to the algorithm’s capacity to withstand brute force attacks, as the security of image encryption increases with the size of the key magnitude [39]. The secret key employed in this algorithm is an image with a variable length depending on the size of the plain image, so the key space is 2r × c × 3, where r and c are the row and column dimensions, respectively, of the three images (red, green, and blue). In addition, the key image changes its values in each new encryption process, using the theory of permutation with random numbers. It can be concluded that the size of the key space of the proposed algorithm is too large to withstand brute force.

4.2.3. Sensitivity Analysis

A key sensitivity means that a small change on the secret key during the encryption process will lead to two completely different encrypted results [40,41]. Figure 11a,b, show the encryption of images using Key 1 and the encryption of images using Key 2 after changing one bit of Key 1, where we note that the encrypted image will be completely different for each key. The absolute differences in intensity between the cipher image with Key 1 and the cipher image with the variable key (one bit) are illustrated in Figure 11d. Therefore, the proposed scheme has a high sensitivity to the encryption key.

4.3. Performance Comparison with Other Image Encryption Techniques

The results obtained in Table 5 show that the proposed method produces better or similar results in term of NPCR and other metrics, such as entropy and correlation analysis, when compared with previous similar works for grayscale images. We can see that the NPCR and UACI values for two encrypted images are very close to the ideal values; hence, it can resist differential attack well. In addition, the correlation coefficient of the proposed algorithm is very close to the ideal value of 0. Moreover, the proposed algorithm produces high information entropy compared with values using other image encryption algorithms.

5. Conclusions

An algorithm is proposed on the basis of an image that acts as a key by applying XOR to the plain image to form an encrypted image. Here, the key image data values are very random, and this image is presented only to the sender and the recipient and is agreed upon in advance; thus, it will be difficult for the hacker to know its content. The theory of scrambling the pixels with random numbers on the key image before sending it will be used in each new encryption process, where the random numbers will be hidden with the sent encrypted image; therefore, public key lookup and matching ciphertext attack is not possible.
Statistical analysis results show that the encrypted image pixel distribution is consistent, the relationship among the adjacent pixels of the encrypted image is insignificant, and the encrypted image entropy is very close to the ideal value. Future development of this work may investigate using a two-dimensional chaotic system at the bit level to achieve a high level of security.

Author Contributions

Conceptualizations, methodology, S.W.J.; software, S.W.J.; validation, S.W.J. and F.F.A.; formal analysis, S.W.J. and F.F.A.; investigation, S.W.J., F.F.A. and W.F.S.; resources, F.F.A.; writing—original draft preparation, S.W.J., F.F.A. and W.F.S.; writing—review and editing, S.W.J. and F.F.A.; visualization, S.W.J., F.F.A. and W.F.S.; supervision, S.W.J.; project administration S.W.J. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Saracevi’c, M.H.; Adamovi’c, S.Z.; Miskovic, V.A.; Elhoseny, M.; Macek, N.D.; Selim, M.M.; Shankar, K. Data encryption for internet of things applications based on catalan objects and two combinatorial structures. IEEE Trans. Reliab. 2020, 70, 819–830. [Google Scholar] [CrossRef]
  2. Banu, S.A.; Amirtharajan, R. A robust medical image encryption in dual domain: Chaos-DNA -IWT combined approach. Med. Biol. Eng. Comput. 2020, 58, 1445–1458. [Google Scholar] [CrossRef] [PubMed]
  3. Pourasad, Y.; Ranjbarzadeh, R.; Mardani, A. A New Algorithm for Digital Image Encryption Based on Chaos Theory. Entropy 2021, 23, 341. [Google Scholar] [CrossRef] [PubMed]
  4. Wang, X.-Y.; Li, Z.-M. A color image encryption algorithm based on hopfield chaotic neural network. Opt. Lasers Eng. 2019, 115, 107–118. [Google Scholar] [CrossRef]
  5. Abd-El-Hafiz, S.K.; AbdElHaleem, S.H.; Radwan, A.G. Novel permutation measures for image encryption algorithms. Opt. Lasers Eng. 2016, 85, 72–83. [Google Scholar] [CrossRef]
  6. Mahdi, M.S.; Azeez, R.A.; Hassan, N.F. A proposed lightweight image encryption using ChaCha with hyperchaotic maps. Period. Eng. Nat. Sci. 2020, 8, 2138–2145. [Google Scholar]
  7. Liu, Y.; Jiang, Z.; Xu, X.; Zhang, F.; Xu, J. Optical image encryption algorithm based on hyper-chaos and public-key cryptography. Opt. Laser Technol. 2020, 127, 106171. [Google Scholar] [CrossRef]
  8. Akkasaligar, P.T.; Biradar, S. Medical image encryption with integrity using DNA and chaotic map. In Proceedings of the International Conference on Recent Trends in Image Processing and Pattern Recognition, Solapur, India, 21–22 December 2018; pp. 143–153. [Google Scholar]
  9. Ye, G.; Pan, C.; Huang, X.; Mei, Q. An efficient pixel-level chaotic image encryption algorithm. Nonlinear Dyn. 2018, 94, 745–756. [Google Scholar] [CrossRef]
  10. Cai, Q. A secure image encryption algorithm based on composite chaos theory. Treat. Du Signal 2019, 36, 31–36. [Google Scholar] [CrossRef]
  11. Wang, X.; Chen, X. An image encryption algorithm based on dynamic row scrambling and zigzag transformation. Chaos Solitons Fractals 2021, 147, 110962. [Google Scholar] [CrossRef]
  12. Zhang, X.; Wang, L.; Cui, G.; Niu, Y. Entropy-based block scrambling image encryption using des structure and chaotic systems. Int. J. Opt. 2021, 2019, 3594534. [Google Scholar] [CrossRef] [Green Version]
  13. Sarosh, P.; Parah, S.A.; Bhat, G.M. An efficient image encryption scheme for healthcare applications. Multimed. Tools Appl. 2022, 81, 7253–7270. [Google Scholar] [CrossRef] [PubMed]
  14. Zhu, C.; Wang, G.; Sun, K. Cryptanalysis and improvement on an image encryption algorithm design using a novel chaos based S-box. Symmetry 2018, 10, 399. [Google Scholar] [CrossRef]
  15. Masood, F.; Ahmad, J.; Shah, S.A.; Jamal, S.S.; Hussain, I. A novel hybrid secure image encryption based on julia set of fractals and 3d Lorenz chaotic map. Entropy 2020, 22, 274. [Google Scholar] [CrossRef]
  16. Zhang, R.; Yu, L.; Jiang, D.; Ding, W.; Song, J.; He, K.; Ding, Q. A novel plaintext-related color image encryption scheme based on cellular neural network and Chen’s chaotic system. Symmetry 2021, 13, 393. [Google Scholar] [CrossRef]
  17. Xian, Y.; Wang, X. Fractal sorting matrix and its application on chaotic image encryption. Inf. Sci. 2021, 547, 1154–1169. [Google Scholar] [CrossRef]
  18. Kaur, M.; Singh, D.; Sun, K.; Rawat, U. Color image encryption using non-dominated sorting genetic algorithm with local chaotic search based 5d chaotic map. Future Gener. Comput. Syst. 2020, 107, 333–350. [Google Scholar] [CrossRef]
  19. Chen, X.; Qian, S.; Yu, F.; Zhang, Z.; Shen, H.; Huang, Y.; Cai, S.; Deng, Z.; Li, Y.; Du, S. Pseudorandom number generator based on three kinds of four-wing memristive hyperchaotic system and its application in image encryption. Complexity 2020, 2020, 8274685. [Google Scholar] [CrossRef]
  20. Jiao, K.; Ye, G.; Dong, Y.; Huang, X.; He, J. Image encryption scheme based on a generalized Arnold map and RSA algorithm. Secur. Commun. Netw. 2020, 2020, 9721675. [Google Scholar] [CrossRef]
  21. Patel, S.; Bharath, K.; Kumar, R. Symmetric keys image encryption and decryption using 3d chaotic maps with DNA encoding technique. Multimed. Tools Appl. 2020, 79, 31739–31757. [Google Scholar] [CrossRef]
  22. Li, Z.; Peng, C.; Tan, W.; Li, L. A novel chaos-based color image encryption scheme using bit-level permutation. Symmetry 2020, 12, 1497. [Google Scholar] [CrossRef]
  23. Himeur, Y.; Boukabou, A. A robust and secure key-frames based video watermarking system using chaotic encryption. Multimed. Tools Appl. 2018, 77, 8603–8627. [Google Scholar] [CrossRef]
  24. Jabbar, A.K.; Hashim, A.T.; Al-Doori, Q.F. Secured medical image hashing based on frequency domain with chaotic map. Eng. Technol. J. 2021, 39, 711–722. [Google Scholar] [CrossRef]
  25. Zhang, G.; Ding, W.; Li, L. Image encryption algorithm based on tent delay-sine cascade with logistic map. Symmetry 2020, 12, 355. [Google Scholar] [CrossRef]
  26. Hamad, A.; Farhan, A.K. Image encryption algorithm based on substitution principle and shuffling scheme. Eng. Technol. J. 2020, 38, 98–103. [Google Scholar] [CrossRef]
  27. Ravichandran, D.; Banu, S.A.; Murthy, B.; Balasubramanian, V.; Fathima, S.; Amirtharajan, R. An efficient medical image encryption using hybrid DNA computing and chaos in transform domain. Med. Biol. Eng. Comput. 2021, 59, 589–605. [Google Scholar] [CrossRef]
  28. Tawfic, I.S. Design and development of e-passport scheme using multi encryption biometric information. Iraqi J. Comput. Commun. Control. Syst. Eng. 2019, 19, 27–34. [Google Scholar]
  29. Song, C.; Qiao, Y. A Novel Image Encryption Algorithm Based on DNA Encoding and Spatiotemporal Chaos. Entropy 2015, 17, 6954–6968. [Google Scholar] [CrossRef]
  30. Natiq, H.; Al-Saidi, N.M.; Obaiys, S.J.; Mahdi, M.N.; Farhan, A.K. Image Encryption Based on Local Fractional Derivative Complex Logistic Map. Symmetry 2022, 14, 1874. [Google Scholar] [CrossRef]
  31. Wen, H.; Ma, L.; Liu, L.; Huang, Y.; Chen, Z.; Li, R.; Liu, Z.; Lin, W.; Wu, J.; Li, Y.; et al. High-quality restoration image encryption using DCT frequency-domain compression coding and chaos. Sci. Rep. 2022, 12, 16523. [Google Scholar] [CrossRef]
  32. Li, C.; Shen, X.; Liu, S. Cryptanalyzing an Image Encryption Algorithm Underpinned by 2D Lag-Complex Logistic Map. arXiv 2022, arXiv:2208.06774. [Google Scholar]
  33. Lima, V.S.; Madeiro, F.; Lima, J.B. Encryption of 3D medical images based on a novel multiparameter cosine number transform. Comput. Biol. Med. 2020, 121, 103772. [Google Scholar] [CrossRef] [PubMed]
  34. Jirjees, S.W.; Yousif, N.A.; Hashim, A.T. Colour image privacy based on cascaded design of symmetric block cipher. J. Eng. Sci. Technol. 2022, 17, 2135–2156. [Google Scholar]
  35. Wang, X.; Çavuşoğlu, Ü.; Kacar, S.; Akgul, A.; Pham, V.-T.; Jafari, S.; Alsaadi, F.E.; Nguyen, X.Q. S-Box Based Image Encryption Application Using a Chaotic System without Equilibrium. Appl. Sci. 2019, 9, 781. [Google Scholar] [CrossRef] [Green Version]
  36. Gan, Z.H.; Chai, X.L.; Han, D.J.; Chen, Y.R. A chaotic image encryption algorithm based on 3-D bit-plane permutation. Neural Comput. Appl. 2019, 31, 7111–7130. [Google Scholar] [CrossRef]
  37. Hua, Z.; Zhu, Z.; Yi, S.; Zhang, Z.; Huang, H. Cross-plane colour image encryption using a two-dimensional logistic tent modular map. Inf. Sci. 2021, 546, 1063–1083. [Google Scholar] [CrossRef]
  38. Zhang, S.; Liu, L. A novel image encryption algorithm based on SPWLCM and DNA coding. Math. Comput. Simul. 2021, 190, 723–744. [Google Scholar] [CrossRef]
  39. Albahrani, E.A.; Maryoosh, A.A.; Lafta, S.H. Block image encryption based on modified playfair and chaotic system. J. Inf. Secur. Appl. 2020, 51, 102445. [Google Scholar] [CrossRef]
  40. Shengtao, G.; Tao, W.; Shida, W.; Xuncai, Z.; Ying, N. A novel image encryption algorithm based on chaotic sequences and cross-diffusion of bits. IEEE Photonics J. 2020, 13, 1–15. [Google Scholar] [CrossRef]
  41. Zhang, Y.; Xie, H.; Sun, J.; Zhang, H. An efficient multi-level encryption scheme for stereoscopic medical images based on coupled chaotic system and Otsu threshold segmentation. Comput. Biol. Med. 2022, 146, 105542. [Google Scholar] [CrossRef]
  42. Zheng, J.; Luo, Z.; Tang, Z. An image encryption algorithm based multichroic system and DNA coding. Discret. Dyn. Nat. Soc. 2020, 2020, 5982743. [Google Scholar] [CrossRef]
Figure 1. Key image specifications. (a) key image; (b) key image histogram. (c) key image adjacent pixel correlation.
Figure 1. Key image specifications. (a) key image; (b) key image histogram. (c) key image adjacent pixel correlation.
Symmetry 15 00409 g001
Figure 2. Structure of the RGB image encryption approach.
Figure 2. Structure of the RGB image encryption approach.
Symmetry 15 00409 g002
Figure 3. The proposed algorithm.
Figure 3. The proposed algorithm.
Symmetry 15 00409 g003
Figure 4. The proposed permutation. (a) Row permutation; (b) Column permutation.
Figure 4. The proposed permutation. (a) Row permutation; (b) Column permutation.
Symmetry 15 00409 g004
Figure 5. Example of the encrypted image.
Figure 5. Example of the encrypted image.
Symmetry 15 00409 g005
Figure 6. The proposed decryption system.
Figure 6. The proposed decryption system.
Symmetry 15 00409 g006
Figure 7. Experimental results for images with a 512 × 512 resolution.
Figure 7. Experimental results for images with a 512 × 512 resolution.
Symmetry 15 00409 g007
Figure 8. Histogram of images. (a) Plain images; (b) Histogram of plain images; (c) Histogram of encrypted images by the proposed algorithm.
Figure 8. Histogram of images. (a) Plain images; (b) Histogram of plain images; (c) Histogram of encrypted images by the proposed algorithm.
Symmetry 15 00409 g008
Figure 9. Adjacent pixel correlation of plain image Lena: (a) Horizontal adjacent pixels of plain image, (b) Vertical adjacent pixels of plain image, (c) Diagonal adjacent pixels of plain image, (d) Horizontal adjacent pixels of encrypted image, (e) Vertical adjacent pixels of encrypted image, and (f) Diagonal adjacent pixels of encrypted image.
Figure 9. Adjacent pixel correlation of plain image Lena: (a) Horizontal adjacent pixels of plain image, (b) Vertical adjacent pixels of plain image, (c) Diagonal adjacent pixels of plain image, (d) Horizontal adjacent pixels of encrypted image, (e) Vertical adjacent pixels of encrypted image, and (f) Diagonal adjacent pixels of encrypted image.
Symmetry 15 00409 g009
Figure 10. Analysis results for data losses and noise, (a) 6.25% data loss in the cipher image; (b) 12.5% data loss in the cipher image; (c) 25% data loss in the cipher image; (d) 5% salt and pepper noise; (e) 10% salt and pepper noise; (f) corresponding decryption image of (a); (g) corresponding decryption image of (b); (h) corresponding decryption image of (c); (i) corresponding decryption image of (d); and (j) corresponding decryption image of (e).
Figure 10. Analysis results for data losses and noise, (a) 6.25% data loss in the cipher image; (b) 12.5% data loss in the cipher image; (c) 25% data loss in the cipher image; (d) 5% salt and pepper noise; (e) 10% salt and pepper noise; (f) corresponding decryption image of (a); (g) corresponding decryption image of (b); (h) corresponding decryption image of (c); (i) corresponding decryption image of (d); and (j) corresponding decryption image of (e).
Symmetry 15 00409 g010
Figure 11. Sensitivity of secret key: (a) The plain images; (b) Encrypted image with Key 1; (c) Encrypted image with Key 2; (d) Absolute difference of images (b,c).
Figure 11. Sensitivity of secret key: (a) The plain images; (b) Encrypted image with Key 1; (c) Encrypted image with Key 2; (d) Absolute difference of images (b,c).
Symmetry 15 00409 g011
Table 1. Processing time for encryption and decryption (seconds).
Table 1. Processing time for encryption and decryption (seconds).
Colour Image SizeEncryptionDecryption
GrayscaleColour ImageGrayscaleColour Image
256 × 2560.00360.060.0040.07
512 × 5120.010.10.020.17
1024 × 10240.040.30.060.29
Table 2. The correlation of plain images and encrypted images.
Table 2. The correlation of plain images and encrypted images.
ImageColourPlain ImageCipher Image
HorizontalVerticalDiagonalHorizontalVerticalDiagonal
LenaRed0.98870.99470.9815−0.00040.0036−0.0035
Green0.98920.9950.9826−0.00260.00590.0019
Blue0.97930.98980.9668−0.00070.0056−0.0004
BaboonRed0.990.00830.9744−0.00370.0071−0.0027
Green0.99710.99660.9909−0.00290.0073−0.0028
Letter ARed0.94930.96560.9185−0.00130.0051−0.0030
Green0.94930.96560.9185−0.00050.009−0.0008
Blue0.94930.96560.91850.00270.0086−0.0015
Table 3. Materials of entropy.
Table 3. Materials of entropy.
ImageOriginalEncrypted
RedGreenBlueRedGreenBlue
Lena7.28657.55927.05277.99817.9987.9978
Baboon7.62027.31397.62777.99817.9987.9981
Letter A1.16081.16081.16087.99737.99737.9973
Table 4. Differential analysis of encrypted images.
Table 4. Differential analysis of encrypted images.
ImageNPCRUACI
RedGreenBlueRedGreenBlue
Lena99.2199.399.1133.3833.4133.49
Baboon98.9898.9498.9132.3132.2832.29
Letter A99.699.699.633.4633.4633.46
Table 5. Comparison among suggested schemes and various encryption algorithms.
Table 5. Comparison among suggested schemes and various encryption algorithms.
SchemeImageEntropyNPCRUACICorrelation
HorizontalVerticalDiagonal
Ref. [22]Baboon7.999299.617433.3920.0049−0.00260.0068
Ref. [39]Baboon7.998699.16733.3260.0021−0.0159−0.0017
Ref. [42]Baboon7.997199.59633.4590.65780.73010.6387
ProposedBaboon7.998099.35233.453−0.00370.0071−0.0027
Ref. [30]Lena7.999599.68033.1200.00450.00160.0017
Ref. [38]Lena7.996999.62433.5020.0040−0.0012−0.0021
Ref. [40]Lena7.902399.60633.444−0.0020−0.00650.0087
ProposedLena7.998099.25233.455−0.00040.0036−0.0035
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Jirjees, S.W.; Alkalid, F.F.; Shareef, W.F. Image Encryption Using Dynamic Image as a Key Based on Multilayers of Chaotic Permutation. Symmetry 2023, 15, 409. https://doi.org/10.3390/sym15020409

AMA Style

Jirjees SW, Alkalid FF, Shareef WF. Image Encryption Using Dynamic Image as a Key Based on Multilayers of Chaotic Permutation. Symmetry. 2023; 15(2):409. https://doi.org/10.3390/sym15020409

Chicago/Turabian Style

Jirjees, Seerwan W., Farah F. Alkalid, and Waleed F. Shareef. 2023. "Image Encryption Using Dynamic Image as a Key Based on Multilayers of Chaotic Permutation" Symmetry 15, no. 2: 409. https://doi.org/10.3390/sym15020409

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop