Fractional number theory transformation image encryption method based on national encryption SM3 and combined chaotic system

By combining the Guoxin SM3 and the combined chaotic system, a key is generated and asymmetric keys are used for image encryption in multi-parameter fractional numerical transformation, the problems of low security and low encryption efficiency in the prior art are solved, and high security and high efficiency image encryption are achieved.

CN119743560BActive Publication Date: 2025-05-13NANJING UNIV OF POSTS & TELECOMM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510239843.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-03
Publication Date
2025-05-13
Estimated Expiration
2045-03-03

AI Technical Summary

Technical Problem

The existing image encryption method based on number theory transformation uses symmetric fractional orders at both ends of number theory transformation. The algorithm is not safe and easy to be brute-forced. The chaotic system is not used when the initial key is generated, resulting in insufficient encryption strength.

Method used

The fractional numerical transform image encryption method based on Guomi SM3 and combined chaotic system is adopted. The hash value is generated through the SM3 algorithm to initialize the chaotic system, combined with the combined chaotic system of Sine and Logistic to generate the key, and the asymmetric key is used for encryption in the multi-parameter fractional criterion transform.

Benefits of technology

It significantly improves the sensitivity and security of the algorithm, enhances its resistance to statistical attacks, differential attacks and sensitivity attacks, improves encryption efficiency, and ensures the hugeness of the key space.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119743560B_ABST
    Figure CN119743560B_ABST
Patent Text Reader

Abstract

The present invention discloses a fractional number theory transformation image encryption method based on the national secret SM3 and combined chaotic system, comprising: obtaining a key based on a combined full chaos map of Sine and Logistic and the national secret SM3 algorithm, then defining a multi-parameter fractional number theory transformation by constructing a number theory transformation feature vector, performing a round of number theory transformation on the plaintext image to obtain an intermediate image, then using Arnold scrambling to scramble the image, and finally performing another round of number theory transformation to obtain a ciphertext image. The present invention combines a multi-parameter fractional number theory transformation, a combined full chaos map based on Sine and Logistic, and the national secret SM3 algorithm, and can be used to protect the privacy security of images during transmission or storage. The technical solution of the present invention overcomes the problems of low encryption speed, low security, and low sensitivity of image encryption technology in the prior art, and has a good application prospect in the field of multimedia security.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of multimedia security and digital image confidentiality, and specifically relates to a fractional number theory transformation image encryption method based on national secret SM3 and combined chaotic system. Background Art

[0002] Image encryption technology is one of the important research directions in the field of information security. With the rapid development of the Internet and digital media, the security of image data has become an increasingly urgent issue. In the past few decades, various technologies dedicated to multimedia security have emerged one after another.

[0003] In recent years, encryption technology combining modern cryptographic algorithms with new mathematical transformation methods has gradually attracted attention. In this context, some studies have focused on the construction of image encryption schemes based on fractional-order transformations. Among them, some image encryption schemes use fractional number-theoretic transformations, as well as complex-valued or real-valued multi-parameter fractional transformations, in which a single fractional order is replaced by a vector with multiple fractional orders as a key. The security of these systems is related to the fractional order of the transformation. However, the existing image encryption methods based on number-theoretic transformations use symmetric fractional orders at both ends of the number-theoretic transformation. The algorithm security is not high and is easily cracked by brute force. In addition, no chaotic system is used or a single chaotic system is used when generating the initial key. However, a single chaotic system often has problems such as too short periodicity and insufficient randomness in image encryption, resulting in insufficient encryption strength.

[0004] On the other hand, as a secure hash algorithm, SM3 has been widely used in data encryption, digital signature and other fields. It has strong anti-collision ability and high defense against cryptographic attacks. Therefore, how to combine SM3 with SM3 to design an image encryption algorithm with both high security and good encryption efficiency is an important research topic at present. Summary of the invention

[0005] The present invention aims to solve one of the technical problems existing in the related art at least to a certain extent.

[0006] One object of the present invention is to provide an image encryption method based on fractional number theory transformation of national encryption SM3 and combined chaotic system, which avoids the defects of poor security, low sensitivity and low encryption efficiency in traditional algorithms by combining multi-parameter fractional number theory transformation with national encryption SM3.

