Protection circuit, encryption chip and equipment for preventing side channel attack caused by light intensity change of indicator light
By isolating the power supply lines of the key management unit and the indicator light unit in the protection circuit, the problem that the indicator light intensity change during key verification in the prior art may be used to calculate the key, and the reliability of preventing side channel attacks is improved.
Patent Information
- Application Number
- CN202421088559.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-17
- Publication Date
- 2025-03-25
- Estimated Expiration
- 2034-05-17
AI Technical Summary
In the prior art, the method of preventing side channel attacks has the problem of poor reliability, especially when the light intensity change of the indicator light may be used to calculate the key during key verification.
A protection circuit is designed to prevent side channel attacks from being attacked by side channel by isolating the power supply line of the key management unit from the power supply line of the indicator light unit, so as to prevent the change in energy consumption during key verification from causing changes in the indicator light intensity.
It effectively protects the user's key security, data security and privacy security, and improves the reliability of preventing side channel attacks.
Smart Images

Figure CN222674331U_ABST
Abstract
Description
Technical Field
[0001] The utility model relates to the technical field of information security, and in particular to a protection circuit, an encryption chip and a device for preventing a side channel attack caused by a change in the light intensity of an indicator light. Background Art
[0002] As the name implies, a side channel attack is a method of obtaining additional information through unconventional information channels and obtaining secret information "indirectly". It is sometimes called a bypass attack. In practical applications, the cryptographic module in the electronic device to be protected will leak its internal state information in the form of energy consumption during operation. This information related to the key used by the cryptographic algorithm is called side information. The electronic devices to be protected are, for example, smart home devices and smart robots. In the process of attacking the cryptographic module, the attacker can use a variety of side information analysis techniques to recover secret information such as keys.
[0003] In the related art, there are two main methods to prevent side channel attacks: one is to change the side channel leakage characteristics of the encryption and decryption unit in the time dimension, which is mainly achieved by changing the execution time of the operation implemented by the encryption algorithm; the other is to hide the side channel leakage characteristics of the encryption unit in the amplitude dimension, which is mainly achieved by directly making the amount of side information of the operation performed by the encryption and decryption unit equal or random. However, the above two methods to prevent side channel attacks only increase the computational difficulty of side information analysis, and the key can still be deciphered through more complex side information analysis.
[0004] Considering that the light intensity of the indicator light changes when the password module in the protection device performs key verification, there is a risk of inferring the key based on the light intensity change of the indicator light. At present, there is no more effective solution to the above risk. Therefore, the side channel attack prevention method in the related art still has the problem of poor reliability. Utility Model Content
[0005] The embodiments of the utility model provide a protection circuit, encryption chip and device for preventing side-channel attacks caused by changes in the light intensity of an indicator light, so as to solve the problem in the prior art that there is a risk of calculating a key based on changes in the light intensity of an indicator light, thereby having poor reliability in preventing side-channel attacks.
[0006] In a first aspect, an embodiment of the utility model provides a protection circuit for preventing a side channel attack caused by a change in the light intensity of an indicator light, comprising: a key management unit, an indicator light unit, a first DC converter and a second DC converter; wherein:
[0007] One end of the first DC converter and one end of the second DC converter are respectively connected to the power supply, the other end of the first DC converter is connected to the key management unit; the other end of the second DC converter is connected to the indicator light unit;
[0008] The first DC converter is used to convert the first power supply current output by the power supply into a second power supply current required by the key management unit, and input the second power supply current into the key management unit to supply power to the key management unit;
[0009] The second DC converter is used to convert the first power supply current output by the power supply into a third power supply current required by the indicator light unit, and input the third power supply current into the indicator light unit to supply power to the indicator light unit.
[0010] The embodiment of the utility model provides a protection circuit for preventing the indicator light intensity change from performing a side channel attack, comprising: a key management unit, an indicator light unit, a first DC converter and a second DC converter; one end of the first DC converter and one end of the second DC converter are respectively connected to a power supply, and the power supply inputs the power supply current into the first DC converter and the second DC converter respectively; the other end of the first DC converter is connected to the key management unit; the other end of the second DC converter is connected to the indicator light unit. The first DC converter converts the first power supply current output by the power supply into the second power supply current required by the key management unit, and supplies power to the key management unit; the second DC converter converts the first power supply current output by the power supply into the third power supply current required by the indicator light unit, and supplies power to the indicator light unit. Thus, the power supply circuit of the key management unit is isolated from the power supply circuit of the indicator light unit. The utility model isolates the power supply circuit of the key management unit from the power supply circuit of the indicator light unit, thereby preventing the change of external energy consumption caused by key verification from the hardware, thereby causing the change of the light intensity of the LED indicator light, and then analyzing and calculating the key according to the waveform restored from the change of the light intensity of the LED indicator light, effectively protecting the key security, data security and privacy security of the user. The reliability of preventing side channel attacks is improved.
[0011] In an optional embodiment, it further includes: a protection unit; wherein:
[0012] One end of the protection unit is connected to the power supply, and the other end is connected to one end of the first DC converter and one end of the second DC converter respectively;
[0013] The protection unit is used to perform overcurrent protection on the key management unit and the indicator light unit;
[0014] The first DC converter is used to convert the first power supply current output by the power supply and passing through the protection unit into a second power supply current required by the key management unit, and input the second power supply current into the key management unit to supply power to the key management unit;
[0015] The second DC converter is used to convert the first power supply current output by the power supply and passing through the protection unit into a third power supply current required by the indicator light unit, and input the third power supply current into the indicator light unit to supply power to the indicator light unit.
[0016] In the embodiment of the utility model, overcurrent protection for the key management unit and the indicator light unit is achieved by setting a protection unit.
[0017] In an optional embodiment, the protection unit includes: a fuse and a thyristor; wherein:
[0018] One end of the thyristor is grounded; one end of the fuse is connected to the power supply; an ungrounded end of the thyristor and an end of the fuse not connected to the power supply are respectively connected to one end of the first DC converter and one end of the second DC converter.
[0019] In an optional embodiment, the first DC converter and the second DC converter respectively include: a DC-DC direct current-to-direct current converter.
[0020] In an optional embodiment, the first DC converter includes: a first capacitor, a first resistor, a second capacitor, a first DC-DC chip, a first inductor, a second resistor, a third resistor and a third capacitor; wherein:
[0021] One end of the first capacitor is grounded; one end of the second capacitor is grounded; the ungrounded end of the thyristor in the protection unit and the end of the fuse that is not connected to the power supply are connected to the ungrounded end of the first capacitor; the ungrounded end of the second capacitor is respectively connected to one end of the first resistor and the EN pin of the first DC-DC chip; the ungrounded end of the first capacitor is also connected to the other end of the first resistor; the end of the first resistor connected to the first capacitor is also connected to the VIN pin of the first DC-DC chip; the GND pin of the first DC-DC chip is grounded; the SW pin of the first DC-DC chip is connected to one end of the first inductor; the other end of the first inductor is respectively connected to one end of the second resistor and one end of the third capacitor; the other end of the third capacitor is grounded; one end of the third resistor is grounded; the other end of the third resistor is respectively connected to the end of the second resistor that is not connected to the first inductor and the FB pin of the first DC-DC chip; the ungrounded end of the third capacitor is also connected to the key management unit.
[0022] In an optional embodiment, the second DC converter includes: a fourth capacitor, a fourth resistor, a fifth capacitor, a second DC-DC chip, a second inductor, a fifth resistor, a sixth resistor and a sixth capacitor; wherein:
[0023] One end of the fourth capacitor is grounded; one end of the fifth capacitor is grounded; the ungrounded end of the thyristor in the protection unit and the end of the fuse that is not connected to the power supply are connected to the ungrounded end of the fourth capacitor; the ungrounded end of the fifth capacitor is respectively connected to one end of the fourth resistor and the EN pin of the second DC-DC chip; the ungrounded end of the fourth capacitor is also connected to the other end of the fourth resistor; the end of the fourth resistor connected to the fourth capacitor is also connected to the VIN pin of the second DC-DC chip; the GND pin of the second DC-DC chip is grounded; the SW pin of the second DC-DC chip is connected to one end of the second inductor; the other end of the second inductor is respectively connected to one end of the fifth resistor and one end of the sixth capacitor; the other end of the sixth capacitor is grounded; one end of the sixth resistor is grounded; the other end of the sixth resistor is respectively connected to one end of the fifth resistor that is not connected to the second inductor and the FB pin of the second DC-DC chip; the ungrounded end of the sixth capacitor is also connected to the indicator light unit.
[0024] In an optional embodiment, the indicator light unit comprises: an LED indicator light, a microcontroller unit MCU and a MOS tube; wherein;
[0025] The MOS tube is used to drive the LED indicator light;
[0026] The micro control unit MCU is used to control the LED indicator light.
[0027] In an optional embodiment, the indicator light unit further includes:
[0028] a seventh resistor, an eighth resistor, a seventh capacitor and a ninth resistor; wherein:
[0029] The IO pin of the microcontroller unit MCU is connected to one end of the seventh resistor; the other end of the seventh resistor is respectively connected to one end of the eighth resistor and the gate of the MOS tube; the other end of the eighth resistor is respectively connected to an ungrounded end of the sixth capacitor, one end of the seventh capacitor and the source of the MOS tube; the other end of the seventh capacitor is grounded; the drain of the MOS tube is connected to the anode of the LED indicator; the cathode of the LED indicator is connected to one end of the ninth resistor; and the other end of the ninth resistor is grounded.
[0030] In a second aspect, an embodiment of the utility model provides an encryption chip, including the above-mentioned protection circuit for preventing side channel attacks caused by changes in the light intensity of the indicator light.
[0031] In a third aspect, an embodiment of the utility model provides an electronic device, comprising the above-mentioned encryption chip.
[0032] For the technical effects that may be achieved by the encryption chip of the second aspect of the utility model and the electronic device of the third aspect of the utility model, please refer to the technical effects that can be achieved by the first aspect or various possible solutions in the first aspect, and no further details will be given here. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0034] Figure 1 A schematic diagram of the energy trace signal waveform and the key correspondence provided for the related technology;
[0035] Figure 2 A schematic diagram of the lighting principle of the LED indicator light provided by the utility model;
[0036] Figure 3 A schematic diagram of a protection circuit for preventing side channel attacks caused by changes in the light intensity of an indicator light provided by the utility model;
[0037] Figure 4 A schematic diagram of a protection circuit for preventing side channel attacks caused by changes in the light intensity of an indicator light provided by the utility model;
[0038] Figure 5 A circuit diagram of the protection unit provided by the utility model;
[0039] Figure 6 A circuit diagram of a first DC converter provided in an embodiment of the utility model;
[0040] Figure 7 A circuit diagram of a second DC converter provided in an embodiment of the utility model;
[0041] Figure 8 It is a circuit diagram of an indicator light unit in the related art;
[0042] Fig. 9 It is another indicator light unit circuit diagram in the related art;
[0043] Fig.10A schematic diagram of an indicator light unit circuit provided by an embodiment of the utility model;
[0044] Fig.11 A schematic diagram of an indicator light unit circuit provided by an embodiment of the utility model;
[0045] Fig.12 It is a schematic diagram of a power supply scheme in the related art;
[0046] Fig.13 This is a schematic diagram of the power supply solution provided by the utility model. DETAILED DESCRIPTION
[0047] The present invention will be further described in detail below in conjunction with the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0048] Unless otherwise defined, the technical or scientific terms used in the present invention shall have the usual meanings understood by persons with ordinary skills in the field to which the present invention belongs. The words "first", "second" and similar terms used in the present invention do not indicate any order, quantity or importance, but are only used to distinguish different components. Words such as "include" or "comprise" and the like mean that the elements or objects appearing before the word include the elements or objects listed after the word and their equivalents, without excluding other elements or objects. Words such as "connect" or "connected" and the like are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect.
[0049] In order to protect the user's information security, the plaintext data sent by the electronic device will be encrypted according to the key when passing through the key management unit to encrypt the plaintext data and form ciphertext data. However, in the process of encrypting the plaintext data, energy changes will occur. By obtaining the energy changes in the encryption process and using the energy analysis attack method, external personnel can decipher the key used by the encryption unit, thereby recovering the user information and causing the user information to be leaked.
[0050] In the related art, the external power supply passes through a DC converter to supply power to the key management unit and the indicator light unit respectively. The change in energy consumption during key verification by the key management unit causes a change in input current, and the current change may cause a change in the light intensity of the indicator light. There is a risk of obtaining the light intensity change curve through an observation device, and then calculating the energy change waveform during key verification, calculating the flip of the secret key '1', and thus analyzing and calculating the key.
[0051] The basic principle of SPA (Simple Power Analysis) attack is: Pt=Po+Pd+Pe+Pc, where Pt is the total energy consumption of the electronic device; Po is the operation component in the energy trace that depends on the operation performed by the electronic device, that is, the operation-dependent component, where the energy trace is a sampled signal of the energy consumption of the electronic device; Pd is the data component in the energy trace that depends on the processing of the electronic device, that is, the data-dependent component; Pe is electronic noise that is independent of the operation and data; and Pc is a constant that is independent of the operation and data.
[0052] When performing SPA attacks, each data bit in the key corresponds to a different operation, and different operations will leak side information of the key, that is, the key can be recovered according to the operation-dependent component Po. Taking the modular exponent in the RSA algorithm as an example, in the process of calculating the modular exponent "md mod n", the modular square calculation and modular multiplication calculation depend on whether the value of the corresponding bit of the private key "d" is 0 or 1. If it is 0, the modular square calculation is performed, and if it is 1, the modular multiplication calculation is performed.
[0053] The computation time of the two computation operations is significantly different, forming two different patterns in the energy trace signal. Based on this, the values of all bits of the private key can be recovered by observing the two patterns appearing in the energy trace, and thus the private key can be recovered. Figure 1 A schematic diagram of the energy trace signal waveform and the key corresponding to the related technology is provided, such as Figure 1 As shown in the figure, during the execution of modular exponentiation in the RSA algorithm, the sequential operations are "SS SM SM SSS SM SS SM SM SSS". Here, "S" represents the modular square operation, and the corresponding bit value is 0; "SM" represents the modular multiplication operation, and the corresponding bit value is 1, so the private key used by the RSA algorithm is "001100010011000".
[0054] In the related art, there are two main methods for preventing side channel attacks: one is to change the side channel leakage characteristics of the encryption and decryption unit in the time dimension, which is mainly achieved by changing the operation execution time implemented by the encryption algorithm; the other is to hide the side channel leakage characteristics of the encryption unit in the amplitude dimension, which is mainly achieved by directly making the amount of side information of the operation performed by the encryption and decryption unit equal or random. However, the above two methods for preventing side channel attacks only increase the computational difficulty of side information analysis, and the key can still be deciphered through more complex side information analysis. Considering that the change in energy consumption during key verification by the key management unit causes the input current to change, the current change may cause the light intensity of the indicator light to change. There is a risk of obtaining the light intensity change curve through the observation device, and then calculating the energy change waveform during key verification, calculating the flip of the secret key '1', and thus analyzing and calculating the key. Therefore, the utility model provides a protection circuit, encryption chip and device for preventing the light intensity change of the indicator light from performing side channel attacks. It is used to solve the problem of poor reliability of the side channel attack prevention method in the related art.
[0055] Figure 2 The schematic diagram of the light-emitting principle of the LED indicator light provided by the utility model is that the LED indicator light is a solid-state semiconductor device that can convert electrical energy into visible light. It can directly convert electricity into light. The semiconductor chip consists of two parts, one part is a P-type semiconductor, in which holes dominate, and the other end is an N-type semiconductor, which is mainly electrons. When these two semiconductors are connected, a PN junction is formed between them. When the current acts on the chip through the wire, the electrons will be pushed to the P area, and the electrons in the N-type semiconductor and the holes in the P-type semiconductor will collide and recombine violently in the light-emitting layer to produce photons, and then energy will be emitted in the form of photons. This is the principle of LED light emission.
[0056] The LED indicator light is a current control element. By controlling the current of the LED indicator light, the brightness and color temperature of the LED light can be controlled. The brightness and color temperature can be regarded as a linear relationship. Therefore, if the power supply current of the LED indicator light changes, its brightness will change. If the power supply current of the LED indicator light is constant, the brightness of the LED indicator light will not change. In the related art, the LED indicator light is driven and controlled by the IO pin of the MCU. When the voltage fluctuates due to the key operation, it cannot be ensured that the current flowing through the LED indicator light is constant, which will directly affect the brightness of the LED indicator light. There is a risk of obtaining the brightness change of the LED light, and then calculating the energy change of the key operation through the brightness change, and then recovering the key.
[0057] Based on the above considerations, the utility model isolates the power supply of the key management unit from the indicator light unit on the one hand. The power supplies of the key management unit and the indicator light unit are isolated by two DC-DCs, so that they will not affect each other, thereby avoiding the change in energy consumption of the key management unit during key verification causing the input current to change. The current change may cause the light intensity of the indicator light to change. There is a problem of obtaining the light intensity change curve through the observation device, and then calculating the energy change waveform during key verification, and analyzing and calculating the risk of the key. On the other hand, for the indicator light unit, MOS tubes are selected as drivers, and the IO port of the MCU is only used for control, which ensures the stability of the power supply voltage and current of the LED indicator light, and effectively prevents side channel attacks by observing the brightness changes of the LED indicator light.
[0058] The solution provided by the embodiment of the utility model is described in detail below with reference to the accompanying drawings.
[0059] Figure 3 The schematic diagram of the protection circuit for preventing the indicator light intensity change from being attacked by a side channel provided by the utility model includes: a key management unit 11, an indicator light unit 12, a first DC converter 13 and a second DC converter 14; wherein:
[0060] One end of the first DC converter 13 and one end of the second DC converter 14 are respectively connected to the power supply, the other end of the first DC converter 13 is connected to the key management unit 11; the other end of the second DC converter 14 is connected to the indicator light unit 12;
[0061] The first DC converter 13 is used to convert the first power supply current output by the power supply into a second power supply current required by the key management unit 11, and input the second power supply current into the key management unit 11 to supply power to the key management unit 11;
[0062] The second DC converter 14 is used to convert the first power supply current output by the power supply into a third power supply current required by the indicator light unit 12 , and input the third power supply current into the indicator light unit 12 to supply power to the indicator light unit 12 .
[0063] The embodiment of the utility model provides a protection circuit for preventing the indicator light intensity from changing and performing a side channel attack, comprising: a key management unit 11, an indicator light unit 12, a first DC converter 13 and a second DC converter 14; one end of the first DC converter 13 and one end of the second DC converter 14 are respectively connected to a power supply, and the power supply current output by the power supply is respectively input to the first DC converter 13 and the second DC converter 14; the other end of the first DC converter 13 is connected to the key management unit; the other end of the second DC converter 14 is connected to the indicator light unit. The power supply current required by the key management unit 11 itself may be the same as or different from the power supply current output by the power supply, and the function of the first DC converter 13 is to convert the first power supply current output by the power supply into the second power supply current required by the key management unit 11, and to supply power to the key management unit 11. The power supply current required by the indicator light unit may be the same as or different from the power supply current output by the power supply, and the function of the second DC converter 14 is to convert the first power supply current output by the power supply into the third power supply current required by the indicator light unit 12, and to supply power to the indicator light unit 12. The above hardware design realizes the isolation of the power supply circuit of the key management unit 11 from the power supply circuit of the indicator light unit 12. The utility model isolates the power supply circuit of the key management unit 11 from the power supply circuit of the indicator light unit 12, thereby preventing the change of external energy consumption caused by key verification, thereby causing the change of the light intensity of the LED indicator light, and then analyzing and calculating the key based on the waveform restored from the change of the light intensity of the LED indicator light, effectively protecting the key security, data security and privacy security of the user, and improving the reliability of preventing side channel attacks.
[0064] Figure 4 The schematic diagram of the protection circuit for preventing the indicator light intensity change from performing a side channel attack provided by the utility model also includes: a protection unit 15; wherein:
[0065] One end of the protection unit 15 is connected to the power supply, and the other end is connected to one end of the first DC converter 13 and one end of the second DC converter 14 respectively;
[0066] The protection unit 15 is used to perform overcurrent protection on the key management unit 11 and the indicator light unit 12;
[0067] The first DC converter 13 is used to convert the first power supply current output by the power supply through the protection unit 15 into a second power supply current required by the key management unit 11, and input the second power supply current into the key management unit 11 to supply power to the key management unit 11;
[0068] The second DC converter 14 is used to convert the first power supply current output by the power supply through the protection unit 15 into a third power supply current required by the indicator light unit 12 , and input the third power supply current into the indicator light unit 12 to supply power to the indicator light unit 12 .
[0069] By setting the protection unit 15, overcurrent protection is implemented for the key management unit 11 and the indicator light unit 12. In addition, the power supply current output by the power supply first passes through the protection unit 15, and then is input into the first DC converter 13 and the second DC converter 14 respectively. The first DC converter 13 is used to convert the first power supply current output by the power supply through the protection unit 15 into the second power supply current required by the key management unit 11, and supply power to the key management unit 11. The second DC converter 14 is used to convert the first power supply current output by the power supply through the protection unit 15 into the third power supply current required by the indicator light unit 12, and supply power to the indicator light unit 12.
[0070] Figure 5 The circuit diagram of the protection unit provided by the utility model includes a fuse F and a thyristor D; wherein:
[0071] One end of the thyristor D is grounded; one end of the fuse F is connected to the power supply; the ungrounded end of the thyristor D and the end of the fuse F not connected to the power supply are respectively connected to one end of the first DC converter 13 and one end of the second DC converter 14.
[0072] In the above circuit, the fuse F (fuse) mainly plays the role of overload protection. If the fuse F is correctly placed in the circuit, the fuse F will melt and cut off the current when the current abnormally rises to a certain height and temperature, thus protecting the safe operation of the circuit and realizing overcurrent protection for the key management unit and the indicator light unit.
[0073] The main function of thyristor D in the circuit is to achieve controlled rectification. When a positive voltage is applied between the cathode and anode of thyristor D and no signal is applied to the control electrode, thyristor D is in the off state. If a small positive voltage is applied between the control electrode and the cathode, thyristor D will be turned on. At this time, even if the control signal is removed, thyristor D can still remain turned on unless the anode power supply circuit is disconnected or the anode current is reduced to less than the holding current of thyristor D. Under normal circumstances, the current required to trigger thyristor D is equal to 1 / 100 to 1 / 1000 of the current flowing through thyristor D. When thyristor D is connected in series to the secondary winding of the arc welding transformer and the welding cable, it can not only convert AC into DC, but also control the size of the welding current with the cooperation of the corresponding electronic device. Thyristor D has only two working states, namely, on and off, and the current can only be adjusted by adjusting the conduction point (trigger angle) of thyristor D. The earlier the conduction time of thyristor D, the greater the power output to the load.
[0074] During the operation of thyristor D, its anode (A) and cathode (K) are connected to the power supply and load to form the main circuit of thyristor D. The gate G and cathode K of thyristor D are connected to the device for controlling the thyristor to form the control circuit of thyristor D. Thyristor D is a semi-controlled power electronic device. Its working conditions include: when thyristor D is subjected to reverse anode voltage, no matter what voltage the gate is subjected to, thyristor D is in reverse blocking state. When thyristor D is subjected to positive anode voltage, the thyristor is turned on only when the gate is subjected to positive voltage. At this time, thyristor D is in forward conduction state, which is the thyristor current characteristic of thyristor D, i.e., controllable characteristic. When thyristor D is turned on, as long as there is a certain positive anode voltage, no matter what the gate voltage is, thyristor D remains turned on, that is, after thyristor D is turned on, the gate loses its function. The gate only plays a triggering role. When thyristor D is turned on, when the main circuit voltage (or current) decreases to near zero, thyristor D is turned off.
[0075] In the embodiment of the utility model, the first DC converter and the second DC converter respectively include: a DC-DC direct current-to-direct current converter.
[0076] The DC-DC converter can convert any DC voltage into the required DC voltage.
[0077] Figure 6 A circuit diagram of a first DC converter provided in an embodiment of the utility model includes: a first capacitor C1, a first resistor R1, a second capacitor C2, a first DC-DC chip U1, a first inductor L1, a second resistor R2, a third resistor R3 and a third capacitor C3; wherein:
[0078] One end of the first capacitor C1 is grounded; one end of the second capacitor C2 is grounded; the ungrounded end of the thyristor D in the protection unit and the end of the fuse F that is not connected to the power supply are connected to the ungrounded end of the first capacitor C1; the ungrounded end of the second capacitor C2 is respectively connected to one end of the first resistor R1 and the EN pin of the first DC-DC chip U1; the ungrounded end of the first capacitor C1 is also connected to the other end of the first resistor R1; the end of the first resistor R1 connected to the first capacitor C1 is also connected to the VIN pin of the first DC-DC chip U1 ; The GND pin of the first DC-DC chip U1 is grounded; the SW pin of the first DC-DC chip U1 is connected to one end of the first inductor L1; the other end of the first inductor L1 is respectively connected to one end of the second resistor R2 and one end of the third capacitor C3; the other end of the third capacitor C3 is grounded; one end of the third resistor R3 is grounded; the other end of the third resistor R3 is respectively connected to one end of the second resistor R2 that is not connected to the first inductor L1 and the FB pin of the first DC-DC chip U1; the end of the third capacitor C3 that is not grounded is also connected to the key management unit 11.
[0079] pass Figure 6 The circuit of the first DC converter shown is capable of converting a first power supply current output by a power supply power source into a second power supply current required by a key management unit, and inputting the second power supply current into the key management unit to supply power to the key management unit; or is capable of converting a first power supply current output by the power supply power source and passing through a protection unit into a second power supply current required by a key management unit, and inputting the second power supply current into the key management unit to supply power to the key management unit.
[0080] Figure 7 A circuit diagram of a second DC converter provided by an embodiment of the utility model includes: a fourth capacitor C4, a fourth resistor R4, a fifth capacitor C5, a second DC-DC chip U2, a second inductor L2, a fifth resistor R5, a sixth resistor R6 and a sixth capacitor C6; wherein:
[0081] One end of the fourth capacitor C4 is grounded; one end of the fifth capacitor C5 is grounded; the ungrounded end of the thyristor D in the protection unit and the end of the fuse F that is not connected to the power supply are connected to the ungrounded end of the fourth capacitor C4; the ungrounded end of the fifth capacitor C5 is respectively connected to one end of the fourth resistor R4 and the EN pin of the second DC-DC chip U2; the ungrounded end of the fourth capacitor C4 is also connected to the other end of the fourth resistor R4; the end of the fourth resistor R4 connected to the fourth capacitor C4 is also connected to the VIN pin of the second DC-DC chip U2 ; The GND pin of the second DC-DC chip U2 is grounded; the SW pin of the second DC-DC chip U2 is connected to one end of the second inductor L2; the other end of the second inductor L2 is respectively connected to one end of the fifth resistor R5 and one end of the sixth capacitor C6; the other end of the sixth capacitor C6 is grounded; one end of the sixth resistor R6 is grounded; the other end of the sixth resistor R6 is respectively connected to one end of the fifth resistor R5 that is not connected to the second inductor L2 and the FB pin of the second DC-DC chip U2; the ungrounded end of the sixth capacitor C6 is also connected to the indicator light unit 12.
[0082] pass Figure 7 The circuit of the second DC converter shown in the figure converts the first power supply current output by the power supply power source into the third power supply current required by the indicator light unit, and inputs the third power supply current into the indicator light unit to power the indicator light unit; or converts the first power supply current output by the power supply power source and passed through the protection unit into the third power supply current required by the indicator light unit, and inputs the third power supply current into the indicator light unit to power the indicator light unit.
[0083] Figure 8 It is a circuit diagram of an indicator light unit in the related technology, including an MCU, an LED indicator light and a resistor Ra, wherein the IO pin of the MCU is connected to the anode of the LED indicator light, the cathode of the LED indicator light is connected to one end of the resistor Ra, and the other end of the resistor Ra is grounded. Figure 8 The indicator light unit circuit diagram shown is an indicator light unit circuit diagram driven by an IO pin high level.
[0084] Fig. 9 This is another indicator light unit circuit diagram in the related technology, including an MCU, an LED indicator light and a resistor Rb, wherein the IO pin of the MCU is connected to one end of the resistor Rb, the other end of the resistor Rb is connected to the cathode of the LED indicator light, and the anode of the LED indicator light is connected to the power input terminal. Fig. 9 The indicator light unit circuit diagram shown is an indicator light unit circuit diagram driven by a low level of the IO pin.
[0085] The IO pin level drive calculation formula is Iled =(V io -V led ) / R 1 .
[0086] Figure 8 and Fig. 9 The indicator light unit circuit diagram shown is a circuit diagram that directly uses the MCU's IO pin for drive control. This design cannot ensure that the current flowing through the LED indicator light is constant when the key calculation produces voltage fluctuations, which will directly affect the brightness of the LED indicator light. There is a risk of obtaining the brightness change of the LED indicator light, and then inferring the key calculation energy change through the brightness change, and then recovering the key.
[0087] Based on the above considerations, an embodiment of the utility model proposes a circuit diagram of an indicator light unit. Fig.10 The schematic diagram of the indicator light unit circuit provided by the embodiment of the utility model includes an LED indicator light 21, a microcontroller unit MCU22 and a MOS tube 23; wherein;
[0088] The MOS tube 23 is used to drive the LED indicator light 21;
[0089] The micro control unit MCU22 is used to control the LED indicator light 22 .
[0090] The utility model does not use the IO port of the MCU for drive control during hardware design, but selects a MOS tube for drive, and the IO port of the MCU is only used for control, thereby ensuring the stability of the power supply voltage and current of the LED indicator light, and effectively preventing side channel attacks by observing the brightness changes of the LED indicator light.
[0091] Fig.11 The schematic diagram of the indicator light unit circuit provided by the embodiment of the utility model, the indicator light unit also includes:
[0092] A seventh resistor R7, an eighth resistor R8, a seventh capacitor C7 and a ninth resistor R9; wherein:
[0093] The IO pin of the microcontroller unit MCU22 is connected to one end of the seventh resistor R7; the other end of the seventh resistor R7 is respectively connected to one end of the eighth resistor R8 and the gate of the MOS tube 23; the other end of the eighth resistor R8 is respectively connected to an ungrounded end of the sixth capacitor C6, one end of the seventh capacitor C7 and the source of the MOS tube 23; the other end of the seventh capacitor C7 is grounded; the drain of the MOS tube 23 is connected to the anode of the LED indicator 21; the cathode of the LED indicator 21 is connected to one end of the ninth resistor R9; the other end of the ninth resistor R9 is grounded.
[0094] The P-channel MOS tube drives the LED indicator light, with low-level driving and high-level cutoff. The LED indicator light adopts PWM control. When the control IO port of the MCU outputs a low level, the MOS tube turns on and the LED indicator lightens. Conversely, when the control IO port of the MCU outputs a high level, the MOS tube turns off and the LED indicator lightens.
[0095] It should be noted that: the MOS tube needs to work in the cut-off area and the saturation area; the seventh resistor is a voltage-dividing resistor, which makes the MOS tube work in the cut-off area and the saturation area; the seventh capacitor is a filter capacitor, which effectively filters out high-frequency interference from the power supply; the eighth resistor is a pull-up resistor, which performs voltage-dividing driving on the MOS tube, so that the MOS tube works in the cut-off area and the saturation area; the ninth resistor is a current-limiting resistor, which prevents the LED indicator from burning out due to excessive working current.
[0096] The utility model makes full use of the characteristic that the brightness of the LED indicator light is determined by the current, reconstructs the power supply scheme, and adopts the hardware design of driving the LED indicator light with a P-channel MOS tube, so as to ensure that the power supply voltage fluctuation caused by the key operation will not cause the current change of the LED indicator light, and prevent the indirect acquisition of the key operation information through the change of the LED light brightness; the utility model does not change the key information encoding algorithm, and will not increase the calculation time cost. The utility model cuts off the acquisition of the relevant information generated by the key operation from the source, and directly avoids the possibility of side channel attacks.
[0097] Fig.12 The schematic diagram of the power supply scheme in the related art includes a protection unit, a DC converter, a key management unit and an indicator light unit. The protection unit is connected to the power supply and the DC converter respectively, and the DC converter is also connected to the key management unit and the indicator light unit respectively. Fig.13 A schematic diagram of a power supply scheme provided by the utility model includes a protection unit, a first DC converter, a second DC converter, a key management unit and an indicator light unit. The protection unit is connected to the power supply, the first DC converter and the second DC converter respectively, the first DC converter is also connected to the key management unit, and the second DC converter is also connected to the indicator light unit.
[0098] In addition, the utility model adopts the design of using a P-channel MOS tube to drive the LED indicator light, and the IO port of the MCU is used as the control pin. The MOS tube is a voltage-controlled device, that is, as long as the voltage of the G pole is 1V lower than that of the S pole, the MOS tube is in a fully conductive state, and the voltage drop of the MOS tube and the voltage drop of the LED lamp are constant. The constant voltage at the input end of the indicator light unit can ensure that the current flowing through the LED indicator light is constant, and the brightness of the LED indicator light does not change. The possibility of side channel attacks is further avoided.
[0099] Based on the same concept, the embodiment of the utility model also provides an encryption chip, including a protection circuit for preventing side channel attacks caused by changes in the light intensity of the indicator light as provided in any of the above embodiments. The principle of solving the problem by the encryption chip is similar to that of the protection circuit for preventing side channel attacks caused by changes in the light intensity of the indicator light, so the implementation of the encryption chip can refer to the implementation of the protection circuit for preventing side channel attacks caused by changes in the light intensity of the indicator light, and the repeated parts will not be repeated.
[0100] Based on the same concept, the embodiment of the utility model also provides an electronic device, including the encryption chip provided in the above embodiment. The principle of solving the problem by the electronic device is similar to that of the above encryption chip, so the implementation of the electronic device can refer to the implementation of the above encryption chip, and the repeated parts will not be repeated.
[0101] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present invention.
[0102] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A protection circuit for preventing side channel attacks caused by changes in the light intensity of an indicator light, characterized in that: include: A key management unit, an indicator light unit, a first DC converter and a second DC converter; wherein: One end of the first DC converter and one end of the second DC converter are respectively connected to the power supply, the other end of the first DC converter is connected to the key management unit; the other end of the second DC converter is connected to the indicator light unit; The first DC converter is used to convert the first power supply current output by the power supply into a second power supply current required by the key management unit, and input the second power supply current into the key management unit to supply power to the key management unit; The second DC converter is used to convert the first power supply current output by the power supply into a third power supply current required by the indicator light unit, and input the third power supply current into the indicator light unit to supply power to the indicator light unit.
2. The circuit according to claim 1, characterized in that Also includes: Protection unit; wherein: One end of the protection unit is connected to the power supply, and the other end is connected to one end of the first DC converter and one end of the second DC converter respectively; The protection unit is used to perform overcurrent protection on the key management unit and the indicator light unit; The first DC converter is used to convert the first power supply current output by the power supply and passing through the protection unit into a second power supply current required by the key management unit, and input the second power supply current into the key management unit to supply power to the key management unit; The second DC converter is used to convert the first power supply current output by the power supply and passing through the protection unit into a third power supply current required by the indicator light unit, and input the third power supply current into the indicator light unit to supply power to the indicator light unit.
3. The circuit according to claim 2, characterized in that The protection unit comprises: a fuse and a thyristor; wherein: One end of the thyristor is grounded; one end of the fuse is connected to the power supply; the ungrounded end of the thyristor and the end of the fuse not connected to the power supply are respectively connected to one end of the first DC converter and one end of the second DC converter.
4. The circuit according to claim 3, characterized in that The first DC converter and the second DC converter include: a DC-DC converter.
5. The circuit according to claim 4, characterized in that The first DC converter includes: a first capacitor, a first resistor, a second capacitor, a first DC-DC chip, a first inductor, a second resistor, a third resistor and a third capacitor; wherein: One end of the first capacitor is grounded; one end of the second capacitor is grounded; the ungrounded end of the thyristor in the protection unit and the end of the fuse that is not connected to the power supply are connected to the ungrounded end of the first capacitor; the ungrounded end of the second capacitor is respectively connected to one end of the first resistor and the EN pin of the first DC-DC chip; the ungrounded end of the first capacitor is also connected to the other end of the first resistor; the end of the first resistor connected to the first capacitor is also connected to the VIN pin of the first DC-DC chip; the GND pin of the first DC-DC chip is grounded; the SW pin of the first DC-DC chip is connected to one end of the first inductor; the other end of the first inductor is respectively connected to one end of the second resistor and one end of the third capacitor; the other end of the third capacitor is grounded; one end of the third resistor is grounded; the other end of the third resistor is respectively connected to the end of the second resistor that is not connected to the first inductor and the FB pin of the first DC-DC chip; the ungrounded end of the third capacitor is also connected to the key management unit.
6. The circuit according to claim 4, characterized in that The second DC converter includes: a fourth capacitor, a fourth resistor, a fifth capacitor, a second DC-DC chip, a second inductor, a fifth resistor, a sixth resistor and a sixth capacitor; wherein: One end of the fourth capacitor is grounded; one end of the fifth capacitor is grounded; the ungrounded end of the thyristor in the protection unit and the end of the fuse that is not connected to the power supply are connected to the ungrounded end of the fourth capacitor; the ungrounded end of the fifth capacitor is respectively connected to one end of the fourth resistor and the EN pin of the second DC-DC chip; the ungrounded end of the fourth capacitor is also connected to the other end of the fourth resistor; the end of the fourth resistor connected to the fourth capacitor is also connected to the VIN pin of the second DC-DC chip; the GND pin of the second DC-DC chip is grounded; the SW pin of the second DC-DC chip is connected to one end of the second inductor; the other end of the second inductor is respectively connected to one end of the fifth resistor and one end of the sixth capacitor; the other end of the sixth capacitor is grounded; one end of the sixth resistor is grounded; the other end of the sixth resistor is respectively connected to one end of the fifth resistor that is not connected to the second inductor and the FB pin of the second DC-DC chip; the ungrounded end of the sixth capacitor is also connected to the indicator light unit.
7. The circuit according to claim 6, characterized in that The indicator light unit comprises: an LED indicator light, a microcontroller unit MCU and a MOS tube; wherein; The MOS tube is used to drive the LED indicator light; The micro control unit MCU is used to control the LED indicator light.
8. The circuit according to claim 7, characterized in that The indicator light unit also includes: a seventh resistor, an eighth resistor, a seventh capacitor and a ninth resistor; wherein: The IO pin of the microcontroller unit MCU is connected to one end of the seventh resistor; the other end of the seventh resistor is respectively connected to one end of the eighth resistor and the gate of the MOS tube; the other end of the eighth resistor is respectively connected to an ungrounded end of the sixth capacitor, one end of the seventh capacitor and the source of the MOS tube; the other end of the seventh capacitor is grounded; the drain of the MOS tube is connected to the anode of the LED indicator; the cathode of the LED indicator is connected to one end of the ninth resistor; and the other end of the ninth resistor is grounded.
9. An encryption chip, characterized in that: The invention comprises a protection circuit for preventing a side channel attack caused by a change in the light intensity of an indicator light as described in any one of claims 1 to 8.
10. An electronic device, characterized in that: Comprising the encryption chip as described in claim 9.