Image encryption method combining S box and hyperchaotic integrated system

By combining the image encryption method of S-box and hyperchaotic integrated system, the problem of insufficient optimization of a single chaotic system and S-box is solved, and image encryption with high security and attack resistance is achieved to meet the needs of future information security.

CN120498632APending Publication Date: 2025-08-15GUILIN UNIV OF ELECTRONIC TECH
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510617626.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-13
Publication Date
2025-08-15

AI Technical Summary

Technical Problem

In the existing image encryption technology, the key sequence generated by a single chaotic system is low in complexity, the S-box is not fully optimized, it is difficult to resist differential attacks and algebraic attacks, and the lack of a hierarchical diffusion mechanism, which cannot meet the high-intensity anti-cracking needs.

Method used

The image encryption method combined with S box and super chaotic integrated system is adopted to search the S box through particle swarm optimization algorithm, and high-dimensional chaotic sequences are generated by combining the super chaotic Chen, Lorenz and Henon systems, and global mixing is achieved through the key matrix XOR operation, enhancing the complexity and randomness of the key space.

Benefits of technology

It improves the security of image encryption algorithms, enhances the resistance to statistical analysis and local attacks, and meets the high-demand image information security needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120498632A_ABST
    Figure CN120498632A_ABST
Patent Text Reader

Abstract

The invention discloses an image encryption method combining an S box and a hyper-chaotic integrated system because of continuous development of an attack technology and increasing requirements on the anti-attack capability of an encryption algorithm. Firstly, a particle swarm optimization algorithm is designed based on a fitness function considering multiple safety indexes and an S-type function inertia weight strategy to search for an S box. And the searched S box has excellent performance in the aspects of nonlinearity, difference uniformity, algebraic times, strict avalanche criterion and the like. Furthermore, a hyperchaos Chen system is taken as a core, and a hyperchaos integrated system is constructed by combining a Lorenz system and a Henon system. A three-order diffusion mechanism is adopted in the encryption process, and an S box obtained through searching of a particle swarm optimization algorithm and a chaotic sequence generated by a hyperchaotic integrated system are fully fused in first two-order diffusion so as to improve the safety and randomness of an encryption algorithm. The encryption algorithm has strong anti-noise and anti-cutting capabilities for encryption. The image encryption algorithm combining the S box and the hyper-chaos integrated system provided by the invention has relatively high security and is suitable for the field of image encryption with high requirements.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical fields of cryptography, chaos theory and application, image processing, optimization algorithm, etc., and specifically designs an image encryption method combining an S-box and a hyperchaotic integrated system. Background Art

[0002] With the rapid evolution of information technology, image data has become increasingly valuable in a variety of key scenarios, including communications, medical diagnosis, military reconnaissance, and intelligent surveillance. However, due to its inherent redundancy and strong inter-pixel correlation, image data is highly susceptible to unauthorized theft and tampering during network transmission and remote storage, seriously compromising the confidentiality and integrity of information. Therefore, ensuring the confidentiality of image content has become a critical issue in data security.

[0003] Among numerous protection technologies, image encryption, as a means of converting visual information into an unreadable form, effectively prevents unauthorized access and malicious modification. Benefiting from the development of nonlinear dynamics and cryptographic mechanisms, encryption strategies based on chaotic dynamics have been widely used in visual data protection due to their excellent initial value sensitivity, trajectory unpredictability, and parameter controllability. These strategies have attracted considerable attention from researchers.

[0004] Targeting this technical approach, researchers have continuously refined the design of chaotic systems. By introducing fractional-order modeling, constructing piecewise polynomial mappings, or fusing multiple chaotic structures to form more complex system dynamics, they have significantly increased the complexity and randomness of encryption sequences. These methods not only expand the manifestations of chaotic behavior but also enhance the disruption and diffusion mechanisms, thereby improving the security of the overall encryption process.

