Differential fault analysis methods, devices, electronic equipment and storage media
By injecting a random single-bit fault in the (T-5)th round of the SIMON algorithm, analyzing the fault injection location and propagation trajectory of the ciphertext differential recovery, the round key is gradually recovered, and the master key is finally determined. This solves the problems of device damage and high complexity caused by multiple fault injections in the prior art, and achieves efficient key recovery and security assessment.
Patent Information
- Application Number
- CN202411886966.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-19
- Publication Date
- 2025-11-14
- Estimated Expiration
- 2044-12-19
AI Technical Summary
Existing techniques for differential fault attacks on the SIMON algorithm require multiple fault injections, which can lead to device damage. Furthermore, the attack complexity is high, making it difficult to efficiently recover the master key.
The plaintext is encrypted using the SIMON algorithm for T rounds. A random single-bit fault is injected in round (T-5). The fault injection location is determined by analyzing the ciphertext differential, the differential propagation trajectory is recovered, and the round keys for the last 4 rounds of encryption are gradually recovered to finally determine the master key.
It reduces the number of fault injections, lowers the risk of device damage, improves attack efficiency, and can efficiently recover the master key of the SIMON algorithm to assess its security.
Smart Images

Figure CN119921938B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of Internet technology, and in particular relates to a differential fault analysis method, device, electronic device and storage medium. Background Technology
[0002] The Internet of Things (IoT) is currently very popular and is applied in various industries such as smart healthcare, smart homes, and automobiles. Block ciphers, as an effective measure to ensure data security, are widely used in the information transmission of IoT devices. Due to resource constraints, IoT devices widely adopt lightweight block ciphers such as the SIMON algorithm to ensure data security.
[0003] However, these devices are vulnerable to fault attacks. Attackers can efficiently recover the key by injecting faults and analyzing output differences. Differential fault attacks, combined with differential analysis, can obtain the complete key with just a few fault injections, posing a threat to lightweight block ciphers. Therefore, performing differential fault attacks on lightweight block cipher algorithms to evaluate their security can help designers find algorithmic flaws and further improve the cryptographic algorithms, which is of great help to the design and development of cryptography. Therefore, it is necessary to perform differential fault attacks on the proposed lightweight block ciphers.
[0004] Currently, research on differential fault attacks against SIMON under different fault models requires multiple fault injections, which increases the risk of equipment damage. Summary of the Invention
[0005] This application provides a differential fault analysis method, apparatus, device, and storage medium, which can solve the problem of equipment damage risk caused by multiple fault injections.
[0006] In a first aspect, embodiments of this application provide a differential fault analysis method, the method comprising:
[0007] The correct ciphertext is obtained by performing T rounds of encryption on plaintext using the SIMON algorithm, and the incorrect ciphertext is obtained by injecting a random single-bit fault in the (T-5)th round of the T-round encryption operation. T is a positive integer greater than 5. The fault injection position information of the random single-bit fault is determined based on the ciphertext difference between the correct and incorrect ciphertexts. Based on the fault injection position information, random single-bit faults are injected at different fault injection positions in the (T-5)th round to obtain the differential propagation trajectory. The differential propagation trajectory is analyzed to obtain the intermediate state information of the (T-5)th round and its corresponding round key. Based on the round key corresponding to the intermediate state information of the (T-5)th round, the round keys of the last 4 rounds of encryption are gradually recovered. Through the key expansion characteristics of the SIMON algorithm, the master key is determined based on the recovered round keys of the last 4 rounds of encryption.
[0008] Secondly, embodiments of this application provide a differential fault analysis device, which includes:
[0009] The encryption module is used to obtain the correct ciphertext by performing T rounds of encryption operations on plaintext using the SIMON algorithm, and to obtain the incorrect ciphertext by injecting a random single-bit fault in the (T-5)th round of T rounds of encryption operations on plaintext using the SIMON algorithm; T is a positive integer greater than 5.
[0010] The determination module is used to determine the fault injection location information of random single-bit faults based on the ciphertext difference between the correct ciphertext and the incorrect ciphertext.
[0011] The analysis module is used to inject random single-bit faults at different fault injection positions in round (T-5) based on the fault injection position information to obtain differential propagation trajectories, and analyze the differential propagation trajectories to obtain the intermediate state information of round (T-5) and its corresponding round key.
[0012] The recovery module is used to gradually recover the round keys for the last 4 rounds of encryption operations based on the round keys corresponding to the intermediate state information of round (T-5).
[0013] The determination module is also used to determine the master key based on the round keys of the last four rounds of encryption operations that have been recovered, using the key expansion feature of the SIMON algorithm.
[0014] Thirdly, embodiments of this application provide an electronic device, the device including: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, it implements the method as described in the first aspect or any possible implementation of the first aspect.
[0015] Fourthly, embodiments of this application provide a readable storage medium storing computer program instructions that, when executed by a processor, implement the method as described in the first aspect or any possible implementation thereof.
[0016] In this embodiment, the plaintext is encrypted using the SIMON algorithm for T rounds to obtain the correct ciphertext, and an incorrect ciphertext is obtained by injecting a random single-bit fault in the (T-5)th round of the T-round encryption operation. T is a positive integer greater than 5. The fault injection location information of the random single-bit fault is determined based on the ciphertext difference between the correct and incorrect ciphertexts. By comparing the correct and incorrect ciphertexts, the impact of the fault injection on the encryption result can be observed, and the impact of the fault injection on the ciphertext can be analyzed to determine the specific location of the fault injection. After determining the fault injection location, the propagation path of the fault during the encryption process can be further analyzed. Based on the fault injection location information, a random single-bit fault is injected at different fault injection locations in the (T-5)th round to obtain a differential propagation trajectory. The differential propagation trajectory is analyzed to obtain the intermediate state information of the (T-5)th round and its corresponding round key. By observing the differential propagation trajectory of the fault during the encryption process and analyzing the differential propagation trajectory, the intermediate state information of the (T-5)th round and its corresponding round key can be inferred, providing a basis for further key recovery. Based on the round keys corresponding to the intermediate state information of round (T-5), the round keys for the last four rounds of encryption are gradually recovered. Using the key expansion characteristic of the SIMON algorithm, the master key is determined based on the recovered round keys for the last four rounds of encryption. This reduces the number of fault injection attempts and completes the key recovery for the SIMON algorithm. Attached Figure Description
[0017] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0018] Figure 1 This is a flowchart of a differential fault analysis method provided in an embodiment of this application;
[0019] Figure 2 This is a flowchart of another differential fault analysis method provided in the embodiments of this application;
[0020] Figure 3 This is a differential propagation trajectory table provided in an embodiment of this application;
[0021] Figure 4 This is an example of an ambiguous situation in fault location determination provided by an embodiment of this application;
[0022] Figure 5 This is a comparison table of theoretical analysis and experimental results for the number of fault injections provided in an embodiment of this application;
[0023] Figure 6This is a comparison table of attack methods against SIMON32 / 64 under a random single-bit model provided in the embodiments of this application;
[0024] Figure 7 This is a comparison table of attack methods against SIMON48 / 96 under a random single-bit model provided in the embodiments of this application;
[0025] Figure 8 This is a comparison table of attack methods against SIMON64 / 128 under a random single-bit model provided in the embodiments of this application;
[0026] Figure 9 This is a schematic diagram of the structure of a differential fault analysis device provided in an embodiment of this application;
[0027] Figure 10 This is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0028] The features and exemplary embodiments of various aspects of this application will now be described in detail. To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only configured to explain this application and are not configured to limit this application. For those skilled in the art, this application can be implemented without some of these specific details. The following description of the embodiments is merely to provide a better understanding of this application by illustrating examples of this application.
[0029] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus that includes the element.
[0030] The following is a brief introduction to the technical terms used in this application.
[0031] The SIMON algorithm, exhibiting excellent performance in both hardware and software environments, is a balanced Feistel lightweight block cipher with an ARX structure. Its round structure consists of bitwise AND, cyclic shift, and bitwise XOR operations. The SIMON algorithm with bit block length and bit key length is denoted as SIMON, where 16, 24, 32, 48, or 64, and m = 2, 3, or 4. The specific values of n, m, and the number of encryption rounds vary.
[0032] Differential Fault Attack (DFA): An attacker introduces a fault into the encryption process, causing the intermediate state of the algorithm to change. Then, by analyzing the relationship between the correct ciphertext and the faulty ciphertext using differential analysis, the attacker obtains information about part or all of the intermediate states, thereby recovering the value of the round key and then obtaining the complete master key through a key expansion algorithm.
[0033] Fault attack: refers to the act of inducing erroneous information into a cryptographic device during the encryption process, thereby obtaining the key information of the cipher by exploiting the fault information output by the device when it malfunctions.
[0034] Fault injection refers to the process of inducing a device to generate erroneous information, typically achieved by placing the cryptographic device in an abnormal operating environment. Fault injection methods include controlling the temperature to high or ultra-low temperatures, creating a strong electromagnetic environment or placing it under strong light, laser injection, and altering the power supply or clock frequency.
[0035] Single-bit fault: refers to a fault whose impact is limited to a single bit. Generally, the impact width of a fault model can be single-bit, multi-bit, single-byte, or multi-byte, etc.
[0036] The differential fault analysis method provided in this application embodiment can be applied to at least the following application scenarios, which will be described below.
[0037] The Internet of Things (IoT) is now widely used and applied in various industries such as smart healthcare, smart homes, and automobiles. Block ciphers, as an effective measure to ensure data security, are widely used in the information transmission of IoT devices. However, the memory, resources, and power of IoT devices are extremely limited, hence the emergence of lightweight block ciphers.
[0038] Lightweight block ciphers use less computation and protect data with low resources and computational cost, making them suitable for a variety of resource-constrained devices. Since most devices in the Internet of Things (IoT), such as wireless sensors, are based on electronic technology and have relatively simple interfaces, they are easily affected by external conditions during actual system operation, inevitably leaking information such as energy, electromagnetic fields, and power consumption. Attackers can use this information to launch side-channel attacks on the system.
[0039] Currently, side-channel attacks mainly include timing attacks, power analysis, and fault attacks. Compared with timing, power consumption, and electromagnetic attacks, fault attacks have relatively low data complexity and may only require a few fault injection analyses to recover the complete key of a block cipher.
[0040] With the continuous development of cryptanalysis, fault attacks have been combined with the classic attack method—differential analysis. By introducing faults at different execution steps of the encryption algorithm, the impact of these faults on the output can be analyzed to obtain information about the key. If an attacker understands the internal structure of the encryption algorithm, differential fault attacks can obtain information about the key more accurately and efficiently.
[0041] Compared to classic differential analysis methods, differential fault attacks, under ideal conditions, can obtain the complete key of an algorithm with just a few faulty encryptions, significantly reducing the complexity of analysis. This poses a major threat to the security of lightweight block cipher algorithms; therefore, considering resistance to differential fault attacks is essential when designing algorithms.
[0042] Therefore, performing differential fault attacks on lightweight block cipher algorithms to assess their security can help designers identify algorithmic flaws and further improve the cryptographic algorithms, which is of great benefit to the design and development of cryptography. Thus, performing differential fault attacks on the proposed lightweight block ciphers is essential.
[0043] The SIMON cryptosystem is a family of highly optimized lightweight block ciphers proposed by the U.S. National Security Agency in 2013, exhibiting excellent performance in both hardware and software environments. Researchers have primarily focused on differential fault attacks against SIMON under different fault models, mainly categorized into three types: random single-bit fault model, random byte fault model, and random multi-bit fault model.
[0044] Under the random single-bit fault model, for the SIMON algorithm with a block length of n, n / 2 fault injections are required to recover the round key of the last round, and recovering the complete master key of the algorithm requires fault injections in 4 rounds respectively.
[0045] Finally, through experimental simulations, the researchers determined the average number of fault injections required to recover the SIMON32 / 64 master key to be 101.72, the average number of fault injections required to recover the SIMON48 / 96 master key to be 174.37, and the average number of fault injections required to recover the SIMON64 / 128 master key to be 252.58. The final experimental results show that injecting faults in two rounds of the key expansion algorithm can recover the complete master key, and that an average of 50.32 fault injections are needed to recover the SIMON32 / 64 master key, an average of 85.86 fault injections are needed to recover the SIMON48 / 96 master key, and an average of 124.72 fault injections are needed to recover the SIMON64 / 128 master key.
[0046] Considering that fault injection in real-world applications can irreversibly damage equipment, reducing the number of rounds and instances of fault injection is crucial for differential fault attacks. In the random single-bit fault model, researchers primarily utilize the round function of the cryptographic algorithm to create a truth table of the ciphertext difference and intermediate state bits, determining the round key based on the actual value of the ciphertext difference. This approach requires at least two rounds of fault injection to recover the master key, and the high number of injections (high attack complexity) increases the likelihood of device damage, ultimately impacting the overall efficiency of the solution.
[0047] The master key is the core of the encryption algorithm, determining the generation of all round keys during the encryption process. Once an attacker obtains the master key, they have complete control over the encryption process, including encrypting and decrypting arbitrary data. Possessing the master key means an attacker can decrypt all data encrypted with that key, thereby obtaining sensitive information. Recovering the master key is a key indicator of the success of a differential fault attack. Only by successfully recovering the master key can the effectiveness of the attack be proven, and the security of the algorithm further evaluated. By recovering the master key, attackers can further analyze the algorithm's weaknesses, propose improvements, or verify the effectiveness of other attack methods.
[0048] Recovering the master key can reduce the number of rounds and attempts required for an attack. Once the master key is recovered, an attacker can use it to generate all round keys, thus simplifying the subsequent attack process. Recovering the master key simplifies the attack flow, reduces unnecessary operations and calculations, and improves attack efficiency.
[0049] Recovering the master key is a crucial means of comprehensively evaluating algorithm security. By recovering the master key, vulnerabilities to physical attacks can be revealed, allowing for suggestions for improvement. Furthermore, by recovering the master key, designers can understand how the algorithm performs against differential fault attacks, thereby improving algorithm design and increasing its resistance to such attacks.
[0050] In practical applications, protecting sensitive data is crucial. Recovering the master key means an attacker can decrypt all data encrypted with that key, thereby gaining access to sensitive information. By recovering the master key, the security of a device against physical attacks can be assessed, thus improving the overall security of the device.
[0051] Recovering the master key is crucial in differential fault attacks. It not only signifies a successful attack but also allows attackers to gain complete control of the encryption process, improving attack efficiency, assessing algorithm security, and protecting sensitive data in real-world applications. Therefore, recovering the master key is a core objective in differential fault attacks and is of significant value for evaluating and improving cryptographic algorithms.
[0052] Figure 1 This is a flowchart of a differential fault analysis method provided in an embodiment of this application.
[0053] like Figure 1 As shown, the differential fault analysis method may include steps 110-150. This method is applied to a differential fault analysis device, as detailed below:
[0054] Step 110: The plaintext is encrypted using the SIMON algorithm for T rounds to obtain the correct ciphertext, and the (T-5)th round of encryption using the SIMON algorithm is used to inject a random single-bit fault to obtain the incorrect ciphertext; T is a positive integer greater than 5.
[0055] SIMON Algorithm: SIMON is a symmetric-key block cipher algorithm designed by the U.S. National Security Agency (NSA). It is a lightweight encryption algorithm suitable for resource-constrained environments, such as embedded systems. The SIMON algorithm encrypts plaintext through multiple rounds of encryption operations, each round involving the mixing of the round key and plaintext.
[0056] Plaintext: In the encryption process, the unencrypted original data is called plaintext. Ciphertext: Data processed by an encryption algorithm is called ciphertext.
[0057] Single-bit fault: An error in a single bit (0 or 1) is intentionally introduced during encryption. This fault is often used in cryptanalysis to observe changes in the behavior of the encryption algorithm.
[0058] Fault injection: Intentionally introducing errors or faults during the encryption process, often used in cryptanalysis to observe changes in the behavior of encryption algorithms.
[0059] A random single-bit fault is injected into the SIMON algorithm in round (T-5) to observe its propagation and impact. A bit is randomly selected at a certain position in round (T-5) and flipped (0 becomes 1 or 1 becomes 0), introducing a single-bit fault. By injecting the fault, its propagation path and impact within the algorithm can be observed, allowing for the deduction of the algorithm's intermediate states and round keys.
[0060] The plaintext is encrypted using the SIMON algorithm for T rounds to obtain the correct ciphertext. Then, a random single-bit fault is injected in the (T-5)th round, and another T rounds of encryption are performed to obtain the incorrect ciphertext. By comparing the correct and incorrect ciphertexts, the impact of the fault injection on the encryption result can be observed.
[0061] Step 120: Determine the fault injection location information of the random single-bit fault based on the ciphertext difference between the correct ciphertext and the incorrect ciphertext.
[0062] Fault injection location information: The specific location information where a fault is injected during the encryption process.
[0063] By calculating the difference between the correct and incorrect ciphertext, the propagation properties of single-bit faults are analyzed, the specific location of fault injection is determined, and the intermediate state of the algorithm is restored.
[0064] Analyze fault propagation: By analyzing the propagation path of a single-bit fault in the algorithm, the specific location of fault injection can be determined.
[0065] Restoring intermediate states: By combining ciphertext differentiation and fault propagation paths, the intermediate states of the algorithm are restored.
[0066] By analyzing fault propagation and ciphertext differentiation, the specific location of fault injection can be determined, and the intermediate state of the algorithm can be restored, providing a basis for further recovery of the round key.
[0067] By analyzing the ciphertext difference between the correct and incorrect ciphertexts, the impact of fault injection on the ciphertext is determined, thus pinpointing the specific location of the fault injection. Once the location is determined, the propagation path of the fault during the encryption process can be further analyzed.
[0068] Step 130: Based on the fault injection location information, inject random single-bit faults at different fault injection locations in round (T-5) to obtain differential propagation trajectories, and analyze the differential propagation trajectories to obtain intermediate state information of round (T-5) and its corresponding round key.
[0069] Intermediate state information: In the encryption process, the intermediate result after each round of encryption operation is called intermediate state information.
[0070] Round key: The subkey used in each round of encryption, generated from the master key using a key expansion algorithm.
[0071] Random single-bit faults are injected at different positions in round (T-5). The propagation trajectory of the faults during the encryption process is observed, and these trajectories are analyzed to infer the intermediate state information of round (T-5) and its corresponding round key. By analyzing the differential propagation trajectory, the intermediate state information and round key of round (T-5) can be obtained, providing a basis for further key recovery.
[0072] Step 140: Based on the round key corresponding to the intermediate state information of round (T-5), gradually recover the round keys for the last 4 rounds of encryption operations;
[0073] A fault is injected at a certain point in the last four rounds, and its propagation and impact are observed. By analyzing the fault propagation and ciphertext differential, the round keys for the last four rounds are recovered. By recovering the round keys for the last four rounds, the master key can be further deduced.
[0074] Based on the intermediate state information of round (T-5) and the corresponding round key, the round keys for the last four rounds of encryption are derived step by step in reverse. After successfully recovering the round keys for the last four rounds, the master key can be further derived.
[0075] Step 150: Using the key expansion feature of the SIMON algorithm, determine the master key based on the round keys of the last four rounds of encryption operations that have been recovered.
[0076] Master key: The original key used to generate round keys in the encryption algorithm. Utilizing the key expansion property of the SIMON algorithm, the master key is derived in reverse from the recovered last four round keys. Finally, the master key is determined, completing the key recovery for the SIMON algorithm.
[0077] By employing fault injection and differential analysis techniques, the intermediate state information and round keys of the SIMON algorithm are gradually derived, ultimately recovering the master key. This method has significant applications in cryptanalysis, especially in countering lightweight encryption algorithms.
[0078] In one possible embodiment, step 120 may specifically include the following steps:
[0079] The propagation characteristics of a single-bit fault in five consecutive rounds were analyzed, and partial bit information of the input difference in the penultimate round and the input difference in other rounds was calculated.
[0080] Based on partial bit information from the ciphertext difference, the input difference of the penultimate round, and the input differences of other rounds, the fault injection location information of the random single-bit fault is determined.
[0081] Propagation characteristics: The property of how a fault propagates from one bit to other bits during encryption. This involves the internal logic and operations of the encryption algorithm. Input difference: The difference between the input data at a specific round during encryption and the normal input data. Ciphertext difference: The difference between correct ciphertext and incorrect ciphertext.
[0082] By analyzing the propagation path of a single-bit fault across five consecutive rounds of encryption, we can understand how the fault affects the input and output of each round. This analysis helps determine the specific impact of the fault on the encryption process. Through this analysis, we can calculate partial bit information of the input difference in the penultimate round and the input differences in other rounds.
[0083] Based on the fault propagation characteristics, the input difference for the penultimate round is calculated, which is the difference between the input data in the penultimate round and the normal input data. Simultaneously, partial bit information of the input differences in other rounds is calculated. This difference information provides crucial data for subsequently determining the fault injection location.
[0084] By combining partial bit information from the ciphertext differential, the penultimate round's input differential, and the input differentials from other rounds, the relationships between these differential information are analyzed to determine the specific location of the fault injection. This analysis allows for precise location determination of the fault injection, providing a foundation for further differential propagation trajectory analysis and key recovery.
[0085] By analyzing the propagation characteristics of a single-bit fault in five consecutive rounds, partial bit information of the input difference in the penultimate round and the input differences in other rounds is calculated. Combined with the ciphertext difference, the specific location of the fault injection is finally determined, which can effectively deduce the internal state and key of the encryption algorithm.
[0086] The propagation characteristics of a single-bit fault in five consecutive rounds were analyzed, and the input difference in the penultimate round was calculated, including:
[0087] Analyze the propagation characteristics of a single-bit fault in five consecutive rounds, and determine some bits of the input difference in the penultimate round based on the relationship between the low-order bits of the ciphertext difference and the output difference of the penultimate round.
[0088] By utilizing the propagation pattern of intermediate differences during fault propagation, the input difference up to the penultimate round is gradually derived.
[0089] By analyzing the propagation path of a single-bit fault across five consecutive rounds of encryption, we can understand how the fault affects the input and output of each round. This analysis helps determine the specific impact of the fault on the encryption process. Partial bit information of the input difference for the penultimate round and other rounds can be calculated.
[0090] There is a certain relationship between the low-order bits of the ciphertext differential and the penultimate round output differential. By analyzing this relationship, some bits of the penultimate round input differential can be determined. This provides a preliminary basis for further differential propagation trajectory analysis, allowing for the identification of some bit information in the penultimate round input differential.
[0091] During fault propagation, specific propagation patterns exist between the intermediate differences in each round (i.e., the input and output differences in each round). By analyzing these propagation patterns, the input difference for the penultimate round can be derived step by step. Through this step-by-step derivation, the input difference for the penultimate round can be accurately calculated, providing crucial data for further key recovery.
[0092] By analyzing the propagation characteristics of a single-bit fault over five consecutive rounds, and combining the relationship between the low-order bits of the ciphertext difference and the output difference of the penultimate round, some bits of the input difference of the penultimate round are initially determined. Then, using the propagation pattern of the intermediate differences during fault propagation, the input difference of the penultimate round is gradually derived. This method has significant application value in cryptanalysis, especially in combating lightweight encryption algorithms, as it can effectively deduce the internal state and key of the encryption algorithm.
[0093] In one possible embodiment, the method further includes:
[0094] Analyze the propagation characteristics of a single-bit fault in five consecutive rounds to determine that the low-order bits of the ciphertext difference correspond to a portion of the output difference in the penultimate round; the ciphertext difference is the difference between the correct ciphertext and the incorrect ciphertext.
[0095] In the penultimate round of the encryption operation, the XOR operation and cyclic shift characteristics of the SIMON algorithm are used to propagate the output difference of the encryption operation in reverse to the input difference, thereby determining at least some bits of the input difference in the penultimate round.
[0096] By analyzing the propagation path of a single-bit fault in five consecutive rounds of encryption, we can understand how the fault affects the input and output of each round. In particular, there is a certain relationship between the low-order bits of the ciphertext difference and the penultimate round output difference. By analyzing this relationship, we can determine some bits of the penultimate round output difference. This preliminary determination of some bit information of the penultimate round output difference provides a foundation for further differential propagation trajectory analysis.
[0097] In the penultimate round of encryption, the XOR operation and cyclic shift properties of the SIMON algorithm can be used to backpropagate the output difference to the input difference. Specifically, by applying the SIMON algorithm's operations in reverse (such as XOR and cyclic shift), the input difference can be derived from the output difference. Through this reverse propagation, at least some bits of the input difference in the penultimate round can be accurately calculated, providing crucial data for further key recovery.
[0098] The SIMON algorithm primarily relies on bitwise operations (such as AND, XOR, and cyclic shift) for encryption. The characteristics of these operations enable differential fault analysis (DFA), as fault injection can affect the results of these operations. SIMON's key expansion algorithm generates round keys, which are used in each round of the encryption process.
[0099] The random single-bit fault model was chosen because the bitwise operation characteristics of SIMON allow single-bit faults to significantly affect the encryption process. After a single-bit fault is injected, changes in the ciphertext can be observed, allowing the inference of the intermediate state differences.
[0100] The fault is injected at round (T-5) of the T-round algorithm. This means injecting the fault in the fifth-to-last round, allowing us to observe its propagation properties in the final five rounds. By analyzing the propagation properties of a single-bit fault across these five consecutive rounds, we can deduce some of the input difference values for those five rounds.
[0101] After a fault is injected in round (T-5), the fault propagates to subsequent rounds via SIMON's round functions. Due to SIMON's bitwise operation characteristics, the fault propagates in a predictable manner, affecting the intermediate states of subsequent rounds. By analyzing the propagation of the fault in the last 5 rounds, some values of the input differences in these 5 rounds can be inferred. These difference values can help in further analysis of the ciphertext differences.
[0102] After a fault injection, the ciphertext changes. By comparing the normal ciphertext with the fault-injected ciphertext, the ciphertext difference can be obtained. Combined with the previously inferred input difference values, the ciphertext difference can be further analyzed to deduce the round keys for the final four rounds. By analyzing the combination of the ciphertext difference and the input difference, the round keys for the final four rounds can be directly deduced. This is because SIMON's key expansion algorithm and round function structure allow these round keys to be directly recovered through differential analysis.
[0103] By injecting random single-bit faults in round (T-5) and analyzing their propagation properties in the last 5 rounds, combined with ciphertext differential analysis, the round keys for the last 4 rounds can be directly deduced. This attack strategy leverages the bitwise operation characteristics of the SIMON algorithm and the key expansion algorithm.
[0104] By analyzing the propagation characteristics of a single-bit fault over five consecutive rounds, the low-order bits of the ciphertext difference correspond to a portion of the output difference in the penultimate round. Then, in the penultimate round of the encryption operation, utilizing the XOR operation and cyclic shift properties of the SIMON algorithm, the output difference of the encryption operation is propagated backwards to the input difference, thus determining at least a portion of the input difference in the penultimate round. This method has significant application value in cryptanalysis, effectively deriving the internal state and key of the encryption algorithm.
[0105] In one possible embodiment, the method further includes:
[0106] Based on the propagation properties of ciphertext difference and single-bit fault in the SIMON algorithm, the input difference for the last three rounds is calculated.
[0107] Based on the input differentials of the last three rounds, the injection location information of the single-bit fault is determined, and a differential propagation trajectory table is established.
[0108] Based on the differential propagation trajectory table, the intermediate state information of the last three rounds and their corresponding round keys are derived step by step.
[0109] By analyzing the propagation properties of ciphertext differences and single-bit faults in the SIMON algorithm, the input differences for the last three rounds can be derived. Specifically, the propagation path and impact of faults during encryption can be determined through differential analysis. This analysis allows for the calculation of the input differences for the last three rounds, providing a foundation for further fault injection location analysis and the establishment of a differential propagation trajectory table.
[0110] Based on the input differentials of the last three rounds, the injection location of a single-bit fault can be determined. By analyzing the relationship between the input and output differentials, a differential propagation trajectory table can be established, recording the propagation path and impact of the fault in each round. Through this analysis, the location of the fault injection can be accurately determined, and a differential propagation trajectory table can be established, providing crucial data for further intermediate state information and round key derivation.
[0111] Based on the differential propagation trajectory table, the intermediate state information and corresponding round keys for the last three rounds can be derived step by step. Specifically, by analyzing the input and output differences of each round, the intermediate state information and round keys for each round can be derived in reverse. Through this step-by-step derivation, the intermediate state information and round keys for the last three rounds can be accurately calculated, providing crucial data for further key recovery.
[0112] Optionally, such as Figure 2 As shown, the steps to recover the last round key include:
[0113] Step 101: Randomly select a plaintext P, and under the control of the master key, perform T rounds of encryption using the SIMON algorithm to obtain the correct ciphertext C = L. T ||R T .
[0114] Step 102: Encrypt again using the same plaintext P and key K. When the algorithm reaches round (T-5), input L to the left. T-5 Inducing a random single-bit fault and continuing encryption for 5 more rounds yields erroneous ciphertext.
[0115] Step 103: Based on the ciphertext difference ΔC=C⊕C * The input difference Δ for the last three rounds is calculated using the single-bit fault propagation property. T ,Δ T-1 and Δ T-2 According to Δ T-2 The specific value is used to determine the location q of the fault injection and to establish a differential propagation trajectory table.
[0116] Step 104: Using the information in the trajectory table, Δ T-1 and Δ T-2 Get the left side of wheel (T-2) and input L. T-2 Two bits
[0117] Step 105: Combine Δ in the trajectory table T-3 and Δ T-2 The value of can be at least obtained and Two bits in the middle.
[0118] Step 106: Obtain L T-2 After obtaining partial bit information, via K T-1 =L T-2 ⊕F(R T )⊕L T Restore the last round key K T-1 The corresponding bits. Repeat steps S2 to S5 until the complete round key K is recovered. T-1 .
[0119] Optionally, in step 103 Δ T-2 The calculation method is as follows:
[0120] Δ T-2 =[(Δ T-1 <<<1)&(Δ T-1 <<<8)]⊕[(Δ T-1 <<<8)&(L T-1 <<<1)]
[0121] ⊕[(Δ T-1 <<<1)&(L T-1 <<<8)]⊕(Δ T-1 <<<2)⊕Δ T
[0122] The above formula is derived using the bitwise operation characteristics of the round function in the SIMON algorithm. Using this formula, the penultimate round input difference Δ can be directly calculated from the correct and incorrect ciphertext pairs. T-2 This allows for direct and rapid key recovery, eliminating the need for the previous method of retrieving keys by listing truth tables, significantly reducing attack complexity. The specific method for obtaining the above formula is as follows:
[0123] Let the n-bit input from the left side of the i-th round be denoted as The n-bit input on the right is denoted as Let f denote the effect of the round function F on a single bit. For any j = 0, 1, ..., n, the following equation holds:
[0124]
[0125] Let the error value input from the left side in the i-th round after fault injection be denoted as... The error value entered on the right is recorded as follows: After one round of encryption, the left input difference in the (i+1)th round The j-th bit can be represented as:
[0126]
[0127] Using the distributive law of the bitwise AND operation & and the bitwise XOR operation ⊕, we have:
[0128]
[0129] Therefore
[0130]
[0131] When i = T, the input difference Δ in the (T-2)th round T-2 The j-th bit representation:
[0132]
[0133] Based on the characteristics of bitwise operations in round functions, the input difference Δ of round (T-2) can be summarized from the above formula. T-2 The calculation formula, that is, for the T-round SIMON algorithm, given Δ T-1 Δ T Input L on the left side of (T-1) wheel T-1 In the case of (T-2) round input difference Δ T-2 For ΔT-2 =[(Δ T-1 <<<1)&(Δ T-1 <<<8)]⊕[(Δ T-1 <<<8)&(L T-1 <<<1)]⊕[(Δ T-1 <<<1)&(L T-1 <<<8)]⊕(Δ T-1 <<<2)⊕Δ T .
[0134] Optionally, the method for determining the fault location in step S103 is as follows: Δ is obtained based on the fault propagation law. T-2 The data contains a fixed pattern where a bit is 1 and the higher bits are consecutive 0s. This pattern can be analyzed using Δ. T-2 The actual value is matched with the fixed pattern. After the match, the first "1" in the lower bit is located at position (q+6), thus determining the specific location of the fault injection as q.
[0135] Optionally, the basis for establishing the differential propagation trajectory table from position q in step S103 is as follows:
[0136]
[0137] Where δ is the effect of a bit change on the next round of differential processing; n is the block length; q is the fault injection position; i is the number of changes in one round; j is the fault displacement; and t is the assumption at round t. This represents the input difference at position q in round t; the above formula is used to characterize the input difference in each round.
[0138]
[0139] The above formula can be used to list the values of the input difference obtained in each round of faulty encryption after fault injection. Based on the values, the key can be recovered directly without having to recover other keys by injecting faults in a new round, which greatly reduces the complexity of the attack.
[0140] Optionally, the method for restoring the intermediate state in step S105 is as follows:
[0141] like and but
[0142] like and but
[0143] like and but
[0144] like and but
[0145] Combined with the trajectory table Δ T-3 and Δ T-2 The value of , when satisfying the above conditions, can at least obtain and Two bits in the middle.
[0146] Optionally, the process of analyzing to obtain the initial key includes:
[0147] Step 201: Recover K using S106 T-1 The final round of decryption yields L. T-1 ||R T-1 and Analyze using the method claimed in claim 6, repeat steps S103 to S106, and recover the round key K. T-2 Continue this process to recover the other two round keys K. T-3 and K T-4 .
[0148] Step 202: Using the recovered 4 round keys, recover the complete master key according to SIMON's key expansion algorithm.
[0149] Optionally, injecting a random single-bit fault in round 27 of the SIMON32 / 64 algorithm can recover an average of 5.38 bits of the final round key; injecting a random single-bit fault in round 31 of the SIMON48 / 96 algorithm can recover an average of 5.83 bits of the final round key; and injecting a random single-bit fault in round 39 of the SIMON64 / 128 algorithm can recover an average of 5.81 bits of the final round key.
[0150] Optionally, ambiguity in determining the fault location can lead to the inability to recover the correct key. Specifically, the input difference is matched with a fixed pattern in ascending order of bit position. Due to unpredictable values in the fault propagation trajectory, the pattern may match successfully, but the first '1' in the lower bit may not be due to fault injection, thus preventing the recovery of the correct key. By analyzing all cases of ambiguity, the probabilities of fault location ambiguity for SIMON32 / 64, SIMON48 / 96, and SIMON64 / 128 are calculated to be 3 / 8, 29 / 128, and 11 / 128, respectively.
[0151] Optionally, in cases where there may be ambiguity in determining the fault location, resulting in the inability to recover the correct key, analysis shows that the SIMON32 / 64, SIMON48 / 96, and SIMON64 / 128 cryptographic algorithms require an average of 4.76, 5.32, and 6.03 fault injections, respectively, to recover the complete last round key.
[0152] Optionally, after recovering the round key of the last round, the round keys of the last four rounds can be recovered in the same way, and the master key can be recovered by combining the key expansion algorithm.
[0153] In this embodiment, the plaintext is encrypted using the SIMON algorithm for T rounds to obtain the correct ciphertext, and an incorrect ciphertext is obtained by injecting a random single-bit fault in the (T-5)th round of the T-round encryption operation. T is a positive integer greater than 5. The fault injection location information of the random single-bit fault is determined based on the ciphertext difference between the correct and incorrect ciphertexts. By comparing the correct and incorrect ciphertexts, the impact of the fault injection on the encryption result can be observed, and the impact of the fault injection on the ciphertext can be analyzed to determine the specific location of the fault injection. After determining the fault injection location, the propagation path of the fault during the encryption process can be further analyzed. Based on the fault injection location information, a random single-bit fault is injected at different fault injection locations in the (T-5)th round to obtain a differential propagation trajectory. The differential propagation trajectory is analyzed to obtain the intermediate state information of the (T-5)th round and its corresponding round key. By observing the differential propagation trajectory of the fault during the encryption process and analyzing the differential propagation trajectory, the intermediate state information of the (T-5)th round and its corresponding round key can be inferred, providing a basis for further key recovery. Based on the round key corresponding to the intermediate state information of round (T-5), the round keys for the last four rounds of encryption are gradually recovered. Using the key expansion characteristic of the SIMON algorithm, the master key is determined based on the recovered round keys for the last four rounds of encryption. Thus, the key recovery for the SIMON algorithm is completed.
[0154] For example, to recover the round key of the last round, a fault is injected into the left side of round 27. By analyzing the relationship between the differential and fault propagation in round 30, theoretically, one fault injection can recover the 5.25-bit last round key K. 31 At least 4.76 erroneous ciphertexts are needed to recover the complete last round key. To obtain the round keys for the remaining three rounds, it is necessary to continue injecting faults in round 27 and calculate the round 29 differential based on the recovered round keys to recover the penultimate round key K. 30 Similarly, continue recovering the round key K. 29 and K 28 This allows the master key to be recovered.
[0155] In one possible embodiment, the detailed steps for recovering the round key of the last round are as follows:
[0156] Step 301: Encrypt the same plaintext P. During the 27th round of encryption, inject a random single-bit fault into the left input to obtain erroneous ciphertext.
[0157] calculate Δ 30 =[(Δ 31 <<<1)&(Δ 31 <<<8)]⊕[(Δ 31 <<<8)&(L 31 <<<1)]⊕[(Δ 31 <<<1)&(L 31 <<<8)]⊕(Δ 31 <<<2)⊕Δ 32 .
[0158] Step 302: Based on Δ T-2 The value of Δ determines the location of the fault injection. Taking a single-bit fault injection into the least significant bit as an example, it can be determined by Δ. 30 Obtained by matching the pattern "000***0*01". Established based on the fault injection location and the following formula: Figure 3 The table shows the differential trajectory of the five rounds of fault propagation.
[0159]
[0160] according to Figure 3 The values of the input differences in each round are determined using the input difference Δ. 31 and Δ 30 The two bits of the left input in round 30 are calculated. and
[0161] Step 303: According to The specific value to be taken, if and but
[0162] like and but
[0163] like and but
[0164] like and but At least two bits can be obtained.
[0165] Step 304: Based on L obtained in steps S102 and S103 30 , by K 31 =L 30 ⊕F(R 32 )⊕L 32 The last round key K can be recovered. 31 The corresponding bits. By injecting faults at different positions in the left-hand input of round 27 of the algorithm, the complete last-round key K can be recovered using the method described above. 31 .
[0166] Step 305: Decrypt the ciphertext using the last round key, and continue in the same way to lower rounds to recover the round keys used in the lower rounds of encryption. After recovering the round keys of the last 4 rounds of the algorithm, the complete master key of the SIMON algorithm can be recovered using the key expansion algorithm.
[0167] The complexity of a differential fault attack on the SIMON cryptographic algorithm primarily depends on the number of bits that can be recovered after a single fault injection. Therefore, the number of fault injections required to recover a complete round of keys can be calculated based on the block length. In a specific embodiment, after a fault injection, in step S102, after confirming the fault injection position q = 0, q and the input difference Δ... 31 Δ 30 The value can restore the intermediate state L 30 2 bits and Therefore, after a fault injection, step S102 can recover an average of 2 / 16 bits of the round key.
[0168] Assume Δ 29 Some bits are known. According to step S103, only when the triplet... or When the value condition (1, 0, 0) is met, L can be recovered. 30 The partial bits are then used to recover the corresponding round key bits.
[0169] Where j takes values from 0 to n-1, iterate through all possible values of j, and combine the values of the triplet that satisfy the condition with Δ. 30 The values at the corresponding positions in the fixed pattern "000***0*01" are compared one by one. If no contradiction is found, the intermediate state bit at the corresponding position can be restored.
[0170] Δ 30 In the fixed pattern, the probability of "*" taking 0 and 1 is equal. By calculating the probability of the value satisfying the condition, this instance can recover on average (1 / 2) after a fault injection. 3 ×5+1 / 2 2(×4+1)×2=5.25 bits of key. Therefore, by injecting a random single-bit fault in the 27th round of the specific embodiment, approximately 2 / 16+5.25≈5.38 bits of the key from the last round can be recovered.
[0171] Since the embodiments of this application require determining the recoverable key bits based on the location of the fault injection, ambiguity in determining the fault location needs to be considered. For this specific embodiment, the obtained input difference Δ 30 The fixed pattern "000***0*01" is matched from low to high bits. Due to the uncertainty of the value of "*", the pattern is matched successfully, but the first 1 in the low bit is not the correct fault injection position.
[0172] Since the probability of "*" taking the value 0 and 1 is equal, by analyzing the possible values of "*" in the input difference that lead to successful pattern matching, the probability of ambiguity in fault location judgment is calculated using the value of "*", as shown below. Figure 4 The three versions shown illustrate instances of ambiguity in fault location determination, along with the corresponding probabilities of these instances occurring. Based on the above, the probability of ambiguity in fault location determination in the specific embodiments can be calculated to be 4 × 1 / 2. 5 +2×1 / 2 4 +1 / 2 3 =3 / 8.
[0173] Therefore, in this specific embodiment, it takes an average of 16 / [(1-3 / 8)×5.38]=4.76 fault injections to fully recover the round key of the last round.
[0174] To verify the correctness of the theoretical analysis, a controlled differential fault attack process was simulated, where faults were injected at different locations without repetition. Simulations were also performed for recovering the round key of the final round and the complete master key of the algorithm. A complete experiment was defined as recovering the complete round key or master key after fault injection, and the number of fault injections required to recover the key was recorded for each experiment.
[0175] Figure 5 The experimental results were compared with the theoretical analysis results. It can be seen that when the location of the control fault injection and some differential bits are known, the experimental results are close to the theoretical calculation results, which verifies the correctness of the theoretical analysis.
[0176] The embodiments of this application, by studying the characteristics of AND operation in the SIMON round function, analyze the propagation properties of single-bit faults in five consecutive rounds, study the characteristics of bitwise operations, obtain the calculation formula for the penultimate round input difference, and give a method for determining the fault injection position and intermediate state bits. Based on this, a new differential fault attack method for the SIMON algorithm is proposed.
[0177] In this embodiment, the fault injection location is determined based on the key expansion algorithm. After the fault is injected, the properties of the round function and operation are fully studied, the fault propagation properties are analyzed, and then the intermediate state bits are directly calculated using the known difference to recover the key. Since the fault injection location cannot be controlled in actual attacks, a new simulation experiment is set up, assuming that the attacker cannot control the specific location of the fault injection. In this case, the attacker may inject the fault multiple times at the same location until a complete round key or master key is recovered. Furthermore, during the attack process, the actual obtained Δ... T-3 The specific value of the recovery key will be used, therefore the number of failures in actual attacks will be higher than the theoretical analysis results.
[0178] Figures 6 to 8 The paper presents the average number of fault injections required to recover the final round key and master key in 10,000 experiments using three versions of the SIMON algorithm. It also compares the number of fault injections required to recover the final round key and master key in the random single-bit fault model with existing methods, and compares the number of fault injection rounds required to recover the master key.
[0179] In practical applications, by controlling the spatial and temporal precision of laser injection, fault injection can be targeted at a single bit of the cryptographic state, triggering a single-bit fault and thus performing related cryptanalysis. However, fault injection can irreversibly damage the device; therefore, minimizing the location and frequency of fault injections is crucial for differential fault attacks.
[0180] Depend on Figures 6 to 8 As can be seen, under the random single-bit fault model, compared with existing differential fault attack methods for the SIMON cryptographic algorithm, the differential fault attack method proposed in this application only requires injecting faults in one round to recover the master key, which is easy to implement and reduces the degree of damage to the encryption device.
[0181] Furthermore, whether recovering the round key of the last round of the algorithm or recovering the master key, the embodiments of this application require the fewest number of fault injections, meaning the attack requires the least data complexity. Therefore, this differential fault attack method of the embodiments of this application is more effective against the SIMON algorithm.
[0182] The embodiments of this application present a novel differential fault attack against the SIMON cryptographic algorithm. Besides its effectiveness in terms of lower attack complexity and fewer fault injection rounds, it also fully utilizes the characteristics of the AND operation in the algorithm's round functions. It directly obtains the input difference of the penultimate round from the ciphertext difference and, combined with fault propagation properties, quickly recovers the master key. For algorithm designers, improving the SIMON algorithm's resistance to differential fault attacks under a random single-bit fault model is essential.
[0183] Based on the above Figure 1 The differential fault analysis method shown in this application also provides a differential fault analysis device, such as... Figure 9 As shown, the differential fault analysis device 900 may include:
[0184] Encryption module 910 is used to obtain correct ciphertext by performing T rounds of encryption on plaintext using the SIMON algorithm, and to obtain incorrect ciphertext by injecting a random single-bit fault in the (T-5)th round of T rounds of encryption on plaintext using the SIMON algorithm; T is a positive integer greater than 5.
[0185] The determination module 920 is used to determine the fault injection location information of a random single-bit fault based on the ciphertext difference between the correct ciphertext and the incorrect ciphertext.
[0186] Analysis module 930 is used to inject random single-bit faults at different fault injection positions in round (T-5) according to the fault injection position information to obtain differential propagation trajectory, and analyze the differential propagation trajectory to obtain intermediate state information of round (T-5) and its corresponding round key.
[0187] Recovery module 940 is used to gradually recover the round keys of the last 4 rounds of encryption operations based on the round keys corresponding to the intermediate state information of round (T-5).
[0188] The determination module 950 is also used to determine the master key based on the round keys of the last four rounds of encryption operations that have been recovered, using the key expansion feature of the SIMON algorithm.
[0189] In one possible embodiment, the determining module 920 is specifically used for:
[0190] The propagation characteristics of a single-bit fault in five consecutive rounds were analyzed, and partial bit information of the input difference in the penultimate round and the input difference in other rounds was calculated.
[0191] Based on partial bit information from the ciphertext difference, the input difference of the penultimate round, and the input differences of other rounds, the fault injection location information of the random single-bit fault is determined.
[0192] In one possible embodiment, the determining module 920 is specifically used for:
[0193] Analyze the propagation characteristics of a single-bit fault in five consecutive rounds, and determine some bits of the input difference in the penultimate round based on the relationship between the low-order bits of the ciphertext difference and the output difference of the penultimate round.
[0194] By utilizing the propagation pattern of intermediate differences during fault propagation, the input difference up to the penultimate round is gradually derived.
[0195] In one possible embodiment, the analysis module 930 is further configured to analyze the propagation characteristics of a single-bit fault in five consecutive rounds, and determine the bits of the penultimate round output difference corresponding to the low-order bits of the ciphertext difference; the ciphertext difference is the difference between the correct ciphertext and the incorrect ciphertext.
[0196] The determination module 950 is also used to, in the penultimate round of the encryption operation, utilize the XOR operation and cyclic shift characteristics of the SIMON algorithm to propagate the output difference of the encryption operation in reverse to the input difference, thereby determining at least a portion of the bits of the input difference in the penultimate round.
[0197] In one possible embodiment, the differential fault analysis device 900 may further include:
[0198] The calculation module is used to calculate the input differences for the last three rounds based on the propagation properties of ciphertext differences and single-bit faults in the SIMON algorithm.
[0199] The determination module 950 is also used to determine the injection location information of a single-bit fault based on the input differentials of the last three rounds, and to establish a differential propagation trajectory table;
[0200] The derivation module is used to derive the intermediate state information of the last three rounds and their corresponding round keys step by step based on the differential propagation trajectory table.
[0201] In this embodiment, the plaintext is encrypted using the SIMON algorithm for T rounds to obtain the correct ciphertext, and an incorrect ciphertext is obtained by injecting a random single-bit fault in the (T-5)th round of the T-round encryption operation. T is a positive integer greater than 5. The fault injection location information of the random single-bit fault is determined based on the ciphertext difference between the correct and incorrect ciphertexts. By comparing the correct and incorrect ciphertexts, the impact of the fault injection on the encryption result can be observed, and the impact of the fault injection on the ciphertext can be analyzed to determine the specific location of the fault injection. After determining the fault injection location, the propagation path of the fault during the encryption process can be further analyzed. Based on the fault injection location information, a random single-bit fault is injected at different fault injection locations in the (T-5)th round to obtain a differential propagation trajectory. The differential propagation trajectory is analyzed to obtain the intermediate state information of the (T-5)th round and its corresponding round key. By observing the differential propagation trajectory of the fault during the encryption process and analyzing the differential propagation trajectory, the intermediate state information of the (T-5)th round and its corresponding round key can be inferred, providing a basis for further key recovery. Based on the round key corresponding to the intermediate state information of round (T-5), the round keys for the last four rounds of encryption are gradually recovered. Using the key expansion characteristic of the SIMON algorithm, the master key is determined based on the recovered round keys for the last four rounds of encryption. Thus, the key recovery for the SIMON algorithm is completed.
[0202] Figure 10 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application is shown.
[0203] An electronic device may include a processor 1001 and a memory 1002 storing computer program instructions.
[0204] Specifically, the processor 1001 may include a central processing unit (CPU), an application-specific integrated circuit (ASIC), or one or more integrated circuits that can be configured to implement the embodiments of this application.
[0205] Memory 1002 may include a large-capacity storage for data or instructions. For example, and not limitingly, memory 1002 may include a hard disk drive (HDD), a floppy disk drive, flash memory, optical disk, magneto-optical disk, magnetic tape, or a Universal Serial Bus (USB) drive, or a combination of two or more of these. Where appropriate, memory 1002 may include removable or non-removable (or fixed) media. Where appropriate, memory 1002 may be internal or external to the integrated gateway disaster recovery device. In a particular embodiment, memory 1002 is a non-volatile solid-state memory. In a particular embodiment, memory 1002 includes read-only memory (ROM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically rewritable ROM (EAROM), or flash memory, or a combination of two or more of these.
[0206] The processor 1001 implements any of the differential fault analysis methods in the embodiment shown in the figure by reading and executing computer program instructions stored in the memory 1002.
[0207] In one example, the electronic device may also include a communication interface 10010 and a bus 1010. For example, Figure 10 As shown, the processor 1001, memory 1002, and communication interface 10010 are connected through bus 1010 and complete communication with each other.
[0208] The communication interface 10010 is mainly used to realize communication between various modules, devices, units and / or equipment in the embodiments of this application.
[0209] Bus 1010 includes hardware, software, or both, that couples components of an electronic device together. For example, and not limitingly, the bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Enhanced Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), HyperTransport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an Infinite Bandwidth Interconnect, a Low Pin Count (LPC) bus, a memory bus, a Microchannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable buses, or combinations of two or more of these. Where appropriate, bus 1010 may include one or more buses. Although specific buses are described and illustrated in embodiments of this application, any suitable bus or interconnect is contemplated herein.
[0210] The electronic device can execute the differential fault analysis method in the embodiments of this application, thereby achieving a combination of Figure 1 The differential fault analysis method is described.
[0211] Furthermore, in conjunction with the differential fault analysis method in the above embodiments, this application embodiment can provide a computer-readable storage medium for implementation. This computer-readable storage medium stores computer program instructions; when these computer program instructions are executed by a processor, they implement… Figure 1 Differential fault analysis method.
[0212] It should be clarified that this application is not limited to the specific configurations and processes described above and shown in the figures. For the sake of brevity, detailed descriptions of known methods are omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of this application is not limited to the specific steps described and shown. Those skilled in the art can make various changes, modifications, and additions, or change the order of steps, after understanding the spirit of this application.
[0213] The functional blocks shown in the above-described structural diagram can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this application are programs or code segments used to perform the required tasks. Programs or code segments can be stored on a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried on a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, fiber optic media, radio frequency (RF) links, etc. Code segments can be downloaded via computer networks such as the Internet, intranets, etc.
[0214] It should also be noted that the exemplary embodiments mentioned in this application describe methods or systems based on a series of steps or apparatus. However, this application is not limited to the order of the above steps; that is, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.
[0215] The above description is merely a specific implementation of this application. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, modules, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. It should be understood that the protection scope of this application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and these modifications or substitutions should all be covered within the protection scope of this application.
Claims
1. A differential fault analysis method, characterized in that, The method includes: The correct ciphertext is obtained by performing T rounds of encryption on plaintext using the SIMON algorithm, and the incorrect ciphertext is obtained by injecting a random single-bit fault in the (T-5)th round of T rounds of encryption on plaintext using the SIMON algorithm; T is a positive integer greater than 5. Based on the ciphertext difference between the correct ciphertext and the incorrect ciphertext, the fault injection location information of the random single-bit fault is determined. Based on the fault injection location information, random single-bit faults are injected at different fault injection locations in round (T-5) to obtain differential propagation trajectories, and the intermediate state information of round (T-5) and its corresponding round key are obtained by analyzing the differential propagation trajectories. Based on the round key corresponding to the intermediate state information of round (T-5), the round keys for the last 4 rounds of encryption operations are gradually recovered; By utilizing the key expansion feature of the SIMON algorithm, the master key is determined based on the round keys of the last four rounds of encryption operations that have been recovered.
2. The method according to claim 1, characterized in that, The step of determining the fault injection location information of a random single-bit fault based on the ciphertext difference between the correct and incorrect ciphertext includes: The propagation characteristics of a single-bit fault in five consecutive rounds were analyzed, and partial bit information of the input difference in the penultimate round and the input difference in other rounds was calculated. Based on partial bit information from the ciphertext difference, the input difference of the penultimate round, and the input differences of other rounds, the fault injection location information of the random single-bit fault is determined.
3. The method according to claim 2, characterized in that, The analysis of the propagation characteristics of a single-bit fault over five consecutive rounds yields the input difference for the penultimate round, including: Analyze the propagation characteristics of a single-bit fault in five consecutive rounds, and determine some bits of the input difference in the penultimate round based on the relationship between the low-order bits of the ciphertext difference and the output difference of the penultimate round. By utilizing the propagation pattern of intermediate differences during fault propagation, the input difference up to the penultimate round is gradually derived.
4. The method according to claim 1, characterized in that, The method further includes: Analyze the propagation characteristics of a single-bit fault in five consecutive rounds to determine that the low-order bits of the ciphertext difference correspond to a portion of the output difference in the penultimate round; the ciphertext difference is the difference between the correct ciphertext and the incorrect ciphertext. In the penultimate round of the encryption operation, the XOR operation and cyclic shift characteristics of the SIMON algorithm are used to propagate the output difference of the encryption operation in reverse to the input difference, thereby determining at least some bits of the input difference in the penultimate round.
5. The method according to claim 1, characterized in that, The method further includes: Based on the propagation properties of ciphertext difference and single-bit fault in the SIMON algorithm, the input difference for the last three rounds is calculated. Based on the input differentials of the last three rounds, the injection location information of the single-bit fault is determined, and a differential propagation trajectory table is established. Based on the differential propagation trajectory table, the intermediate state information of the last three rounds and their corresponding round keys are derived step by step.
6. A differential fault analysis device, characterized in that, The differential fault analysis device includes: The encryption module is used to obtain the correct ciphertext by performing T rounds of encryption operations on plaintext using the SIMON algorithm, and to obtain the incorrect ciphertext by injecting a random single-bit fault in the (T-5)th round of T rounds of encryption operations on plaintext using the SIMON algorithm; T is a positive integer greater than 5. The determination module is used to determine the fault injection location information of random single-bit faults based on the ciphertext difference between the correct ciphertext and the incorrect ciphertext. The analysis module is used to inject random single-bit faults at different fault injection positions in round (T-5) based on the fault injection position information to obtain differential propagation trajectories, and analyze the differential propagation trajectories to obtain the intermediate state information of round (T-5) and its corresponding round key. The recovery module is used to gradually recover the round keys for the last 4 rounds of encryption operations based on the round keys corresponding to the intermediate state information of round (T-5). The determination module is also used to determine the master key based on the round keys of the last four rounds of encryption operations that have been recovered, using the key expansion feature of the SIMON algorithm.
7. The apparatus according to claim 6, characterized in that, The determining module is specifically used for: The propagation characteristics of a single-bit fault in five consecutive rounds were analyzed, and partial bit information of the input difference in the penultimate round and the input difference in other rounds was calculated. Based on partial bit information from the ciphertext difference, the input difference of the penultimate round, and the input differences of other rounds, the fault injection location information of the random single-bit fault is determined.
8. The apparatus according to claim 7, characterized in that, The determining module is specifically used for: Analyze the propagation characteristics of a single-bit fault in five consecutive rounds, and determine some bits of the input difference in the penultimate round based on the relationship between the low-order bits of the ciphertext difference and the output difference of the penultimate round. By utilizing the propagation pattern of intermediate differences during fault propagation, the input difference up to the penultimate round is gradually derived.
9. An electronic device, characterized in that, The electronic device includes: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, it implements the differential fault analysis method as described in any one of claims 1-5.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer program instructions that, when executed by a processor, implement the differential fault analysis method as described in any one of claims 1-5.
Citation Information
Patent Citations
Novel fault attack method for SKINNY-N-N algorithm
CN117811725A
System, method and computer readable medium for software protection via composable process-level virtual machines
US20180268130A1