# Self-Adaptive Image Encryption Algorithm Based on Quantum Logistic Map

Authors: Youxia Dong; Xiaoling Huang; Qixiang Mei; Yuanju Gan
Journal: Security and Communication Networks
 (2021)

---

## Abstract

This study proposes a self-adaptive image encryption algorithm based on the quantum logistic map. First, the initial values are substituted into the quantum logistic map based on an iteration process to generate three random sequences. After preprocessing, three new random sequences with better randomicity were obtained from the generated random sequences. In particular, the correlation coefficients for random sequences before and after preprocessing are compared to determine the best model to make the correlation coefficients closer to zero. Second, one random sequence in the scrambling stage is selected with respect to the plain image. The selected random sequence is then used to perform row-column perturbation on the plain image. Finally, the remaining two random sequences are used to perform forward and reverse diffusion to obtain the final cipher image. Because of the dependence on the plain image, the algorithm can frustrate the chosen-plaintext and known-plaintext attacks. Experimental results show that the proposed encryption algorithm can achieve secure communications.


---

## Body

## 1. Introduction

With the rapid development of network technology and multimedia, the forms of information expression on the network are also diversified. This digital information is transmitted through the network to all corners of the world to facilitate the daily needs of people. As the most universal and key information carrier in the field of digital information systems and modern communication, digital images may contain abundant private information. If an unauthorized person accesses this information, there could be serious consequences. Therefore, the protection of image information from being leaked and stolen has become the focus of the field of information security [1].The randomness, ergodicity, and unpredictability of chaotic systems can satisfy the requirements of image encryption. In [2], a chaotic system is used for image encryption, in which the iterative state value of the chaotic system is directly used to scramble image pixel points proposed. This study introduces the performance of an image cryptosystem, including key space, known-plain attacks, ciphertext-only attacks, and chaotic map pseudorandom sequence generators. Then, this type of image encryption method based on the chaotic system is extensively used in image encryption systems. A new chaotic system was presented in [3] based on two existing one-dimensional chaotic maps that can be used to implement a sorting-based scrambling algorithm. The new chaotic system has good chaotic behavior, and the distribution of chaotic sequences is uniform. Image encryption was also realized by combining the Arnold map and the Rivest–Shamir–Adleman (RSA) algorithm [4]. First, the initial value of the Arnold map is generated by the RSA algorithm followed by the XOR diffusion operation. After the scrambling operation of the rows and columns, the additive mode diffusion operation is performed. This achieves a three-layer image hiding effect. Because the security of the encryption scheme depends on the RSA algorithm, the security is at a high level. In [5], an image encryption scheme based on the RSA and Arnold transform was proposed that is better than the traditional ones that are based on the Arnold transform and row-column chaos. First, two sets of parameters are generated by the RSA algorithm. Subsequently, during the scrambling operation, two sets of parameters are applied to the Arnold transform. A set of parameters is used in block scrambling, and another set is used in global scrambling. In turn, in [6], an improved image encryption and decryption algorithm was proposed that combined Tent and Arnold maps. The plain image was first transformed by the Hadamard transformation and then scrambled using the Arnold map, finally XOR diffusion using the Tent map. Reference [7] suggested image encryption with two different sets of chaotic maps. First, the Tent-Sine map was used to generate the measurement matrix and the random numbers needed for embedding. The plain image was then scrambled using the Logistic-Tent map. The experiments proved that the system has enhanced security and improved robustness characteristics. A chaos-based asymmetric color image encryption scheme was proposed in [8], in which different keys were distributed to different receivers by a key conversion mechanism. Using the hash value of the plain image as two initial values of the Henon map, the random sequence needed for encryption was generated. However, owing to the short cryptosystem period and low precision in the low-dimensional chaotic system, the security of image encryption was difficult to promise. With the development of cryptographic security analysis, these low-dimensional chaotic systems are no longer secure considering key space. Thus, a method that combines high-dimensional chaotic systems to design the image encryption algorithm needs our attention. Reference [9] proposed an image cryptosystem based on a lifting scheme and a chaotic system. In the lifting scheme, the plain image data were split into even- and odd-indexed sequences. Based on these two sequences, one low-frequency and three high-frequency components of the image were obtained by computing wavelet transforms. The pseudorandom sequences generated by the chaotic system with the secret key were used to disturb the detailed components’ high frequency and were then used to disturb the approximation components’ low frequency of the image. The two disturbed components are inverted separately to execute the prediction and update operations once more to achieve the cipher image. A new digital image encryption scheme was proposed combining with Lorenz chaotic system in [10]. In the process of generating a random keystream, the hash value of the plain image was embedded into the encryption system, and the initial key was changed dynamically to improve the security level. However, the chaotic sequences obtained by the Lorenz system have some problems such as weak wideband characteristics, imperfect sequence correlation, and local monotonicity. Therefore, an improved version of the Lorenz system was proposed in [11]. By replacing the nonlinear term in the Lorenz system with the sum of the exponential and the quadratic terms of a single variable, more complex chaotic attractors with larger positive Lyapunov exponents can be generated. Reference [12] combined chaotic systems with compression sensing technology to design a visually meaningful encryption scheme. In the process of preencryption, compressed perceptual technology and Zigzag obfuscation were used to obtain the middle encrypted image. The random sequence generated by 3D-cat map and the middle encrypted image are embedded with the least significant bit to obtain the final cipher image. Reference [13] proposed a new image encryption algorithm that included a quantum chaotic map, Lorenz chaotic map, and deoxyribonucleic acid (DNA) coding. It used four DNA base pairs to dynamically select DNA coding rules, DNA additions, and XOR rules. Dynamic selection of DNA coding and decoding rules was achieved by the dynamic changes in pixel DNA encoding that effectively improved the security of the encryption algorithm. Reference [14] proposed a color image encryption based on DNA and a 4D memristive hyperchaos. The main feature was to use the dynamic DNA mechanism based on hyperchaos in the processes of encoding, confusion, and diffusion. In [15], an efficient bit-level quantum color image encryption scheme based on quantum cross-exchange operation and 5D hyperchaotic system was proposed, which shows high security and enough capacity of resisting noise attack.Image encryption is usually pursued in the frequency and spatial domains. Reference [16] used frequency domain encryption, wherein the plain image was first transformed with the discrete wavelet transform and then compressed. The carrier image was then processed by lifting the wavelet transform and discrete cosine transform together with a Schur decomposition. Finally, an embedding operation was performed to achieve visually meaningful image encryption. Although frequency domain encryption greatly improves encryption efficiency, the implementation of frequency domain transformation leads to data loss. A secure and efficient image encryption algorithm based on adaptive permutation diffusion and DNA random coding was proposed in [17]. Plain images were first transformed into DNA sequences using random coding rules to disperse the distribution of the plain image. The adaptive permutation-diffusion process was then introduced to encrypt. In [18], the perturbation operation was designed as a self-adaptive method to replace the traditional confusion method. In addition, it provided a feedback-based diffusion mechanism that could act on internal blocks so that minor changes can affect the value of the current and another block. A new multi-image encryption scheme based on QDFrHT and an improved pixel adaptive diffusion was proposed in [19], which can achieve large-capacity image compression and encryption. Moreover, it is more convenient for key storage and transmission. Zhou et al. [20] proposed a quantum image encryption and decryption scheme, which was based on iterative generalized Arnold transforms and quantum image cycle shift operations. Different parameters and different iteration times were suggested for high security. In [21], a DQWT and 3D hyperchaotic Henon map based image compression and encryption algorithm was presented. For a high security, the quantum image is scrambled by the iterative generalized Arnold transforms to eliminate the block effect. Ye et al. [22] proposed an image encryption scheme by employing DCT, quantum logistic map, and substitution-permutation structure which has a high sensitivity to plain text and keys. Reference [23] proposed an efficient pixel-level chaotic image encryption algorithm based on the two-dimensional sine logistic modulation map. To be different from the traditional encryption architecture, the method enhances the connection between pixel shuffling and value changing. In [24], a three-dimensional chaotic map was employed for fast image encryption. The scheme, especially, uses the latest generated numbers to permute the next block. There are some other encryption methods, for example, public-key cryptosystem based [25] and random numbers insertion based [7].Because the low-dimensional chaotic system has certain security problems and the frequency domain encryption will cause data loss, therefore, this study uses the quantum logistic map to conduct the encryption algorithm in the spatial domain. The range of the parameters is wider, and the random sequence generated can be preprocessed to produce a more random sequence which improves the encryption effect. This article is organized as follows: the proposed encryption algorithm is given in Section2 with detailed image encryption and decryption processes. Section 3 executes the simulation and obtains the experimental result. Security analysis is performed in Section 4. Section 5 presents some conclusions of the proposed method.