[0005] Despite this, relying solely on the aforementioned dynamic mechanisms still struggles to meet higher-level attack defense requirements. In the encryption process, the nonlinear transformation unit (S-box) is a core component that primarily performs pixel-level numerical perturbations and plays a crucial role in improving resistance to statistical analysis and differential attacks. Currently, most solutions directly use chaotic maps to generate S-box elements, but without systematically testing their ability to meet cryptographic requirements, ensuring their robustness in high-intensity application scenarios.

[0006] To optimize the construction of such alternative structures, some recent studies have introduced heuristic search algorithms to discover high-performing S-box instances in large parameter spaces. Among them, the particle swarm optimization algorithm, due to its collaborative mechanism and efficient search, has demonstrated promising results in nonlinear replacement design. Furthermore, by incorporating chaotic initialization, local search strategies, and weight adjustment mechanisms, these algorithms have made significant progress in improving search quality and escaping local optima, resulting in generated structures with superior statistical and algebraic properties.

[0007] On the other hand, integrating chaotic systems of different dimensions to enhance the complexity of key sequences has also been a research direction that has yielded positive results in recent years. By coupling one-dimensional, two-dimensional, and even higher-dimensional dynamical models, not only does this broaden the state space, but it also significantly increases the unpredictability of the output sequence, providing a more robust foundation for the overall encryption system. If optimized S-boxes and high-dimensional chaotic dynamical models can be synergistically utilized within the scrambling mechanism, it is expected to achieve even higher levels of information masking and anti-decryption capabilities.

[0008] In summary, current image data protection technology still faces bottlenecks in two key areas: first, the performance optimization of nonlinear substitution structures is insufficient, and second, deep integration with complex chaotic systems needs to be strengthened. Therefore, it is urgent to develop an image encryption scheme that synergistically integrates multidimensional chaotic structures with the highly secure S-box. This scheme can further enhance confidentiality, interference resistance, and overall system stability, meeting the growing demand for image information security in the future. Summary of the Invention

[0009] 1. Technical Problems Solved

[0010] In real-world image encryption scenarios, the continuous development of attack technologies has led to a proliferation of new techniques. However, traditional methods rely on a single chaotic system to generate key sequences, which suffers from issues such as low complexity of chaotic behavior and a limited key space. This makes the encryption algorithm vulnerable to differential attacks, algebraic attacks, and statistical analysis. Furthermore, the S-boxes used in existing technologies are often generated through simple chaotic mappings, without systematic optimization of key security metrics such as nonlinearity, differential uniformity, and algebraic order. This results in insufficient obfuscation capabilities and makes it difficult to resist reverse engineering attacks. Although some studies have attempted to improve randomness by combining multiple chaotic systems, these efforts have not effectively resolved the compatibility conflict between dynamic encryption requirements and static algorithm parameters, and lack a layered diffusion mechanism to counter localized attacks.

[0011] To address these issues, this paper proposes an image encryption method based on a hyperchaotic integrated system and dynamic S-boxes. Building on the traditional single chaotic system and S-box, this method combines the S-box and hyperchaotic integrated system. This method enhances the complexity and randomness of the key space through parameter coupling and sequence superposition. Combined with the key matrix XOR operation, it achieves global mixing, resists statistical analysis and local attacks, and thus improves the security of the image encryption algorithm.

[0012] 2. Technical Solution

[0013] Step 1: Obtain grayscale images of baboon and peppers from the publicly available CVG-UGR image database. Grayscale images are relatively simple, with each pixel containing only a single intensity value. This allows us to focus on the core properties of the encryption algorithm while reducing the computational burden associated with increased image complexity.

[0014] Step 2: First, initialize the S-box population. For each particle, use the custom S-box to initialize the first particle. For the remaining particles, use the chaotic map to generate random S-boxes.

[0015] Step 3. Then define the calculation method of particle g_best and p_best, set the fitness function to find the optimal balance by adjusting the weights of nonlinearity, differential uniformity and algebraic number, and then obtain an S-box with better security.