[0007] In order to achieve the above-mentioned purpose, the present invention provides, on the one hand, a method for image encryption based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system, comprising the following steps:

[0008] S100, obtain plaintext image , use SM3 algorithm to get the plaintext image The hash value of is used to calculate the initial value, control parameters and number of iterations of the chaotic system;

[0009] S200, a combined chaotic system based on Sine and Logistic, iterates the chaotic sequence according to the initial value, control parameters and number of iterations, and converts it into a key ;

[0010] S300, the plaintext image Divide into the first sub-image of size s×s , s is the size of the fractional number theory transformation matrix; using the key and , for each first sub-image Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image , and transform the first transformed sub-image Stitch back to the original scale as the first transformed image ;

[0011] S400: first transformed image Apply at least three times Anold scrambling to get the scrambled image ;

[0012] S500: scramble the image Divide into a second sub-image of size s×s ; Use key and , for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image , and the second transformed sub-image Stitch back to the original scale as the second transformed image , The plaintext image Encrypted ciphertext image.

[0013] A further preferred technical solution of the present invention is that the plaintext image obtained by using the SM3 algorithm in step S100 The hash value is a hexadecimal string of length 64, divided into groups of 16 bits, recorded as .

[0014] Preferably, the specific method for calculating the initial value, control parameter and iteration number of the chaotic system in step S100 is:

[0015] The initial value of the chaotic system is The control parameters are and the number of iterations is , the calculation formula of each parameter is:

[0016] ;

[0017] in, This is the remainder operation.

[0018] Preferably, the combined chaotic system of Sine and Logistic described in step S200 is expressed as:

[0019] ;

[0020] in, and are the sine and cosine functions in the real number domain, is the circumference of a circle, represents the absolute value operation, To control the parameters, is the generated chaotic sequence.

[0021] As a preferred embodiment, the key in step S200 The method to obtain is:

[0022] In the iterative chaotic sequence, discard the previous Item, get a length of The chaotic sequence k is divided into groups of s items to obtain the key , is the number of iterations, is the scale of the fractional number theory transformation matrix.

[0023] Preferably, the key is used in step S300 and , for each first sub-image Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image , the specific method is:

[0024] S310, in the finite field GF( ) to select an element ,satisfy ,Right now The fractional order is ,and is a multiple of four, and calculate , ,in is an odd prime number; all the following operations are performed on the modulo Under the meaning;

[0025] S320. Define the sine function and cosine function of the finite field as follows:

[0026] ;

[0027] ;

[0028] At the same time, define the sequence:

[0029] ;

[0030] in ;

[0031] S330, construct even symmetric vector and odd symmetric vectors , expressed as:

[0032] ;

[0033] ;

[0034] and , ;

[0035] S340, construct characteristic basis vector , expressed as:

[0036] ;

[0037] ;

[0038] ;

[0039] ;

[0040] Apply the Schmidt orthogonalization algorithm to the constructed eigenvalue vector to obtain the orthogonal NTT eigenvalue , and use this to construct the matrix ;

[0041] S350, calculate diagonal matrix and , the diagonal elements of D are given by the matrix The inverse of the square norm of the column vector in is formed, The diagonal elements of Given by:

[0042] ;

[0043] S360, define fractional order , , , and obtain the fractional number theory transformation matrix and , apply a multi-parameter fractional number theory transform to the image, that is , where the diagonal matrix The diagonal elements of Given by:

[0044] ;

[0045] For vector No. Components, first calculate ,Right now of times the remainder, and then calculate the result Power.

[0046] As a preferred embodiment, the Anold scrambling described in step S400 is specifically to perform pixel scrambling on the image. Coordinates and The linear transformation of is defined as:

[0047] ;

[0048] Its corresponding inverse transform for:

[0049] ;

[0050] in, , is the number of rows and columns of the image, only square graphics are considered here; This is the remainder operation.

[0051] Preferably, the key is used in step S500 and , for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image , the specific method is:

[0052] S510, in the finite field GF( ) to select an element ,satisfy ,Right now The fractional order is ,and is a multiple of four, and calculate , ,in is an odd prime number;

[0053] S520, define the sine function and cosine function of the finite field respectively:

[0054] ;

[0055] ;

[0056] At the same time, define the sequence:

[0057] ;