## 2. Proposed Encryption Algorithm

### 2.1. Quantum Logistic Map

A quantum chaotic map was presented in [26], which is defined as(1)xn+1=rxn−xn2−ryn,yn+1=−yne−2β+e−βr2−xn−x¯nyn−xnz¯n−x¯nzn,zn+1=−zne−2β+e−βr21−x¯nzn−2xnyn−xn,where the control parameter r∈3.74,4.00, the parameter β≥3.5, and x¯n and z¯n are the complex conjugations of xn and zn, respectively. The above quantum logistic map has the advantages of natural parallelism, simple structure, and large capacity. Moreover, the generated chaotic sequences are more pseudorandom. When r=3.99 and β≥6, the quantum chaotic map can exhibit better chaotic behavior. In this study, r=3.99, β=7, and the initial conditions x0=0.067, y0=0.247, and z0=0.863, are randomly selected and substituted 2500 times; then, three random sequences are obtained, and the first 500 are discarded to eliminate the transient effect.The autocorrelation and cross-correlation diagrams of the sequencesx,y,z are shown in Figure 1. Because the ideal pseudorandom sequence needs to be uniformly distributed, the autocorrelation function should satisfy the shape of a delta function, and the cross-correlation function is close to zero. As can be observed from Figure 1, the autocorrelation and cross-correlation functions of the sequences x,y,z are not very close to the ideal case. Thus, a preprocess is designed for these sequences as follows with test results listed in Table 1:(2)x′=x×10α−roundx×10α,y′=y×10α−roundy×10α,z′=z×10α−roundz×10α.Figure 1
Autocorrelation and cross-correlation: (a) autocorrelation ofx, (b) autocorrelation of y, (c) autocorrelation of z, (d) cross-correlation of x,y, (e) cross-correlation of x,z, and (f) cross-correlation of y,z.
(a)(b)(c)(d)(e)(f)Table 1
Cross-correlation coefficients.
SequenceCross-correlation coefficient before preprocessingCross-correlation coefficients of differentα-values after preprocessingα=4α=5α=6α=7α=8x−y0.0392−0.03090.0244−0.0020−0.01280.0060x−z−0.1211−0.0610−0.0217−0.00200.02500.0338y−z0.0343−0.0024−0.0212−0.0153−0.00980.0192Mean0.06490.03150.02240.00640.01580.0196When we setα=6, the autocorrelation and cross-correlation of the new sequences x′,y′,z′ are shown in Figure 2. It can be observed that the treated sequence autocorrelation function is closer to the delta function and the cross-correlation function is closer to zero. Compared with the random sequence before processing, the random sequence after processing is closer to the ideal random sequence, and the randomness is improved. To prove that the randomness of the processed sequences is better, the histograms of the sequence before and after processing are shown in Figure 3. Obviously, the new sequences are more random. It is noted that α=6 is chosen due to the smallest mean value of the cross-correlation coefficient as seen in Table 1.Figure 2
Autocorrelation and cross-correlation. (a) Autocorrelation ofx′, (b) autocorrelation of y′, (c) autocorrelation of z′, (d) cross-correlation of x′,y′, (e) cross-correlation of x′,z′, and (f) cross-correlation of y′,z′.
(a)(b)(c)(d)(e)(f)Figure 3
Frequency distribution histogram: sequences of (a)x, (b) y, (c) z, (d) x′, (e) y′, and (f) z′.
(a)(b)(c)(d)(e)(f)


