Image encryption method based on novel two-dimensional integer chaotic system and binary block compressed sensing and suitable for being realized on embedded equipment
A novel two-dimensional integer chaotic system with binary block compressive sensing is used to efficiently encrypt and compress images on embedded devices, addressing security and speed challenges in image encryption.
Patent Information
- Application Number
- CN202510639199.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-19
- Publication Date
- 2025-07-15
AI Technical Summary
Existing image encryption methods face challenges in efficiently encrypting large volumes of image data on resource-constrained devices due to high computational complexity and storage demands, and traditional methods fail to provide adequate security and speed for real-time applications.
A method combining a novel two-dimensional integer chaotic system with binary block compressive sensing to generate encryption keys and compress images, utilizing chaotic sequences for efficient encryption and compression on embedded devices.
The proposed method achieves fast encryption with high security and quality image reconstruction, resisting common attacks while optimizing computational efficiency and storage needs.
Smart Images

Figure CN120321343A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of image encryption, and particularly relates to an image encryption method suitable for implementation on embedded devices, which is based on a two-dimensional integer chaotic system and binary block compressive sensing. Background Art
[0002] As a typical non-linear dynamic system, the chaotic system has characteristics such as pseudo-randomness, initial value sensitivity, and ergodicity, and has received extensive attention in the fields of cryptography, communication, image processing, etc. Traditional chaotic systems are usually based on the real number domain and can generate complex chaotic sequences. However, in practical applications, especially when implemented on hardware, real-number-based operations often face problems such as high computational complexity and difficulty in ensuring accuracy. To solve these problems, some researchers have proposed integer chaotic systems. As a new type of chaotic system, the research advantages of integer chaotic systems are as follows: integer chaotic systems perform operations based on the integer domain, avoiding floating-point operations when performing operations based on the real number domain, significantly improving the efficiency during calculations, and being more suitable for scenarios with high real-time requirements; operations based on the integer domain are simpler to implement on hardware and are suitable for resource-constrained environments such as embedded systems and Internet of Things devices; integer chaotic systems still retain characteristics such as initial value sensitivity of chaotic systems and have important application values in cryptography. Integer chaotic systems can make encryption algorithms more efficient and enhance data security. In recent years, integer chaotic systems have shown important application potential in the fields of image encryption, data security, random number generation, etc.
[0003] Due to the huge amount of information and high redundancy characteristics of image data, it often faces the problem of low efficiency during the transmission process. The traditional method relying solely on key encryption can no longer meet the requirements of efficient and secure transmission. Since a certain degree of distortion of the image is allowed in most application scenarios, in order to improve the transmission speed, it is usually necessary to compress the image before transmission. In 2006, Candes, Donoho, and Tao jointly proposed the Compressed Sensing (CS) theory. Compressed Sensing can encrypt the image while compressing it, and can better reconstruct the original signal with the help of optimization algorithms. Compressed Sensing has achieved remarkable results in the fields of signal processing, image reconstruction, medical imaging, etc. However, with the increase in the scale of the signal, the traditional compressed sensing method faces problems such as high computational complexity and large storage requirements, and is not suitable for real-time sensing of natural images. To solve these problems, Gan et al. proposed the fast compressed sensing technology of block sampling, that is, Block Compressed Sensing (BCS). BCS mainly divides the signal into multiple sub-blocks, and then performs compressed sampling and reconstruction on them respectively. The main research advantages of BCS are: by processing the signal in blocks, the computational complexity and storage requirements of large-scale signal processing can be significantly reduced; BCS allows independent processing of each sub-block and supports parallel computing, which can greatly improve the signal processing efficiency; BCS can dynamically adjust the block size and sampling rate according to the characteristics of the signal, thereby improving the quality and adaptability of signal reconstruction.
[0004] During the application process, if only the chaotic sequence with randomness generated by the chaotic system is used as the key in the encryption process, there may be potential risks. Once the chaotic system is cracked, it may lead to information leakage. Therefore, when encrypting images, the chaotic system is usually combined with other encryption technologies to enhance the overall security and transmission speed of the encryption algorithm. This invention mainly combines the integer chaotic system with block compressed sensing, which has important theoretical value and application prospects: the integer chaotic system is used to generate encryption keys or encrypt the signal, and block compressed sensing performs efficient compression processing on the signal while encrypting, providing a new solution for secure communication and data storage; the integer chaotic system has high computational power, and block compressed sensing has the characteristics of parallel processing. Combining the two can meet the requirements of real-time signal processing; in an environment with limited resources, this solution can optimize the computational efficiency, reduce the storage capacity required, and improve the overall performance of the system. Summary of the Invention
[0005] The present invention provides an image encryption method suitable for implementation on embedded devices based on a new two-dimensional integer chaotic system and binary block compressed sensing in view of the deficiencies of the prior art.
[0006] The present invention adopts the following technical solutions to solve the above technical problems. An image encryption method based on a new two-dimensional integer chaotic system and binary block compressive sensing suitable for implementation on embedded devices, characterized in that the specific steps are as follows:
[0007] Step S1: Design a new two-dimensional integer chaotic system to generate two chaotic sequences X and Y;
[0008] Step S2: Use the chaotic sequence X to generate a binary measurement matrix during the compressive sensing process to reduce the computational amount when the embedded device performs compression. In order to further improve the compressive sensing efficiency, the original image is divided into blocks;
[0009] Step S3: Use the chaotic sequence Y to perform diffusion processing on the block-processed image to achieve secondary encryption.
[0010] Furthermore, the specific process of step S1 is as follows:
[0011] A new two-dimensional integer chaotic system generated by combining an integer Logistic chaotic map and an integer Tent chaotic map is defined by the following formula:
[0012]
[0013] Among them, u and v are respectively the control parameters of the new two-dimensional integer chaotic system, both of which are integers greater than 0, and are used to control the proportion of the two one-dimensional integer chaotic systems in the new two-dimensional integer chaotic system; is an integer Logistic chaotic system; is an integer Tent chaotic system, R is the word length of the embedded device processor, and two chaotic sequences X and Y are generated using the new two-dimensional integer chaotic system for subsequent experiments.
[0014] Furthermore, the specific process of step S2 is as follows:
[0015] The construction process of the binary measurement matrix of size M×N is as follows:
[0016] (1) Generate a sequence q1 of length C through the new two-dimensional integer chaotic system:
[0017] C = (M×N×l + c) / R
[0018] Among them, l is the step size, and c is a constant, for example, it can take the value of 1000;
[0019] (2) In order to make the randomness better, the first c / R elements of the sequence q1 are ignored to obtain a new sequence q1':
[0020] q1' = q1(c / R + 1:l:C);
[0021] (3) Convert all elements in the sequence q′1 into binary numbers of R bits to obtain a binary sequence q'2, and then perform equally spaced sampling on the binary sequence q'2 to obtain the sequence q2:
[0022] q2 = q'2(1:l:C - c / R);
[0023] (4) Obtain the measurement matrix through the last bit of each element of the sequence q2. The process is as follows:
[0024]
[0025] Further, the specific process of step S3 is:
[0026] Assume that the size of the original image α is M×N. The main process of image encryption is as follows:
[0027] (1) First, evenly divide the original image into n0 = M×N / K 2 non - overlapping image blocks of size K×K, and perform column transformation on each image block one by one to obtain column vectors α 2 of size K×1 i (i = 1, 2,..., n0), and connect all the column vectors α i with the matrix concatenation operator [,] to form a new matrix α v :
[0028]
[0029] (2) Generate the initial values and parameters of the new two - dimensional integer chaotic system through the SHA - 512 function. Use the original image to calculate the SHA - 512 function hash value, and convert the 512 - bit hash value of the original image into 32 16 - bit binary numbers e1, e2,..., e 32 , and the secret key {u, v, x0, y0, n, a} is obtained through the following formula, where represents the exclusive - or operation:
[0030]
[0031] (3) Use the chaotic sequence X generated by the new two - dimensional integer chaotic system. This chaotic sequence X is denoted by the symbol q' b , and its length is N b ×K 2 , is the floor function, so that the value range of the chaotic sequence X is [0, 255], and the sequence q' b ' is obtained:
[0032] q' b ' = mod(q' b , 256).;
[0033] (4) Convert the sequence q' b ' into a binary number with R1 bits, thus obtaining a binary sequence q b , where R1 is set to 8, and construct the measurement matrix Φ using the construction method of the binary measurement matrix in step S2 b , and use the measurement matrix Φ b to sample α v and obtain the corresponding encrypted image β v :
[0034] β v = Φ b α v ;
[0035] (5) To improve the privacy of the image, perform diffusion processing using the following formula to perform secondary encryption on the image:
[0036]
[0037] where H is the high four bits of the data; L is the low four bits of the data; Γ en is the diffusion sequence, which is constructed from the chaotic sequence Y generated by the new two-dimensional integer chaotic system through the following formula. The chaotic sequence Y is represented by the symbol q' a , and its length is N b × K 2 , is the floor function:
[0038] Γ en = mod(floor(q' a × 10 16 ), 256);
[0039] (6) Perform the inverse operation of the block division in step (1) on the sequence I' obtained after secondary encryption to reconstruct it into a matrix I. The number of rows and columns of the matrix I is the same as that of the plaintext image, thus obtaining the ciphertext image I after secondary encryption.
[0040] This method has the following advantages and beneficial effects next year: The present invention proposes an image encryption method suitable for implementation on embedded devices based on a new two-dimensional integer chaotic system and binary block compressive sensing (BCS). First, a two-dimensional integer chaotic system is designed to generate two chaotic sequences X and Y. Then, during the compressive sensing process, the chaotic sequence X is used to generate a binary measurement matrix to reduce the computational amount when the embedded device performs compression. To further improve the compressive sensing efficiency, the original image is block-processed. Finally, the chaotic sequence Y is used to perform diffusion processing on the image to achieve secondary encryption. Simulation experiments and performance analysis show that the chaotic sequences X and Y generated by the two-dimensional integer chaotic system proposed in the present invention both have good chaotic characteristics. When the computer word length is 32, its Lyapunov exponent is always above 20. Moreover, the image encryption scheme proposed based on this chaotic system has a fast encryption speed, high decryption quality of the obtained image, and high security performance, and can resist common attack means. Description of the Drawings
[0041] Figure 1 It is the Lyapunov exponent diagram of different chaotic systems. (a) and (b) are the LEs of the chaotic sequences X and Y when S = 16 respectively, (c) and (d) are the LEs of the chaotic sequences X and Y when S = 32 respectively, (e) is the integer Logistic chaotic system, and (f) is the integer Tent chaotic system.
[0042] Figure 2 It is the power spectrum of the chaotic sequences X and Y generated by the new two-dimensional integer chaotic system.
[0043] Figure 3 It is the framework diagram of the proposed image encryption algorithm.
[0044] Figure 4 It is the simulation result of the proposed method. (a1)-(a4) are four original images Baboon, Barbara, Milkdrop, and Landscape, (b1)-(b4) are the corresponding encrypted images, and (c1)-(c4) are the corresponding decrypted images.
[0045] Figure 5 It is the histogram of the original image and the encrypted image. (a1)-(a4) are the histograms of four original images Baboon, Milkdrop, Man, and Lena, and (b1)-(b4) are the histograms of the corresponding ciphertext images.
[0046] Figure 6It is the distribution diagram of adjacent pixels of the plaintext image and the ciphertext image in the horizontal direction, vertical direction, positive diagonal direction, and skew diagonal direction. (a1)-(a4) are the distribution diagrams of adjacent pixels of the plaintext image in each direction, and (b1)-(b4) are the distribution diagrams of adjacent pixels of the corresponding ciphertext image in each direction.
[0047] Figure 7 They are the original image and the decrypted images at different sampling rates. (a1) and (b1) are the original images Baboon and Milkdrop respectively, (a2) and (b2) are the corresponding decrypted images at a sampling rate of 0.25, (a3) and (b3) are the corresponding decrypted images at a sampling rate of 0.5, and (a4) and (b4) are the corresponding decrypted images at a sampling rate of 0.75.
[0048] Figure 8 They are the decrypted images under different noise attacks. (a1)-(a4) are the decrypted images under Gaussian noise attack, (b1)-(b4) are the decrypted images under salt-and-pepper noise attack, and (c1)-(c4) are the decrypted images under speckle noise attack.
[0049] Figure 9 They are the experimental results of shear attack. (a1)-(a3) are the ciphertext images with cropping sizes of 8×8, 16×16, and 32×32 respectively, and (b1)-(b3) are the corresponding decrypted images. Detailed implementation manners
[0050] The above content of the present invention will be further described in detail below through embodiments. However, it should not be understood that the scope of the above subject matter of the present invention is limited to the following embodiments. Any technology implemented based on the above content of the present invention belongs to the scope of the present invention.
[0051] Embodiment
[0052] 1. Design an image encryption method based on a new two-dimensional integer chaotic system and binary block compressive sensing suitable for implementation on embedded devices
[0053] In practical applications, it is necessary to balance the chaotic performance and computer performance in combination with specific requirements. While maintaining the chaotic performance, it is necessary to make the computer have higher computing efficiency and resource utilization rate. Therefore, in this embodiment, the values of each parameter are as follows: u = 21, v = 30, x0 = 6, y0 = 8, R = 32, S = 32, a = 2 31 , b = 32. Through 2DICS-LT, many chaotic sequences with good randomness can be generated, which are suitable for aspects such as image encryption.
[0054] 1.1 Generation of the new two-dimensional integer chaotic system
[0055] A new two-dimensional integer chaotic system generated by combining an integer Logistic chaotic map and an integer Tent chaotic map is defined by the following formula:
[0056]
[0057] where u and v are the control parameters of the new two-dimensional integer chaotic system, both of which are integers greater than 0 and are used to control the proportion of the two one-dimensional integer chaotic systems in the new two-dimensional integer chaotic system; is an integer Logistic chaotic system; is an integer Tent chaotic system, and R is the word length of the embedded device processor. The new two-dimensional integer chaotic system is used to generate two chaotic sequences X and Y for subsequent experiments.
[0058] 1.2 Construction of Binary Measurement Matrix
[0059] The construction process of the binary measurement matrix of size M×N is as follows:
[0060] Step 1: Generate a sequence q1 of length C through the new two-dimensional integer chaotic system:
[0061] C = (M×N×l + c) / R
[0062] where l is the step size and c is a constant with a value of 1000.
[0063] Step 2: To make the randomness better, the first c / R elements of the sequence q1 can be ignored to obtain a new sequence q1':
[0064] q1' = q1(b / R + 1:l:C);
[0065] Step 3: Convert the elements in the sequence q′1 into R-bit binary numbers to obtain a binary sequence q'2. Then, perform equally spaced sampling on the binary sequence q'2 to obtain a sequence q2:
[0066] q2 = q'2(1:l:C - c / R);
[0067] Step 4: Obtain the measurement matrix through the last bit of each element of the sequence q2. The process is as follows:
[0068]
[0069] 1.3 Image Encryption Process
[0070] Assume that the size of the original image α is M×N. The main process of image encryption is as follows:
[0071] Step 1: First, evenly divide the original image into n0 = M×N / K 2K×K non - overlapping image patches, and perform column transformation on each image patch one by one to obtain a column vector α of size K 2 ×1 i (i = 1, 2, …, n0), concatenate all column vectors α i using the matrix concatenation operator [,] to form a new matrix α v :
[0072]
[0073] Step 2: Generate the initial values and parameters of the new two - dimensional integer chaotic system through the SHA - 512 function. Use the original image to calculate the SHA - 512 function hash value, and convert the 512 - bit hash value of the original image into 32 16 - bit binary numbers e1, e2, …, e 32 . The secret key {u, v, x0, y0, n, a} is obtained through the following formula, where represents the exclusive - or operation:
[0074]
[0075] Step 3: Use the chaotic sequence X generated by the new two - dimensional integer chaotic system. This chaotic sequence X is denoted by the symbol q' b , and its length is N b ×K 2 , is floor. Make the value range of the chaotic sequence be [0, 255] to obtain the sequence q' b ':
[0076] q' b ' = mod(q' b , 256);
[0077] Step 4: Convert the sequence q' b ' into a binary number of R1 bits to obtain a binary sequence q b , where R1 takes the value of 8. Use the above - mentioned method for constructing the binary measurement matrix to construct the measurement matrix Φ b , and use the measurement matrix Φ b to sample α v to obtain the corresponding encrypted image β v :
[0078] β v = Φ b α v ;
[0079] Step 5: To improve the privacy of the image, perform diffusion processing using the following formula to perform secondary encryption on the image:
[0080]
[0081] Among them, H is the upper four bits of the data; L is the lower four bits of the data; Γ en is the diffusion sequence, which is constructed from the chaotic sequence Y generated by the new two-dimensional integer chaotic system through the following formula. The chaotic sequence Y is denoted by the symbol q' a and its length is N b ×K 2 , is floor function:
[0082] Γ en = mod(floor(q' a ×10 16 ), 256);
[0083] Step 6: Perform the inverse operation of the block division in Step 1 on the sequence I' obtained after double encryption to reconstruct it into a matrix I. The number of rows and columns of the matrix I is the same as that of the plaintext image, thereby obtaining the double-encrypted ciphertext image I.
[0084] 2. Experimental Results
[0085] 2.1 Verification of the New Two-Dimensional Integer Chaotic System
[0086] Figure 1 The Lyapunov exponent (LE) diagrams of different chaotic systems are given. (a) and (b) are the LEs of the chaotic sequences X and Y when the computer word length S = 16, respectively; (c) and (d) are the LEs of the chaotic sequences X and Y when the computer word length S = 32, respectively; (e) is the integer Logistic chaotic system; (f) is the integer Tent chaotic system. It can be Figure 1 seen that the LE values of the new two-dimensional integer chaotic system will continuously change with the changes of u and v and are all greater than 0. When the computer word length is 16, its value fluctuates around 9; when the computer word length is 32, its value is always greater than 20. However, the maximum LE values of the one-dimensional integer Logistic chaotic system and the one-dimensional integer Tent chaotic system are 22 and 5.5, respectively. Thus, it can be seen that the new two-dimensional integer chaotic system has strong chaotic characteristics and its performance is significantly higher than that of the other two one-dimensional integer chaotic systems.
[0087] Table 1 gives the comparison results of the information entropy of the chaotic sequences generated by different integer chaotic systems. It can be seen from Table 1 that the information entropies of the two chaotic sequences generated by the new two-dimensional integer chaotic system are similar, and in each interval, the information entropy of the chaotic sequence generated by the new two-dimensional integer chaotic system is the highest, approaching the maximum entropy, indicating that the sequence distribution of the new two-dimensional integer chaotic system is uniform.
[0088] Table 1 Comparison of Information Entropies of Chaotic Sequences Generated by Different Integer Chaotic Systems
[0089]
[0090]
[0091] Table 2 presents the SP800-22 Revla randomness test results of the chaotic sequences X and Y generated by the new two-dimensional integer chaotic system. The length of the test sequence is 10 6 , since some of the randomness test results are an array, which is represented by pass / fail here. It can be seen from Table 2 that both the chaotic sequences X and Y generated by 2DICS-LT can pass all the randomness tests, indicating that 2DICS-LT has good randomness.
[0092] Table 2 SP800-22 Revla Randomness Test Results
[0093]
[0094] Figure 2 Shows the power spectra of the two chaotic sequences X and Y generated by the new two-dimensional integer chaotic system. It can be seen from the figure that the power spectra of the two chaotic sequences both have the characteristics of background noise, wide peaks, and continuous power spectra, indicating that the two chaotic sequences generated by the new two-dimensional integer chaotic system both satisfy the chaotic characteristics and have good randomness.
[0095] In summary, it can be seen that the two chaotic sequences generated by the new two-dimensional integer chaotic system proposed in this design both have good chaotic characteristics.
[0096] 2.2 Experimental Results of the Proposed Encryption Scheme
[0097] Figure 3 Gives the framework of the proposed image encryption algorithm, and the encryption effect and anti-attack ability are shown below.
[0098] 2.2.1 Experimental Effect
[0099] Use the classic grayscale images "Baboon", "Barbara", "Milkdrop" for testing. Considering the actual application in life, a landscape photo in daily life is randomly selected for comparative testing. Figure 4 Shows the original image and the simulation results of the proposed encryption method when the sampling rate is 0.75.
[0100] By Figure 4It can be seen that when the sampling rate is 0.75, the encrypted image does not have visual information, indicating that the proposed image encryption method is secure. The naked eye cannot tell the difference between the decrypted image and the original image, which has no impact on the subsequent use of the image, indicating that the proposed encryption scheme has a good reconstruction effect. The proposed encryption scheme can achieve the same effect when encrypting and decrypting randomly selected landscape photos, indicating that the encryption scheme has practical applicability.
[0101] 2.2.2 Key Space
[0102] To resist the attacker from cracking the encryption scheme through brute-force attack, the key space of the encryption scheme is usually increased to increase the difficulty of brute-force attack and enhance the security of the image encryption scheme. From the existing knowledge, it is known that when the key space is greater than 2 100 the encryption system can effectively resist brute-force attack. The key of the proposed image encryption scheme is {u, v, x0, y0, n, a}, where u ∈ [0, 2 32 , v ∈ [0, 2 32 , x0 ∈ [1, 2 32 , y0 ∈ [1, 2 32 , n ∈ [0, 2 32 , a ∈ [2 7 , 2 63 . When the step size of the key is 2 n the key space of the proposed image encryption algorithm is (2 32 + 1) × (2 32 + 1) × 2 32 × (2 32 + 1) × (2 32 + 1) × 2 56 ≈ 2 216 > 2 100 . Therefore, the size of the key space of the encryption algorithm proposed in the present invention can resist brute-force attack.
[0103] 2.2.3 Key Sensitivity
[0104] NPCR and UACI are usually used to compare the differences between two images of the same size. The ideal value of NPCR is 99.6094%, and the ideal value of UACI is 33.4635%. The closer to the ideal value, the stronger the sensitivity of the encryption scheme to the key, and the more secure the encryption scheme. Taking the image Lena as an example for experiments, making slight changes to two keys x0 and y0 respectively, the changes in the NPCR and UACI values between the encrypted images corresponding to the two keys are shown in Table 3. It can be seen from Table 3 that when using two chaotic series for encryption, when the key changes slightly, the NPCR and UACI values corresponding to the two encrypted images are close to the ideal values, indicating that the proposed image encryption scheme has good key sensitivity.
[0105] Table 3 NPCR and UACI values between encrypted images when the key changes slightly
[0106]
[0107]
[0108] 2.2.4 Statistical analysis
[0109] (1) Histogram analysis
[0110] The histogram shows the number of occurrences of different pixel values in the image, which can intuitively reflect the distribution law of the pixel values of the image. Statistical attacks can crack the information of the image according to the distribution of pixel values in the image. To resist statistical attacks, the pixel values of the encrypted image should be evenly distributed on the histogram. Figure 5 Shows the histograms of the original image and its corresponding ciphertext image.
[0111] (2) χ 2 test
[0112] To evaluate the difference between the histograms of the original image and the encrypted image, the χ 2 statistic is used as a measurement tool. If the pixel values in the image histogram are evenly distributed, it follows a χ 2 distribution with 255 degrees of freedom. When the significance level value is 0.05, the corresponding expected value Table 4 shows the χ 2 test values of the histograms of the ciphertext images obtained by encrypting the original images when the significance level value is 0.05. It can be seen from Table 4 that the χ 2 test values of the histogram of the plaintext image are all greater than The χ 2 test values of the histograms of the ciphertext images obtained by encryption are all less than Therefore, when the significance level value of the ciphertext image generated by the proposed encryption scheme is 0.05, the pixel values conform to the uniform distribution, and it can effectively resist frequency analysis attacks.
[0113] Table 4 χ 2 test
[0114]
[0115] (3) Correlation analysis
[0116] Correlation refers to the degree of correlation between the gray values of adjacent pixels in an image. Generally, in a plaintext image, there is a strong correlation between adjacent pixels in the horizontal, vertical, positive diagonal, and anti-diagonal directions, making it easy for attackers to crack. Therefore, there should be no correlation between adjacent pixels in the ciphertext image in all directions. The performance of the encryption algorithm can be measured by correlation. The correlation of the Lena image is analyzed, and the results are as Figure 6 shown. It can be seen from the figure that the distribution of adjacent pixel pairs in the plaintext image in each direction is relatively concentrated, but the adjacent pixel pairs in the corresponding ciphertext image are evenly distributed in all regions of the image. This shows that the image encryption method proposed in this patent significantly reduces the correlation of the ciphertext image. Table 5 shows the correlation coefficients of the plaintext images of three images and the corresponding ciphertext images in each direction. The range of the correlation coefficient value is from -1 to 1, and the value is 0 when there is no correlation between variables. It can be seen from Table 5 that the correlation coefficient of the plaintext image is close to 1, and the correlation coefficient of the ciphertext image is close to 0.
[0117] Table 5 Correlation coefficients of plaintext images and ciphertext images in different directions
[0118]
[0119] 2.2.5 Visual security
[0120] PSNR and MSSIM are two common metrics used to measure the quality of decrypted images. As the PSNR value and MSSIM value increase, the similarity between the original image and the decrypted image also increases, and the quality of the decrypted image is enhanced accordingly. Table 6 shows the PSNR values and MSSIM values corresponding to different images under different sampling rates. Figure 7 The original images of the Baboon and Milkdrop images and their corresponding decrypted images at different sampling rates are shown. It can be seen from Table 6 that as the sampling rate increases, the corresponding PSNR value and MSSIM value also increase. When the sampling rate is 0.75, the PSNR values of the Lena and Milkdrop images reach above 40dB. From Figure 7(b4) It can be seen that at this time, visually, the difference between the decrypted image and the original image is hardly perceptible, that is to say, it has a high reconstruction quality. However, as the sampling rate increases, the required computing resources also increase, the compression efficiency decreases, and the amount of image information that can be stored with the same data volume decreases. In actual applications, it is necessary to select an appropriate sampling rate in combination with specific requirements and conditions to achieve the best balance between the quality of the decrypted image and computing resources.
[0121] Table 6 PSNR and MSSIM values corresponding to each image at different sampling rates
[0122]
[0123]
[0124] In addition, it can also be seen from Table 6 that for the image Baboon with complex texture compared to the smooth image Milkdrop, its corresponding PSNR value and MSSIM value have always been in a relatively low state. As shown in Figure 7 (a2), when the sampling rate is 0.25, the difference between the decrypted image and the original image can be perceived by the human eye, but it still has high visual usability. This shows that the quality of the decrypted image is also related to the texture degree of the image, and the proposed encryption scheme still has high decryption quality when the sampling rate is 0.2.
[0125] 2.2.6 Information entropy
[0126] Information entropy is used to measure the uncertainty of an image. The greater the information entropy, the greater the uncertainty of the image and the better the encryption effect. When the gray level of the image is 256, the maximum information entropy of the image is 8. The comparison results of the information entropy of the ciphertext images obtained by encrypting different images using the proposed encryption scheme are shown in Table 7. It can be seen that the information entropy of the ciphertext images obtained by the proposed encryption scheme is close to the ideal value of 8, indicating that the ciphertext images generated by the proposed encryption scheme have good randomness and can better resist entropy attacks.
[0127] Table 7 Comparison of information entropy of different encryption schemes
[0128]
[0129] 2.2.7 Robustness analysis
[0130] (1) Noise attack
[0131] During the process of transmitting the encrypted image over the network, it is vulnerable to natural noise interference, resulting in the loss of some information in the encrypted image, and thus the original image cannot be restored. A good encryption scheme should be able to resist noise attacks. Therefore, it is necessary to add some artificial noise interference to the encrypted image to detect its ability to resist noise attacks. To test the ability of the encryption scheme proposed in this patent to resist noise attacks, the image Barbara was encrypted, and then Gaussian noise, speckle noise, and salt-and-pepper noise attacks with different intensities were applied to the generated encrypted image respectively, and the changes in the quality of the decrypted image were observed. The decrypted images are as Figure 8 shown. As can be seen from Figure 8 , the encryption scheme proposed in this patent has different resistance abilities to different noise attacks. However, the reconstruction quality of the image decreases with the increase of the noise intensity, that is, the ability to resist noise attacks decreases accordingly. Although there is some noise in the decrypted image, it still has visual usability. Table 8 shows the Figure 8 PSNR values of the decrypted images in
[0132] Table 8 PSNR values of decrypted images under different noise attacks
[0133]
[0134] As can be seen from Table 8, the proposed encryption scheme has the greatest ability to resist Gaussian noise attacks, and the PSNR value can reach more than 30 dB; the ability to resist speckle noise attacks is the weakest, and the PSNR value is about 20 dB. Therefore, the proposed encryption scheme can resist noise attacks of a certain intensity.
[0135] (2) Cropping attack
[0136] During the transmission of the image, there may be situations where the image is cropped or pixels are lost. Therefore, the encryption algorithm should have the ability to resist cropping attacks. To detect the ability of the proposed encryption algorithm to resist cropping attacks, the encrypted image was respectively cropped with sizes of 8×8, 16×16, and 32×32, and then the cropped image was decrypted. The cropped encrypted image and the decrypted image are as Figure 9 shown. As can be seen from Figure 9 , the quality of the decrypted image decreases with the increase of the cropping size, but it still has a certain visual usability. Therefore, the proposed algorithm has a certain ability to resist cropping attacks.
[0137] (3) Differential attack
[0138] Differential attack is an attack method used to crack ciphertext images and can be used to detect the plaintext sensitivity of algorithms. Usually, the pixel values of the plaintext image are slightly modified and then encrypted. By comparing the ciphertext images obtained from encrypting the plaintext images before and after modification, the relationship between the two is found, thus cracking the ciphertext image. The closer the calculated values of NPCR and UACI are to the ideal values of 99.6094% and 33.4635%, the stronger the ability of the encryption algorithm to resist differential attacks. Randomly change one pixel in the plaintext image, and then encrypt the images before and after modification. The UPCR and NACI values of the different images obtained are shown in Table 9. It can be seen from Table 9 that when the pixel values change slightly, the NPCR and UACI values corresponding to the ciphertext images are close to the ideal values. This shows that the encryption algorithm proposed in this patent has plaintext sensitivity and is sufficient to resist differential attacks.
[0139] Table 9 NPCR and UACI Values of Encrypted Images
[0140]
[0141]
[0142] (4) Anti-attack Analysis
[0143] Known-plaintext attack and chosen-plaintext attack are both common attacks against image encryption systems. The initial key of the proposed encryption scheme is generated by the SHA-512 hash function of the plaintext image. The measurement matrix and the diffusion process both rely on the chaotic sequences generated by the chaotic system. As the plaintext image changes, the generated initial key will also change accordingly. Therefore, the proposed encryption algorithm can resist known-plaintext attack and chosen-plaintext attack very well. Since the correlation coefficient of the ciphertext is close to 0 and the information entropy is close to 8, it shows that it can also resist ciphertext-only attack.
[0144] 2.2.8 Time Complexity Analysis
[0145] In practical applications, not only the security of the encryption algorithm needs to be considered, but also the time taken for encryption. Encryption efficiency is also an important indicator for evaluating the performance of encryption algorithms. This patent uses a new integer chaotic system defined in the integer domain to construct a binary measurement matrix for BCS processing of images. Compared with the chaotic system defined in the real number domain, it reduces the rounding operation, making the operation simpler and faster. The binary measurement matrix only contains integers 0 and 1. Compared with the traditional measurement matrix containing floating-point numbers, it is more conducive to hardware processing, and the required storage space and computational amount are relatively small. Therefore, the computational amount for compressive sensing by embedded devices is reduced.
[0146] Images with sizes of 256×256 and 512×512 are encrypted respectively, and the test results of the encryption time required at different sampling rates are shown in Table 10. It can be seen from Table 10 that the encryption algorithm proposed in the present invention requires less than 0.1 s for encryption, has high encryption efficiency, and is applicable to embedded devices.
[0147] Table 10 Encryption time for each image at different sampling rates
[0148]
[0149]
[0150] 3. Conclusion
[0151] The experimental results show that the proposed encryption algorithm has good performance in both the encryption and decryption stages. Compared with other existing floating-point-based chaotic systems, the new two-dimensional integer chaotic system proposed in the present invention has higher encryption efficiency, better ciphertext correlation, better reconstruction quality, and can better resist attacks such as brute-force attack, statistical attack, noise attack, shear attack, and differential attack. It still has good image quality and the ability to resist various attacks at low sampling rates, and is more applicable to various fields using embedded devices.
[0152] The above embodiments describe the basic principles, main features and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited by the above embodiments. What is described in the above embodiments and the specification only illustrates the principle of the present invention. Without departing from the principle of the present invention, the present invention will have various changes and improvements, and these changes and improvements all fall within the scope of protection of the present invention.
Claims
1. An image encryption method based on a new two-dimensional integer chaotic system and binary block compressive sensing suitable for implementation on embedded devices, characterized in that The specific steps are as follows: Step S1: Design a new two-dimensional integer chaotic system to generate two chaotic sequences X and Y; Step S2: In the process of compressive sensing, use the chaotic sequence X to generate a binary measurement matrix to reduce the computational complexity when the embedded device performs compression. To further improve the compressive sensing efficiency, the original image is divided into blocks; Step S3: Use the chaotic sequence Y to perform diffusion processing on the block-processed image to achieve secondary encryption.
2. The image encryption method based on a novel two-dimensional integer chaotic system and binary block compressive sensing suitable for implementation on an embedded device according to claim 1, characterized in that The specific process of Step S1 is as follows: A new two-dimensional integer chaotic system generated by combining the integer Logistic chaotic map and the integer Tent chaotic map is defined by the following formula: Among them, u and v are the control parameters of the new two-dimensional integer chaotic system, both of which are integers greater than 0 and are used to control the proportion of the two one-dimensional integer chaotic systems in the new two-dimensional integer chaotic system; is an integer Logistic chaotic system; is an integer Tent chaotic system, R is the word length of the embedded device processor, and two chaotic sequences X and Y are generated using the new two-dimensional integer chaotic system for subsequent experiments.
3. The image encryption method based on a new two-dimensional integer chaotic system and binary block compressive sensing suitable for implementation on an embedded device according to claim 2, wherein The specific process of Step S2 is as follows: The construction process of the binary measurement matrix of size M×N is as follows: (1) Generate a sequence q1 of length C through the new two-dimensional integer chaotic system: C = (M×N×l + c) / R where l is the step size and c is a constant with a value of 1000; (2) To make the randomness better, ignore the first c / R elements of the sequence q1 to obtain a new sequence q1': q1' = q1(c / R + 1:l:C); (3) Convert the elements in the sequence q1' into R-bit binary numbers to obtain a binary sequence q'2, and then perform equally spaced sampling on the binary sequence q'2 to obtain the sequence q2: q2 = q'2(1:l:C - c / R); (4) Obtain the measurement matrix through the last bit of each element of the sequence q2. The process is as follows:
4. The image encryption method based on a new two-dimensional integer chaotic system and binary block compressive sensing suitable for implementation on an embedded device according to claim 3, characterized in that The specific process of Step S3 is as follows: Assume that the size of the original image α is M×N. The main process of image encryption is as follows: (1) First, evenly divide the original image into n0 = M × N / K 2 non - overlapping image blocks of size K × K. Perform column transformation on each image block one by one to obtain column vectors α 2 of size K × 1 i (i = 1, 2, …, n0). Connect all the column vectors α i using the matrix concatenation operator [,] to form a new matrix α v : (2) Generate the initial values and parameters of the new two-dimensional integer chaotic system through the SHA-512 function. Use the original image to calculate the SHA-512 function hash value, and convert the 512-bit hash value of the original image into 32 16-bit binary numbers e1, e2, …, e 32 , and the secret key {u, v, x0, y0, n, a} is obtained through the following formula, where represents the exclusive OR operation: (3) The chaotic sequence X generated by using a new two-dimensional integer chaotic system, and this chaotic sequence X is denoted by the symbol q' b with a length of N b ×K 2 , where floor is used to make the value range of the chaotic sequence X be [0, 255], thus obtaining the sequence q' b ': q' b ' = mod(q' b , 256); (4) Convert the sequence q' b ' into a binary number with R1 bits, thereby obtaining a binary sequence q b , where R1 is set to 8, and construct a measurement matrix Φ using the construction method of the binary measurement matrix in step S2 b , and use the measurement matrix Φ b to sample α v to obtain the corresponding encrypted image β v : β v = Φ b α v ; (5) To improve the privacy of the image, use the following formula for diffusion processing to perform secondary encryption on the image: Where, H is the upper four bits of the data; L is the lower four bits of the data; Γ en is a diffusion sequence, which is constructed from the chaotic sequence Y generated by a new two-dimensional integer chaotic system. The chaotic sequence Y is denoted by the symbol q' a and its length is N b ×K 2 , is rounding down: Γ en = mod(floor(q' a × 10 16 ), 256); (6) Perform the inverse operation of the block division in step (1) on the sequence I' obtained after secondary encryption to reconstruct it into a matrix I. The rows and columns of the matrix I are the same as those of the plaintext image, so as to obtain the ciphertext image I after secondary encryption.