An asymmetric visual meaningful image encryption method based on 2D compressive sensing
By constructing a new chaotic system and 2D compressed sensing technology, combined with RSA encryption and integer wavelet transform, visually meaningful encrypted images are generated, solving the problem of insufficient encryption quality and security in existing technologies, and achieving efficient image encryption and secure reconstruction.
Patent Information
- Application Number
- CN202310115228.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-13
- Publication Date
- 2025-11-07
- Estimated Expiration
- 2043-02-13
AI Technical Summary
Existing image encryption schemes based on compressed sensing are insufficient in ensuring encryption quality and security, especially when the receiver needs to reconstruct the image after receiving the ciphertext image, making it difficult to simultaneously meet the requirements of high efficiency and high security.
A novel chaotic system is constructed and combined with 2D compressed sensing. A key stream is generated through the RSA encryption algorithm, and scrambling encryption and mapping operations are performed. The mid-to-high frequency detail matrix of the carrier image is embedded using integer wavelet transform to generate a visually meaningful encrypted image.
It improves the security and reconstruction quality of image encryption, effectively resists known-plaintext attacks and chosen-plaintext attacks, and ensures the visual quality and security of encrypted images.
Smart Images

Figure CN116192360B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of image encryption technology, in particular to an asymmetric visual meaningful image encryption method. BACKGROUND
[0002] With the rapid development and popularization of mobile communication technology, multimedia technology and digital image processing technology, more and more people accept the image as a feature of information image, and image has become an important part of our information carrier. Image has become the most common and key information carrier in modern communication with its strong visual performance and low storage characteristics. As an important multimedia resource, image meets the communication needs of the digital society, and it can communicate in a more rapid, convenient and efficient way. However, although the development of technology improves the efficiency of digital information transmission, it also brings new risks and challenges. Image exchange or transmission in an unprotected public channel may be stolen or damaged by unauthorized persons, resulting in loss and leakage of image information. Therefore, how to effectively protect the image has become an important research topic.
[0003] At present, the protection methods of image information mainly include image encryption and image hiding. Image encryption is to convert the plaintext image into a chaotic and noise-like ciphertext image by using encryption technology before transmission, so that the attacker cannot obtain meaningful information. Image hiding is to embed the plaintext image information into another meaningful carrier image without changing the main semantic expression of the original carrier image, so as to achieve the effect of information hiding.
[0004] Nonlinear chaotic system is widely used in key stream generation of image encryption or image hiding due to its initial value sensitivity, parameter sensitivity, unpredictability and pseudo-randomness, so as to effectively protect the transmitted image. Compressed sensing technology has the functions of compression and encryption in image secret communication. It samples the image information at a sampling rate much lower than the traditional Nyquist sampling theorem, and completes high-quality image reconstruction with high probability. Therefore, compressed sensing technology has been widely used in signal processing and image processing fields due to its low sampling rate and high efficiency. However, the image encryption scheme based on compressed sensing method needs to reconstruct the image to obtain the plaintext image after receiving the ciphertext image at the receiving end. Most of the existing schemes are not ideal in terms of ensuring encryption quality and encryption security at the same time. SUMMARY
[0005] The application provides an asymmetric visual meaningful image encryption method based on 2D compressive sensing, which is used for obtaining a visual meaningful encrypted image, and guarantees the image encryption security and reconstruction quality through the steps of 2D compressive sensing, scrambling encryption, mapping operation, integer wavelet transform and the like.
[0006] To achieve the above effects, the technical scheme of the application is as follows:
[0007] An asymmetric visual meaningful image encryption method based on 2D compressive sensing comprises the following steps:
[0008] S1: a new chaotic system is constructed, a plaintext image is taken as an image to be encrypted, a new parameter conversion model TransM is constructed, plaintext parameters are extracted from the plaintext image, and the plaintext parameters are encrypted into public parameters through an RSA encryption algorithm;
[0009] S2: a new initial value acquisition model GetM is constructed, the plaintext parameters and the public parameters are taken as input values to generate initial values of the chaotic system, the chaotic system is iterated, a chaotic sequence is generated, the chaotic sequence is preprocessed, and a key stream is calculated;
[0010] S3: the key stream is sorted to obtain an index, the plaintext image is indexed and scrambled to obtain a scrambled image, and pixels of the scrambled image are mapped to obtain a mapped image;
[0011] S4: the mapped image is subjected to 2D compressive sensing through a measurement matrix to obtain a compressed image, the compressed image is subjected to quantization operation to obtain a quantized image, and the quantized image is subjected to diffusion encryption to obtain a ciphertext image;
[0012] S5: the ciphertext image is subjected to decimal bit decomposition to obtain three bit matrices, and a carrier image is subjected to integer wavelet transform to obtain four coefficient matrices; wherein the coefficient matrices are an approximation matrix and three detail matrices respectively;
[0013] S6: the three bit matrices are embedded into the three scrambled detail matrices to obtain embedded detail matrices, the embedded detail matrices are subjected to inverse scrambling to obtain inverse scrambled detail matrices, the approximation matrix and the inverse scrambled detail matrices are subjected to inverse integer wavelet transform to obtain a visual meaningful encrypted image.
[0014] Further, step S1 comprises the following steps:
[0015] S1.1: input a plaintext image P and a carrier image Z with a size of MxN, and construct a new chaotic system as follows:
[0016]
[0017] S1.2: Calculate the plaintext parameters a, b, g: extract the information entropy s of the image P and the trace tr of the matrix, and generate two random numbers u and r; in order to meet the restriction conditions of the plaintext input in the RSA encryption algorithm and enhance the sensitivity of the plaintext, the information entropy s, the trace tr of the matrix, the random numbers u and r are used as the plaintext information of the image P, a new parameter conversion model TransM is constructed to convert the plaintext information s, tr, u, r, and three plaintext parameters a, b, g are obtained, and the parameter conversion model TransM is as follows:
[0018]
[0019] S1.3: Calculate the public parameters a', b', g': according to the three public keys {(e1, n1), (e2, n2), (e3, n3)} received by the receiver, encrypt the three plaintext parameters a, b, g using the RSA encryption algorithm respectively, and obtain three public parameters a', b', g', which are used as the key to transmit to the receiver.
[0020] Further, the initial key of the chaotic system in step S1.1 is x0, y0, z0, the control parameters are: a=3, b=40, c=0.5, d=0.001, g=0.09, the control parameters for eliminating transient effects are t=200, two large prime numbers p=1381, q=1231, public key e=311, compression ratio RT=0.25.
[0021] Further, the step S2 includes:
[0022] S2.1: Generate the initial value of the chaotic system: construct a new initial value acquisition model GetM to perform nonlinear conversion on the three parameter pairs (a, a'), (b, b'), (g, g'), and generate three initial values x0, y0, z0 of the chaotic system by taking the plaintext parameters and public parameters as input values; the initial value acquisition model GetM is a binary nonlinear function, as follows:
[0023]
[0024] Wherein, v represents the plaintext parameters a, b, g, and v' represents the public parameters a', b', g'; the domain of the initial value acquisition model GetM is all real numbers, and the value range is [0, 1];
[0025] S2.2: Generate the key stream: generate three chaotic sequences x, y, z with a length of M×N+t according to the Rouge-Kutta method to iterate the chaotic system; and the key streams X, Y, Z are obtained by preprocessing and calculating the chaotic sequences x, y, z, as follows:
[0026]
[0027] wherein t represents the first t points of the chaotic sequence.
[0028] Further, in step S2.2, in order to eliminate the transient effect of the chaotic system, the first t points of the chaotic sequence are removed, wherein t = 200.
[0029] Further, the step S3 comprises:
[0030] S3.1: scrambling encryption: indexing the key stream X to obtain the index IX, and indexing and scrambling the plaintext image P to obtain the scrambled image Q;
[0031] S3.2: mapping operation: mapping the pixels of the scrambled image Q from [0, 255] to [-128, 128] to obtain the mapped image R.
[0032] Further, the step S4 specifically comprises:
[0033] S4.1: setting the compression rate: setting the compression rate RT of the mapped image R as 0.25;
[0034] S4.2: generating a measurement matrix: constructing two partial Hadamard matrices ρ1 and ρ2 with a size of RT×M×N; taking two non-intersecting key stream segments Z1 and Z2 from the key stream Z, with a length of RT×M; indexing and sorting the key stream segments Z1 and Z2 to obtain the indexes IZ1 and IZ2; scrambling and encrypting the partial Hadamard matrices ρ1 and ρ2 by using the indexes IZ1 and IZ2, respectively, to obtain two measurement matrices and
[0035] S4.3: compressed sampling: using the measurement matrices and to perform 2D compressed sensing on the image R to obtain a compressed image G, wherein the size of the compressed image G is one quarter of the size of the plaintext image; the 2D compressed sensing is as follows:
[0036]
[0037] S4.4: performing a quantization operation on the compressed image G: quantizing the pixel values of the compressed image G to [0, 255] to obtain an image K, and the quantization operation is as follows:
[0038]
[0039] S4.5: diffusion encryption: converting the image K into a one-dimensional sequence A, indexing and sorting the one-dimensional sequence A to obtain the index IY of the key stream Y; using the index IY to diffuse the one-dimensional sequence A to obtain a sequence D, and converting the sequence D into a two-dimensional ciphertext image C, i.e., obtaining the ciphertext image C.
[0040] Further, the sequence D in the S4.5 step is as follows:
[0041]
[0042] wherein i = 2, 3, …, M x N, j = M x N - 1, M x N - 2, …, 1.
[0043] Further, the S5 step is specifically as follows:
[0044] S5.1: Decimal bit decomposition: the ciphertext image C is subjected to decimal bit decomposition to obtain three bit matrices H1, H2, H3 with the size of M x N, wherein H1 represents the matrix of the unit digit set, H2 represents the matrix of the ten digit set, and H3 represents the matrix of the hundred digit set;
[0045] S5.2: Integer wavelet transform: the carrier image Z is subjected to integer wavelet transform to obtain four coefficient matrices with the size of M x N / 2 x N / 2, wherein the coefficient matrices are an approximation matrix CA and three detail matrices CH, CV, CD.
[0046] Further, the S6 step is specifically as follows:
[0047] S6.1: Scrambling encryption: the three detail matrices CH, CV, CD are subjected to scrambling encryption by using the index IY to obtain three scrambled detail matrices CH1, CV1, CD1.
[0048] S6.2: Embedding hiding: the three bit matrices H1, H2, H3 are embedded into the three scrambled detail matrices CH1, CV1, CD1 by using addition operation to obtain three embedded detail matrices CH2, CV2, CD2, as follows:
[0049]
[0050] S6.3: Generating visual image: the three embedded detail matrices CH2, CV2, CD2 are subjected to inverse scrambling to obtain three inversely scrambled detail matrices CH3, CV3, CD3, and the approximation matrix CA and the three inversely scrambled detail matrices CH3, CV3, CD3 are subjected to inverse integer wavelet transform to obtain a visual meaningful encrypted image VMEI (i.e., a reconstructed image).
[0051] In summary, the application constructs a new nonlinear chaotic system, and on this basis, an asymmetric visual meaningful image compression and hiding method is proposed by combining 2D compression sensing (2DCS) ; in the encryption preprocessing process, two nonlinear models TransM and GetM are newly built to generate the plaintext key of the chaotic system; in order to avoid the key management problem of the symmetric cipher, the plaintext key is encrypted by using the RSA encryption algorithm, and the security of the algorithm of the application is further improved; therefore, the plaintext image information is associated with the generation of the key stream, so that the application can effectively resist known plaintext attack and chosen plaintext attack; 2D compression sensing is used to ensure that the image is compressed and sampled without affecting the structured information of the image, so that the image encryption rate is improved, and the reconstruction quality of the decrypted image is also enhanced; based on the asymmetric cipher framework, the visual meaningful encrypted image can resist exhaustive attack and cropping attack in the data transmission process of the image, and has certain robustness.
[0052] Compared with the prior art, the application has the beneficial effects that:
[0053] 1. The application constructs a new chaotic system for generating a key stream, so that the chaotic system has a larger positive Lyapunov exponent, thereby having better chaotic dynamic characteristics;
[0054] 2. Two nonlinear models TransM and GetM are newly built to generate the dependence on the plaintext image and ensure that the initial value is uniformly distributed in the effective range of the chaotic system;
[0055] 3. By using the technical solutions of scrambling encryption, 2D compression sensing, diffusion encryption and embedding hiding, the statistical characteristics of the plaintext image can be effectively broken, the security of the encrypted image is ensured, and the key stream is used to participate in the generation of the measurement matrix, thereby improving the image encryption effect;
[0056] 4. The decimal decomposition of the ciphertext image can effectively ensure the visual quality of the visual meaningful image and reduce the probability of being found and attacked. BRIEF DESCRIPTION OF DRAWINGS
[0057] The drawings are only used for illustrative description, and cannot be understood as a limitation on the application; in order to better illustrate the embodiments, some components in the drawings may be omitted, enlarged or reduced, and do not represent the size of the actual product; for those skilled in the art, it is understandable that some well-known structures and their descriptions in the drawings may be omitted.
[0058] Figure 1 The asymmetric visual meaningful image encryption method provided by the application is shown in the following steps.
[0059] Figure 2is a specific plaintext image Truck schematic diagram provided by the embodiment of the present application;
[0060] Figure 3 is a specific carrier image Baboon schematic diagram provided by the embodiment of the present application;
[0061] Figure 4 is a visual meaningful carrier image Baboon containing plaintext image Truck schematic diagram provided by the embodiment of the present application;
[0062] Figure 5 is a reconstructed image Truck schematic diagram provided by the embodiment of the present application;
[0063] Figure 6 is a histogram of the grayscale carrier image Baboon schematic diagram provided by the embodiment of the present application;
[0064] Figure 7 is a histogram of the visual meaningful grayscale carrier image Baboon containing plaintext image Truck schematic diagram provided by the embodiment of the present application;
[0065] Figure 8 is a specific color plaintext image Peppers schematic diagram provided by the embodiment of the present application;
[0066] Figure 9 is a specific color carrier image Taiyang schematic diagram provided by the embodiment of the present application;
[0067] Figure 10 is a histogram of the color carrier image Taiyang schematic diagram provided by the embodiment of the present application;
[0068] Figure 11 is a histogram of the visual meaningful color carrier image Taiyang containing plaintext image Peppers schematic diagram provided by the embodiment of the present application. DETAILED DESCRIPTION
[0069] In order to make the purpose, technical scheme and advantages of the embodiments of the present application clearer, the technical scheme in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are some embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the protection scope of the present application.
[0070] For the convenience of understanding, please refer to Figure 1 An embodiment of the present application provides a non-symmetrical visual meaningful image encryption method based on 2D compressive sensing, which comprises the following steps:
[0071] S1: Construct a new chaotic system, take the plaintext image as the image to be encrypted and construct a new parameter conversion model TransM to extract plaintext parameters from the plaintext image, encrypt the plaintext parameters into public parameters by RSA encryption algorithm; Specifically, the following steps are included:
[0072] S1.1: The present application can not only be applied to grayscale images, but also can be applied to color images, because color images can be decomposed into R, G, and B channels, and each channel can be hidden in the manner of grayscale image, and finally integrated into a visually meaningful color visual image; Therefore, in order to better express, the present application uses grayscale image for compression and hiding test; The input plaintext image P and the carrier image Z, the size of the plaintext image P and the carrier image Z is MxN, the initial key is x0, y0, z0, the control parameters of the chaotic system are: a=3, b=40, c=0.5, d=0.001, g=0.09, the control parameter for eliminating transient effect is t=200, a pair of public key and private key is generated by selecting two large prime numbers, the two large prime numbers are p=1381, q=1231, the public key e=311, the compression ratio RT=0.25;
[0073] A three-dimensional continuous chaotic system is used as a chaotic sequence generator, and a new chaotic system is constructed as follows:
[0074]
[0075] S1.2: Calculate the plaintext parameters α, β, γ: Extract the information entropy s of the image P and the trace tr of the matrix, and generate two random numbers u and r; In order to meet the restriction condition of plaintext input in RSA encryption algorithm and enhance the sensitivity of plaintext, the information entropy s, the trace tr of the matrix, the random number u and r are used as the plaintext information of the image P, a new parameter conversion model TransM is constructed to convert the parameters of the plaintext information s, tr, u, r, and three plaintext parameters α, β, γ are obtained, and the parameter conversion model TransM is as follows:
[0076]
[0077] S1.3: Calculate the public parameters α', β', γ': According to the three public keys {(e1, n1), (e2, n2), (e3, n3)} received by the receiver, encrypt the three plaintext parameters α, β, γ by RSA encryption algorithm respectively, and obtain three public parameters α', β', γ', and α', β', γ' are used as the key to transmit to the receiver; The plaintext parameters α, β, γ and the public parameters α', β', γ' constitute three parameter pairs (α, α'), (β, β'), (γ, γ');
[0078] S2: Construct a new initial value acquisition model GetM to generate the initial value of the chaotic system with the plaintext parameter and the public parameter as input values, iterate the chaotic system, generate the chaotic sequence, and obtain the key stream by preprocessing the chaotic sequence and calculation; specifically comprising the following steps:
[0079] S2.1: Generate the initial value of the chaotic system: construct a new initial value acquisition model GetM to perform nonlinear conversion on three parameter pairs (a, a'), (b, b'), and (g, g'), generate three initial values x0, y0, and z0 of the chaotic system with the plaintext parameter and the public parameter as input values; the initial value acquisition model GetM is a binary nonlinear function, as follows:
[0080]
[0081] wherein v represents the plaintext parameters a, b, and g, and v' represents the public parameters a', b', and g'; the domain of the initial value acquisition model GetM is all real numbers, and the range is [0, 1];
[0082] S2.2: Generate the key stream: generate three chaotic sequences x, y, and z with a length of MxN+t according to the Rouge-Kutta method to iterate the chaotic system; in order to eliminate the transient effect of the chaotic system, the first t points of the chaotic sequence are removed, wherein t=200; at the same time, in order to meet the subsequent use conditions, the chaotic sequences x, y, and z are preprocessed and calculated to obtain the key stream X, Y, and Z, so as to have stronger randomness; as another embodiment of the present application, the key stream X, Y, and Z are as follows:
[0083]
[0084] wherein mod is the remainder function, and t represents the first t points of the chaotic sequence.
[0085] The dependence of the key on the key image is used to construct a high correlation mechanism between the key stream and the plaintext image, so as to ensure the key sensitivity of the algorithm.
[0086] S3: Sort the key stream to obtain an index, index the plaintext image to obtain a scrambled image, and map the pixels of the scrambled image to obtain a mapped image; specifically comprising the following steps:
[0087] S3.1: Scramble encryption: sort the key stream X to obtain an index IX, and index the plaintext image P to obtain a scrambled image Q;
[0088] S3.2: Mapping operation: map the pixels of the scrambled image Q from [0, 255] to [-128, 128] to obtain a mapped image R; the mapping operation is conducive to enhancing the image reconstruction quality of the subsequent 2D compressed sensing (i.e., 2DCS);
[0089] S3.3: Set the compression rate: set the compression rate RT of the mapping image R as 0.25;
[0090] S4: 2D compressive sensing of the mapping image by using the measurement matrix to obtain a compressed image, performing quantization operation on the compressed image to obtain a quantized image, and performing diffusion encryption on the quantized image to obtain a ciphertext image; specifically comprising the following steps:
[0091] S4.1: generating a measurement matrix: constructing two partial Hadamard matrices ρ1 and ρ2 with the size of RT×M×N; taking two non-intersecting key stream segments Z1 and Z2 from the key stream Z, with the length of RT×M; sorting the key stream segments Z1 and Z2 and calculating the indexes IZ1 and IZ2 of Z1 and Z2; and using IZ1 and IZ2 to respectively scramble and encrypt the partial Hadamard matrices ρ1 and ρ2 to obtain two measurement matrices and
[0092] S4.2: compressed sampling: performing 2D compressive sensing on the mapping image R by using the measurement matrix and to obtain a compressed image G, and the size of the compressed image G is one fourth of the plaintext image; the 2D compressive sensing is as follows:
[0093]
[0094] S4.3: performing quantization operation on the compressed image G: quantizing the pixel value of the compressed image G to [0, 255] to obtain a quantized image K, and the quantization operation is as follows:
[0095]
[0096] S4.4: diffusion encryption: converting the quantized image K into a one-dimensional sequence A, sorting the one-dimensional sequence A and calculating the index IY of the key stream Y; using the index IY to perform forward and reverse "modulo addition" diffusion on the one-dimensional sequence A to obtain a sequence D, and converting the sequence D into a two-dimensional ciphertext image C, that is, obtaining the ciphertext image C;
[0097] As another embodiment of the present application, the sequence D in step S2.7 is as follows:
[0098]
[0099] Wherein, i=2, 3,..., M×N, j=M×N-1, M×N-2,..., 1.
[0100] S5: Perform decimal bit decomposition on the encrypted image, and perform integer wavelet transform, scrambling, embedding, inverse scrambling, and inverse integer wavelet transform on the carrier image to obtain a visually meaningful encrypted image; specifically including the following steps:
[0101] S5.1: Decimal bit decomposition: Perform decimal bit decomposition on the ciphertext image C to obtain three bit matrices H1, H2, and H3 of size M×N; where H1 represents the matrix of the units digit set, H2 represents the matrix of the tens digit set, and H3 represents the matrix of the hundreds digit set.
[0102] S5.2: Integer Wavelet Transform: Perform an integer wavelet transform on the carrier image Z to obtain four waves of size Z. The coefficient matrices are the approximation matrix CA and the three detail matrices CH, CV, and CD.
[0103] S6: Embed the three bit matrices into the three scrambled detail matrices to obtain the embedded detail matrix; inversely scramble the embedded detail matrix to obtain the inversely scrambled detail matrix; perform inverse integer wavelet transform on the approximate matrix and the inversely scrambled detail matrix to obtain a visually meaningful encrypted image; specifically including the following steps:
[0104] S6.1: Scrambling and Encryption: Use index IY to scramble and encrypt the three detail matrices CH, CV, and CD to obtain the scrambled detail matrices CH1, CV1, and CD1.
[0105] S6.2: Embedding Hiding: The three bit matrices H1, H2, and H3 are embedded into the three scrambled detail matrices CH1, CV1, and CD1 using an addition operation, resulting in the embedded detail matrices CH2, CV2, and CD2; as shown in the following formula:
[0106]
[0107] S6.3: Generate visual image: Inversely scramble the embedded detail matrices CH2, CV2, and CD2 to obtain inversely scrambled detail matrices CH3, CV3, and CD3. Perform inverse integer wavelet transform on the approximation matrix CA and the inversely scrambled detail matrices CH3, CV3, and CD3 to obtain the visually meaningful encrypted image VMEI.
[0108] In terms of result testing, such as Figure 2 Randomly select a specific plaintext image Truck, and use Figure 3 A specific carrier image, Baboon, is encrypted using the method of this invention to obtain... Figure 4 The visually meaningful image of Baboon containing a truck. Figure 5 It is a reconstructed image truck; regarding the statistical characteristics of image grayscale values,Figure 6 is the histogram of the gray carrier image Baboon, Figure 7 is the histogram of the gray carrier image Baboon of the visual meaningful stego image Truck containing plaintext. It can be seen that the histogram of the gray carrier image Baboon of the present application and the histogram of the visual meaningful stego image containing plaintext are almost the same, which shows that the encryption effect of the ciphertext image of the present application is good and the visual performance is strong.
[0109] In the specific implementation process, the present application is also applicable to color images. The color image can be decomposed into three channels of R, G and B, and each channel can be hidden in the manner of the gray image, and finally integrated into a visual meaningful color stego image containing plaintext. Figure 8 is a specific color image Pepper, Figure 9 is a specific color carrier image Taiyang, Figure 10 is the histogram of the color carrier image Taiyang, Figure 11 is the histogram of the color carrier image Taiyang of the visual meaningful stego image Peppers containing plaintext. It can be seen that the histogram of the carrier image and the histogram of the carrier image of the visual meaningful stego image containing plaintext are basically the same, so the encryption and hiding effect of the present application method is good. In the histogram of the present application, the abscissa represents the gray level, and the ordinate represents the number of pixels.
[0110] The image decryption reconstruction process of the present application: the extraction and decryption reconstruction process of the encrypted image information is the inverse process of the encryption and hiding of the plaintext image; that is, the receiver decrypts the public parameters α', β', γ' to obtain the plaintext parameters α, β, γ according to the private key d stored; the plaintext parameters α, β, γ and the public parameters α', β', γ' are taken as input values to pass through the initial value acquisition model GetM to generate three initial values of the chaotic system; the three key streams x, y, z are generated by solving the chaotic system by using the fourth-order five-level Rouge-Kutta method; and after pre-processing, the usable sequences X, Y, Z are obtained;
[0111] The visual meaningful encrypted image VMEI and the carrier image Z are subjected to integer wavelet transform to obtain corresponding coefficient matrices CA, CH, CV, CD and CA', CH', CV', CD'; the sequence Y is sorted to generate an index IY, and the index IY is used to perform scrambling operation on the six coefficient matrices CA, CH, CV, CA', CH', CV' of the middle and high frequency bands to obtain CH1, CV1, CD1, CH1', CV1', CD1';
[0112] The embedded information is extracted from CH1, CV1, CD1, CH1', CV1', CD1' to obtain three bit matrices H1, H2, H3, as follows:
[0113]
[0114] The three bit matrices H1, H2 and H3 are combined to obtain a ciphertext image C, as follows:
[0115] C = H3 * 100 + H2 * 10 + H1
[0116] The ciphertext image is inversely diffused by using the index IY to obtain an image K; the image K is inversely quantized to obtain a frequency domain image G; the frequency domain image G is decrypted and reconstructed by using a two-dimensional projection gradient algorithm (2D CS-ETS), and thus a plaintext image P can be obtained.
[0117] The application constructs a new three-dimensional chaotic system, proposes an asymmetric visual meaningful image encryption method based on a chaotic system and 2D compressed sensing (2D CS), and analyzes and verifies the method.
[0118] (1) In the encryption preprocessing stage, a parameter conversion model TransM is constructed to extract plaintext parameters from a plaintext image, and the plaintext parameters are encrypted into public parameters by using an RSA (Rivest-Shamir-Adleman) encryption algorithm; a new initial value acquisition model GetM generates chaotic system initial values by taking the plaintext parameters and the public parameters as input values; finally, the chaotic system is iterated to generate chaotic sequences, which are used for image encryption.
[0119] (2) In the image encryption stage, an index scrambling and pixel mapping are performed on the plaintext image to obtain a mapping image; 2D compressed sensing, quantization operation and diffusion encryption are performed on the mapping image by using a measurement matrix to obtain a ciphertext image; wherein the measurement matrix is generated by controlling part of a Hadamard matrix by using the chaotic sequences.
[0120] (3) In the embedding and hiding stage, an integer wavelet transform (IWT) is first performed on a carrier image to obtain four coefficient matrices; the ciphertext image is decomposed into decimal, and the three bit planes of the decimal, the tens and the hundreds are embedded into the three middle-high frequency detail coefficient matrices of the carrier image; after inverse integer wavelet transform (IIWT), a final visual meaningful encrypted image (VMEI) is obtained; the integer wavelet transform and the inverse integer wavelet transform are used to realize reversibility and reduce data loss caused by frequency domain transformation. When the compression ratio (CR) is set to 0.25, the NC values of the plaintext image and the decrypted image are almost equal to 1, and the PSNR values of the carrier image and the visual meaningful encrypted image are as high as 42 dB, which indicates that the decrypted image has high quality and the visual meaningful encrypted image has excellent visual security; in addition, the algorithm can resist exhaustive attack and cropping attack and has certain robustness.
[0121] Obviously, the above embodiments of the present application are merely exemplary but not intended to limit the embodiments of the present application. Based on the above description, any other variations or changes can be made by those skilled in the art without departing from the spirit and principles of the present application. It is not necessary to list all the embodiments here. Any modifications, equivalent replacements, and improvements made within the spirit and principles of the present application shall fall within the scope of the claims of the present application.
Claims
1. A 2D compressive sensing based asymmetric visually meaningful image encryption method, characterized in that, Comprising the following steps: S1: constructing a new chaotic system, taking the plaintext image as the image to be encrypted and constructing a new parameter conversion model TransM to extract plaintext parameters from the plaintext image, and encrypting the plaintext parameters into public parameters by RSA encryption algorithm; S2: constructing a new initial value acquisition model GetM to generate the initial value of the chaotic system by taking the plaintext parameters and the public parameters as input values, iterating the chaotic system, generating a chaotic sequence, preprocessing the chaotic sequence and calculating the key stream; S3: sorting the key stream to obtain an index, and performing index scrambling on the plaintext image to obtain a scrambled image, and mapping the pixels of the scrambled image to obtain a mapped image; S4: using a measurement matrix to perform 2D compressive sensing on the mapped image to obtain a compressed image, performing quantization operation on the compressed image to obtain a quantized image, and performing diffusion encryption on the quantized image to obtain a ciphertext image; S5: performing decimal bit decomposition on the ciphertext image to obtain three bit matrices; performing integer wavelet transform on the carrier image to obtain four coefficient matrices; wherein the coefficient matrices are an approximation matrix and three detail matrices, respectively; S6: embedding the three bit matrices into the three scrambled detail matrices to obtain embedded detail matrices; performing inverse scrambling on the embedded detail matrices to obtain inverse scrambled detail matrices; and performing inverse integer wavelet transform on the approximation matrix and the inverse scrambled detail matrices to obtain a visually meaningful encrypted image.
2. The asymmetric visual meaningful image encryption method based on 2D compressive sensing according to claim 1, characterized in that, Step S1 includes: S1.1: inputting a plaintext image P and a carrier image Z with a size of MxN, and constructing a new chaotic system as follows: The initial key of the chaotic system is x0, y0, z0, the control parameters of the chaotic system are: a=3, b=40, c=0.5, d=0.001, g=0.09, the control parameter for eliminating transient effect is t=200, a pair of public key and private key is generated by selecting two large prime numbers, the two large prime numbers are p=1381 and q=1231, the public key is e=311, and the compression ratio RT=0.25; S1.2: calculating the plaintext parameters α, β, γ: extracting the information entropy s and the trace tr of the matrix of the image P, and generating two random numbers u and r; in order to meet the restriction condition of the plaintext input in the RSA encryption algorithm and enhance the sensitivity of the plaintext, the information entropy s, the trace tr of the matrix, the random number u and r are taken as the plaintext information of the image P, a new parameter conversion model TransM is constructed to convert the parameters of the plaintext information s, tr, u, r respectively, and three plaintext parameters α, β, γ are obtained, the parameter conversion model TransM is as follows: S1.3: calculating the public parameters α', β', γ': according to the three public keys {(e1, n1), (e2, n2), (e3, n3)} received by the receiver, three plaintext parameters α, β, γ are encrypted by RSA encryption algorithm respectively, and three public parameters α', β', γ' are obtained, which are taken as the key to the receiver.
3. The asymmetric visual meaningful image encryption method based on 2D compressive sensing according to claim 2, characterized in that, S2 includes: S2.1: generating initial values of chaotic system: constructing a new initial value acquisition model GetM to generate three initial values x0, y0, z0 of chaotic system by nonlinearly transforming three parameter pairs (a, a'), (b, b'), (g, g') and taking plaintext parameters and public parameters as input values; the initial value acquisition model GetM is a binary nonlinear function, as follows: wherein, v represents plaintext parameters a, b, g, and v' represents public parameters a', b', g'; the definition domain of the initial value acquisition model GetM is all real numbers, and the value domain is [0, 1]; S2.2: generating key stream: generating three chaotic sequences x, y, z with a length of MxN+t according to the Rouge-Kutta method to iterate the chaotic system; and pre-processing the chaotic sequences x, y, z and calculating to obtain a key stream X, Y, Z, as follows: wherein, t represents the first t points of the chaotic sequence.
4. The asymmetric visual meaningful image encryption method based on 2D compressive sensing according to claim 3, characterized in that, In step S2.2, in order to eliminate the transient effect of the chaotic system, the first t points of the chaotic sequence are removed, wherein t = 200.
5. The asymmetric visual meaningful image encryption method based on 2D compressive sensing according to claim 4, characterized in that, S3 step includes: S3.1: scrambling encryption: sorting the key stream X to obtain an index IX, and performing index scrambling on the plaintext image P to obtain a scrambled image Q; S3.2: mapping operation: mapping the pixels of the scrambled image Q from [0, 255] to [-128, 128] to obtain a mapped image R.
6. The method of claim 4, wherein the method is asymmetric visual meaningful image encryption based on 2D compressive sensing. S4 step is specifically: S4.1: setting compression rate: setting the compression rate RT of the mapped image R as 0.25; S4.2: Generate measurement matrix: construct two partial Hadamard matrices p1 and p2 with size RTXMXN; take two disjoint key stream segments Z1 and Z2 from the key stream Z, with length RTXM; sort the key stream segments Z1 and Z2 and calculate the indexes of Z1 and Z2, which are IZ1 and IZ2; use IZ1 and IZ2 to scramble and encrypt the partial Hadamard matrices p1 and p2 respectively, to obtain two measurement matrices and S4.3: Compressive Sampling: Utilizing Measurement Matrix and 2D compressive sensing is performed on the image R to obtain a compressed image G, and the size of the compressed image G is one quarter of the size of the plaintext image; the 2D compressive sensing is as follows: S4.4: quantization operation on the compressed image G: quantizing the pixel values of the compressed image G to [0, 255] to obtain an image K, and the quantization operation is as follows: S4.5: Diffusion encryption: convert the image K into a one-dimensional sequence A, sort the one-dimensional sequence A and calculate the index IY of the key stream Y; diffuse the one-dimensional sequence A using the index IY to obtain a sequence D, convert the sequence D into a two-dimensional ciphertext image C, that is, obtain the ciphertext image C. a two-dimensional ciphertext image C, that is, obtain the ciphertext image C.
7. The asymmetric visual meaningful image encryption method based on 2D compressive sensing according to claim 6, characterized in that, S4.5 step sequence D is as follows: wherein, i = 2, 3,..., MxN, and j = MxN-1, MxN-2,..., 1.
8. The asymmetric visual meaningful image encryption method based on 2D compressive sensing according to claim 7, characterized in that, S5 step is specifically: S5.1: decimal bit decomposition: performing decimal bit decomposition on the ciphertext image C to obtain three bit matrices H1, H2, H3 with a size of MxN; wherein, H1 represents a matrix of unit digit sets, H2 represents a matrix of ten digit sets, and H3 represents a matrix of hundred digit sets; S5.2: Integer wavelet transform: perform integer wavelet transform on the carrier image Z to obtain four coefficient matrices of size , which are an approximation matrix CA and three detail matrices CH, CV, CD, respectively.
9. The asymmetric visual meaningful image encryption method based on 2D compressive sensing according to claim 8, characterized in that, S6 step is specifically: S6.1: scrambling encryption: scrambling and encrypting three detail matrices CH, CV, CD by using the index IY to obtain scrambled and encrypted detail matrices CH1, CV1, CD1; S6.2: embedding and hiding: embedding three bit matrices H1, H2, H3 into three scrambled and encrypted detail matrices CH1, CV1, CD1 by using addition operation to obtain embedded detail matrices CH2, CV2, CD2, as follows: S6.3: generating visual image: performing inverse scrambling on the embedded detail matrices CH2, CV2, CD2 to obtain inverse scrambled detail matrices CH3, CV3, CD3; and performing inverse integer wavelet transform on the approximate matrix CA and the inverse scrambled detail matrices CH3, CV3, CD3 to obtain a visual meaningful encrypted image VMEI.