A Novel Image Encryption Algorithm Based on DNA Subsequence Operation

We present a novel image encryption algorithm based on DNA subsequence operation. Different from the traditional DNA encryption methods, our algorithm does not use complex biological operation but just uses the idea of DNA subsequence operations (such as elongation operation, truncation operation, deletion operation, etc.) combining with the logistic chaotic map to scramble the location and the value of pixel points from the image. The experimental results and security analysis show that the proposed algorithm is easy to be implemented, can get good encryption effect, has a wide secret key's space, strong sensitivity to secret key, and has the abilities of resisting exhaustive attack and statistic attack.


Introduction
Nowadays, the computer network has changed the mode of people's communication. People can easily transfer the various multimedia information through the network. However, because of the openness of the network, people have to take more and more attention on security and confidentiality of multimedia information. The digital image is an important information vector of multimedia communication, thus how to protect the image information becomes a universal concern problem for people. The traditional image encryption methods (such as DES, IDEA, and AES) are not suitable for image encryption due to the different storage format of an image. The new research algorithms of image encryption are needed urgently.
As an example, due to chaotic system with like-random, high sensitivity to initial value, and unforeseeable properties, chaos based cryptosystems have become current research hotspot. According to the object of scrambling, the chaosbased algorithms operate in two stages: the shuffling stage and the substitution stage. In the shuffling stage, the position of pixels from original image is changed by chaotic sequences [1] or by some matrix transformation, such as Arnold transform, magic square transform, and so forth. These shuffling algorithms are easy to be realized and have better encryption effect. Due to these shuffling algorithms, just changing the position of pixels but not changing the pixel values leads to the histogram of the encryption image is the same as the original image, and thus its security is threatened by the statistical analysis. In the substitution stage, the pixel values are changed by chaotic sequences. Most of these encryption methods are directly implemented by overlaying a chaotic sequence generated by a single chaotic map and the pixel grey value from the image. Comparing with the method of the shuffling, the method of value substitution may lead to higher security, but from the vision angle the encryption effect is not good. Thereby, in order to improve the security and the encryption effect, the shuffling and the value substitution are combined by some researchers, the readers can refer to [2,3]. However, only using a single chaotic map to encrypt image may result in lower security and smaller key space. Ren et al. [1] presented a chaotic algorithm of image encryption based on dispersion sampling; their algorithm has better scrambling effect, but has small key space. Zhang et al. [4] use logistic and standard systems to scramble the location and the value of pixel points from the image, and they have got better result; however, no security analysis in their paper was given. Recently, Lian et al. [5][6][7] used some multidimensional chaotic maps (such as the chaotic standard map, the chaotic neural networks, and spatiotemporal chaos system) to encrypt images and make a detailed analysis for the security of algorithms. Their algorithms have satisfactory 2 The Scientific World Journal security with a low cost. A new image encryption algorithm based on multiple chaos system is proposed by Zuo et al. [8]. Similarly, Liu et al. [9] also used multiple chaotic maps to encrypt image. All of their algorithms have a large key space, high sensitivity to key variation, and unforeseeable and have the ability of resisting traditional attacks. Generally speaking, to improve the security of encryption algorithm, researchers usually try to use more complex chaotic system or combine some new encryption methods with the existing chaotic systems to implement image encryption. However, some chaotic systems have been proven to be insecure [10][11][12].
With the rapid development of DNA computing, DNA cryptography, as a new field, has come into being. A method for hiding message in DNA microdots was proposed by Clelland et al. [13]. Clelland used DNA microdots to hide message to implement the protection of information. For instance, letter A is expressed as DNA sequence GGT by complex biological operation. Obviously, it is difficult to be implemented and is not suitable for image encryption. Gehani et al. presented an encryption algorithm of the onetime pad cryptography with DNA strands [14]; Gehani's method is effective, but the process of encryption must utilize complex biological operations, which are difficult to be controlled under the experimental environment. So the method is not easy to be realized. In fact, since the high-tech laboratory requirements and computational limitations, combining with the labor intensive extrapolation means, researches of DNA cryptography are still much more theoretical than practical. Recently, Kang presented a pseudo DNA cryptography method [15]. Kang's method not only has the better encryption effect, but also does not require complex biological operation. However, it was only used for encrypting text files.
In this paper, we do not use biological operation to implement image encryption, but adopt the rule of DNA subsequence operation such as truncation operation, deletion operation, transformation operation and so forth, then combine DNA subsequence operation with chaos system to scramble the location and the value of pixel point from the image.
The structure of this paper is as follows. In Section 2, we will introduce the basic theory of the proposed algorithm. The design of the proposed image encryption scheme is discussed in the Section 3. In Section 4, some simulation results and security analysis are given. In Section 5, we compare our algorithm with other encryption algorithms. Section 6 draws the conclusion.