[0058] in ;

[0059] S530, construct even symmetric vector and odd symmetric vectors , expressed as:

[0060] ;

[0061] ;

[0062] and , ;

[0063] S540, construct characteristic basis vector , expressed as:

[0064] ;

[0065] ;

[0066] ;

[0067] ;

[0068] Apply the Schmidt orthogonalization algorithm to the constructed eigenvalue vector to obtain the orthogonal NTT eigenvalue , and use this to construct the matrix ;

[0069] S550, calculate diagonal matrix and , the diagonal elements of D are given by the matrix The inverse of the square norm of the column vector in is formed, The diagonal elements of Given by:

[0070] ;

[0071] S560, define fractional order , , , and obtain the fractional number theory transformation matrix and , apply a multi-parameter fractional number theory transform to the image, that is , where the diagonal matrix The diagonal elements of Given by:

[0072] ;

[0073] For vector No. Components, first calculate ,Right now of times the remainder, and then calculate the result Power.

[0074] On the other hand, the present invention provides a non-transitory computer-readable storage medium having computer instructions stored thereon, which enable a computer to execute the above-mentioned fractional number theory transformation image encryption method based on the national encryption SM3 and the combined chaotic system.

[0075] On the other hand, the present invention provides an electronic device, comprising: a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus, and the processor calls the logic instructions in the memory to execute the above-mentioned fractional number theory transformation image encryption method based on the national encryption SM3 and the combined chaotic system.

[0076] On the other hand, the present invention provides a computer program product, which includes a computer program stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer executes the above-mentioned fractional number theory transformation image encryption method based on the national encryption SM3 and the combined chaotic system.

[0077] Beneficial effects: The present invention designs an image encryption method based on multi-parameter fractional number theory transformation, national secret SM3 algorithm, Sine and Logistic chaotic systems. The method uses the national secret SM3 algorithm and the combined chaotic system to generate keys, which significantly improves the sensitivity and security of the algorithm. At the same time, the encryption algorithm is performed in the transformation domain, avoiding floating-point operations and significantly improving the encryption efficiency. In addition, the two rounds of multi-parameter fractional number theory transformations use four different sets of keys, ensuring that it is difficult for attackers to crack the algorithm from the perspective of cryptanalysis.

[0078] The encryption method provided by the present invention has high security and encryption efficiency, a large key space, and strong resistance to statistical attacks, differential attacks, sensitivity attacks, etc., and has broad practical value and application prospects in the field of multimedia security. BRIEF DESCRIPTION OF THE DRAWINGS

[0079] Figure 1This is a flow chart of the image encryption method based on the national encryption SM3 and the fractional number theory transformation of the combined chaotic system of the present invention;

[0080] Figure 2 are the original images of Baboon, Pepper, and Plane in Example 1;

[0081] Figure 3 Encrypted images of Baboon, Pepper, and Plane in Example 1;

[0082] Figure 4 Decrypted images for Baboon, Pepper, and Plane in Example 1;

[0083] Figure 5 is the grayscale histogram of the original images of Baboon, Pepper, and Plane in Example 1;

[0084] Figure 6 is the grayscale histogram of the encrypted images of Baboon, Pepper, and Plane in Example 1;

[0085] Figure 7 The decrypted image corresponding to the Baboon encrypted image decrypted by changing one key bit in Example 1. DETAILED DESCRIPTION

[0086] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings in the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments, and they should not be understood as limitations on the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention. In the description of the present invention, it should be understood that the terms used are only for descriptive purposes and cannot be understood as indicating or implying relative importance.

[0087] Based on the problems existing in traditional encryption methods, if we can combine the national secret SM3, combined chaotic system and multi-parameter fractional number theory transformation, we can design an image encryption algorithm that has both high security and good encryption efficiency. By using the inherent high sensitivity of modular operations to slight modifications of corresponding operands, as well as the stronger randomness and longer periodicity of combined chaotic systems, we can effectively resist various attacks, such as statistical attacks, differential attacks and sensitivity attacks. This results in the technical solution of the present invention. In order to more clearly illustrate the technical solution of this application, the following is combined with Figure 1-Figure 7 The invention describes the image encryption method based on the national encryption SM3 and the fractional number theory transformation of the combined chaotic system.