[0016] Step 4. Then apply the particle swarm optimization algorithm of the S-type function inertia weight strategy to the S-box search problem to coordinate the global and local search capabilities of the algorithm, and iteratively obtain the optimal S-box g_best and the suboptimal S-box second_best.

[0017] Step 5: Convert the input image to grayscale and calculate its hash value using the SHA-512 algorithm. This hash value is then used to generate a second hash value. These two hash values are concatenated to form a 128-bit master key K. Each 12 elements in K are XORed together, and the result is XORed with the average of these 12 elements. Finally, each result is divided by 512 to generate nine sets of initial keys.

[0018] Step 6: Use the first four sets of keys as initial values for the hyperchaotic Chen system to generate chaotic sequence I. The next three sets of keys are used as initial values for the Lorenz system to generate chaotic sequence II. The final two sets are used as initial values for the Henon chaotic system to generate chaotic sequences, resulting in four chaotic sequences: X, Y, Z, and W. Adding these chaotic sequences together and taking the result modulo 256 further enhances their randomness, yielding a more unpredictable chaotic sequence, Q.

[0019] Step 7: Assume the image is of M×N shape. Use the Arnold transform to scramble the image pixels, disrupting the original image's pixel arrangement. Then perform S-box diffusion on the scrambled image's pixel values. Use the S-box obtained in step 1 as a nonlinear replacement in encryption. Then perform an XOR operation on each pixel value in the image with the S-box value.

[0020] Step 8: Diffusion is performed pixel by pixel. Each pixel value is encrypted using the chaotic sequence Q and S-box. The hash value generated by the SHA512 algorithm on the master key K is used as the seed to initialize the pseudo-random number generator, generate the M×N random matrix img_key, and perform the XOR operation on T and img_key.

[0021] 3. Beneficial Effects

[0022] 1. Compared with traditional S-boxes, a particle swarm optimization algorithm was designed to search for S-boxes using a fitness function and an S-shaped function inertia weight strategy that takes into account multiple safety indicators. The resulting S-boxes exhibit excellent performance in terms of nonlinearity, differential uniformity, algebraic degree, and strict avalanche criterion.

[0023] 2. Integrate the hyperchaotic Chen system (4D), Lorenz system (3D) and Henon system (2D), generate high-dimensional chaotic sequences through parameter coupling and sequence superposition, and significantly expand the key space.

[0024] 3. Remove the first 1000 items of the chaotic sequence to eliminate the initial transient effect, ensure the unpredictability of the sequence, and enhance anti-predictability: the generated chaotic sequence passes the NIST randomness test and meets the cryptographic randomness standards.

[0025] 4. Single-stage diffusion cannot completely destroy the statistical features of the image, and has weak anti-noise and cropping capabilities. The key matrix (img_key) is used to perform a global XOR operation to eliminate residual statistical features and encrypt the image information entropy. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] Figure 1 Model framework diagram of the specific application of the present invention in multi-behavior recommendation DETAILED DESCRIPTION

[0027] In order to make the objectives, technical solutions and advantages of the present invention more clear, the present invention is further described in detail below with reference to specific examples and accompanying drawings.

[0028] The present invention is based on the following overall process: Figure 1 The specific steps include:

[0029] Step 1: Download the publicly available image dataset CVG-UGRimagedatabase and obtain the grayscale images baboon and peppers from the dataset. The baboon image contains rich texture details, which effectively tests the algorithm's ability to obfuscate high-frequency information. The peppers image has smooth gradients, which is suitable for evaluating the diffusion mechanism's coverage of low-frequency features. By focusing on single-channel data, the performance of S-box substitution and chaotic sequence generation can be more accurately quantified.