### 2.2. Image Encryption Process

The flowchart of our image encryption algorithm is shown in Figure4. The encryption steps are as follows:Step 1: read the size of the plain imageP as m×n, and compute sum s=∑i=1M∑j=1NPi,j . Then, sequences x=x1,x2,…,xs1+m×n,y=y1,y2,…,ys1+m×n, and z=z1,z2,…,zs1+m×n with lengths s1+m×n are generated with keys x0,y0,z0, where s1=smod200+300.Step 2: preprocess the sequencesx,y,z with α=6, and then three new sequences x′=x1′,x2′,…,xs1+m×n′, y′=y1′,y2′,…,ys1+m×n′, and z′=z1′,z2′,…,zs1+m×n′ are obtained. m numbers are taken from s1+1 to form a sequence L=xs1+1′,xs1+2′,…,xs1+m′ which is used to scramble the plain image, and n numbers are taken from s1+m+1 to form sequence T=xs1+m+1′,xs1+m+2′,…,xs1+m+n′, which is also used to scramble the plain image. m×n numbers from location 301 are taken to form the sequences Y=y301′,y302′,…,y300+m×n′ and Z=z301′,z302′,…,z300+m×n′, respectively.Step 3: map all values in the random sequenceL into the range of 1,m and the random sequence T into the range of 1,n according to(3)L=floorL−floorL×1014modm+1,T=floorT−floorT×1014modn+1.Step 4: perform the scrambling operation on the plain imageP to obtain Musing updated sequence Land sequence Tas(4)P′i,:=PLi,:,M:,j=P′:,Tj,wherei=1,2,…,m and j=1,2,…,n.Step 5: the random sequencesY,Z are mapped into the range of [0–255] by(5)Y=floorY−floorY×1014mod256,Z=floorZ−floorZ×1014mod256.Step 6: arrange the imageM into a one-dimensional matrix M′, and do the XOR operation for it by sequence Y as follows:(6)A1=Y1⊕M1′,Ai=Ai−1⊕Yi⊕Mi′,wherei=2,…,m×n.Step 7: perform a reverse diffusion operation again to achieve a better diffusion effect as follows:(7)Bm×n=Zm×n⊕Am×n,Bj=Bj+1⊕Zj⊕Aj,wherej=m×n−1,…,1.Step 8: convert sequenceB into matrix C with size m×n to obtain the final image C.Figure 4
Flowchart of the proposed image encryption algorithm.