[0088] Embodiment 1: This embodiment provides a method for image encryption based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system. In general, this embodiment includes the following steps:

[0089] Step 1: Get the plaintext image ;

[0090] Step 2: Use SM3 algorithm to get the plaintext image The hash value of the chaotic system is calculated based on this. , control parameters and the number of iterations ;

[0091] Step 3: Based on the combined chaotic system of Sine and Logistic, the chaotic sequence is iterated according to the initial value, control parameters and number of iterations, and converted into the key. ;

[0092] Step 4: Convert the plaintext image Divide into the first sub-image of size s×s ;

[0093] Step 5: Use the key and , for each first sub-image Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image , and transform the first transformed sub-image Stitch back to the original scale as the first transformed image ;

[0094] Step 6: First transform image Apply at least three times Anold scrambling to get the scrambled image ;

[0095] Step 7: Scramble the image Divide into a second sub-image of size s×s ;

[0096] Step 8: Use the key and , for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image , and the second transformed sub-image Stitch back to the original scale as the second transformed image , The plaintext image Encrypted ciphertext image.

[0097] The following is a more detailed description of the key points of each step based on the three selected images, namely "Plane", "Pepper" and "Baboon". Figure 2 As shown, the size is 256×256.

[0098] In step 2, the plaintext image obtained by SM3 algorithm is first The hash value is a 64-bit hexadecimal string divided into groups of 16 bits, recorded as .

[0099] Calculate the initial value of the chaotic system based on the hash value , control parameters and the number of iterations ; The calculation formula is:

[0100] ;

[0101] in, This is the remainder operation.

[0102] In step 3, the combined chaotic system of Sine and Logistic is expressed as:

[0103] ;

[0104] in, and are the sine and cosine functions in the real number domain, is the circumference of a circle, represents the absolute value operation, To control the parameters, is the generated chaotic sequence.

[0105] The chaotic sequence is obtained by iteration. In this chaotic sequence, the previous Item, get a length of The chaotic sequence k is divided into groups of s items to obtain the key , is the number of iterations, is the scale of the fractional number theory transformation matrix.

[0106] In step 5 and step 8, the multi-parameter fractional number theory transformation method is involved. The method used in the two steps is the same, but the difference is that different keys are used on both sides of the multi-parameter fractional number theory transformation. In step 5, the keys used on both sides of the multi-parameter fractional number theory transformation are and , that is, the divided image Apply fractional number theory transformations , where the fractional order , In step 8, the multi-parameter fractional number theory transformation uses the key and , that is, the divided image Apply fractional number theory transformations , where the fractional order , The following is a detailed explanation of the multi-parameter fractional number theory transformation method using step five as an example.

[0107] Since the selected image size is 256×256, , construct an 8th-order fractional number theory transformation on GF(257), choose ,satisfy , , so we have: , , , ,at the same time , the denominator of the fractional order is 64.

[0108] Construct an even vector as shown below and odd vectors :

[0109] ;

[0110] ;

[0111] ;

[0112] ;

[0113] ;

[0114] ;

[0115] ;

[0116] ;

[0117] And construct the feature basis :

[0118] ;

[0119] ;

[0120] ;

[0121] ;

[0122] ;

[0123] ;

[0124] ;

[0125] ;

[0126] Applying the Gram-Schmidt method to the above eigenbase, we get the orthogonal NTT eigenbase :

[0127] ;

[0128] ;

[0129] ;

[0130] ;

[0131] ;

[0132] ;

[0133] ;

[0134] ;

[0135] Constructing the Matrix , accordingly, we can get the diagonal matrix and :

[0136] ;

[0137] ;

[0138] Using these eigenvectors, we can write the number-theoretic transformation matrix The spectral expansion of is:

[0139] ;

[0140] The following shows the encryption process of the sub-image. For example, To encrypt, b is as follows:

[0141] ;

[0142] Key and They are:

[0143] ;

[0144] ;

[0145] again ,but:

[0146] ;

[0147] ;

[0148] ;

[0149] ;

[0150] Then encrypt the sub-image for:

[0151] ;

[0152] Anold scrambling in step 6 is a pixel scrambling algorithm that scrambles the pixels of the image. Coordinates and The linear transformation of is defined as:

[0153] ;

[0154] Its corresponding inverse transform for:

[0155] ;

[0156] in, , is the number of rows and columns of the image, only square graphics are considered here; This is the remainder operation.

[0157] Finally, the same multi-parameter fractional number theory transformation method as in step 5 is applied, using the key and , for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image , and the second transformed sub-image Stitch back to the original scale as the second transformed image , The plaintext image The encrypted ciphertext image. The encrypted result is as follows Figure 3 As shown in the figure, the encrypted image does not show any information related to the plaintext image, and the encryption effect is good. The decrypted image is shown in the figure. Figure 4As shown, the original image is successfully decrypted and is completely consistent with the plaintext image.

[0158] The encryption method of this embodiment is evaluated and analyzed from the aspects of histogram, key space, key sensitivity, robustness to differential attacks, correlation analysis and information entropy.

[0159] 1. Histogram

[0160] Figure 5 are the histograms corresponding to the three plaintext images, Figure 6 It is the histogram of the corresponding ciphertext image. It can be seen from the figure that the pixels of the original image are closely connected and easily attacked by statistics. However, unlike the histogram of the original image, the histogram of the corresponding encrypted image is close to uniform distribution, hiding the statistical characteristics of the image information, indicating that the encryption method of this embodiment can resist the statistical attack of attackers.

[0161] 2. Key space

[0162] The key space of this embodiment mainly involves the SM3 hash value of the plaintext image, which has a length of 256. Therefore, the key space is . In general, the key space is larger than , its security can be guaranteed, so the key space of this embodiment is much larger than the key space required for security and can resist exhaustive attacks.

[0163] 3. Key sensitivity

[0164] Key sensitivity means that during the encryption and decryption process, a small change in the initial key causes a huge change in the key generated by the key sequence generator or iterative function, thus causing a huge change in the encrypted and decrypted image. One of them decrypts the ciphertext image, such as Figure 7 As shown, it can be seen that by changing only one bit of the key, any part of the original image and any information about the key cannot be accessed, which shows that the encryption method of this embodiment has high key sensitivity.

[0165] 4. Robustness against differential attacks

[0166] The robustness of the encryption method of this embodiment to differential attacks can be calculated by comparing the encrypted versions of the two original images with the minimum difference. Two indicators are used to measure this difference: the pixel change rate (NPCR) and the unified average change intensity (UACI). For the Baboon image, only one pixel is changed. The calculated NPCR and UACI values ​​are shown in Table 1. They are images Baboon, Pepper and Plane respectively. From the table, we can see that the average values ​​of NPCR and UACI are good, close to the ideal values ​​NPCR=99.6094% and UACI=33.4635%, indicating that the encryption method of this embodiment can effectively resist differential attacks.

[0167] Table 1 NPCR and UACI values

[0168]

[0169] 5. Relevance

[0170] Correlation describes the relationship between adjacent pixels in an image. Generally speaking, adjacent pixels in the original image are highly correlated with each other, and this correlation can be measured by calculating the correlation coefficient. The experiment randomly selected 5,000 pixels in each image and calculated their correlation coefficients with adjacent pixels in the horizontal, vertical, and diagonal directions, as shown in Table 2. are the correlation coefficients in the horizontal, vertical and diagonal directions, It is an encrypted version. It can be seen that the correlation coefficient of the original image is close to 1, and the correlation coefficient of the encrypted image is close to 0 within two decimal points, indicating that the encryption method of this embodiment can effectively eliminate the correlation between the pixels of the original image and the encryption effect is good.

[0171] Table 2 Correlation coefficients of adjacent pixels in horizontal, vertical and diagonal directions

[0172]

[0173] 6. Information Entropy

[0174] Information entropy can be used to measure the randomness of an image. If the uniform distribution is better, then it will be more resistant to statistical attacks. In order to avoid the difference between the number of bits used to encode pixels in the original image and the encrypted image, a normalized version of the entropy can be used. The original image ( ) and the corresponding encrypted image ( ) is shown in Table 3. It can be seen that for the encrypted image, the value of the normalized entropy is very close to 1, indicating that each pixel in the image has the same chance to have any possible value, and the encryption effect is good.

[0175] Table 3 Original image ( ) and the corresponding encrypted image ( )

