Image encryption method based on hyperchaotic system and DNA operation

Through the image encryption method based on hyperchaotic system and DNA operation, the problem that the image encryption algorithm in the existing technology is unable to resist chosen plaintext attacks is solved, a larger key space and better security are achieved, and the protection effect of digital images is enhanced.

CN114362913BActive Publication Date: 2025-10-17BEIJING UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111098242.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-18
Publication Date
2025-10-17
Estimated Expiration
2041-09-18

AI Technical Summary

Technical Problem

Existing image encryption algorithms cannot effectively resist chosen plaintext attacks, and the key space of low-dimensional chaotic systems is small, so traditional encryption algorithms are not suitable for the characteristics of digital images.

Method used

An image encryption method based on hyperchaotic system and DNA operation is adopted. By generating new keys K' and kxor, a chaotic sequence is generated using a five-dimensional hyperchaotic system and Logistic mapping, and the plaintext image is scrambled and blocked. DNA encoding and operation are performed, and diffusion processing is performed in combination with multiple DNA operation rules.

Benefits of technology

It achieves effective encryption of digital images, resists known plaintext and chosen plaintext attacks, improves key space and security, and enhances the protection capability of image information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114362913B_ABST
    Figure CN114362913B_ABST
Patent Text Reader

Abstract

The application provides an image encryption method and device based on a hyperchaotic system and DNA operation, and comprises the following steps: first, initial values of a five-dimensional hyperchaotic system and a Logistic mapping are generated by using an external key and a nested hash function of a plaintext image, so that the sensitivity of the algorithm to the plaintext image is improved; then, scrambling, blocking and encoding operations are performed on the plaintext image, a random sequence generated by the Logistic mapping is converted into a DNA matrix, and the same size blocking operation is performed on the DNA matrix, and the sub-blocks are diffused by using DNA operation; and the scrambling, encoding and operation modes are controlled by using a chaotic sequence generated by the five-dimensional hyperchaotic system. Experimental results show that the application has good encryption effect.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of image encryption technology, and particularly relates to an image encryption method based on a hyperchaotic system and DNA operation. BACKGROUND

[0002] With the development of the Internet and communication technology, digital images play an important role in communication, medical treatment, military and social life. However, image information is vulnerable to damage and attack during transmission. Therefore, image encryption is an effective method to protect the security of digital image information. Compared with text information, digital images have inherent characteristics such as large data volume, high redundancy and strong correlation between adjacent pixels. Traditional encryption algorithms, such as DES, AES and RSA, are mainly used for text encryption and are not suitable for existing image encryption.

[0003] Chaotic systems have been widely used in image encryption due to their high sensitivity to initial state and control parameters, good ergodicity and pseudo-randomness. Compared with low-dimensional chaos, hyperchaotic systems have more complex dynamics, larger key space and better sensitivity, so various image encryption algorithms based on hyperchaotic systems have been proposed.

[0004] DNA computing has the advantages of massive storage, low power consumption and large-scale parallel processing, which opens up a new research direction for digital images. Domestic and foreign scholars have proposed many image encryption schemes using the excellent characteristics of chaotic systems and DNA computing. However, most of these schemes use fixed DNA encoding and single operation rules, which cannot resist chosen-plaintext attacks. SUMMARY

[0005] In view of the shortcomings of DNA operation and chaotic systems in image encryption, such as single DNA encoding and operation rules, small key space of low-dimensional chaos and independent key generation process from plaintext images, a new image encryption algorithm based on hyperchaotic systems and DNA operation is proposed,

[0006] To achieve the above purpose, the technical scheme adopted by the present application is as follows:

[0007] The present application provides an image encryption method based on hyperchaos and DNA operation, comprising the following steps:

[0008] 1. An image encryption method based on a hyperchaotic system and DNA operation, characterized by comprising the following steps:

[0009] Step 1: Use the nested hash function of the external key K and the plaintext image P1 to generate a new key K' and k xor .

[0010] Step 2: Based on the key K' and k xor , generate the initial values ​​of the five-dimensional hyperchaotic system and the Logistic map and produce a chaotic sequence.

[0011] Step 3: Scramble and block the plaintext image.

[0012] Step 4: DNA encode each sub-block of the matrix, and then perform DNA operations between sub-blocks.

[0013] Step 5: Perform DNA decoding on the diffused matrix and convert it into a ciphertext image in the range of 0 to 255.

[0014] Furthermore, step 1 specifically includes:

[0015] The 256-bit external key K is divided into 32 groups of 8 bits each, expressed as K = k1, k2, ..., k 32}.

[0016] Assume that the plaintext image is a matrix P1 of size M×N, where P1(i, j) represents the pixel value at position (i, j). Calculate three vectors S1, S2, and S3, where S1(i) represents the sum of all pixel values ​​in the i-th row of P1, S2(i) represents the sum of all pixel values ​​in the i-th column of P1, and S3(i) represents the sum of all pixel values ​​on the i-th diagonal of P1. The 256-bit hash value H is generated by the MD5 hash value of S1, S2, S3, and K, as shown below:

[0017]

[0018] Use the XOR operation to combine the external key K and the hash value H to generate new keys K' and k xor

[0019]

[0020] Furthermore, the five-dimensional hyperchaotic system in step 2 is:

[0021]

[0022] When the control parameter c i =[30, 10, 15.7, 5, 2.5, 4.45, 38.5], the system of formula (4) exhibits hyperchaotic behavior.

[0023] The Logistic mapping is:

[0024] x n+1 =μx n (1-x n ) (5)

[0025] μ is a system nonlinear strength control parameter, x n Traverse on the interval [0, 1]. When 3.5699456 < μ ≤ 4, x n ∈ (0, 1), the system mapping is in a chaotic state.

[0026] According to the key K' and k xor , the initial values X (0), Y (0), Z (0), U (0), and W (0) of the five-dimensional hyperchaotic system are calculated.

[0027]

[0028] Where x0, y0, z0, u0, and w0 are given values. The key generated in this way has the advantages of long key space and good randomness, and the algorithm will effectively resist known plaintext and chosen plaintext attacks by combining the original image information with the key. The five-dimensional hyperchaotic system is pre-iterated (1000+k' 31 +k' 32 +k xor ) times to eliminate transient effects and improve security. Continue to iterate the five-dimensional hyperchaotic system to obtain a random sequence {X i} with a length of 1 × 4MN and a random sequence {Y 2} with a length of 4 × (M × N) / t i , {Z i}, {U i}, and {W i}. The sequence {X i} is used for scrambling operation, the sequence {Y i} is used for DNA encoding, the sequences {Z i} and {U i} are used for DNA operation between subblocks, and the sequence {W i} is used for DNA decoding.

[0029] According to the key K' and k xor , the control parameter μ and the initial value x (0) of the Logistic chaotic system are calculated.

[0030]

[0031] The Logistic chaotic mapping is pre-iterated (1000+k'1+k'3+k'5+k xor ) times to eliminate transient effects, and then the Logistic chaotic mapping is iterated to obtain a random sequence {V i} with a length of 1 × 4MN.

[0032] Further, step 3 specifically includes:

[0033] Suppose the size of the plaintext image P1 is M x N, the zero padding operation is taken to fill P1 so that its size satisfies equation (8), and the filled data value is taken as 0.

[0034]

[0035] where t is the block size, the zero padded image size is re-assigned to M and N, and the zero padded matrix is denoted as P2.

[0036] Each pixel value of P2 is encoded as a 4-bit quaternary number, and then it is transformed into a one-dimensional vector P3 with the size of 1 x 4MN.

[0037] The random sequence {X i} generated by the 5D hyper-chaotic system is used to shuffle the vector P3, and the function [l X ,f X ] = Sort(X) is used to sort the elements in X in ascending order, f X is the new X sequence, and l X is the index value of f X . The position of the vector P3 is shuffled by equation (9):

[0038] P4(i) = P3(l X (i)), i = 1, 2, …, 4MN (9)

[0039] The vector P4 is converted into a matrix P5 with the size of M x 4N, and P5 is uniformly divided into blocks with the size of t x t, and a total of 4 x (M x N) / t 2 image blocks can be obtained.

[0040] Further, step 4 specifically comprises:

[0041] Each sub-block of the matrix P5 is DNA encoded, and the encoding rule is determined by the chaotic sequence {Y i} generated by the 5D hyper-chaotic system, and the DNA encoding mode of the i-th sub-block in P5 is Y i . Because there are 8 DNA encoding modes, the sequence {Y i} needs to be converted into an integer ranging from 1 to 8 according to equation (10).

[0042] Y = mod(floor(Y x 10 14 ), 8) + 1 (10)

[0043] The random sequence {V i} generated by the Logistic chaotic mapping is converted into a DNA matrix R according to equation (11) without the DNA encoding process, which reduces the execution time.

[0044]

[0045] The size of the matrix R is converted from 1x4MN to Mx4N, and then evenly divided into txt size blocks.

[0046] DNA operation is performed between the sub-blocks, and the operation rule between the corresponding blocks of P5 and R is determined by the sequence {Z i} generated by the 5D hyper-chaotic system, and the algorithm uses 7 DNA operation rules, so the sequence {Z i} is converted into an integer in the range of 1-7 according to formula (12).

[0047] Z = mod(floor(Zx10 14 ),7) + 1 (12)

[0048] It is specified that if Z i =1, addition operation is used; if Z i =2, subtraction operation is used; if Z i =3, XOR operation is used; if Z i =4, XNOR operation is used; if Z i =5, multiplication operation is used; if Z i =6, left circular shift operation is used; and if Z i =7, right circular shift operation is used.

[0049] In order to obtain better diffusion effect, the encryption result of the current sub-block is subjected to DNA operation again with the previous sub-block, and the operation rule is determined by the sequence {U i}, and the diffused DNA matrix P7 is obtained.

[0050] Further, step 5 specifically comprises:

[0051] The matrix P7 is subjected to DNA decoding to obtain a quaternary matrix P8, and the decoding rule is determined by the sequence {W i}.

[0052] The quaternary matrix P8 is converted into a ciphertext image P9 in the range of 0-255. BRIEF DESCRIPTION OF DRAWINGS

[0053] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed in the embodiment or prior art description will be briefly introduced below, and obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0054] Figure 1 The encryption process in the present application is a flow chart;