Basic Theory of the Proposed Algorithm
2.1. Generation of the Chaotic Sequences. The chaotic system is a deterministic nonlinear system. It possesses a varied characteristics, such as high sensitivity to initial conditions and system parameters, random-like behaviors, and so forth. Chaotic sequences produced by chaotic maps are pseudorandom sequences; their structures are very complex and difficult to be analyzed and predicted. In other words, chaotic systems can improve the security of encryption systems. Thus, it is advisable to encrypt digital image with chaotic systems [16][17][18][19][20][21][22][23][24]. Here, we introduce the following two chaotic maps, one is logistic map, and the other is 2D logistic map. In the paper, we use 2D logistic map to produce the eight parameters as the initial values and system parameters of four logistic maps.

DNA Encoding and Decoding for Image.
A single DNA sequence is made up of four nucleic acid bases: A (adenine), C (cytosine), G (guanine), and T (thymine), where A and T are complements, and C and G are complements. Let binary number 0 and 1 be complements, so 00 and 11 are complements, and 01 and 10 are complements. Thus we can use these four bases: A, T, G, and C to encode 01, 10, 00, and 11, respectively. The encoding method still satisfies the Watson-Crick complement rule [25]. Usually, each pixel value of the 8 bit grey image can be expressed to 8 bits binary stream. The binary stream can be encoded to a DNA sequence whose length is 4. For example: if the first pixel value of the original image is 75, convert it into a binary stream [01001011]. By using the above DNA encoding rule to encode the stream, we can get a DNA sequence [AGTC], whereas we use A, T, G, and C to express 01, 10, 00, and 11, respectively. We can get a binary sequence [01001011].

DNA Subsequences Operation.
In this section we use the idea of [26] to define the DNA subsequence and the corresponding operation. We define that a DNA sequence P k contains m strands of DNA subsequences according to the order, in the P k , the number of bases is k (m ≤ k). The expression is P k = P m P m−1 · · · P 2 P 1 . The number of bases for the corresponding DNA subsequences is l m l m−1 · · · l 2 l 1 , respectively. Apparently, k = l m + l m−1 + · · · l 2 + l 1 . Based on the above DNA subsequence expression, we described the following five kinds of DNA subsequence operation; they are elongation operation, truncation operation, deletion operation, insertion operation, and transformation operation.
The Scientific World Journal 3 Definition 1. We suppose that there is an original DNA sequence P 1 , the subsequence P 2 , whose length is l 1 , is elongated to the tail of P 1 . After elongation operation, we can get a new DNA sequence P = P 1 P 2 . The expression is as follows: (2) DNA subsequence truncation operation.
Definition 2. The truncation operation and the elongation operation are contrary. Truncating the end of the subsequence P 2 in the DNA sequence P 1 P 2 , we will obtain a new DNA sequence P = P 1 . The expression is as follows: (3) DNA subsequence deletion operation.
Definition 3. We suppose that there is an original DNA sequence P = P 3 P 2 P 1 . Deleting the subsequence P 2 , then we will obtain a new DNA sequence P = P 1 P 3 . The expression is as follows: (4) DNA subsequence insertion operation.
Definition 4. The deletion operation and the insertion operation are contrary. We suppose that there is an original DNA sequence P = P 3 P 1 , inserting a subsequence P 2 , whose length is l 2 , into P. The expression is as follows: (5) DNA subsequence transformation operation.
Definition 5. In brief, the locations of two subsequences are transformed. If the original DNA sequence is P = P 5 P 4 P 3 P 2 P 1 . Transforming the locations of P 4 and P 2 , we will get a new DNA sequence P = P 5 P 2 P 3 P 4 P 1 . The expression is as follows: We introduced five kinds of DNA subsequence operations, where the inverse operation of elongation operation is truncation operation and the inverse operation of deletion operation is insertion operation. In our algorithm, we use elongation operation, truncation operation, deletion operation, and transformation operation and combined with the use of the Logistic chaotic map we will realize the image encryption algorithm. However, the insertion operation is just used in the decryption process.