### 2.3. Image Decryption Process

Step 1: the receiver puts the correct initial values into the quantum logistic map and produces three sequencesx,y,z. Then, α=6 is used to generate three new sequences x′,y′,z′ by a preprocessing. Sequences L,T,Y,Z can be obtained by the same operations.Step 2: the cipher imageC is arranged into a one-dimensional vectorB, and the sequence Z is used to do the XOR diffusion to obtainA as follows:(8)Am×n=Bm×n⊕Zm×n,Aj=Bj⊕Bj+1⊕Zj,wherej=mn−1,mn−2,…,1.Step 3: XOR diffusion is performed again onA to obtain M by sequence Yas follows:(9)M1=A1⊕Y1,Mi=Ai⊕Ai−1⊕Yi,wherei=1,2,…,mn.Step 4: inverse scrambling operation is performed on the matrixM to obtain the plain image using sequences L and T as follows:(10)E:,Tj=M:,j,PLi,:=Ei,:,wherei=1,2,…,m and j=1,2,…,n.


## 2.1. Quantum Logistic Map

A quantum chaotic map was presented in [26], which is defined as(1)xn+1=rxn−xn2−ryn,yn+1=−yne−2β+e−βr2−xn−x¯nyn−xnz¯n−x¯nzn,zn+1=−zne−2β+e−βr21−x¯nzn−2xnyn−xn,where the control parameter r∈3.74,4.00, the parameter β≥3.5, and x¯n and z¯n are the complex conjugations of xn and zn, respectively. The above quantum logistic map has the advantages of natural parallelism, simple structure, and large capacity. Moreover, the generated chaotic sequences are more pseudorandom. When r=3.99 and β≥6, the quantum chaotic map can exhibit better chaotic behavior. In this study, r=3.99, β=7, and the initial conditions x0=0.067, y0=0.247, and z0=0.863, are randomly selected and substituted 2500 times; then, three random sequences are obtained, and the first 500 are discarded to eliminate the transient effect.The autocorrelation and cross-correlation diagrams of the sequencesx,y,z are shown in Figure 1. Because the ideal pseudorandom sequence needs to be uniformly distributed, the autocorrelation function should satisfy the shape of a delta function, and the cross-correlation function is close to zero. As can be observed from Figure 1, the autocorrelation and cross-correlation functions of the sequences x,y,z are not very close to the ideal case. Thus, a preprocess is designed for these sequences as follows with test results listed in Table 1:(2)x′=x×10α−roundx×10α,y′=y×10α−roundy×10α,z′=z×10α−roundz×10α.Figure 1
Autocorrelation and cross-correlation: (a) autocorrelation ofx, (b) autocorrelation of y, (c) autocorrelation of z, (d) cross-correlation of x,y, (e) cross-correlation of x,z, and (f) cross-correlation of y,z.
(a)(b)(c)(d)(e)(f)Table 1
Cross-correlation coefficients.
SequenceCross-correlation coefficient before preprocessingCross-correlation coefficients of differentα-values after preprocessingα=4α=5α=6α=7α=8x−y0.0392−0.03090.0244−0.0020−0.01280.0060x−z−0.1211−0.0610−0.0217−0.00200.02500.0338y−z0.0343−0.0024−0.0212−0.0153−0.00980.0192Mean0.06490.03150.02240.00640.01580.0196When we setα=6, the autocorrelation and cross-correlation of the new sequences x′,y′,z′ are shown in Figure 2. It can be observed that the treated sequence autocorrelation function is closer to the delta function and the cross-correlation function is closer to zero. Compared with the random sequence before processing, the random sequence after processing is closer to the ideal random sequence, and the randomness is improved. To prove that the randomness of the processed sequences is better, the histograms of the sequence before and after processing are shown in Figure 3. Obviously, the new sequences are more random. It is noted that α=6 is chosen due to the smallest mean value of the cross-correlation coefficient as seen in Table 1.Figure 2
Autocorrelation and cross-correlation. (a) Autocorrelation ofx′, (b) autocorrelation of y′, (c) autocorrelation of z′, (d) cross-correlation of x′,y′, (e) cross-correlation of x′,z′, and (f) cross-correlation of y′,z′.
(a)(b)(c)(d)(e)(f)Figure 3
Frequency distribution histogram: sequences of (a)x, (b) y, (c) z, (d) x′, (e) y′, and (f) z′.
(a)(b)(c)(d)(e)(f)