[0176]

[0177] In summary, it can be seen that, based on the existing methods, the present invention proposes an image encryption method based on the national secret SM3 and the fractional number theory transformation of the combined chaotic system, introduces the Sine and Logistic combined chaotic system, and uses asymmetric keys on both sides of the multi-parameter fractional number theory transformation, which has broad application prospects in the field of image encryption.

[0178] Embodiment 2: This embodiment provides a non-transitory computer-readable storage medium, on which computer instructions are stored, the computer instructions causing the computer to execute a fractional number theory transformation image encryption method based on the national encryption SM3 and the combined chaotic system, the method comprising the following steps:

[0179] S100, obtain plaintext image , use SM3 algorithm to get the plaintext image The hash value of is used to calculate the initial value, control parameters and number of iterations of the chaotic system;

[0180] S200, a combined chaotic system based on Sine and Logistic, iterates the chaotic sequence according to the initial value, control parameters and number of iterations, and converts it into a key ;

[0181] S300, the plaintext image Divide into the first sub-image of size s×s , s is the size of the fractional number theory transformation matrix; using the key and , for each first sub-image Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image , and transform the first transformed sub-image Stitch back to the original scale as the first transformed image ;

[0182] S400: first transformed image Apply at least three times Anold scrambling to get the scrambled image ;

[0183] S500: scramble the image Divide into a second sub-image of size s×s ; Use key and , for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image , and the second transformed sub-image Stitch back to the original scale as the second transformed image , The plaintext image Encrypted ciphertext image.

[0184] Embodiment 3: This embodiment provides an electronic device, which may include: a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus. The processor may call the logic instructions in the memory to execute the image encryption method based on the national encryption SM3 and the fractional number theory transformation of the combined chaotic system, and the method includes the following steps:

[0185] S100, obtain plaintext image , use SM3 algorithm to get the plaintext image The hash value of is used to calculate the initial value, control parameters and number of iterations of the chaotic system;

[0186] S200, a combined chaotic system based on Sine and Logistic, iterates the chaotic sequence according to the initial value, control parameters and number of iterations, and converts it into a key ;

[0187] S300, the plaintext image Divide into the first sub-image of size s×s , s is the size of the fractional number theory transformation matrix; using the key and , for each first sub-image Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image , and transform the first transformed sub-image Stitch back to the original scale as the first transformed image ;

[0188] S400: first transformed image Apply at least three times Anold scrambling to get the scrambled image ;

[0189] S500: scramble the image Divide into a second sub-image of size s×s ; Use key and , for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image , and the second transformed sub-image Stitch back to the original scale as the second transformed image , The plaintext image Encrypted ciphertext image.

[0190] In addition, the logic instructions in the above-mentioned memory can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc., which can store program code.

[0191] Embodiment 4: This embodiment provides a computer program product, which includes a computer program. The computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute an image encryption method based on the national encryption SM3 and the fractional number theory transformation of the combined chaotic system. The method includes the following steps:

[0192] S100, obtain plaintext image , use SM3 algorithm to get the plaintext image The hash value of is used to calculate the initial value, control parameters and number of iterations of the chaotic system;

[0193] S200, a combined chaotic system based on Sine and Logistic, iterates the chaotic sequence according to the initial value, control parameters and number of iterations, and converts it into a key ;

[0194] S300, the plaintext image Divide into the first sub-image of size s×s , s is the size of the fractional number theory transformation matrix; using the key and , for each first sub-image Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image , and transform the first transformed sub-image Stitch back to the original scale as the first transformed image ;

[0195] S400: first transformed image Apply at least three times Anold scrambling to get the scrambled image ;

[0196] S500: scramble the image Divide into a second sub-image of size s×s ; Use key and , for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image , and the second transformed sub-image Stitch back to the original scale as the second transformed image , The plaintext image Encrypted ciphertext image.