Generation of Chaotic Sequences.
Input initial state (x 0 , μ 1 , y 0 , μ 2 ), by using 2D Logistic to produce eight parameters (x 1 , x 2 , x 3 , x 4 , x 5 , x 6 , x 7 , x 8 ) after iterating 1000 times. We Use the following formulas to produce four groups of parameters: Then, by using logistic chaotic map to generate four chaotic sequences under the condition that the four groups of initial values are (x 1 , u 1 ), (y 1 , u 2 ), (z 1 , u 3 ), and (q 1 , u 4 ), their length are m × n, respectively.

Generation of DNA Subsequences
Step 1. Input an 8 bit grey image A(m, n), as the original image, where m and n is rows and columns of the image.
Step 2. Convert image A into binary matrix A whose size is (m, n × 8) and divide A into eight bit-planes. Here, the first bitplanes and the eighth bitplanes, the second bitplanes and the seventh bitplanes, the third bitplanes and the sixth bitplanes, and the forth bit-planes and the fifth bit-planes are composed, respectively. Then we obtain four bit-planes.
Step 3. Carry out DNA encoding operation according to Section 2.2.1 for the four bitplanes, then we get four coding matrices P 1 , P 2 , P 3 , P 4 , all of their sizes are (m, n).

Deletion Operation
Step 1. We suppose that there is a chaotic sequence X = {x 1 , x 2 · · · x mn/li }.
Step 2. If x i < 0.5, delete the ith subsequence according to Section 2.2.2, otherwise save the subsequence.

4
The Scientific World Journal   Step 3. Those deleted subsequences are moved to the end of the saved subsequences.

Transformation Operation
Step 1. We suppose that there is a chaotic sequence X = {x 1 , x 2 · · · x mn/li }.
Step 2. To sort X by ascending, we get a new sequence X = {x 1 , x 2 · · · x mn/li }.
Step 3. If x i < 0.5, the ith subsequence and the i th subsequence from the location of X are transformed according to Section 2.2.2. Figure 1, P 1 and P 2 are two DNA subsequences from any of two bit-planes, we suppose that the length of P 1 is 128, the length of P 2 is 64, S 1 and S 2 , S 3 , and S 4 are DNA subsequences of P 1 and P 2 , respectively. First, we truncate S 1 and S 4 , then elongate S 1 to the tail of P 2 , elongate S 4 to the tail of P 1 .

Complement Operation.
Complement operation is carried out for every one dimension bit-plane whose size is (1, m × n), we suppose there is a chaotic sequence X = {x 1 , x 2 · · · x mn/li }. If x i < 0.5, the nucleic acid base of the ith location is complemented, otherwise, it is unchanged.

The Procedure of Image Encryption and Decryption.
The proposed encryption algorithm includes three steps: first, by using the method proposed in the Section 3.1 to produce four groups of DNA sequences P 1 , P 2 , P 3 , and P 4 , where P i (i = 1, 2, 3, 4) is made up of many DNA subsequences. Then, to disturb the position and the value of pixel points from image by combining the logistic map, generate chaotic sequences and DNA subsequence operations (such as elongation operation, truncation operation, deletion operation, transformation, etc.). At last, the encrypted image is obtained by DNA decoding and recombining bit-planes. The block diagram of the proposed algorithm is shown in Figure 2, the block diagram of the encryption algorithm is shown in Figure 2 image decryption is inverse procedure of image encryption from Figure 2. The detailed procedure of our encryption and decryption algorithms are explained in the following pseudocodes (Algorithms 1 and 2).
The functions and parameters in Algorithms 1 and 2 are the same as Sections 3.1-3.6, where DNA decoding and recombining are the inverse process of Steps 3 and 2 in Section 3.2. The procedure of acquiring the original image from the encryption image is an inverse operation according to Algorithm 2, where deletion operation is replaced by insertion operation. in Figure 3(a), Figure 3(b) shows encrypted image, and Figure 3(b) points out that it is difficult to recognize the original image. Figures 3(c) and 3(d) show the decrypted image under the wrong secret keys and the right secret keys, respectively. From Figure 3(c), we know that it has not any connection with the original image, but Figure 3(d) is as same as the original image.