[0055] Figure 2 Lena original image and encrypted and decrypted image in the present application;

[0056] Figure 3 Baboon original image and encrypted and decrypted image in the present application;

[0057] Figure 4 Peppers original image and encrypted and decrypted image in the present application;

[0058] Figure 5 Cameraman original image and encrypted and decrypted image in the present application;

[0059] Figure 6 Lena original image histogram in the present application;

[0060] Figure 7 Lena encrypted image histogram in the present application; DETAILED DESCRIPTION

[0061] The technical solutions in the embodiments of the present application will be apparently and completely described in combination with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative labor fall within the protection scope of the present application.

[0062] As shown in Figure 1 , it shows a flow chart of the image encryption method based on the hyperchaotic system and DNA operation in the embodiments of the present application, including the following steps:

[0063] Step 1: In order to enhance the universality of the algorithm, the zero padding operation is adopted to fill the plaintext image P1, so that its size satisfies formula (1), and the filled data value is 0.

[0064]

[0065] Wherein, t is the block size. The size of the zero-padded image is re-assigned to M and N, and the zero-padded matrix is denoted as P2.

[0066] Step 2: Each pixel value of P2 is encoded into a 4-bit quaternary number, and then it is transformed into a vector P3 with a size of 1x4MN.

[0067] Step 3: The random sequence {X i} generated by the 5D hyperchaotic system is used to scramble the vector P3, and the function [l X ,f X ] = Sort(X) is used to sort the elements in X in ascending order, and fX is a new X sequence, l X is f X The index value. The position of the scrambling vector P3 is scrambled by formula (2), and the scrambled vector is denoted as P4.

[0068] P4(i) = P3(i X (i)), i = 1, 2, …, 4MN (2)

[0069] Step 4: Convert the vector P4 into a matrix P5 with a size of M x 4N, and uniformly divide P5 into blocks with a size of t x t, a total of 4 x (M x N) / t 2 image blocks.

[0070] Step 5: Perform DNA encoding on each sub-block of the matrix P5, and the encoding rule is determined by the chaotic sequence {Y i} generated by the 5D hyper-chaotic system. The DNA encoding mode of the i-th sub-block in P5 is Y i . Since there are 8 DNA encoding modes, the sequence {Y i} needs to be converted into an integer ranging from 1 to 8 according to formula (3).

[0071] Y = mod(floor(Y x 10 14 ), 8) + 1 (3)

[0072] The encoding and decoding rules of DNA are as follows:

[0073] Table 1 DNA encoding and decoding rules

[0074]

[0075] Step 6: Convert the random sequence {V i} generated by the Logistic chaotic mapping into a DNA matrix R with a size of 1 x 4MN according to formula (4). No DNA encoding process is needed, which reduces the execution time.

[0076]

[0077] Step 7: Convert the size of the matrix R from 1 x 4MN to M x 4N, and then uniformly divide it into blocks with a size of t x t, a total of 4 x (M x n) / t 2 image blocks.