## 2.2. Image Encryption Process

The flowchart of our image encryption algorithm is shown in Figure4. The encryption steps are as follows:Step 1: read the size of the plain imageP as m×n, and compute sum s=∑i=1M∑j=1NPi,j . Then, sequences x=x1,x2,…,xs1+m×n,y=y1,y2,…,ys1+m×n, and z=z1,z2,…,zs1+m×n with lengths s1+m×n are generated with keys x0,y0,z0, where s1=smod200+300.Step 2: preprocess the sequencesx,y,z with α=6, and then three new sequences x′=x1′,x2′,…,xs1+m×n′, y′=y1′,y2′,…,ys1+m×n′, and z′=z1′,z2′,…,zs1+m×n′ are obtained. m numbers are taken from s1+1 to form a sequence L=xs1+1′,xs1+2′,…,xs1+m′ which is used to scramble the plain image, and n numbers are taken from s1+m+1 to form sequence T=xs1+m+1′,xs1+m+2′,…,xs1+m+n′, which is also used to scramble the plain image. m×n numbers from location 301 are taken to form the sequences Y=y301′,y302′,…,y300+m×n′ and Z=z301′,z302′,…,z300+m×n′, respectively.Step 3: map all values in the random sequenceL into the range of 1,m and the random sequence T into the range of 1,n according to(3)L=floorL−floorL×1014modm+1,T=floorT−floorT×1014modn+1.Step 4: perform the scrambling operation on the plain imageP to obtain Musing updated sequence Land sequence Tas(4)P′i,:=PLi,:,M:,j=P′:,Tj,wherei=1,2,…,m and j=1,2,…,n.Step 5: the random sequencesY,Z are mapped into the range of [0–255] by(5)Y=floorY−floorY×1014mod256,Z=floorZ−floorZ×1014mod256.Step 6: arrange the imageM into a one-dimensional matrix M′, and do the XOR operation for it by sequence Y as follows:(6)A1=Y1⊕M1′,Ai=Ai−1⊕Yi⊕Mi′,wherei=2,…,m×n.Step 7: perform a reverse diffusion operation again to achieve a better diffusion effect as follows:(7)Bm×n=Zm×n⊕Am×n,Bj=Bj+1⊕Zj⊕Aj,wherej=m×n−1,…,1.Step 8: convert sequenceB into matrix C with size m×n to obtain the final image C.Figure 4
Flowchart of the proposed image encryption algorithm.


## 2.3. Image Decryption Process

Step 1: the receiver puts the correct initial values into the quantum logistic map and produces three sequencesx,y,z. Then, α=6 is used to generate three new sequences x′,y′,z′ by a preprocessing. Sequences L,T,Y,Z can be obtained by the same operations.Step 2: the cipher imageC is arranged into a one-dimensional vectorB, and the sequence Z is used to do the XOR diffusion to obtainA as follows:(8)Am×n=Bm×n⊕Zm×n,Aj=Bj⊕Bj+1⊕Zj,wherej=mn−1,mn−2,…,1.Step 3: XOR diffusion is performed again onA to obtain M by sequence Yas follows:(9)M1=A1⊕Y1,Mi=Ai⊕Ai−1⊕Yi,wherei=1,2,…,mn.Step 4: inverse scrambling operation is performed on the matrixM to obtain the plain image using sequences L and T as follows:(10)E:,Tj=M:,j,PLi,:=Ei,:,wherei=1,2,…,m and j=1,2,…,n.


## 3. Experimental Results