[0030] Step 2: In the image encryption scenario, the encryption algorithm is implemented through a chaotic system. Due to the continuous development of attack technology, the traditional method of using only a single chaotic system for image encryption can no longer provide sufficient security and randomness. Therefore, we use an image encryption method that combines S-boxes with hyperchaotic integrated systems to improve the anti-attack ability and robustness of the encryption algorithm. First, we use a 2-bit length image encryption algorithm. 8 The empty array S is used to store the function value of the S box. Generate pseudo-random numbers through the Logistic map to fill it:

[0031] z n+1 =sz n (1-z n )

[0032] Among them, z n is the value of the nth iteration, z n+1 is the next iteration value, s is the parameter that controls the mapping behavior, and s is set to 3.999999.

[0033] Step 3: Use the three major indicators of nonlinearity, differential uniformity, and algebraic degree, and balance the impact of different characteristics on the security of the S-box by weighing multiple design goals:

[0034]

[0035] Among them, N s represents the nonlinearity of the S-box, δ s and d s They represent the differential uniformity and algebraic degree of the S-box respectively.

[0036] By combining four different conditions, the algorithm can assign different weights to different S-box characteristics and optimize their performance. In each case, the fitness function adjusts the weights of nonlinearity, differential uniformity, and algebraic order to find the optimal balance and obtain an S-box with better security.

[0037] Step 4: To avoid falling into a local optimum too early, in the later stages, gradually reducing the inertia weight can enhance the ability of local search, thereby better converging to the global optimal solution or a better solution. We use the S-type function inertia weight strategy, and its inertia weight formula is as follows:

[0038]

[0039] Where t is the number of iterations. Under this strategy, the inertia weight shows an inverted S-shaped decreasing trend throughout the iteration process. This allows the particle swarm optimization algorithm to maintain a large inertia weight in the early stages of the iteration, avoiding prematurely falling into the local optimum; while in the later stages of the iteration, the inertia weight can be kept at a small value, thereby enhancing the algorithm's local search capability.

[0040] Step 5: Convert the input image into a grayscale image and calculate the hash value of the image using the SHA-512 algorithm. Use this hash value to generate a second hash value, and concatenate the two hash values to obtain a master key K with a length of 128. Let K = (k1, k2, ..., k 128 ), perform an XOR operation on every 12 elements in K, perform an XOR operation on the calculated result with the average value of these 12 elements, and finally divide each set of results by 512 to generate 9 sets of initial keys:

[0041]

[0042] Among them, i=1,2,···,9; n=1,13,···,108.

[0043] Step 6: As the initial value of the hyperchaotic Chen system to generate chaotic sequences Generate chaotic sequence as the initial value of Lorenz system As the initial value of the Henon chaotic system to generate chaotic sequences Combine I, II and III according to formula (14) to generate four chaotic sequences X, Y, Z, W:

[0044]

[0045] Remove the first 1000 items of them to get the chaotic sequence To enhance the randomness, complexity, anti-attack capability, and breadth of the key space of the encryption system.

[0046] Step 7: The above chaotic sequence is converted into the following formula: Adding and modulo 256 the result can further enhance the randomness of the chaotic sequence and obtain a chaotic sequence with higher unpredictability:

[0047]

[0048] Assume that the image is of M×N type, and use the Arnold transformation shown in the following formula to scramble the image pixels in position, disrupting the pixel arrangement of the original image, making the image more difficult to restore.

[0049] i'=(i+j)modM

[0050] j'=(i+2j)modN

[0051] Where i and j are the row and column indices of image pixel a, and i′ and j′ are the scrambled row and column indices.

[0052] Perform S-box diffusion on the pixel values of the scrambled image. Use the S-box obtained in step 1 as a nonlinear replacement in encryption. Perform an XOR operation on each pixel value in the image and the value of the S-box, thereby effectively scrambling the image data and making it more difficult to reversely infer.

[0053]

[0054] Among them, idx is the index calculated according to the pixel value position (i, j), the specific calculation is:

[0055] idx=(i·N+j)mod256