[0197] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0198] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0199] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A fractional number theory transformation image encryption method based on the national secret SM3 and combined chaotic system, characterized in that: The steps include: S100, obtaining a plaintext image I, using the SM3 algorithm to obtain a hash value of the plaintext image I, and calculating the initial value, control parameter and number of iterations of the chaotic system based on the hash value; S200, based on the combined chaotic system of Sine and Logistic, according to the initial value, control parameter and iteration number obtained in step S100, iterate to obtain the chaotic sequence, and convert it into keys k1, k2, k3, k4; S300, dividing the plaintext image I into a first sub-image I of size s×s k , s is the scale of the fractional number theory transformation matrix; using keys k1 and k2, for each first sub-image I k Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image And the first transformed sub-image Stitch back to the original scale as the first transformed image I 1 ; S400: first transformed image I 1 Apply at least three Anold scramblings to get the scrambled image I 2 ; S500: scramble the image I 2 Divide into a second sub-image of size s×s Using keys k3 and k4, for each second sub-image Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image I′ k , and the second transformed sub-image I′ k The original scale is restored as the second transformed image I′, which is the ciphertext image after the plaintext image I is encrypted.

2. The image encryption method based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system according to claim 1 is characterized in that: The hash value of the plaintext image I obtained by using the SM3 algorithm in step S100 is a hexadecimal string with a length of 64, which is divided into groups of 16 bits and recorded as r1~r 64 .

3. The image encryption method based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system according to claim 2 is characterized in that: The specific method for calculating the initial value, control parameter and iteration number of the chaotic system in step S100 is: Let the initial value of the chaotic system be x0, the control parameter be u and the number of iterations be t. The calculation formulas of the parameters are: Among them, mod is the remainder operation.

4. The image encryption method based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system according to claim 1 is characterized in that: The combined chaotic system of Sine and Logistic described in step S200 is expressed as: sine(i+1)=abs(abs(sin(π*u0*sine(i)*11-sine(i)3*10 4 *sin(sine(i))))-abs(cos(π*u0*sine(i)*11-sine(i)3*10 4 *his(his(i))))); Among them, sin() and cos() are the sine function and cosine function of the real number domain, π is the circumference of a circle, abs() represents the absolute value operation, u i is the control parameter, and sine(i) (i=0,1,…,t-1) is the generated chaotic sequence.

5. The image encryption method based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system according to claim 4 is characterized in that: The method for obtaining keys k1, k2, k3, k4 in step S200 is: In the chaotic sequence obtained by iteration, the first t-4s items are discarded to obtain a chaotic sequence k with a length of 4s. Each s items are grouped together to obtain keys k1, k2, k3, k4, where t is the number of iterations and s is the scale of the fractional number theory transformation matrix.

6. The image encryption method based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system according to claim 1 is characterized in that: In step S300, keys k1 and k2 are used to generate each first sub-image I k Apply the multi-parameter fractional number theory transformation method to obtain the first transformed sub-image The specific method is: S310. Select an element α in the finite field GF(p) that satisfies ord(α)=N=4L, that is, the fractional order of α is N, and N is a multiple of 4, and calculate p is an odd prime number; S320. Define the sine function and cosine function of the finite field as follows: At the same time, define the sequence: Where S ξ (0): =1; S330, construct an even symmetric vector {u j } -L≤j≤L and odd symmetric vector {v j } -L+1≤j≤L-1 , expressed as: u j (n): cos ξ (k)S ξ (3L+j-1+n)S ξ (3L+j-1-n),-L+1≤j≤L; <h2 style=";text-align:left;direction:ltr">v<h2 style=";text-align:left;direction:ltr"> j <h2 style=";text-align:left;direction:ltr"> (n):=sin<h2 style=";text-align:left;direction:ltr"> ξ <h2 style=";text-align:left;direction:ltr"> (k)S<h2 style=";text-align:left;direction:ltr"> ξ <h2 style=";text-align:left;direction:ltr"> (3L+j-1+n)S<h2 style=";text-align:left;direction:ltr"> ξ <h2 style=";text-align:left;direction:ltr"> (3L+j-1-n),-L+1≤j≤L-1; and u -L (n): = 2L, n ∈ I N ; S340, construct characteristic basis vector w,x,y,z, expressed as: w j =u j +U j ,0≤j≤L; x j =v j +iV j ,0≤j≤L-1; y j =-u j+1 +U j+1 ,0≤j≤L-1; z j =-v j+1 +iV j+1 ,0≤j≤L-2; Apply the Schmidt orthogonalization algorithm to the constructed eigenvalue vectors to obtain the orthogonal NTT eigenvalues And construct the matrix S350, calculate the diagonal matrix D and Λ, the diagonal elements of D are given by the matrix The inverse of the square norm of the column vector in , the diagonal element λ of Λ m Given by: l m =(-i) m ,0≤m≤N-1; S360, define fractional order k1, k2∈F p , And get the fractional number theory transformation matrix and Apply a multi-parameter fractional number theory transform to the image, i.e. The diagonal matrix The diagonal elements λ′ m Given by: a′ im is the vector a′ i The mth component of That is, m a times the remainder, and then calculate the result of k i Power.