The encryption algorithm presented in this study was implemented with MATLAB (version R2019a) on the Windows 10 platform with a 1.90 GHz processor. In the experiment, two gray-scale images and two-color images were selected randomly as the plain images to do the tests. Initial valuesx0=0.067, y0=0.247, and z0=0.863 and parameters r=3.99, β=7, α=6 are set. As can be observed from Figure 5, no effective information about the plain image can be seen in the cipher image. Table 2 shows the value s1 used in different rounds of perturbation for different images. Because different images have different pixels, the values of s1 are also different. As a result, the random sequence used in the scrambling stage is different, and the final encryption effect is different, which reflects the adaptive encryption method very well.Figure 5
Test results. Plain images of (a) bridge, (b) baboon, (c) Earth, and (d) sun; (e) cipher image of (a), (f) cipher image of (b), (g) cipher image of (c), (h) cipher image of (d), (i) correct decrypted image of (e), (j) correct decrypted image of (f), (k) correct decrypted image of (g), and (l) correct decrypted image of (h).
(a)(b)(c)(d)(e)(f)(g)(h)(i)(j)(k)(l)Table 2
Values ofs1.
ImageBaboonBridgeSunEarth peppersRGBRGBFirst round416482340395435454326424Second round333452388353451427312409Third round360427340314332330354313


## 4. Performance Analysis

### 4.1. Key Space

The key space is a set of all keys in the algorithm. An encryption system with a large key space can resist violent attacks effectively and has enhanced security. In this algorithm, the initial valuesx0,y0,z0 are used in the chaotic map. When the computational accuracy is set as 10−14, the key space can reach 1014×1014×1014=1042≈2139.5>2100. Therefore, the proposed algorithm has a large key space that can effectively resist violent attacks.


### 4.2. Key Sensitivity Analysis

This part mainly tests the key sensitivity of the proposed algorithm. If an encryption algorithm has high-key sensitivity, the cryptosystem can effectively resist violent attacks and ensure the security of the images. Consider a bridge image with a size of512×512 as an example used for testing purposes. Figure 6 shows the corresponding decryption image when the key is changed only with 10−14 during the decryption process. Because the scrambling phase is determined by the sum value s of the plain image, the correct image cannot be decrypted when a small change occurs. It can be observed that when the decryption key changes slightly, the cipher image cannot be restored to the original plain image. So, the proposed encryption algorithm is sensitive to the key.Figure 6
Key sensitivity test: (a) plain image, (b) cipher image, (c) correct decrypted image, (d) wrong decrypted image withx0−10−14, (e) wrong decrypted image with y0−10−14, (f) wrong decrypted image with r−10−14, (g) wrong decrypted image with β−10−14, and (h) wrong decrypted image with s1−1.
(a)(b)(c)(d)(e)(f)(g)(h)


### 4.3. Histogram Analysis

The histogram is used to show the distribution of each pixel in an image; we use the histogram to show the encryption effect of the proposed encryption scheme. Usually, the histogram of a plain image has obvious statistical characteristics, while the histogram of the encrypted image is evenly distributed. It can be observed from Figure7 that the histogram of the cipher image is evenly distributed and can resist statistical attacks. So, if the attacker obtains a cipher image, he or she cannot obtain any information about the plain image.Figure 7
Histograms of (a) plain image of baboon, (b) cipher image of baboon, (c) plain image of peppers, and (d) cipher image of peppers.
(a)(b)(c)(d)


### 4.4. Correlation Coefficient

Commonly, each pixel in a meaningful image has a strong correlation with its neighbors in the horizontal, vertical, and diagonal directions; an encryption algorithm is supposed to destroy the correlation between pixels to protect the secret information more effectively. The lower the correlation of adjacent pixels in the secret image is, the better the performance of the algorithm is, and the better the antistatistical attack is. Figure8 analyzes the correlation between adjacent pixels in the plain and cipher images from three directions: horizontal, vertical, and diagonal. The correlation coefficient is calculated as follows:(11)Rxy=covx,yDxDy,(12)covx,y=1N∑i=1Nxi−Exyi−Ey,(13)Ex=1N∑i=1Nxi,Dx=1N∑i=1Nxi−Ex2,where Rxy is the correlation coefficient, x and y are the gray values of the two adjacent pixels, and N is the number of adjacent pixels selected from the image. It can be seen from Figure 8 that the correlation of the cipher images is much weaker than that of the original images. Table 3 lists the correlation values in the three directions of the test image. It can be observed that the correlation coefficient of the plain image is close to one, and that of the cipher image is closer to zero. This shows that the proposed encryption algorithm can eliminate the correlation between pixels. This makes the pixel arrangement of the cipher image more random.Figure 8
Correlation coefficients test: (a) horizontal direction of plain image, (b) vertical direction of plain image, (c) positive diagonal direction of plain image, (d) horizontal direction of cipher image, (e) vertical direction of cipher image, and (f) positive diagonal direction of cipher image.
(a)(b)(c)(d)(e)(f)Table 3
Correlation coefficients.
ImagePlain imageCipher imageHorizontalVerticalPositive diagonalHorizontalVerticalPositive diagonalBaboon0.75970.86110.7215−0.00730.01060.0186Bridge0.92790.94110.90030.00120.0061−0.0027Peppers0.97960.97870.9650−0.0001−0.0049−0.0032Lena0.98590.97090.95970.0052−0.0092−0.0078