[0078] Step 8: Perform DNA operations between sub-blocks, and the operation rule between the corresponding blocks of P5 and R is determined by the sequence {Z i} generated by the 5D hyper-chaotic system, and the diffused DNA matrix P6 is obtained. This algorithm uses 7 DNA operation rules, so the sequence {Z i} is converted into an integer ranging from 1 to 7 according to formula (5).

[0079] Z = mod(floor(Z x 10 14 ), 7) + 1 (5)

[0080] According to the regulation, if Z i = 1, the addition operation is adopted; if Z i = 2, the subtraction operation is adopted; if Z i = 3, the XOR operation is adopted; if Z i = 4, the XNOR operation is adopted; if Z i = 5, the multiplication operation is adopted; if Z i = 6, the left circular shift operation is adopted; if Z i = 7, the right circular shift operation is adopted.

[0081] The seven DNA operation rules are as follows:

[0082] Table 2 Addition operation

[0083]

[0084] Table 3 Subtraction operation

[0085]

[0086] Table 4 Multiplication operation

[0087]

[0088] Table 5 XOR operation

[0089]

[0090] Table 6 XNOR operation

[0091]

[0092]

[0093] Table 7 Left circular shift

[0094]

[0095] Table 8 Right circular shift

[0096]

[0097] Step 9: In order to obtain a better diffusion effect, except for the first sub-block, the encryption result of the current sub-block is subjected to DNA operation again with the previous sub-block, and the operation rule adopted is determined by the sequence {U i}, and the diffused DNA matrix P7 is obtained.

[0098] Step 10: DNA decoding is performed on the matrix P7 to obtain a quaternary matrix P8, and the decoding rule is determined by the sequence {W i}.

[0099] Step 11: The quaternary matrix P8 is converted into a ciphertext image P9 in the range of 0 to 255.

[0100] The decryption process of the image is the inverse process of the encryption, which is not described here.

[0101] In order to verify the image encryption method based on the super chaotic system and DNA operation provided by the application, the application also provides the following experimental data.

[0102] The experimental selected gray-scale images "Lena", "Baboon", "Peppers" and "Cameraman" with a size of 512*512 as test images. The initial values of the five-dimensional super chaotic system used in this paper are set to x 0= 0.215, y0=0.276, z0=0.857, u0=0.745, w0=0.923, the block size of the image in the experiment is 4*4, and the external key K is "8d5e79a231d719b4c37ad649be7293df7a52bf4e8394c7135be96ac45fdaebc1".

[0103] The encryption results of the four images "Lena", "Baboon", "Peppers" and "Cameraman" are shown in the attached Figures 2 to 5 The experimental results show that the encrypted image cannot obtain any effective information, and the proposed image encryption system has good encryption effect.

[0104] Figure 6 and Figure 7 are the original image histogram and the encrypted image histogram of the Lena image respectively, it can be seen that the histogram distribution of the original image is uneven and has a certain regularity, the histogram distribution of the ciphertext image is flat, effectively hiding the distribution rule of the pixel value of the original image, and the attacker cannot obtain the information of the original image through statistical analysis, so the application has the ability to resist statistical analysis attack.

Claims

1. An image encryption method based on hyperchaotic system and DNA computing, characterized in that: The following steps are involved: Step 1: Generate new keys K' and k using the nested hash function of the external key K and the plaintext image P1 xor ; Step 2: Based on the key K' and k xor , generate the initial values ​​of the five-dimensional hyperchaotic system and the Logistic map and produce a chaotic sequence; Step 3: Scramble and block the plaintext image; Step 4: DNA encode each sub-block of the matrix, and then perform DNA operations between sub-blocks; Step 5: Perform DNA decoding on the diffused matrix and convert it into a ciphertext image in the range of 0 to 255; Step 1 specifically includes: The 256-bit external key K is divided into 32 groups of 8 bits each, expressed as K = {k1, k2, ..., k 32 } Assume that the plaintext image is a matrix P1 of size M×N, where P1(i, j) represents the pixel value at position (i, j); calculate three vectors S1, S2, and S3, where S1(i) represents the sum of all pixel values ​​in the i-th row of P1, S2(i) represents the sum of all pixel values ​​in the i-th column of P1, and S3(i) represents the sum of all pixel values ​​on the i-th diagonal of P1; the 256-bit hash value H is generated by the MD5 hash value of S1, S2, S3, and K, as shown below: Use the XOR operation to combine the external key K and the hash value H to generate new keys K' and k xor Step 4 specifically includes: DNA encoding is performed on each sub-block of the matrix. The encoding rule is the chaotic sequence {Y i } determines that the DNA encoding method of the i-th sub-block is Y i ; Because there are 8 kinds of DNA coding, the sequence {Y i } is converted into an integer ranging from 1 to 8 according to formula (10); Y=mod(floor(Y×10 14 ),8)+1 (10) The random sequence {V i }Convert it into DNA matrix R according to formula (11), which does not require DNA encoding process and reduces execution time; Convert the size of matrix R from 1×4MN to M×4N, and then divide it into blocks of t×t; DNA operations are performed between sub-blocks, and the operation rules between the corresponding blocks of R are generated by the sequence {Z i }, the algorithm uses a total of 7 DNA operation rules, so the sequence {Z i } is converted into an integer ranging from 1 to 7 according to formula (12); Z=mod(floor(Z×10 14 ),7)+1 (12) Provisions, if Z i =1, use addition operation; if Z i =2, use subtraction operation; if Z i =3, use XOR operation; if Z i =4, use XOR operation; if Z i =5, use multiplication operation; if Z i =6, use left circular shift operation; if Z i =7, right circular shift operation is adopted; In order to obtain a better diffusion effect, except for the first sub-block, the encryption result of the current sub-block and the previous sub-block are subjected to DNA operation again. The operation rule used is given by the sequence {U i }determined, the diffused DNA matrix P7 was obtained.