7. The image encryption method based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system according to claim 1 is characterized in that: The Anold scrambling described in step S400 is specifically a linear transformation of the coordinates x and y of the pixel point (x, y) of the image, and the transformation is defined as: Its corresponding inverse transform Γ -1 for: Among them, 0≤x,y≤L, L is the number of rows and columns of the image; mod is the remainder operation.

8. The image encryption method based on the fractional number theory transformation of the national secret SM3 and the combined chaotic system according to claim 1 is characterized in that: In step S500, keys k3 and k4 are used to generate each second sub-image. Apply multi-parameter fractional number theory transformation to obtain the second transformed sub-image I′ k , the specific method is: S510. Select an element α in the finite field GF(p) that satisfies ord(α)=N=4L, that is, the fractional order of α is N, and N is a multiple of four, and calculate Where p is an odd prime number; S520, define the sine function and cosine function of the finite field respectively: At the same time, define the sequence: Where S ξ (0): =1; S530, construct an even symmetric vector {u j } -L≤j≤L and odd symmetric vector {v M } -L+1≤j≤L-1 , expressed as: u j (n): cos ξ (k)S ξ (3L+j-1+n)S ξ (3L+j-1-n),-L+1≤j≤L; <h2 style=";text-align:left;direction:ltr">v<h2 style=";text-align:left;direction:ltr"> j <h2 style=";text-align:left;direction:ltr"> (n):=sin<h2 style=";text-align:left;direction:ltr"> ξ <h2 style=";text-align:left;direction:ltr"> (k)S<h2 style=";text-align:left;direction:ltr"> ξ <h2 style=";text-align:left;direction:ltr"> (3L+j-1+n)S<h2 style=";text-align:left;direction:ltr"> ξ <h2 style=";text-align:left;direction:ltr"> (3L+j-1-n),-L+1≤j≤L-1; and u -L (n) := 2L, n ∈ I N ; S540, construct characteristic basis vector w,x,y,z, expressed as: w j =u j +U j ,0≤j≤L; x j =v j +iV j ,0≤j≤L-1; y j =-u j+1 +U j+1 ,0≤j≤L-1; z j =-v j+1 +iV j+1 ,0≤j≤L-2; Apply the Schmidt orthogonalization algorithm to the constructed eigenvalue vectors to obtain the orthogonal NTT eigenvalues And construct the matrix S550, calculate the diagonal matrix D and Λ, the diagonal elements of D are given by the matrix The inverse of the square norm of the column vector in , the diagonal element λ of Λ m Given by: l m =(-i) m ,0≤m≤N-1; S560, define fractional order k3, k4∈F p , And get the fractional number theory transformation matrix and Apply a multi-parameter fractional number theory transform to the image, i.e. The diagonal matrix The diagonal elements λ′ m Given by: a′ im is the vector a′ i The mth component of That is, m a times the remainder, and then calculate the result of k i Power.

9. A non-transitory computer-readable storage medium, characterized in that: Computer instructions are stored thereon, and the computer instructions enable the computer to execute the fractional number theory transformation image encryption method based on the national secret SM3 and the combined chaotic system as described in any one of claims 1-8.

10. An electronic device, characterized in that: include: A processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus, and the processor calls the logic instructions in the memory to execute the fractional number theory transformation image encryption method based on the national encryption SM3 and the combined chaotic system as described in any one of claims 1-8.

Citation Information

Patent Citations

  • Color image encryption and decryption method based on multiple-fractional-order chaotic systems

    CN102982499A

  • Image encryption communication algorithm based on two-dimensional lag-complex logistic mapping, and image decryption communication algorithm based on two-dimensional lag-complex logistic mapping

    WO2022077793A1