A Generation Method of Dynamic S-Box Based on Chaos and Irreducible Polynomials

By adopting a dynamic S-box generation method based on chaotic mapping and irreducible polynomials in the image encryption system, the problem of time efficiency and security imbalance in the prior art is solved, and efficient and secure S-box generation is achieved.

CN116192356BActive Publication Date: 2025-06-17CHONGQING UNIV OF POSTS & TELECOMM
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111424525.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-26
Publication Date
2025-06-17
Estimated Expiration
2041-11-26

AI Technical Summary

Technical Problem

The prior art is difficult to achieve a good balance between time efficiency and security in an image encryption system, resulting in slow encryption speed or insufficient security.

Method used

A dynamic S-box generation method based on chaotic mapping and irreducible polynomials is adopted to generate pseudo-random numbers through Logistic chaotic mapping, and the S-box generation formula is reconstructed in combination with Arnold two-dimensional discrete chaotic mapping, and the calculation formula is optimized to improve the S-box generation speed.

Benefits of technology

It realizes a balance between the time efficiency and security requirements of the image encryption system while improving the S-box generation speed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116192356B_ABST
    Figure CN116192356B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for generating a dynamic S-box based on chaotic mapping and irreducible polynomials, which relates to the fields of chaotic cryptography and image encryption. The method specifically includes: S1: Serializing the plaintext; S2: Selecting a number of irreducible polynomials over the GF(2<supgt;^8< / supgt;) field, and using the iterative results of the Logistic chaotic mapping to select irreducible polynomials to participate in the calculation; Modifying the model formula of the Arnold mapping into a one-dimensional formula, optimizing the one-dimensional formula to obtain the S-box generation formula, and combining the selected irreducible polynomials with the S-box generation formula to generate the S-box; S3: Generating an extended key with the S-box; S4: Encrypting the plaintext sequence with the key; S5: Replacing the encrypted sequence with the S-box; S6: Changing the positions of the ciphertext sequence; S7: Iterating the operations of S2-S6 for 15 rounds. The dynamic S-box generated by the present invention can meet the requirements of the block encryption algorithm for the S-box, especially the performance requirements and time requirements of the image encryption algorithm for the S-box.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the fields of chaotic dynamic S-boxes and image encryption. It relates to a method for generating a dynamic S-box based on chaos and irreducible polynomials. Background Art

[0002] Cryptographic encryption systems are mainly divided into two categories: stream cipher encryption and block cipher encryption. Stream cipher encryption means encrypting 1 bit of data at a time. Block encryption means encrypting several bits of data at a time. As the only non-linear component of the block encryption algorithm, the performance of the S-box largely determines the security level of the entire algorithm and is widely used in image encryption algorithms. An excellent S-box has characteristics such as high non-linearity, low differential uniformity, a strict avalanche criterion infinitely close to 0.5, and satisfying the bit independence criterion between outputs. How to construct an excellent dynamic S-box is a problem faced by researchers and is also a very attractive field in the field of cryptography.

[0003] Chaotic systems have excellent cryptographic characteristics, such as: sensitivity to initial values, non-linearity, pseudo-randomness, etc., and are not only widely used in the construction of dynamic S-boxes, but also in image encryption algorithms. Simply using a chaotic map to complete the image encryption algorithm can encrypt multiple images in a very short time, but the complexity of the encrypted images is low and they are vulnerable to known plaintext attacks; using S-box substitution to complete the image encryption algorithm can resist known plaintext attacks, but the time consumption for generating the S-box is too large, and the security level of the encryption algorithm completely depends on the performance of the generated S-box. The S-box generated by the present invention meets both the time requirements for generating the S-box in the image encryption system and the requirements for the performance of the S-box. Summary of the Invention

[0004] In view of this, the purpose of the present invention is to provide a method for generating a dynamic S-box based on chaotic mapping and irreducible polynomials to achieve a good balance between time efficiency and security.

[0005] To achieve the above object, the present invention provides the following technical solutions:

[0006] A method for generating a dynamic S-box based on chaos and irreducible polynomials, specifically including the following steps:

[0007] S1: Randomly select 15 formulas from among numerous irreducible polynomials in the GF(2^ 8 ) field. Specifically as shown in Table 2.;

[0008] Table 2 Irreducible polynomials in the GF(2^ 8 ) field

[0009]

[0010]

[0011] S2: Generate pseudo-random numbers using the Logistic chaotic map; and iterate it 100 times to avoid the influence of the initial value;

[0012] S3: Iterate the Logistic chaotic map once, set U = 14 and convert it to a positive integer p;

[0013] S4: Select the irreducible polynomial corresponding to the serial number p from Table 2 to participate in the calculation;

[0014] S5: Select the Arnold two-dimensional discrete chaotic map to reconstruct the S-box generation formula, and its model formula is as follows:

[0015]

[0016] S6: Modify the parameter matrix of the Arnold map, and set c = c' = 1, r' = r(t), r = t. Transpose the parameter matrix in the following way:

[0017]

[0018] S7: According to the content of S6, generate the following new formula:

[0019]

[0020] Furthermore, convert the said formula into a one-dimensional formula:

[0021]

[0022] Furthermore, optimize the calculation formula of the S-box generation formula as:

[0023]

[0024] where t is the input value, and a, b, c are generated by the Logistic chaotic map.

[0025] The beneficial effect of the present invention is that: the method of the present invention realizes a good balance between efficiency and security while improving the speed of generating the S-box.

[0026] Other advantages, objectives and features of the present invention will be described to some extent in the subsequent specification, and to some extent, will be obvious to those skilled in the art based on the study of the following text, or can be taught from the practice of the present invention. The objectives and other advantages of the present invention can be achieved and obtained through the following specification. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] To make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be described in detail below with reference to the accompanying drawings, where:

[0028] Figure 1 is the flowchart of the image encryption method described in the present invention;

[0029] Figure 2 is the flowchart of generating a dynamic S-box described in the present invention;

[0030] Figure 3 is the schematic diagram of the minimum nonlinearity of 1000 dynamic S-boxes;

[0031] Figure 4 is the schematic diagram of the maximum differential uniformity of 1000 dynamic S-boxes;

[0032] Figure 5 is the schematic diagram of the strict avalanche criterion of 1000 dynamic S-boxes;

[0033] Figure 6 is the schematic diagram of the linear approximation probability of 1000 dynamic S-boxes. Specific Embodiments

[0034] The following uses specific specific examples to illustrate the embodiments of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the diagrams provided in the following embodiments only illustrate the basic concept of the present invention schematically, and the following embodiments and the features in the embodiments can be combined with each other without conflict.

[0035] Please refer to Figures 1 to 2 , Figure 1 which is the image encryption method described in the present invention, and the specific steps are as follows:

[0036] S1: Serialize the plaintext. Input the plaintext image, and store the pixel values of the M×N plaintext image in a one-dimensional array M with a length of M×N in row order;

[0037] S2: Generate the S-box.

[0038] S21: Initialize the parameters μ = 3.99999, z n = 0.32456, and use the Logistic chaotic map to generate the selection serial number p of the irreducible polynomial, and the parameters a, b, c in the Arnold formula:

[0039] z n+1 = μz n (1 - zn )

[0040] Where: μ is the control parameter of the chaotic system, and z n ∈(0, 1) is the state value of the chaotic system, and the chaotic map is iterated (100 + 10*i) times to eliminate the influence of the initial value. Each iteration of the chaotic map generates a new state value z n+1 , and z n+1 is converted into a positive integer p ∈ [0,..., 14] using the following formula:

[0041]

[0042] where U = 14.

[0043] S22: Select an irreducible polynomial over the Galois field GF(2^ 8 ) according to p:

[0044] S23: Reconstruct the model formula of the Arnold two-dimensional discrete chaotic map into a one-dimensional formula, that is, the S-box generation formula, as follows:

[0045]

[0046] S24: Combine the S-box generation formula with the irreducible polynomial over the Galois field GF(2^ 8 ) to generate the S-box B.

[0047] S3: Set U = 255, and iterate the Logistic chaotic map once. Convert the generated parameter z n+1 into a positive integer k, and select the number with subscript k in the S-box B as the extended secret key K.

[0048] S4: Perform an exclusive OR operation between the extended secret key K and each number in the one-dimensional array M to generate the encrypted array M1.

[0049] S5: Use the generated S-box B to replace the values in the encrypted array M1 with the values in the S-box B to generate the replacement array M2.

[0050] S6: First, convert the one-dimensional array M2 into a 16×16 two-dimensional array M2. Select the two-dimensional chaotic map - Arnold map to change the positions of the data in M2 to generate the scrambled array M3, and then convert the two-dimensional array M3 back into a one-dimensional array M3. Its model formula is as follows:

[0051]

[0052] where r, c represent the positions of the original pixel points in the image, and r′, c′ represent the positions of the original pixel points after being permuted by the Arnold map. N represents the size of the image, and a, b are both non-zero positive integers.

[0053] S7: Change the value of i, set i = i + 1. Determine whether i is less than 15. If it is less than 15, assign M3 to M and return to step 2. Otherwise, output the ciphertext image M3.

[0054] Example:

[0055] The generation method of the dynamic S-box based on chaos and irreducible polynomials described in the present invention, the performance analysis specifically includes the following:

[0056] Step 1: Algorithm performance analysis:

[0057] The algorithm in this paper is completed on a PC. The operating system of the PC is Windows 10 64b, the CPU is Intel Core TM i7-9700@3.00GHz, the RAM is 16GB, and it is tested with the PyCharm 2019 programming software. Experiments show that the average time consumed by this algorithm to generate 1000 S-boxes is: 0.6253 ms, and the average time consumed to update one S-box is: 0.6875 ms. It can be seen that the generation speed of the S-box in this paper meets the requirements of encryption.

[0058] Step 2: S-box performance analysis:

[0059] Perform cryptographic performance analysis on the generated dynamic S-box, and it is easy to verify that the generated S-box satisfies the bijective property.

[0060] (1) Nonlinearity

[0061] The nonlinearity index is one of the important indicators to evaluate the performance of the S-box. As an indispensable nonlinear component in the block encryption algorithm, the size of the nonlinearity of the S-box largely determines the ability of the algorithm to resist linear attacks. Figure 3 Shows the minimum nonlinearity of 1000 dynamic S-boxes. It can be seen from the figure that the minimum nonlinearity of the S-box in this paper is 112.

[0062] (2) Differential uniformity

[0063] The ability of the S-box to resist differential attacks is represented by the differential uniformity. The lower the value of the differential uniformity, the stronger the ability of the S-box to resist attacks. Figure 4 Shows the maximum differential uniformity of 1000 dynamic S-boxes. It can be seen from the figure that the worst differential uniformity of the S-box in this paper is only 6, and the best is 4.

[0064] (3) Strict avalanche criterion

[0065] To comprehensively analyze the performance of the S-box in this paper, the strict avalanche criterion of the S-box is also calculated. By calculating the dependence matrix of the S-box and using the dependence matrix to determine whether the S-box satisfies the strict avalanche criterion, the results are as Figure 5 shown. It can be seen from the figure that the strict avalanche criterion of the S-box in this paper is infinitely close to 0.5, strictly meeting the requirements of the encryption index.

[0066] (4) Linear approximation probability

[0067] The linear approximation probability is a performance index for judging the ability of the S-box to resist linear attacks. The linear approximation probability of the S-box in this paper is 0.625, which can effectively resist linear attacks. Figure 6 The linear approximation probabilities of 1000 dynamic S-boxes are shown.

[0068] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit them. Although the present invention has been described in detail with reference to the preferred embodiments, those of ordinary skill in the art should understand that the technical solutions of the present invention can be modified or equivalently replaced without departing from the purpose and scope of the present technical solution, and they should all be covered by the scope of the claims of the present invention.

Claims

1. A method for generating a dynamic S-box based on chaotic mapping and irreducible polynomials, characterized in that, The method specifically includes the following steps: S1: Plaintext serialization. Input the plaintext image, and store the pixel values of the M×N plaintext image in a one-dimensional array M of length M×N in row order; S2: Generate the S-box; S21: Initialize the parameters μ = 3.99999, z n = 0.32456, and use the Logistic chaotic map to generate the selection serial number p of the irreducible polynomial, and the parameters a, b, c in the Arnold formula: z n+1 = μz n (1 - z n ) where: μ is the control parameter of the chaotic system, and z n ∈(0, 1) is the state value of the chaotic system, and the chaotic map is iterated (100 + 10*i) times to eliminate the influence of the initial value; each iteration of the chaotic map generates a new state value z n+1 , and z n+1 is converted into a positive integer p ∈ [0,..., 14] using the following formula: where U = 14; S22: Select an irreducible polynomial over the Galois field GF(2 ^8 ) according to p: Table 1 Irreducible polynomials over the GF(2 ^8 ) field S23: Reconstruct the model formula of the Arnold two-dimensional discrete chaotic map into a one-dimensional formula, that is, the S-box generation formula, as follows: S24: Generate S-box B by combining the S-box generation method with an irreducible polynomial over the Galois field GF(2^ 8 ); S3: Set U = 255, iterate the Logistic map once to generate parameter z n+1 and convert it to a positive integer k, select the number with subscript k in S-box B as the extended secret key K; S4: Perform an exclusive OR operation on the extended secret key K and each number in the one-dimensional array M to generate the encrypted array M1; S5: Use the generated S-box B to replace the values in the encrypted array M1 with the values in the S-box B to generate the replacement array M2; S6: First, convert the one-dimensional array M2 into a 16×16 two-dimensional array M2. Select the two-dimensional chaotic map Arnold map to change the positions of the data in the array M2 to generate the confusion array M3, and then convert the two-dimensional array M3 into a one-dimensional array M3. Its model formula is as follows: where r and c represent the positions of the original pixel points in the image, and r′ and c′ represent the positions of the original pixel points after being permuted by the Arnold map; N represents the size of the image, and a and b are both non-zero positive integers; S7: Change the value of i, set i = i + 1; determine whether i is less than 15. If it is less than 15, assign M3 to M and return to step 2. Otherwise, output the ciphertext image M3.