2. The image encryption method based on hyperchaotic system and DNA computing according to claim 1 is characterized in that: The five-dimensional hyperchaotic system described in step 2 is: When the control parameter c i =[30, 10, 15.7, 5, 2.5, 4.45, 38.5], the system of formula (4) exhibits hyperchaotic behavior; The Logistic mapping is: x n+1 =μx n (1-x n ) (5) μ is the system nonlinear intensity control parameter, x n Traverse the interval [0,1]; when 3.5699456<μ≤4, x n When ∈(0,1), the system mapping is in a chaotic state; According to the key K′ and k xor , calculate the initial values ​​X(0), Y(0), Z(0), U(0), W(0) of the five-dimensional hyperchaotic system; Where x0, y0, z0, u0, w0 are given values; the 5D hyperchaotic system is subjected to (1000+k′ 31 +k′ 32 +k xor ) pre-iterations; continue to iterate the 5D hyperchaotic system to obtain a random sequence {X i } and length is 4×(M×N) / t 2 The random sequence {Y i }{Z i }{U i }{W i }, sequence {X i } is used for scrambling operation, the sequence {Y i } for DNA coding, the sequence {Z i } and {U i } is used for DNA operations between sub-blocks, the sequence {W i } for DNA decoding; According to the key K′ and k xor , calculate the control parameter μ and initial value x(0) of the Logistic chaotic system; Perform (1000+k′1+k′3+k′5+k xor ) pre-iterations, after eliminating the transient effect, continue to iterate the Logistic chaotic map to obtain a random sequence {V i }.

3. The image encryption method based on hyperchaotic system and DNA computing according to claim 1 is characterized in that: Step 3 specifically includes: Assuming that the size of the plaintext image P1 is M×N, a zero-padding operation is performed to fill P1 so that its size satisfies formula (8), and the padded data value is set to 0; Where t is the block size, the image size after zero padding is reassigned to M and N, and the matrix after zero padding is recorded as P2; Encode each pixel value of P2 into a 4-bit quaternary number, and then transform it into a one-dimensional vector P3 of size 1×4MN; The random sequence {X i }Scramble the vector P3 using the function [l X ,f X ]=Sort(X) sorts the elements in X in ascending order, f X is the new X sequence, l X is f X The index value of; Use formula (9) to scramble the position of vector P3: P4(i)=P3(l X (i)),i=1,2,…,4MN (9) Convert vector P4 into a matrix of size M×4N and evenly divide it into blocks of size t×t, which can be divided into 4×(M×N) / t 2 image blocks.

4. The image encryption method based on hyperchaotic system and DNA computing according to claim 1 is characterized in that: Step 5 specifically includes: DNA decoding is performed on the DNA matrix P7 to obtain the quaternary matrix P8. The decoding rule is given by the sequence {W i }Decide; Convert the quaternary matrix P8 into a ciphertext image P9 in the range of 0 to 255.

Citation Information

Patent Citations

  • Chaotic image encryption method based on bit replacement and dynamic DNA coding

    CN106952213A

  • Image encryption method based on Feistel network and dynamic DNA encoding

    CN108365947A