[0056] Step 8: Pixel-by-pixel diffusion, each pixel value is encrypted using the chaotic sequence Q and S box. Each pixel value image sbox [i,j] is different from the value of the S box and the pixel value T[i,j] after pixel-by-pixel diffusion is obtained:

[0057]

[0058] Then, the hash value generated by the SHA512 algorithm on the master key K is used as the seed to initialize the pseudo-random number generator and generate the M×N random matrix img_key. As shown in formula (20), T and img_key are XORed.

[0059]

[0060] It should be noted that although the embodiments of the present invention described above are illustrative, they are not intended to limit the present invention. Therefore, the present invention is not limited to the above-mentioned specific embodiments. Without departing from the principles of the present invention, any other embodiments obtained by those skilled in the art under the guidance of the present invention are deemed to be within the protection of the present invention.

Claims

1. An image encryption method combining an S-box and a hyperchaotic integrated system, characterized by: The steps are as follows: Step 1: Obtain grayscale images of baboon and peppers from the publicly available CVG-UGR image database. The relatively simple structure of grayscale images allows us to focus on the core properties of the encryption algorithm while reducing the additional computational burden caused by increased image complexity. Step 2: First, use the chaotic map to initialize the S-box population and generate random S-boxes. Step 3. Then define the calculation method of particles g_best and p_best, set the fitness function to obtain an S-box with better security. Step 4. Then apply the particle swarm optimization algorithm of the S-type function inertia weight strategy to the S-box search problem to coordinate the global and local search capabilities of the algorithm, and iteratively obtain the optimal S-box g_best and the suboptimal S-box second_best. Step 5: Convert the input image to grayscale and calculate the hash value of the image using the SHA-512 algorithm. Then use the hash value to generate a second hash value. The two hash values are concatenated to obtain a master key K with a length of 128. The K XOR mixed key is used to generate 9 sets of initial keys. Step 6: Use the first four sets of keys as initial values for the hyperchaotic Chen system to generate chaotic sequence I. The next three sets of keys are used as initial values for the Lorenz system to generate chaotic sequence II. The final two sets are used as initial values for the Henon chaotic system to generate chaotic sequences, resulting in four chaotic sequences: X, Y, Z, and W. Adding these chaotic sequences together and taking the result modulo 256 further enhances their randomness, yielding a more unpredictable chaotic sequence, Q. Step 7: Assume the image is of M×N shape. Use the Arnold transform to scramble the image pixels, disrupting the original image's pixel arrangement. Then perform S-box diffusion on the scrambled image's pixel values. Use the S-box obtained in step 1 as a nonlinear replacement in encryption. Then perform an XOR operation on each pixel value in the image with the S-box value. Step 8: Diffusion is performed pixel by pixel. Each pixel value is encrypted using the chaotic sequence Q and S-box. The hash value generated by the SHA512 algorithm on the master key K is used as the seed to initialize the pseudo-random number generator, generate the M×N random matrix img_key, and perform the XOR operation on T and img_key.

2. The image encryption method according to claim 1, wherein: The parameter s of the Logistic map in step 2 is set to 3.99999, and the initial S-box is filled through multiple iterations to eliminate the influence of the initial value.

3. The image encryption method according to claim 1, wherein: The hyperchaotic system described in step 6 includes: a. The dynamic equation of the hyperchaotic Chen system is: b. To enhance the randomness, complexity, anti-attack capability, and breadth of the key space of the encryption system, it is necessary to remove the first 1000 items to obtain a chaotic sequence 4. The image encryption method according to claim 1, wherein: In step 6, the chaotic sequence is generated by modulo 256.

5. The image encryption method according to claim 1, wherein: In step 7, the modulus NN of the Arnold transform is equal to the image size, and the number of scrambling times is 3-5.

6. The image encryption method according to claim 1, wherein: In step 8, the key matrix is generated by initializing the pseudo-random number generator through the SHA-512 hash value and is consistent with the size of the encryption pixel matrix.

Citation Information

Cited By

  • Data encryption method and related device

    CN121078425A