### 4.5. Information Entropy

As we know, the bigger the information entropy is, the more uniform the distribution of the gray value is, and the more random the image is. Table4 shows the results of gray and color images. As observed from the table, the information entropy value of the plain image is smaller than that of the cipher image, and the information entropy value of the cipher image is closer to the theoretical value of eight. This shows that the cipher image has better randomness and higher security. Compared with [20, 21, 24], the test results by our method are nearer to the theory value:(14)H=−∑PXi,jlog2PXi,j,where X and Y are two different images and PXi,j is the number of Xi,j and is the size of the image M×N.Table 4
Information entropy.
ImageBaboonLenaBaboonPeppersRGBRGBPlain7.35797.44566.57247.45126.76267.33887.49637.0583Cipher7.99927.99937.99927.99927.99937.99947.99927.9993Ref. [20]7.92897.9117——————Ref. [21]7.99747.9960——————Ref. [24]——7.99917.99917.99937.99897.99917.9989


### 4.6. Differential Attack Analysis

For an ideal encryption algorithm, the more sensitive the encryption algorithm is to plain images, the more robust the algorithm is to differential attacks. The sensitivity of encryption algorithms to plain images can be measured by the number of pixels change rate (NPCR) and by the unified average changing intensity (UACI), which are defined by(15)NPCR=1M×N∑i=1M∑j=1NDi,j×100%,(16)UACI=1M×N∑i=1M∑j=1NC1i,j−C2i,j255×100%.When there is only one-pixel difference between two plain images, let the pixel value of pointi,j in their cipher images be C1i,j and C2i,j. If C1i,j=C2i,j, then Di,j=0; if C1i,j≠C2i,j, then Di,j=1. Table 5 lists the test results of NPCR and UACI. It can be observed from the table that the proposed image encryption algorithm has the ability to resist differential attacks since the values of NPCR and UACI are close to their theoretical values.Table 5
NPCR and UACI.
ImageBridgeLenaEarthRGBNPCR (%)99.614199.604499.601199.612099.6127UACI (%)33.499533.464833.484633.462033.4721


## 4.1. Key Space

The key space is a set of all keys in the algorithm. An encryption system with a large key space can resist violent attacks effectively and has enhanced security. In this algorithm, the initial valuesx0,y0,z0 are used in the chaotic map. When the computational accuracy is set as 10−14, the key space can reach 1014×1014×1014=1042≈2139.5>2100. Therefore, the proposed algorithm has a large key space that can effectively resist violent attacks.


## 4.2. Key Sensitivity Analysis

This part mainly tests the key sensitivity of the proposed algorithm. If an encryption algorithm has high-key sensitivity, the cryptosystem can effectively resist violent attacks and ensure the security of the images. Consider a bridge image with a size of512×512 as an example used for testing purposes. Figure 6 shows the corresponding decryption image when the key is changed only with 10−14 during the decryption process. Because the scrambling phase is determined by the sum value s of the plain image, the correct image cannot be decrypted when a small change occurs. It can be observed that when the decryption key changes slightly, the cipher image cannot be restored to the original plain image. So, the proposed encryption algorithm is sensitive to the key.Figure 6
Key sensitivity test: (a) plain image, (b) cipher image, (c) correct decrypted image, (d) wrong decrypted image withx0−10−14, (e) wrong decrypted image with y0−10−14, (f) wrong decrypted image with r−10−14, (g) wrong decrypted image with β−10−14, and (h) wrong decrypted image with s1−1.
(a)(b)(c)(d)(e)(f)(g)(h)


## 4.3. Histogram Analysis

The histogram is used to show the distribution of each pixel in an image; we use the histogram to show the encryption effect of the proposed encryption scheme. Usually, the histogram of a plain image has obvious statistical characteristics, while the histogram of the encrypted image is evenly distributed. It can be observed from Figure7 that the histogram of the cipher image is evenly distributed and can resist statistical attacks. So, if the attacker obtains a cipher image, he or she cannot obtain any information about the plain image.Figure 7
Histograms of (a) plain image of baboon, (b) cipher image of baboon, (c) plain image of peppers, and (d) cipher image of peppers.
(a)(b)(c)(d)


## 4.4. Correlation Coefficient

