Face image data encryption method based on chaotic tent map
By combining multiple chaotic mapping and DNA encoding strategies, this method efficiently encrypts facial images, solving the problems of insufficient security and high computational cost in existing technologies, and achieving high security and high efficiency in image encryption.
Patent Information
- Application Number
- CN202411471428.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-21
- Publication Date
- 2025-11-04
- Estimated Expiration
- 2044-10-21
AI Technical Summary
Existing image encryption technologies based on chaos theory face challenges such as insufficient security, small key space, high computational cost, and insufficient resistance to known attacks, making it difficult to meet the needs of efficient data transmission in a network security environment.
A combined encryption method based on chaotic tent mapping, piecewise linear chaotic mapping, Lorenz chaotic mapping and Chen chaotic mapping, combined with DNA encoding strategy, is used to scramble, diffuse, encode and decode face images to generate highly secure encrypted images.
It effectively expands the key space, improves the security and reliability of the encryption system, enhances resistance to known attacks, and maintains computational cost efficiency, achieving highly efficient image encryption.
Smart Images

Figure CN119676373B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of data encryption, and particularly to a face image data encryption method based on chaotic tent mapping. BACKGROUND
[0002] With the advent of the information age, the rapid development of cutting-edge technologies such as 5G networks, cloud computing technologies, and the Internet of Things, the scale of face image data has exploded. These data are particularly critical due to their widespread application in personal identification, security monitoring, and other fields. Face images not only have a huge amount of data, but also exhibit a high degree of interdependence between pixel values, often containing rich personal information. Therefore, ensuring the privacy and security of these images during network transmission has become a challenge that needs to be addressed. In the field of information security research, encryption technology plays a crucial role. The high data volume and strong correlation between pixel values of digital images require the development of an efficient pseudo-random number generation mechanism.
[0003] Traditional block encryption methods (such as DES, IDEA, AES, etc.) are suitable for image encryption, but cannot resist the transmission noise that may be added to the image during transmission. Therefore, there is an urgent need to research new image encryption algorithms. The application of chaos theory in cryptography provides a new approach to image encryption. Due to the inherent characteristics of digital images in the spatial domain, such as large volume and high correlation, a unique pseudo-random number generator is required. Chaotic systems are good pseudo-random number generators, and the high sensitivity of chaotic systems to seeds and control factors provides an ideal platform for generating high-quality pseudo-random numbers. This characteristic enables encryption algorithms based on chaos to effectively resist various cryptographic analysis attacks, enhancing the security of the encryption system. Considering the urgent need for digital image transmission security in the current network security environment, the present application is dedicated to the in-depth study of image encryption methods based on chaos theory. This research direction not only opens up a new exploration path for the discipline of information security in theory, but also shows broad application potential and important practical significance in actual network security applications.
[0004] However, current image encryption techniques based on chaos theory, although showing great potential, still face several challenges and limitations: (1) Insufficient security: image encryption methods based on single chaotic mapping have security flaws and are vulnerable to chosen-plaintext attacks, and the small key space limits the flexibility and reliability of the encryption system. (2) Balance between complexity of chaotic systems and computational cost: while increasing the complexity of chaotic systems can improve security, it may also lead to increased computational cost and algorithm implementation complexity. (3) Resistance to known attacks: some existing chaotic systems have been proven to be insufficiently resistant to certain attacks (such as salt and pepper noise attacks). SUMMARY
[0005] The present application aims at disclosing a face image data encryption method based on chaotic tent mapping, and solving the technical problems proposed in the background art.
[0006] In order to achieve the above-mentioned purpose, the present application provides the following technical scheme:
[0007] The present application provides a face image data encryption method based on chaotic tent mapping, comprising:
[0008] S1, setting an initial state of a chaotic system;
[0009] S2, receiving a face image and an initialization parameter and generating an initial seed;
[0010] S3, scrambling and diffusing the face image to obtain encrypted images R', G' and B' of three channels R, G and B;
[0011] S4, respectively performing DNA encoding on R', G' and B' to obtain vectors R_DNA, G_DNA and B_DNA;
[0012] S5, respectively performing confusion on R_DNA, R_DNA and R_DNA to obtain encrypted vectors R'_DNA, G'_DNA and B'_DNA;
[0013] S6, decoding and merging R'_DNA, G'_DNA and B'_DNA to obtain an encrypted face image.
[0014] Preferably, S1 comprises:
[0015] Selecting a chaotic tent mapping system, a piecewise linear chaotic mapping system, a Lorenz chaotic mapping system and a Chen chaotic mapping system as the chaotic system for encrypting the face image;
[0016] Respectively initializing the above-mentioned four types of chaotic systems:
[0017] Initializing the chaotic tent mapping system, and the basic form is:
[0018]
[0019] x represents a state variable in the mapping, representing the state of the chaotic tent mapping system at a certain time, x n represents the state of the chaotic tent mapping system in the nth iteration, f represents a constant, and s represents a threshold parameter in the chaotic tent mapping system;
[0020] where f = 0.8, s = 0.5, the chaotic sequence initial value x0= 0.1, for each pixel value pixels[i-1] in the pixel value array, the corresponding chaotic sequence value x[i-1] is calculated, the chaotic sequence value x[i-1] is used to perform XOR operation with the pixel value pixels[i-1] to obtain the pixel value encrypted_arrary[i-1] after chaotic tent map encryption; the next value x[i] of the chaotic sequence is updated according to the value of x[i-1] to ensure the dynamics and unpredictability of the sequence; the process is repeated on each element of the pixel value array, so as to realize the chaotic tent map encryption of the entire image to be encrypted;
[0021] Initialize the piecewise linear chaotic mapping system, and the iterative formula is:
[0022]
[0023] p0 represents a threshold parameter in the piecewise linear chaotic mapping system;
[0024] Through the above iterative formula, a chaotic sequence a i is generated, and the length of the sequence is 3×w×h, where w and h represent the width and height of the image to be encrypted, respectively;
[0025] The chaotic sequence a i is combined with the pixel value list pixels after the first tent map scrambling to form a tuple containing chaotic values and corresponding pixel values, and the chaotic values a i are sorted; after sorting, the pixel values are reorganized to obtain the pixel value list pixels after the second scrambling; the encrypted pixel value list is divided into three color channel pixel value lists of RGB according to the three color channels;
[0026] Initialize the Lorenz chaotic mapping system, which is defined by the following three nonlinear differential equations:
[0027]
[0028] The variable y represents the intensity of the convection motion in the fluid, which is used to quantify the amplitude difference between the rising and descending flows in the air pool, and the variable z represents the temperature gradient in the fluid, which is used to reflect the temperature difference between the rising and sinking fluids, and q is used to describe the deviation of the temperature inside the air pool from the average temperature of the environment, and the parameters f, g, r are physical property constants representing the airflow,
[0029] The initial states y0, z0, q0 of the Lorenz chaotic mapping system are initialized, the Lorenz model function is called, and chaotic sequences Y, Z, Q are generated. In order to remove the initial transient effect, the first 100 values of each sequence are discarded, and then the chaotic sequences are used to sort the pixel values of the RGB three channels of the image to be encrypted, thereby enhancing the randomness and unpredictability of the encryption.
[0030] The Chen chaotic mapping system is initialized, which is defined by the following four nonlinear differential equations:
[0031]
[0032] Where a, b, c, d, k are system parameters, and u, v, w, x are state variables of the system. When the parameters a=36, b=3, c=28, d=16 and the parameter k is in the range of-0.7≤k≤0.7, the Chen chaotic system exhibits typical chaotic dynamic behavior and has the ability to generate multiple chaotic sequences. Within this parameter interval, the Chen chaotic mapping system can generate four independent chaotic sequences. The parameter k=0.2 is selected to construct the Chen chaotic sequence to achieve specific dynamic characteristics and controllability.
[0033] The nonlinear dynamic system equation group composed of the above four nonlinear differential equations is solved by iterative numerical solution process using the fourth-order Runge-Kutta numerical method. Under the given initial conditions and parameter settings, four chaotic sequences U, V, W, X with different dynamic characteristics are generated. In order to remove the initial transient effect, the first 100 values of each sequence are discarded.
[0034] Preferably, S2 comprises:
[0035] An original color face image I and a series of parameter sets for chaotic system initialization and control are received, including a0, p0, u0, v0, w0, x0, y0, z0, q0, and the initialized four chaotic systems Tent, PWLCM, Lorenz and Chen.
[0036] The SHA-256 generated message digest is divided into eight equal size sub-blocks, denoted as m j Where j=1, 2,...8, each sub-block consists of seven hexadecimal digits, and the hexadecimal representation of the numerical value is converted to a decimal floating point number according to the following formula, whose value range is in the interval [0, 0.0156):
[0037] m j =hex2dec(m1,...,m8) / 2 34
[0038] The second group is directly converted into a floating-point value in the range (0, 0.0156):
[0039] d = hex2dec(d) / 2 38
[0040]
[0041] a'0 and p'0 represent the initial seeds of the newly generated piecewise linear chaotic mapping system;
[0042] Assuming that the seed values of the Chen chaotic system are u0, v0, w0, and x0, the following formula is used to generate new initial seeds:
[0043]
[0044] For the Lorenz chaotic system, three seeds are also required, and the calculation method is as follows:
[0045]
[0046] The above SHA-256 generates a 64-bit message digest, and the message digest is divided into nine sub-blocks in total, of which the first eight sub-blocks are equal in size, each being a 7-bit hexadecimal number, denoted as m j , and the remaining one sub-block is an 8-bit hexadecimal number, denoted as d.
[0047] CK is the generated public key, as shown below:
[0048] CK = a0 + p0 + u0 + v0 + w0 + x0 + y0 + z0 + q0 mod 1.
[0049] Preferably, S3 includes:
[0050] The face image in the R, G, B color channels is merged and flattened into a one-dimensional array of size 1x3MN, and XOR operation is performed with the chaotic sequence T generated by the chaotic tent mapping to achieve preliminary encryption of the pixel values:
[0051]
[0052] The PWLCM is iterated 3MN times to obtain a chaotic sequence A, and the pixel values of I are arranged according to the chaotic sequence A as follows to form I':
[0053] A = {a i ,a i+1 ,...,a 3MN}
[0054] [valueA, indexA] = order(A)
[0055] I' = I(indexA)
[0056] order denotes the ordering operation; [valueA, indexA] denotes the index-value pair, valueA is an element in the chaotic sequence, and indexA is the corresponding index of this element in the pixel array; I() denotes the reference to the original pixel array;
[0057] I' is divided into the following three 1 x MN one-dimensional arrays R1, G1, B1 for the third permutation:
[0058] R1 = [I'(1), I'(2),..., I'(MN)]
[0059] G1 = [I'(MN+1), I'(MN+2),..., I'(2MN)]
[0060] B1 = [I'(2MN+1), I'(2MN+2),..., I'(3MN)]
[0061] A pseudo-random number generation strategy based on the initial seeds y'0, z'0, q'0 is used to construct three chaotic sequences Y, Z, Q with a length of t + MN; these sequences are used to perform chaotic permutation and diffusion operations on the RGB three pixel arrays of the face image; to eliminate the transient effect of the initial sequence, a truncation strategy is adopted to discard the first t values in the sequence; then, the remaining sequence is sorted to achieve a specific pixel value permutation mode, as shown in the following formula:
[0062] [valueY, indexY] = order(Y)
[0063] [valueZ, indexZ] = order(Z)
[0064] [valueQ, indexQ] = order(Q)
[0065] In the proposed image encryption framework, the sequences Y, Z, Q generated by chaos theory are sorted to obtain the corresponding index sets indexY, indexZ, indexQ; using these index values, the pixel value elements of the R, G, B three color channels of the image are rearranged based on the index; this operation follows a specific permutation rule, ensuring the remapping of the pixel values, thereby generating a new permutation image, as follows:
[0066]
[0067] where f R , f G , f BRespectively represent the rearrangement function applied to R, G, B three color channels, the function is according to the index generated by the chaos sequence to the original pixel value substitution, get encrypted image R', G', B'.
[0068] Preferably, S4 comprises:
[0069] The encryption process of the three color channels of the face image adopts four specific DNA encoding rules for conversion to realize the binary-based pixel value representation;
[0070] The specific DNA encoding rule is as follows:
[0071] 00: rule[0]
[0072] 01: rule[1]
[0073] 10: rule[2]
[0074] 11: rule[3]
[0075] 00, 01, 10, 11 represent four groups of 2-bit binary numbers obtained by intercepting the 8-bit binary number after converting the decimal pixel value; 8-bit binary numbers are intercepted with 2-bit as the intercept interval to obtain four groups of 2-bit binary numbers;
[0076] Rule is the DNA encoding rule determined by the sequence U generated in the Chen chaos mapping;
[0077] Using Chen hyperchaotic system, combined with the initial key vector u'0, v'0, w'0, x'0, the pseudo-random chaos sequence U, V, W, X is generated through the iteration process, and the iteration number is set to t+MN×3;
[0078] In order to exclude the transient effect of the initial iteration stage, the truncation strategy is adopted, and the first t elements of the sequence are discarded; then, the elements in the sequence U are equally divided into three sub-vectors, each sub-vector contains M×N elements, as shown in the following formula:
[0079] U1=[U(1), U(2),..., U(MN)]
[0080] U2=[U(MN+1), U(MN+2),..., U(2MN)]
[0081] U3=[U(2MN+1), U(2MN+2),..., U(3MN)]
[0082] Based on the DNA-based encoding framework, combined with the sequence generated by chaos theory, each color channel of the face image is independently encoded; according to the preset selection rule, the DNA encoding rule is selected, and each DNA base is arranged according to the array size of 1×4MN:
[0083]
[0084] DNA_Encode_Rule represents DNA encoding operation.
[0085] Preferably, S5 comprises:
[0086] DNA_Encode_Rule is respectively performed on the images of the R, G, B three color channels of the face image;
[0087] Two chaotic sequences V and W are generated by the method described in S4, and the two sequences are converted into start_RGB and times_RGB used to guide XOR operation, as shown in the following formula:
[0088] start_RGB=(V×10 12 )mod 8
[0089] times_RGB=(W×10 12 )mod 8
[0090] start_RGB and times_RGB are decomposed into three sub-arrays, each sub-array has a length of MN, and corresponds to the R, G, B three color channels respectively:
[0091] start_R=[start_RGB(1),...,start_RGB(MN)]
[0092] start_G=[start_RGB(MN+1),...,start_RGB(2MN)]
[0093] start_B=[start_RGB(2MN+1),...,start_RGB(3MN)]
[0094] times_R=[times_RGB(1),...,times_RGB(MN)]
[0095] times_G=[times_RGB(MN+1),...,times_RGB(2MN)]
[0096] times_B=[times_RGB(2MN+1),...,times_RGB(3MN)]
[0097] The obtained sub-arrays are used for the permutation and encoding process of the pixel values of the three color channels R, G, B, in which the R channel pixel values of the original image are converted according to the DNA encoding rule determined by the sequence U generated in the Chen chaotic mapping, combined with the start point start_R and the iteration times times_R generated by the chaotic sequence; this process involves converting the four DNA bases of each pixel value According to the specific permutation logic, the three color channel vectors R'_DNA, G'_DNA and B'_DNA after encryption are generated.
[0098] Preferably, S6 comprises:
[0099] The pseudo-random array X composed of 3MN elements is used as the key input of the decoding process;
[0100] Through random sampling of the preset DNA rule set, the decoding rule obtained by random sampling is used in the following DNA-Decode-Rule operation to realize the decoding of the three color channels R, G and B. The pseudo-random array is generated in the encoding stage and continues to be used in the decoding process to maintain the consistency of the data conversion process;
[0101] The vector X is divided into three arrays according to the following formula, as shown below:
[0102] X1 = [X(1), X(2),..., X(MN)]
[0103] X2 = [X(MN+1), X(MN+2),..., X(2MN)]
[0104] X3 = [X(2MN+1), X(2MN+2),..., X(3MN)]
[0105] Decoding process:
[0106] Cryptogram_R = DNA_Decode_Rule(R'_DNA, X1)
[0107] Cryptogram_G = DNA_Decode_Rule(G'_DNA, X2)
[0108] Cryptogram_B = DNA_Decode_Rule(B'_DNA, X3)
[0109] The DNA-Decode-Rule represents a DNA decoding operation, and finally merges the decoded images corresponding to the three color channels to obtain the encrypted face image I', and Cryptogram_R, Cryptogram_G and Cryptogram_B represent the images obtained by decoding in the R, G and B color channels, respectively.
[0110] Advantages:
[0111] The present application solves the challenges of existing chaotic encryption technology in security, system complexity and resistance to known attacks: (1) In order to enhance security and resist chosen plaintext attacks, the present application dynamically adjusts the initial conditions and control parameters of chaotic tent map, piecewise linear chaotic map, Lorenz chaotic system and Chen chaotic system. This dynamic parameter selection mechanism effectively expands the key space, improves the security and reliability of the algorithm. (2) The chaotic system and DNA cryptography strategy designed by the present application realizes the improvement of security under the premise of not significantly increasing the calculation cost. Through the iteration of chaotic sequence and the pixel-level confusion of DNA encoding, the present application significantly improves the complexity of the encryption process while maintaining the efficiency of the algorithm. (3) The present application specially considers the resistance to specific attacks such as salt and pepper noise. Through the nonlinear characteristics of the chaotic system and the randomness of the DNA encoding, the defense mechanism against known attack patterns is enhanced. BRIEF DESCRIPTION OF DRAWINGS
[0112] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings needed for the embodiment description will be briefly introduced as follows. 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 on the basis of these drawings.
[0113] Figure 1 The figure is a schematic diagram of the face image data encryption method based on chaotic tent map of the present application.
[0114] Figure 2 The figure is an original Lena image.
[0115] Figure 3 The figure is a face recognition Lena image.
[0116] Figure 4 The figure is a face encrypted Lena image.
[0117] Figure 5 The figure is a face decrypted Lena image.
[0118] Figure 6 The figure is a face decrypted image after introducing key disturbance.
[0119] Figure 7 is the histogram of R, G, B three color channels of the standard Lena image.
[0120] Figure 8 is the histogram of the corresponding three color channels of the encrypted Lena image.
[0121] Figure 9 is the schematic diagram of the correlation of adjacent pixels of the three color channels of the original image.
[0122] Figure 10 is the schematic diagram of the correlation of adjacent pixels of the three color channels of the encrypted image.
[0123] Figure 11a is the schematic diagram of the first way of destroying the encrypted image.
[0124] Figure 11b the image obtained by decrypting the encrypted image destroyed in the way of Figure 11a .
[0125] Figure 11c is the schematic diagram of the second way of destroying the encrypted image.
[0126] Figure 11d is the image obtained by decrypting the encrypted image destroyed in the way of Figure 11c .
[0127] Figure 12a is the image obtained by performing the cropping operation on the encrypted image.
[0128] Figure 12b is the image obtained by decrypting the image in Figure 12a .
[0129] Figure 13 is the image obtained by decrypting the image added with the salt and pepper noise.
[0130] Figure 14 is one of the schematic diagrams of the detailed encryption process of the present application. DETAILED DESCRIPTION
[0131] The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all the other embodiments obtained by those skilled in the art without creative labor fall within the scope of protection of the present application.
[0132] As Figure 1 , the present application provides a face image data encryption method based on chaotic tent mapping, comprising:
[0133] S1, setting an initial state of a chaotic system;
[0134] S2, receiving a face image and an initial parameter and generating an initial seed;
[0135] S3, scrambling and diffusing the face image to obtain encrypted images R', G', and B' of three channels R, G, and B;
[0136] S4, respectively encoding R', G', and B' by DNA to obtain vectors R_DNA, G_DNA, and B_DNA;
[0137] S5, respectively confusing R_DNA, R_DNA, and R_DNA to obtain encrypted vectors R'_DNA, G'_DNA, and B'_DNA;
[0138] S6, decoding and merging R'_DNA, G'_DNA, and B'_DNA to obtain an encrypted face image.
[0139] The present application proposes a color face image encryption technology based on chaos theory, which realizes high security encryption effect in a single round of encryption process, and effectively solves the balance problem between efficiency and security in traditional algorithms. The present application first synthesizes three channels of RGB into a one-dimensional data stream, and then sorts the sequence generated by using chaotic tent mapping and segmented linear chaotic mapping to break the correlation between channels. The sorted data stream is divided into three independent sub-streams, and Lorenz chaotic sequence is further applied to fine sorting for each color channel sub-stream. Finally, combined with Chen chaotic sequence, the present application adopts DNA encoding strategy to encode and dynamically confuse each channel pixel, thereby further improving the encryption security of the image at the pixel level.
[0140] Preferably, S1 comprises:
[0141] The chaotic tent mapping system, the segmented linear chaotic mapping system, the Lorenz chaotic mapping system, and the Chen chaotic mapping system are selected as the chaotic system for encrypting the face image;
[0142] The above four types of chaotic systems are respectively initialized:
[0143] The chaotic tent mapping system is initialized, and its basic form is:
[0144]
[0145] x represents a state variable in the mapping, representing the state of the chaotic tent mapping system at a certain time, x nrepresents the state of the chaotic tent map system in the nth iteration, f represents a constant, and s represents a threshold parameter in the chaotic tent map system;
[0146] where f = 0.8, s = 0.5, and the chaotic sequence starting value x0= 0.1, for each pixel value pixels[i-1] in the pixel value array, the corresponding chaotic sequence value x[i-1] is calculated, the chaotic sequence value x[i-1] is used to perform XOR operation with the pixel value pixels[i-1], and the chaotic tent map encrypted pixel value encrypted_arrary[i-1] is obtained; the next value x[i] of the chaotic sequence is updated according to the value of x[i-1], to ensure the dynamics and unpredictability of the sequence; this process is repeated on each element of the pixel value array, so as to realize the chaotic tent map encryption of the entire image to be encrypted;
[0147] The piecewise linear chaotic map system is initialized, and its iterative formula is:
[0148]
[0149] p0represents a threshold parameter in the piecewise linear chaotic map system;
[0150] Through the above iterative formula, a chaotic sequence a i is generated, and the length of the sequence is 3×w×h, where w and h represent the width and height of the image to be encrypted, respectively;
[0151] The chaotic sequence a i is combined with the pixel value list pixels after the first Tent map permutation to form a tuple containing chaotic values and corresponding pixel values, and the chaotic values a i are sorted; after sorting, the pixel values are reorganized to obtain the pixel value list pixels after the second permutation; the encrypted pixel value list is divided into three color channel pixel value lists according to the RGB three color channels;
[0152] The Lorenz chaotic map system is initialized, which is defined by the following three nonlinear differential equations:
[0153]
[0154] The variable y represents the intensity of the convection motion in the fluid, which is used to quantify the amplitude difference between the rising and descending flows in the air pool, the variable z represents the temperature gradient in the fluid, which is used to reflect the temperature difference between the rising and sinking fluids, and the variable q is used to describe the deviation of the temperature inside the air pool from the average temperature of the environment, which is a key factor affecting the dynamic behavior of the system, and the parameters f, g, and r are physical property constants representing the airflow,
[0155] In view of the lack of closed-form analytical expression for the nonlinear system under investigation, the present invention employs an iterative method to perform numerical simulation. Through the iterative process, the numerical solution of the system is obtained, which reveals that under certain parameter selection, i.e., when the control parameter 0 < r < 1, the system exhibits stable fixed-point behavior. As r increases, when the parameter satisfies 1 < r < 24, the system enters a periodic oscillation mode, exhibiting stable periodic solutions. Further increasing the value of r to more than 24, and under the specific parameter settings f = 10, g = 8 / 3, the system dynamically transitions into a chaotic state, where its behavior no longer exhibits predictable periodic patterns, but rather exhibits complex, highly sensitive to initial conditions chaotic characteristics.
[0156] Initialize the initial state y0, z0, q0 of the Lorenz chaotic mapping system, call the Lorenz model function to generate chaotic sequences Y, Z, Q, in order to remove the initial transient effect, discard the first 100 values of each sequence, and then use the chaotic sequences to sort the pixel values of the RGB three channels of the image to be encrypted, enhancing the randomness and unpredictability of the encryption;
[0157] Initialize the Chen chaotic mapping system, which is defined by the following four nonlinear differential equations:
[0158]
[0159] where a, b, c, d, k are system parameters, and u, v, w, x are state variables of the system; when the parameters a = 36, b = 3, c = 28, d = 16 and the parameter k is in the range of -0.7 ≤ k ≤ 0.7, the Chen chaotic system exhibits typical chaotic dynamic behavior and has the ability to generate multiple chaotic sequences; within this parameter interval, the Chen chaotic mapping system can generate four independent chaotic sequences, and the parameter k = 0.2 is selected to construct the Chen chaotic sequence to achieve specific dynamic characteristics and controllability;
[0160] The fourth-order Runge-Kutta numerical method is used to perform an iterative numerical solution process for the nonlinear dynamic system equation set composed of the above four nonlinear differential equations; under given initial conditions and parameter settings, four chaotic sequences U, V, W, X with different dynamic characteristics are generated, and in order to remove the initial transient effect, the first 100 values of each sequence are discarded.
[0161] The chaotic sequence generated by the Chen chaotic system is used to select the subsequent DNA coding rule, and according to the value of the U sequence, the corresponding DNA coding strategy is matched, and the red (R), green (G) and blue (B) color channels of the image are sequentially and accurately coded. The V and W sequences are used to generate the starting position and the number of iterations, which are used for subsequent DNA coding rule selection. Eight different DNA coding rules are applied to encrypt each pixel value multiple times, enhancing the complexity and security of the encryption.
[0162] Preferably, S2 comprises:
[0163] An original color face image I is received, as well as a series of parameter sets for initializing and controlling the chaotic system, including a0, p0, u0, v0, w0, x0, y0, z0, q0, and the initialized four chaotic systems Tent, PWLCM, Lorenz and Chen;
[0164] The SHA-256 generated message digest is divided into eight equal size sub-blocks, denoted as m j , where j = 1, 2,..., 8, each sub-block consists of seven hexadecimal digits, and the hexadecimal representation of the numerical value is converted to a decimal floating point number according to the following formula, whose value range is in the interval [0, 0.0156):
[0165] m j = hex2dec(m1,...,m8) / 2 34
[0166] The second group is directly converted to a floating point value in the range (0, 0.0156):
[0167] d = hex2dec(d) / 2 38
[0168]
[0169] a′0 and p′0 represent the initial seeds of the newly generated piecewise linear chaotic mapping system;
[0170] Assuming that the seed values of the Chen chaotic system are u0, v0, w0, x0, the new initial seeds are generated using the following formula:
[0171]
[0172] For the Lorenz chaotic system, three seeds are also needed, and the calculation method is as follows:
[0173]
[0174] The SHA-256 generates a 64-bit message digest, which is divided into nine sub-blocks, the first eight of which are equal in size, each being a 7-bit hexadecimal number, denoted as m j , and the remaining one is an 8-bit hexadecimal number, denoted as d.
[0175] The CK is a generated public key, as follows:
[0176] CK=a0+p0+u0+v0+w0+x0+y0+z0+q0mod 1.
[0177] Preferably, S3 comprises:
[0178] The face image in the R, G, B three color channels is merged and flattened into a one-dimensional array with a size of 1x3MN, and the chaotic sequence T generated by the chaotic tent map is XOR operated to realize the preliminary encryption of the pixel value:
[0179]
[0180] The PWLCM is iterated 3MN times to obtain a chaotic sequence A, and the pixel value of I is arranged according to the chaotic sequence A to form I' as follows:
[0181] A={a i ,a i+1 ,...,a 3MN}
[0182] [valueA,indexA]=order(A)
[0183] I'=I(indexA)
[0184] order represents the sorting operation; [valueA,indexA] represents the index-value pair, valueA is an element in the chaotic sequence, and indexA is the index corresponding to the element in the pixel array; I() represents the reference of the original pixel array;
[0185] I' is divided into the following three one-dimensional arrays R1, G1, B1 with a size of 1xMN for the third arrangement:
[0186] R1=[I'(1),I'(2),...,I'(MN)]
[0187] G1=[I'(MN+1),I'(MN+2),...,I'(2MN)]
[0188] B1=[I'(2MN+1),I'(2MN+2),...,I'(3MN)]
[0189] A pseudo-random number generation strategy based on initial seeds y'0, z'0, q'0 is used to construct three chaotic sequences Y, Z, Q of length t+MN; these sequences are used to perform chaotic permutation and diffusion operations on the RGB three-pixel array of the face image; to eliminate the transient effect of the initial sequence, a truncation strategy is adopted to discard the first t values in the sequence; then, the remaining sequence is sorted to achieve a specific pixel value permutation mode, as shown in the following formula:
[0190] [valueY,indexY] = order(Y)
[0191] [valueZ,indexZ] = order(Z)
[0192] [valueQ,indexQ] = order(Q)
[0193] In the proposed image encryption framework, the sequences Y, Z, Q generated by chaos theory are sorted to obtain the corresponding index sets indexY, indexZ, indexQ; these index values are used to perform index-based rearrangement operations on the pixel value elements of the R, G, B three-color channels of the image; this operation follows a specific permutation rule to ensure the remapping of pixel values, thereby generating a new arrangement image, as follows:
[0194]
[0195] where f R , f G , f B represent the rearrangement functions applied to the R, G, B three-color channels, respectively; this function permutes the original pixel values according to the indexes generated by the chaotic sequence to obtain the encrypted images R', G', B'.
[0196] Preferably, S4 includes:
[0197] The encryption process of the three-color channels of the face image uses four specific DNA encoding rules for conversion to achieve binary-based pixel value representation;
[0198] The specific DNA encoding rules are as follows:
[0199] 00: rule[0]
[0200] 01: rule[1]
[0201] 10: rule[2]
[0202] 11: rule[3]
[0203] 00, 01, 10, 11 represent four groups of 2-bit binary numbers obtained by intercepting the decimal pixel value converted into 8-bit binary numbers; 8-bit binary numbers are intercepted with 2-bit as the intercept interval to obtain four groups of 2-bit binary numbers;
[0204] For example, for the 8-bit binary number 11100011, the four groups of binary numbers after interception are: 11, 10, 00, 11.
[0205] rule is the DNA encoding rule determined by the sequence U generated in the Chen chaotic mapping;
[0206] By using the Chen hyperchaotic system, combining the initial key vectors u'0, v'0, w'0, x'0, the pseudo-random chaotic sequences U, V, W, X are generated through the iteration process, and the iteration number is set to t+MN×3.
[0207] In order to exclude the transient effect in the initial iteration stage, the truncation strategy is adopted, and the first t elements of the sequence are discarded; then, the elements in the sequence U are equally divided into three sub-vectors, each sub-vector contains M×N elements, as shown in the following formula:
[0208] U1 = [U(1), U(2),..., U(MN)]
[0209] U2 = [U(MN+1), U(MN+2),..., U(2MN)]
[0210] U3 = [U(2MN+1), U(2MN+2),..., U(3MN)]
[0211] Based on the DNA-based encoding framework, the sequence generated by combining the chaotic theory is used to independently encode each color channel of the face image; according to the preset selection rule, the DNA encoding rule is selected, and each DNA base is arranged according to the array size of 1×4MN after being selected:
[0212]
[0213] DNA_Encode_Rule represents the DNA encoding operation.
[0214] Specifically, the preset selection rule is to select the corresponding DNA encoding rule according to the chaotic system parameter interval. The encoding rules corresponding to different parameter intervals and the corresponding decoding rules are shown in Table 1:
[0215] Table 1: Encoding rules and decoding rules corresponding to different chaotic parameter intervals
[0216] Chaos system parameter interval range Encoding rule Decoding rule 0.001-0.05,0.20-0.25,0.40-0.45,0.50-0.55,0.95-0.99 AGCT GTAC 0.05-0.10,0.30-0.35,0.60-0.65,0.070-0.75,0.85-0.90 ACGT TGCA 0.10-0.015,0.35-0.40,0.55-0.60,0.65-0.70,0.80-0.85 GATC CTAG 0.15-0.20,0.25-0.30,0.45-0.50,0.75-0.80,0.90-0.95 CATG TCGA
[0217] When the parameters of the chaotic system fall in the corresponding interval, the corresponding encoding rule and decoding rule on the right of the table are selected.
[0218] Preferably, S5 comprises:
[0219] The XOR operation is performed on the R, G, B color channels of the face image respectively using the DNA encoding rule;
[0220] This process relies on two key deterministic random sequences: one is a sequence constructed based on chaos theory, which is used to guide the selection of the DNA encoding rule; the other is also a sequence from a chaotic system, which is used to determine the iteration period of the XOR operation. The synergistic effect of these two sequences creates a dynamic encryption environment for each channel of the image.
[0221] Using the method described in S4, two chaotic sequences V and W are generated, which are converted into start_RGB and times_RGB used to guide the XOR operation, as shown in the following formula:
[0222] start_RGB = (V x 10 12 ) mod 8
[0223] times_RGB = (W x 10 12 ) mod 8
[0224] start_RGB and times_RGB are decomposed into three sub-arrays, each with a length of MN, corresponding to the R, G, B color channels respectively:
[0225] start_R = [start_RGB(1),..., start_RGB(MN)]
[0226] start_G = [start_RGB(MN+1),..., start_RGB(2MN)]
[0227] start_B = [start_RGB(2MN+1),..., start_RGB(3MN)]
[0228] times_R = [times_RGB(1),..., times_RGB(MN)]
[0229] times_G = [times_RGB(MN+1),..., times_RGB(2MN)]
[0230] times_B = [times_RGB(2MN+1),..., times_RGB(3MN)]
[0231] These sub-arrays are then applied to the permutation and encoding process of the three channel pixels, as described in the following pseudo-code:
[0232] for i = 1 to MN
[0233]
[0234] s = start_R(i)
[0235] for k = 1 to times_R(i)
[0236]
[0237] s = (s + 1) mod 8
[0238] end
[0239] RED(i) = pixel
[0240] end
[0241] The iterative process described in the above pseudo-code will be repeated MN times.
[0242] The resulting sub-arrays are used in the permutation and encoding process of the pixel values of the three color channels R, G, B, in which the R channel pixel values of the original image are converted according to the DNA encoding rules determined by the sequence U generated in the Chen chaotic mapping, combined with the start point start_R and the iteration times times_R generated by the chaotic sequence; this process involves converting the four DNA bases of each pixel value According to the specific permutation logic, the three color channel vectors R'_DNA, G'_DNA, B'_DNA after encryption are generated.
[0243] Preferably, S6 comprises:
[0244] A pseudo-random array X consisting of 3MN elements is used as the key input of the decoding process;
[0245] By randomly sampling the preset DNA rule set, the decoding rules obtained by random sampling are used in the following DNA-Decode-Rule operation to realize the decoding of the three color channels R, G, B. The pseudo-random array is generated in the encoding stage and continues to be used in the decoding process to maintain the consistency of the data conversion process;
[0246] Specifically, the preset DNA rule set includes the four decoding rules in Table 1.
[0247] The vector X is divided into three arrays according to the following formula, as follows:
[0248] X1 = [X(1), X(2),..., X(MN)]
[0249] X2 = [X(MN+1), X(MN+2),..., X(2MN)]
[0250] X3 = [X(2MN+1), X(2MN+2),..., X(3MN)]
[0251] Decoding process:
[0252] Cryptogram_R = DNA_Decode_Rule(R'_DNA, X1)
[0253] Cryptogram_G = DNA_Decode_Rule(G'_DNA, X2)
[0254] Cryptogram_B = DNA_Decode_Rule(B'_DNA, X3)
[0255] DNA-Decode-Rule represents the DNA decoding operation, and the final combined decoded image of the three color channels corresponds to the encrypted face image I'. Cryptogram_R, Cryptogram_G and Cryptogram_B represent the images obtained by decoding in the R, G and B color channels, respectively.
[0256] Figure 14 is a schematic diagram of the detailed encryption process of the application.
[0257] The security test process of the application is as follows:
[0258] The initial values of the piecewise linear chaotic mapping are set as a0=0.123456789010 and p0=0.234578900. The Chen system is configured as u0=0.3456789012, v0=0.245789012, w0=0.4567890124, x0=0.567890124. The Lorenz system is given an initial state as y0=0.678901246, z0=0.7890123456, q0=0.6890123450. The control parameters of the Tent chaotic system are a_tent=0.5 and b_tent=0.5. The control parameters of the Chen system are a=36, b=3, c=28, d=16 and k=0.2. The control parameters of the Loren system are f=10, g=8 / 3 and r=28. The data set uses a Lena_512*512 image and a CelebA-HQ_512*512 face image data set, and a pre-trained face and feature recognition model in the OpenCV library is used to perform a high-precision recognition process on the submitted image data, and the recognition result is clearly displayed in a color image. The results are shown in Figure 2-Figure 5 , Figure 2 Fig. 1 is a schematic diagram of an original Lena image; Figure 3 Fig. 2 is a schematic diagram of a face-recognized Lena image; Figure 4 Fig. 3 is a schematic diagram of a face-encrypted Lena image; Figure 5 Fig. 4 is a schematic diagram of a face-decrypted Lena image. According to the algorithm simulation scheme, the original image can largely restore the local facial attributes of the image, and the face data are subjected to encryption processing, and in terms of visual effect, the information of the decrypted original face image is effectively protected by the designed algorithm.
[0259] Key space analysis:
[0260] The precision of the nine floating-point parameters in the key set γ0=[a'0, p'0, u'0, v'0, w'0, x'0, y'0, z'0, q'0] is 10 16 Therefore, the total key space size is The modern high-performance computer checks that all possible keys with a size of 2 128 require about 10 21 years, and the key space of the present application is much larger than the minimum requirement of 2 128 Therefore, the present application can resist any form of brute force attack.
[0261] Key sensitivity analysis:
[0262] Figure 6 It is shown that a small perturbation (k[0]=k[0]+10-16 k[1] = k[1] + 10 -16 ... k[8] = k[8] + 10 -16 the decrypted image obtained after the above-mentioned adjustment of the key parameters. As can be seen in the illustrated image sequence, even a slight adjustment of the key parameters results in a significant difference between the decrypted image and the original plaintext image. This difference indicates that any attempt to deviate from the correct key will result in a decrypted result that deviates significantly from the expectation, thus making it impossible to recover or extract any valuable information therefrom. This result not only demonstrates the effectiveness of the present application in key protection, but also indicates the good performance of the encryption algorithm designed by the present application in resisting key guessing, because any slight modification of the key will result in the attacker being unable to obtain an effective decryption result.
[0263] Ciphertext distribution analysis:
[0264] When constructing an image encryption algorithm that is resistant to statistical analysis, it is crucial to ensure that the ciphertext distribution of the encrypted image exhibits uniformity. In addition, in order to improve security, the histogram distribution of the encrypted image should be significantly different from the histogram of the original image in statistical characteristics, thereby effectively preventing attacks based on frequency analysis. The histogram of the Lena image is used to illustrate the ciphertext distribution analysis of the present application, Figure 7 shows the histogram distribution of the three color channels of the standard Lena image. Accordingly, Figure 8 presents the corresponding color channel histograms of the Lena image after encryption processing. Through comparative analysis, it can be observed that there is no similarity between the histogram distribution of the encrypted image and the histogram distribution of the original image, and the pixel value distribution histogram of the encrypted image is more uniform than that of the original image, thereby verifying the confusion effect of the encryption algorithm used.
[0265] Adjacent pixel correlation analysis:
[0266] 3000 pairs of adjacent pixels are randomly extracted from the horizontal (Horizontal), vertical (Vertical) and diagonal (Diagonal) directions to implement pixel-level correlation measurement, and a detailed quantitative analysis of the correlation between the original image and the encrypted image is performed. As Figure 9 and Figure 10As shown, the correlation distribution of the original image and the encrypted image reveals significant changes in statistical properties: after applying the encryption technique proposed in the present application, the statistical correlation between image pixels is significantly weakened, approaching the ideal state of no correlation. In addition, Table 2 lists the correlation coefficients between the original image and the encrypted image of adjacent pixel values in detail, and it is clearly observed that the encryption algorithm proposed in this chapter is close to the theoretical minimum value (i.e. 0) in the correlation coefficient, indicating that it exhibits excellent randomness in statistical properties. This result strongly confirms the excellent performance of the present application in resisting statistical analysis attacks. Therefore, it can be concluded that the image encryption algorithm designed in the present application has high security and can significantly reduce the possibility of successful attacks initiated through pixel statistical dependence.
[0267] Table 2 Correlation coefficients of adjacent pixels of original image and encrypted image
[0268]
[0269] Information entropy analysis
[0270] Information entropy is an important indicator of measuring the randomness of information, which evaluates the uncertainty of an image by calculating the pixel distribution of each gray level in each color channel. In an ideal case, if the pixel value distribution is closer to the uniform distribution, the entropy value of the image is higher, indicating that the image has higher randomness and better resistance to statistical attacks. For a color image with 256 intensity values, the ideal entropy value of the red, green and blue color channels should be 8 bits, and a value closer to the ideal entropy value means a more uniform distribution, making it more difficult to predict or attack through statistical analysis. The present application performs information entropy analysis on a color Lena image with a pixel size of 512x512 to quantify the randomness of the image. The obtained information entropy values are recorded in Table 3, and it can be seen that the image encryption method used in the present application effectively increases the randomness of the image, thereby improving its security and making it more difficult to be threatened by statistical attacks.
[0271] Table 3 Information entropy of encrypted image of the present application
[0272] Information entropy The present invention R channel 7.9989 G channel 7.9990 B channel 7.9988
[0273] Randomness analysis
[0274] Gray Value Difference (GVD) is a statistical measure of randomness by comparing the original image and the encrypted image. In the framework of GVD, if the pixel distribution of two images is completely consistent, the GVD value reaches the minimum value 0; relatively, if the pixel distribution of two images is different, the GVD value increases to the maximum value 1, thereby reflecting the difference between images. In this study, the GVD score of the standard test image Lena and its encrypted version is evaluated. Table 4 shows the GVD score of Lena image and its encrypted image in each channel. As can be seen from Table 4, the GVD score of the encrypted image in each channel is close to 1, which indicates that there is a significant visual difference between the original image and the encrypted image, thereby improving the security of the encrypted image.
[0275] Table 4 GVD score
[0276] GVD The present invention R channel 0.9864 G channel 0.9753 B channel 0.9769
[0277] Differential attack analysis
[0278] In the field of cryptography, Eli and Biham proposed two widely recognized test methods, called Non-Overlapping Pixel Change Rate (NPCR) and Unified Average Changing Intensity (UACI), respectively. These two key indicators are used to quantitatively evaluate the performance of the proposed encryption algorithm in resisting differential attacks. These two indicators calculate the score by comparing two ciphertext images with only a single-bit difference, and the ideal values are NPCR = 99.9604% and UACI = 33.4635%, which represent the highest performance standard of encrypted images in resisting differential attacks. The present invention selects the Lena standard test image for encryption, and after encryption, a pixel is randomly selected and changed by 1 bit, thereby generating a contrast image with 1-bit difference to simulate the minimum difference that an attacker may use. These images are then encrypted using the encryption algorithm proposed in the present invention. According to the experimental data shown in Table 5, the performance of the image encryption algorithm proposed in the present invention in the two evaluation indicators of NPCR and UACI has reached a level close to the theoretical optimal value, thereby verifying its advantage in resisting differential attacks.
[0279] Table 5 Evaluation index value of the performance of the encryption algorithm of the present invention in resisting differential attacks
[0280]
[0281] Crop attack analysis
[0282] As a typical attack means, the cropping attack simulates the partial information destruction behavior that the attacker may perform after obtaining the encrypted image, aiming to evaluate the recovery ability of the encryption algorithm when facing incomplete image information. Two groups of experiments are designed to evaluate the robustness and anti-attack ability of the encryption algorithm.
[0283] In the first group of analysis, as shown in Figure 11a , the first time the face encrypted image is randomly removed 80x80 pixel area of red channel, 50x80 pixel area of green channel and 60x50 pixel area of full channel, simulating the partial information destruction that the attacker may perform on the image of specific color channel. The removal operation is realized by setting the pixel value of the selected area to 0, thereby simulating the loss of information. The image obtained by decrypting the encrypted image destroyed in the manner of Figure 11a is shown in Figure 11b .
[0284] As shown in Figure 11c , the second time the image is randomly removed 80x120 pixel area of red channel, 270x80 pixel area of green channel and 60x180 pixel area of full channel. The image obtained by decrypting the encrypted image destroyed in the manner of Figure 11c is shown in Figure 11d .
[0285] As shown in Figure 12a , the second group of analysis further increases the strength of the attack, and a large-scale cropping operation is performed on the encrypted image, and the pixel values of 1 / 16, 1 / 8, 1 / 4 and 1 / 2 of the total area of the image are all removed, to simulate the more aggressive information destruction behavior that the attacker may perform. The experimental results are shown in Figure 12b .
[0286] In Figure 12a , the first row from left to right represents the schematic diagram of the image obtained by removing all pixel values of 1 / 16, 1 / 8, 1 / 4 and 1 / 2 of the total area of the image from left to right, respectively;
[0287] In Figure 12a , the second row from left to right represents the schematic diagram of the image obtained by removing all pixel values of 1 / 16, 1 / 8, 1 / 4 and 1 / 2 of the total area of the image from left to right, respectively;
[0288] In Figure 12b , the first row from left to right represents the schematic diagram of the image obtained by decrypting the image of the first row in Figure 12a from left to right in turn;
[0289] In Figure 12b , the second row from left to right represents the schematic diagram of the image obtained by decrypting the image of the second row in Figure 12aFig. 2 shows a schematic diagram of the decrypted images obtained from left to right in the second row of Fig. 1.
[0290] The experimental results show that at smaller cropping ratios and intensities, the decrypted images can maintain high clarity and details, indicating that the encryption algorithm of the present application is resistant to cropping attacks to some extent. However, as the cropping ratio and intensity increase, the quality of the decrypted images gradually decreases, and some details begin to be lost, indicating that the security of the encryption algorithm may be affected when facing large-scale cropping attacks. However, even in the face of large-scale cropping attacks, the method proposed in the present application can recover most of the key information from the remaining encrypted images, and can identify the main content and structural features in the recovered images. This result further confirms the robustness of the encryption algorithm of the present application, indicating that the present application can minimize information loss and maintain the main visual features and structural integrity of the image when dealing with unauthorized cropping of encrypted images, especially in the face of malicious attacks and accidental damage, ensuring the integrity and usability of the image data.
[0291] Noise attack analysis
[0292] To evaluate the anti-noise attack capability of the system, different levels of salt and pepper noise were added to the encrypted images to simulate channel noise in real-world communication, and the effect of noise density change on the quality of the decrypted images was observed. In the analysis, four different levels of salt and pepper noise density, 0.005, 0.05, 0.1 and 0.5, were selected to process the encrypted images. Subsequently, the decryption algorithm proposed in the present application was used to recover the images containing noise. The results are shown in Fig. 3. Figure 13 As shown in Fig. 3, from left to right, as the noise density increases, the clarity of the decrypted images gradually decreases, and a certain degree of blurring occurs. However, even under the adverse conditions of a noise density of 50%, the encryption framework can still maintain the recognizability of the core content and structural features of the image, indicating that the encryption system of the present application exhibits significant fault tolerance and robustness in the face of high noise interference, thereby verifying its effectiveness in enhancing image security.
[0293] To further quantify and compare, the Peak Signal-to-Noise Ratio (PSNR) was used as an evaluation index to test the PSNR of the decrypted images under different noise densities. Table 6 shows the PSNR results of the encryption algorithm of the present application. The analysis shows that the encryption algorithm of the present application exhibits high PSNR values at each noise density level, thereby verifying the superior performance of the encryption algorithm proposed in the present application in resisting salt and pepper noise attacks.
[0294] Table 6 Evaluation index values of the performance of the encryption algorithm of the present application against noise attacks
[0295] PSNR (dB) The present invention 0.005 31.5973 0.05 21.6589 0.1 18.7934 0.5 12.6397
[0296] The present application addresses the challenges of existing chaotic encryption techniques in terms of security, system complexity, and resistance to known attacks: (1) To enhance security and resist chosen-plaintext attacks, the present application dynamically adjusts the initial conditions and control parameters of chaotic tent map, piecewise linear chaotic map, Lorenz chaotic system, and Chen chaotic system. This dynamic parameter selection mechanism effectively expands the key space, improving the security and reliability of the algorithm. (2) The chaotic system and DNA cryptography strategy designed by the present application achieve improved security without significantly increasing computational cost. Through iteration of chaotic sequences and pixel-level confusion of DNA encoding, the present application significantly improves the complexity of the encryption process while maintaining algorithm efficiency. (3) The present application specifically considers the resistance to specific attacks such as salt and pepper noise. Through the nonlinear characteristics of chaotic systems and the randomness of DNA encoding, the defense mechanism against known attack patterns is enhanced.
[0297] The preferred embodiments of the present application disclosed above are only used to help explain the present application. The preferred embodiments do not describe all the details, nor limit the present application to the specific embodiments described. Obviously, many modifications and variations can be made according to the content of the present application. The present application selects and specifically describes these embodiments in order to better explain the principles and practical applications of the present application, so that those skilled in the art can well understand and utilize the present application. The present application is limited only by the claims and their full scope and equivalents.
Claims
1. A face image data encryption method based on chaotic tent map, characterized in that, Comprise: S1, set the initial state of the chaotic system; S2, receive face image and initialization parameter and generate initial seed; S3, scrambling and diffusion to face image, get R, G, B three channel encryption image R', G', B'; S4, respectively to R', G', B' DNA coding, get vector R_DNA, G_DNA, B_DNA; S5, respectively to R_DNA, R_DNA, R_DNA confusion, get encrypted vector R'_DNA, G'_DNA, B'_DNA; S6, R'_DNA, G'_DNA, B'_DNA decoding and merging, get encrypted face image; S1 comprises: Select chaotic tent map system, piecewise linear chaotic map system, Lorenz chaotic map system and Chen chaotic map system as chaotic system for encrypting face image; Respectively initialize the above four types of chaotic system: Initialize chaotic tent map system, its basic form is: x represents a state variable in the mapping, representing the state of the chaotic tent mapping system at a certain time, x n represents the state of the chaotic tent mapping system in the nth iteration, f represents a constant, and s represents a threshold parameter in the chaotic tent mapping system; Wherein, set f=0.8, s=0.5, chaotic sequence starting value x0=0.1, for each pixel value pixels[i-1] in pixel value array, calculate its corresponding chaotic sequence value x[i-1], use chaotic sequence value x[i-1] and pixel value pixels[i-1] XOR operation, get chaotic tent map encrypted pixel value encrypted_arrary[i-1];According to the value of x[i-1], update the next value x[i] of chaotic sequence, ensure the dynamic and unpredictable of sequence;This process is repeated on each element of pixel value array, so as to realize the chaotic tent map encryption of the whole image to be encrypted; Initialize piecewise linear chaotic map system, its iteration formula is: P0 represents the threshold parameter in piecewise linear chaotic map system; By the above iterative formula, a chaotic sequence a i is generated, which has a length of 3 x w x h, where w and h represent the width and height of the image to be encrypted, respectively; The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic sequence a i The chaotic Initialize Lorenz chaotic map system, which is defined by the following three nonlinear differential equations: Variable y represents the intensity of convection in fluid, which is used to quantify the amplitude difference between the rising and falling air flow in the air pool, variable z represents the temperature gradient in the fluid, which is used to reflect the temperature difference between the rising fluid and the sinking fluid, q user describes the deviation degree of the temperature inside the air pool relative to the average temperature of the environment, parameters f, g, r are physical property constants representing air flow, Initialize the initial state y0, z0, q0 of Lorenz chaotic map system, call Lorenz model function to generate chaotic sequence Y, Z, Q, in order to remove the initial transient effect, discard the first 100 values of each sequence, and then use the chaotic sequence to sort the pixel values of the RGB three channels of the image to be encrypted, enhance the randomness and unpredictability of encryption; Initialize Chen chaotic map system, which is defined by the following four nonlinear differential equations: Wherein, a, b, c, d, k are system parameters, u, v, w, x are state variables of the system; when the parameters a=36, b=3, c=28, d=16 and the parameter k is in the range of-0.7<=k<=0.7, the Chen chaotic system exhibits typical chaotic dynamic behavior and has the ability to generate multiple chaotic sequences; within this parameter interval, the Chen chaotic mapping system can generate four independent chaotic sequences, and the parameter k=0.2 is selected to construct the Chen chaotic sequence to realize specific dynamic characteristics and controllability; The fourth-order Runge-Kutta numerical method is used to perform an iterative numerical solution process on the nonlinear dynamic system equation set composed of the above four nonlinear differential equations; under the given initial conditions and parameter settings, four chaotic sequences U, V, W, X with different dynamic characteristics are generated, and the first 100 values of each sequence are discarded to remove the initial transient effect.
2. The face image data encryption method based on chaotic tent map according to claim 1, wherein S2 It includes: Receiving an original color face image I and a series of parameter sets for chaotic system initialization and control, including a0, p0, u0, v0, w0, x0, y0, z0, q0, and the initialized four chaotic systems Tent, PWLCM, Lorenz and Chen; The SHA-256 generated message digest is split into eight equal size sub-blocks, denoted by m j where j = 1, 2,... 8, each sub-block consists of seven hexadecimal digits, and the hexadecimal represented values are converted to decimal floating point numbers with values in the interval [0, 0.0156) according to the following formula: m j = hex2dec(m1,...,m8) / 2 34 The second group is directly converted into a floating-point value in the range of (0, 0.0156): d = hex2dec(d) / 2 38 a'0 and p'0 represent the initial seeds of the newly generated piecewise linear chaotic mapping system; Assuming that the seed values of the Chen chaotic system are u0, v0, w0, x0, the new initial seeds are generated using the following formula: For the Lorenz chaotic system, three seeds are also needed, and the calculation method is as follows: The SHA-256 generates a 64-bit message digest, which is divided into nine sub-blocks, the first eight of which are equal in size, each being a 7-bit hexadecimal number, denoted as m j , and the remaining one being an 8-bit hexadecimal number, denoted as d. CK is the generated public key, as follows: CK=a0+p0+u0+v0+w0+x0+y0+z0+q0 mod 1.
3. The face image data encryption method based on chaotic tent map according to claim 1, characterized in that, S3 includes: Merge the images of the face image in the R, G, B color channels into a one-dimensional array with a size of 1x3MN, and perform XOR operation with the chaotic sequence T generated by the chaotic tent mapping to realize preliminary encryption of the pixel values: Iterate the PWLCM for 3MN times to obtain the chaotic sequence A, and arrange the pixel values of I according to the chaotic sequence A to form I' as follows: A = {a i ,a i+1 ,...,a 3MN} [valueA, indexA]=order(A) I'=I(indexA) order represents the sorting operation; [valueA, indexA] represents the index-value pair, valueA is an element in the chaotic sequence, and indexA is the index corresponding to this element in the pixel array; I() represents the reference of the original pixel array; Divide I' into the following three one-dimensional arrays R1, G1, B1 with a size of 1xMN for the third arrangement: R1=[I'(1), I'(2),..., I'(MN)] G1=[I'(MN+1), I'(MN+2),..., I'(2MN)] B1=[I'(2MN+1), I'(2MN+2),..., I'(3MN)] A pseudo-random number generation strategy based on the initial seed y'0, z'0, q'0 is used to construct three chaotic sequences Y, Z, Q of length t+MN; these sequences are used to perform chaotic permutation and diffusion operations on the RGB three-pixel array of the face image; to eliminate the transient effect of the initial sequence, a truncation strategy is adopted, and the first t values in the sequence are discarded; then, the remaining sequence is sorted to achieve a specific pixel value permutation mode, as shown in the following formula: [valueY, indexY] = order(Y) [valueZ, indexZ] = order(Z) [valueQ, indexQ] = order(Q) In the proposed image encryption framework, the sequences Y, Z, Q generated by chaos theory are sorted to obtain the corresponding index sets indexY, indexZ, indexQ; using these index values, the pixel value elements of the R, G, B three-color channels of the image are rearranged based on the index; this operation follows a specific permutation rule, ensuring the remapping of pixel values, thereby generating a new arrangement image, as follows: where f R , f G , f B represent the rearrangement functions applied to R, G, B color channels respectively, which permute the original pixel values according to the indexes generated by the chaotic sequence to obtain the encrypted images R', G', B'.
4. The face image data encryption method based on chaotic tent map according to claim 1, wherein S4 Including: The encryption process of the three-color channels of the face image uses four specific DNA encoding rules for conversion to achieve binary-based pixel value representation; The specific DNA encoding rules are as follows: 00: rule[0] 01: rule[1] 10: rule[2] 11: rule[3] 00, 01, 10, 11 represent the 4 groups of 2-bit binary numbers obtained by truncating the 8-bit binary number after converting the decimal pixel value to 8-bit binary; rule is the DNA encoding rule determined by the sequence U generated in the Chen chaos mapping; Using the Chen hyperchaotic system, combined with the initial key vector u'0, v'0, w'0, x'0, a pseudo-random chaotic sequence U, V, W, X is generated through the iteration process, and the iteration number is set to t+MN×3; To eliminate the transient effect of the initial iteration stage, a truncation strategy is adopted, and the first t elements of the sequence are discarded; then, the elements in the sequence U are equally divided into three sub-vectors, each containing M×N elements, as shown in the following formula: U1 = [U(1), U(2),..., U(MN)] U2 = [U(MN+1), U(MN+2),..., U(2MN)] U3 = [U(2MN+1), U(2MN+2),..., U(3MN)] Based on the DNA-based encoding framework, combined with the sequences generated by chaos theory, each color channel of the face image is independently encoded; according to the pre-set selection rule, the DNA encoding rule is selected, and each DNA base is arranged according to the 1×4MN array size: DNA_Encode_Rule represents the DNA encoding operation.
5. The face image data encryption method based on chaotic tent map according to claim 1, characterized in that S5 Including: Using the DNA encoding rule, the XOR operation is performed on the R, G, B three-color channels of the face image respectively; Two chaotic sequences V and W are generated using the method described in S4, which are converted into start_RGB and times_RGB, the starting value sets for guiding the XOR operation, as shown in the following formula: start_RGB = (V x 10 12 ) mod 8 times_RGB = (W x 10 12 ) mod 8 start_RGB and times_RGB are decomposed into three sub-arrays, each with a length of MN, corresponding to the R, G, and B color channels respectively: start_R = [start_RGB(1),..., start_RGB(MN)] start_G = [start_RGB(MN+1),..., start_RGB(2MN)] start_B = [start_RGB(2MN+1),..., start_RGB(3MN)] times_R = [times_RGB(1),..., times_RGB(MN)] times_G = [times_RGB(MN+1),..., times_RGB(2MN)] times_B = [times_RGB(2MN+1),..., times_RGB(3MN)] The obtained sub-array is used for the permutation and encoding process of the pixel values of the three color channels R, G and B. In this process, the pixel values of the R channel of the original image are converted according to the DNA encoding rule determined by the sequence U generated in the Chen chaotic mapping, in combination with the start point start_R and the iteration number times_R generated by the chaotic sequence. This process involves converting the four DNA bases of each pixel value According to the specific permutation logic, the vectors of the three color channels R'_DNA, G'_DNA and B'_DNA after encryption are generated.
6. The face image data encryption method based on chaotic tent map according to claim 1, characterized in that, S6 includes: A pseudo-random array X composed of 3MN elements is used as the key input for the decoding process; Through random sampling of the preset DNA rule set, the randomly sampled decoding rules are used in the following DNA-Decode-Rule operation to decode the R, G, and B color channels. The pseudo-random array is generated in the encoding stage and continues to be used in the decoding process to maintain consistency in the data conversion process; Vector X is divided into three arrays according to the following formula: X1 = [X(1), X(2),..., X(MN)] X2 = [X(MN+1), X(MN+2),..., X(2MN)] X3 = [X(2MN+1), X(2MN+2),..., X(3MN)] Decoding process: Cryptogram_R = DNA_Decode_Rule(R'_DNA, X1) Cryptogram_G = DNA_Decode_Rule(G'_DNA, X2) Cryptogram_B = DNA_Decode_Rule(B'_DNA, X3) DNA-Decode-Rule represents the DNA decoding operation, and the final combined decoded image of the three color channels corresponds to the encrypted face image I'. Cryptogram_R, Cryptogram_G, and Cryptogram_B represent the images obtained by decoding in the R, G, and B color channels respectively.
Citation Information
Patent Citations
An image encryption method based on chaotic tent mapping and DNA decoding
CN109242751A
Efficient batch color image encryption / decryption method
CN112737763A