Secret Key's Space Analysis.
In the proposed algorithm, the initial value and the parameter of the system of 2D logistic are identified as secret keys of this algorithm. Therefore, our algorithm has six secret keys x 0 , μ 1 , γ 1 , y 0 , μ 2 , γ 2 . If the precision is 10 −14 , the secret key's space is 10 14 × 10 14 × 10 14 × 10 14 × 10 14 × 10 14 = 10 84 ≈ 2 279 . It is shown that the secret key's space is large enough to resist exhaustive attack.

Secret Key's Sensitivity Analysis.
The chaotic map is very sensitive to the initial value in chaotic state, in other words, it also ensured the sensibility of this encryption algorithm to the secret key. In this paper, if the initial values from three chaotic maps are changed a little, the recovering image is not allowed to be read, but we can get the original image from the encrypted image by using the correct secret keys. The experiment results are shown in Figure 4, where Figure 4(a) shows the decrypted image under the secret keys (0.95000000000001, 3.2, 0.17, 0.25, 3.3, 0.14). The corresponding histogram is shown in Figure 4(b), and we can see that the histogram of the decrypted image is very uniform. The sensitivity of other parameters is similar. From Figure 4, we can see that only when all secret keys (the chaotic initial value and system parameter) are correct, the original image can be obtained. Otherwise the decrypted image will have no connection with the image. Based on the above argument, our algorithm has strong sensitivity to secret key and we can say again that our algorithm can resist exhaustive attack.

The Grey Histogram Analysis.
We compare the grey histogram of the image before and after encryption to analyze the statistical performance. Figure 5

Correlation Coefficient Analysis.
The correlation of the adjacent pixels in original image is very high, an effective encryption algorithm can reduce the correlation of between adjacent pixels. Here, we randomly select 3000 pairs (horizontal, vertical and diagonal) of adjacent pixels from the original image and the encrypted image, then by using the following formulas to calculate the correlation coefficient:  Table 1. From Figure 6(b) and Table 1, we can see that the correlation coefficient of the adjacent pixels in encrypted image is low, which is close to 0. It follows from Figure 6(b) and Table 1 that the proposed image encryption algorithm has strong ability of resisting statistical attack.

Information Entropy.
It is well known that information entropy can measure the distribution of grey value in the image. We can make sure that the bigger information entropy the more uniform for the distribution of grey value. The definition of information entropy is as follows:   Chen's chaotic system Coupled chaotic system Table 3: Comparison with other DNA-based encryption algorithms.

Considered items Proposed
Clelland et al. [13] G e h a n ie ta l . [ 14] K a n g [ 15] Image where m i is the ith grey value for L level grey image and P(m i ) is the emergence probability of m i . The information entropy of an idea random image is 8. For the proposed algorithm, the information entropy is 7.9975. It is very close to 8.

Comparison with Other Encryption Algorithms
In this section, we will compare our proposed algorithm with existing chaos-based and DNA-based encryption algorithms. We focus on the security consideration in the comparative aspects of chaos-based and focus on the encryption objects and environment in the comparative aspects of DNA-based.
The comparison results are shown in Tables 2 and 3. From Table 2, we can see that the key space and the information entropy of our proposed algorithm are larger than others. However the methods in [17,18] can resist differential attack, the proposed method in this paper cannot resist differential attack. From Table 3, we easily found that only our algorithm and [14] can implement image encryption. But the algorithm proposed in [14] is difficult to be implemented owing to the complex biologic operation. Kang's encryption effect [15] is better than others. However, his algorithm can only encrypt the text. After comparing with other encryption algorithms proposed in Tables 2 and 3, the proposed algorithm is better than other DNA-based encryption algorithm and has larger key space and high key sensitivity, but the disadvantage is that the algorithm cannot resist differential attack. This is our next study work.

Conclusion
A novel image encryption algorithm based on DNA subsequence operation is proposed in this paper. The simulation experimental results and security analysis show that the encryption algorithm is effective, easy to be realized, has larger key space, and is sensitive to the secret key. Our algorithm can also resist statistical analysis and exhaustive attacks. Furthermore, it avoids complex biological experiment in traditional DNA cryptography. But because DNA subsequence operation is based on horizontal, or the length of the subsequences selected is longer, it may lead to the horizontal correlation of the adjacent pixels in original image a bit high. We can improve the horizontal correlation through changing the lengths of DNA subsequences from each bit-planes. In addition to that, the weak ability of resisting differential attack is also a defect of this algorithm. They are our next research works.