Commonly, each pixel in a meaningful image has a strong correlation with its neighbors in the horizontal, vertical, and diagonal directions; an encryption algorithm is supposed to destroy the correlation between pixels to protect the secret information more effectively. The lower the correlation of adjacent pixels in the secret image is, the better the performance of the algorithm is, and the better the antistatistical attack is. Figure8 analyzes the correlation between adjacent pixels in the plain and cipher images from three directions: horizontal, vertical, and diagonal. The correlation coefficient is calculated as follows:(11)Rxy=covx,yDxDy,(12)covx,y=1N∑i=1Nxi−Exyi−Ey,(13)Ex=1N∑i=1Nxi,Dx=1N∑i=1Nxi−Ex2,where Rxy is the correlation coefficient, x and y are the gray values of the two adjacent pixels, and N is the number of adjacent pixels selected from the image. It can be seen from Figure 8 that the correlation of the cipher images is much weaker than that of the original images. Table 3 lists the correlation values in the three directions of the test image. It can be observed that the correlation coefficient of the plain image is close to one, and that of the cipher image is closer to zero. This shows that the proposed encryption algorithm can eliminate the correlation between pixels. This makes the pixel arrangement of the cipher image more random.Figure 8
Correlation coefficients test: (a) horizontal direction of plain image, (b) vertical direction of plain image, (c) positive diagonal direction of plain image, (d) horizontal direction of cipher image, (e) vertical direction of cipher image, and (f) positive diagonal direction of cipher image.
(a)(b)(c)(d)(e)(f)Table 3
Correlation coefficients.
ImagePlain imageCipher imageHorizontalVerticalPositive diagonalHorizontalVerticalPositive diagonalBaboon0.75970.86110.7215−0.00730.01060.0186Bridge0.92790.94110.90030.00120.0061−0.0027Peppers0.97960.97870.9650−0.0001−0.0049−0.0032Lena0.98590.97090.95970.0052−0.0092−0.0078


## 4.5. Information Entropy

As we know, the bigger the information entropy is, the more uniform the distribution of the gray value is, and the more random the image is. Table4 shows the results of gray and color images. As observed from the table, the information entropy value of the plain image is smaller than that of the cipher image, and the information entropy value of the cipher image is closer to the theoretical value of eight. This shows that the cipher image has better randomness and higher security. Compared with [20, 21, 24], the test results by our method are nearer to the theory value:(14)H=−∑PXi,jlog2PXi,j,where X and Y are two different images and PXi,j is the number of Xi,j and is the size of the image M×N.Table 4
Information entropy.
ImageBaboonLenaBaboonPeppersRGBRGBPlain7.35797.44566.57247.45126.76267.33887.49637.0583Cipher7.99927.99937.99927.99927.99937.99947.99927.9993Ref. [20]7.92897.9117——————Ref. [21]7.99747.9960——————Ref. [24]——7.99917.99917.99937.99897.99917.9989


## 4.6. Differential Attack Analysis

For an ideal encryption algorithm, the more sensitive the encryption algorithm is to plain images, the more robust the algorithm is to differential attacks. The sensitivity of encryption algorithms to plain images can be measured by the number of pixels change rate (NPCR) and by the unified average changing intensity (UACI), which are defined by(15)NPCR=1M×N∑i=1M∑j=1NDi,j×100%,(16)UACI=1M×N∑i=1M∑j=1NC1i,j−C2i,j255×100%.When there is only one-pixel difference between two plain images, let the pixel value of pointi,j in their cipher images be C1i,j and C2i,j. If C1i,j=C2i,j, then Di,j=0; if C1i,j≠C2i,j, then Di,j=1. Table 5 lists the test results of NPCR and UACI. It can be observed from the table that the proposed image encryption algorithm has the ability to resist differential attacks since the values of NPCR and UACI are close to their theoretical values.Table 5
NPCR and UACI.
ImageBridgeLenaEarthRGBNPCR (%)99.614199.604499.601199.612099.6127UACI (%)33.499533.464833.484633.462033.4721


## 5. Conclusions

In this study, a self-adaptive image encryption algorithm was proposed based on the quantum logistic map. Because the random sequence used in image encryption needs strong randomicity and the random sequence generated directly by the quantum logistic map does not yield a good performance, we suggested a preprocessing for these random sequences. The test analysis showed that if our preprocessed model was applied, the randomness of the random sequence displayed better behavior. In the process of image encryption, each round of encryption selects a random sequence according to the preencrypted image of the previous rounds of encryption. In other words, the random sequence required in the first round was determined by the plain image, while the second round was determined by the cipher image obtained from the first round, and so on. As a result, the encryption algorithm in our method was dependent both on the keys and on the plain image. Therefore, the encryption effect can yield good performance for security communications.



---

*Source: 6674948-2021-01-15.xml*