True random number generator circuit and true random number system
By using physically uncloned function circuits and random self-calibration circuits in the true random number generator circuit, combined with the counter's metastable state oscillation signal processing, the problems of large area and high power consumption in the traditional circuit are solved, and high-quality and low-power true random number generation is achieved.
Patent Information
- Application Number
- CN202411955068.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-27
- Publication Date
- 2025-04-18
Smart Images

Figure CN119847478A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of true random numbers, and in particular to a true random number generator circuit and a true random number system. Background Art
[0002] A true random number generator circuit is an electronic circuit that can generate truly random numbers. The traditional true random number generator circuit includes an entropy source, a sampling circuit, and a post-processing circuit, wherein the entropy source is the source of randomness in the true random number generator, which determines the available entropy of the output sequence; the sampling circuit is responsible for quantizing the randomness in the entropy source into a random binary sequence; the post-processing circuit is used to further process the sampled binary sequence to improve the randomness of the generated data.
[0003] However, if high-quality true random numbers are generated based on the traditional true random number generator circuit, a large number of circuits are required as entropy sources. At the same time, the post-processing circuit also needs to be set up as a more complex circuit, which will result in a large area and high power consumption for the entire true random number generator circuit. Summary of the invention
[0004] Based on this, it is necessary to provide a true random number generator circuit and a true random number system with low power consumption and high reliability.
[0005] In a first aspect, a true random number generator circuit is provided, comprising:
[0006] A random self-calibration circuit, the random self-calibration circuit is used to randomly generate configuration parameters;
[0007] A physical unclonable function circuit, wherein a first input end of the physical unclonable function circuit is connected to an output end of the random self-calibration circuit, and a second input end of the physical unclonable function circuit is used to access a trigger signal; the physical unclonable function circuit is used to output an entropy source signal via a transmission path corresponding to a configuration parameter when receiving a trigger signal;
[0008] A counter, wherein an input end of the counter is connected to an output end of the physical unclonable function circuit; the counter is used to count a metastable oscillation signal in an entropy source signal to generate and output a counting result;
[0009] A comparator, wherein the input end of the comparator is connected to the first output end of the counter to receive the counting result, and when the counting result is greater than or equal to a preset threshold, the second output end of the counter is controlled to output a true random number, wherein the true random number is a value of at least one digit in the counting result; the output end of the comparator is connected to the input end of the random self-calibration circuit, and the comparator is used to trigger the random self-calibration module to work when the counting result is less than the preset threshold.
[0010] In one embodiment, the true random number is the value of the lowest digit in the counting result.
[0011] In one embodiment, the counter is used to output a counting result when the entropy source signal is in a stable state.
[0012] In one embodiment, the counter is further configured to output a counting result when no metastable oscillation signal is continuously received within a preset time.
[0013] In one embodiment, the number of rising edges in the entropy source signal is the number of metastable oscillation signals.
[0014] In one embodiment, the counter is a binary counter.
[0015] In one embodiment, the physical unclonable function circuit includes:
[0016] A plurality of delay circuits are connected in series, the controlled end of each delay circuit is connected to the output end of the random self-calibration circuit, and the first input end and the second input end of the first delay circuit are respectively used to access the trigger signal;
[0017] An arbitrator, wherein the first input terminal of the arbitrator is connected to the first output terminal of the last-stage delay circuit, and the second input terminal of the arbitrator is connected to the second output terminal of the last-stage delay circuit; the arbitrator is used to output a metastable oscillation signal when the two input terminals simultaneously receive a trigger signal.
[0018] In one embodiment, each delay circuit includes two symmetrically placed two-to-one selectors;
[0019] Wherein, each of the two-to-one selectors in the first-stage delay circuit is connected to the trigger signal via the first input terminal and the second input terminal of the first-stage delay circuit respectively.
[0020] In one embodiment, the random self-calibration circuit is a pseudo-random number generator.
[0021] In a second aspect, a true random number system is provided, comprising: a signal verification module and the true random number generator circuit described above;
[0022] The input end of the signal verification module is connected to the second output end of the counter; the signal verification module is used to work when receiving a true random number output by the counter.
[0023] The above-mentioned true random number generator circuit and true random number system include a random self-calibration circuit, a physical unclonable function circuit, a counter and a comparator, wherein the random self-calibration circuit randomly generates configuration parameters to the physical unclonable function circuit to configure the transmission path of the trigger signal input to the physical unclonable function circuit; when the physical unclonable function circuit receives the trigger signal, the entropy source signal is output to the counter via the transmission path corresponding to the configuration parameter; the counter accumulates the metastable oscillation signal in the entropy source signal to generate and output the counting result to the comparator; when the counting result is less than a preset threshold, the comparator triggers the random self-calibration module to work, outputs new configuration parameters to the physical unclonable function circuit, and re-determines the counting result until the counting result is greater than or equal to the above-mentioned preset threshold, and controls the counter to output a true random number. Compared with the true random number generator circuit of the traditional scheme, the true random number generator circuit provided in the present application adopts a physical unclonable function circuit as an entropy source, and correspondingly, it is no longer necessary to set up a corresponding complex post-processing circuit to process the binary sequence, thereby greatly reducing the complexity and power consumption of the true random number generator circuit; and the random generation of configuration parameters can ensure the randomness of the trigger signal transmission path, thereby making the output of the metastable oscillation signal also random, thereby increasing the randomness of the final true random number, and, according to the counting result determined by the metastable oscillation signal, the true random number is output only when it is greater than or equal to the preset threshold, which can greatly improve the quality of the true random number. Further, high-quality true random numbers can resist the influence of environmental factors such as temperature and voltage, so the stability and reliability of the true random number generator circuit of the present application are high. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the conventional technology, the drawings required for use in the embodiments or the conventional technology descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0025] Figure 1 One of the structural block diagrams of a true random number generator circuit according to an embodiment;
[0026] Figure 2 is a waveform diagram of an entropy source signal of an embodiment;
[0027] Figure 3 This is the second structural block diagram of a true random number generator circuit according to an embodiment. DETAILED DESCRIPTION
[0028] In order to facilitate understanding of the present application, the present application will be described more fully below with reference to the relevant drawings. Embodiments of the present application are provided in the drawings. However, the present application can be implemented in many different forms and is not limited to the embodiments described herein. On the contrary, the purpose of providing these embodiments is to make the disclosure of the present application more thorough and comprehensive.
[0029] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application.
[0030] It is understood that the terms "first", "second", etc. used in this application may be used herein to describe various elements, but these elements are not limited by these terms. These terms are only used to distinguish a first element from another element. For example, without departing from the scope of this application, a first input terminal may be referred to as a second input terminal, and similarly, a second input terminal may be referred to as a first input terminal. Both the first input terminal and the second input terminal are input terminals, but they are not the same input terminal.
[0031] It can be understood that the “connection” in the following embodiments should be understood as “electrical connection”, “communication connection”, etc. if the connected circuits, modules, units, etc. have electrical signals or data transmission between each other.
[0032] It is understood that “plurality” refers to two or more than two, and “at least a portion of an element” refers to a portion or all of an element.
[0033] When used herein, the singular forms "a", "an", and "said / the" may also include plural forms, unless the context clearly indicates otherwise. It should also be understood that the terms "include / comprise" or "have" etc. specify the presence of stated features, wholes, steps, operations, components, parts or combinations thereof, but do not exclude the possibility of the presence or addition of one or more other features, wholes, steps, operations, components, parts or combinations thereof.
[0034] In one embodiment, a true random number generator circuit 100 is provided, comprising: a random self-calibration circuit 102 , a physical unclonable function circuit 104 , a counter 106 , and a comparator 108 .
[0035] The random self-calibration circuit 102 is used to randomly generate configuration parameters.
[0036] Randomly generated configuration parameters can effectively resist interference from environmental factors such as temperature and voltage.
[0037] The first input end of the physical unclonable function circuit 104 is connected to the output end of the random self-calibration circuit 102, and the second input end of the physical unclonable function circuit 104 is used to access the trigger signal; the physical unclonable function circuit 104 is used to output the entropy source signal through the transmission path corresponding to the configuration parameters when receiving the trigger signal.
[0038] The configuration parameters determine the internal routing of the physical unclonable function circuit 104. After the trigger signal is input to the physical unclonable function circuit 104, it is transmitted via the transmission path of the internal routing determined by the configuration parameters. It should be noted that different configuration parameters have different transmission paths corresponding to the configuration parameters. The configuration parameters may be n-bit parameter data.
[0039] An input end of the counter 106 is connected to an output end of the physical unclonable function circuit 104 ; the counter 106 is used to count the metastable oscillation signal in the entropy source signal to generate and output a counting result.
[0040] The entropy source signal output by the physical unclonable function circuit 104 includes a metastable oscillation signal and a stable signal. When the entropy source signal output by the physical unclonable function circuit 104 is a stable signal, it means that the trigger signal is normally transmitted in the physical unclonable function circuit 104; when the entropy source signal output by the physical unclonable function circuit 104 is a metastable oscillation signal, it means that the physical unclonable function circuit 104 has entered an unstable state. The counter 106 can obtain a counting result with high randomness by accumulating the metastable oscillation signal output by the physical unclonable function circuit 104 when it is unstable.
[0041] The input end of the comparator 108 is connected to the first output end of the counter 106 to receive the counting result, and when the counting result is greater than or equal to the preset threshold, the second output end of the counter 106 is controlled to output a true random number, where the true random number is a value of at least one digit in the counting result; the output end of the comparator 108 is connected to the input end of the random self-calibration circuit 102, and the comparator 108 is used to trigger the random self-calibration module to work when the counting result is less than the preset threshold.
[0042] The setting of the preset threshold can ensure the quality of true random numbers. Generally speaking, the larger the preset threshold is, the higher the threshold for outputting true random numbers is, and the better the quality of the obtained true random numbers is. Therefore, the size of the preset threshold can be determined according to the quality requirements for true random numbers in actual applications.
[0043] The true random number is the value of at least one digit in the counting result, which can be understood as follows: the output true random number can be a digit in the counting result, such as the value corresponding to the lowest or highest digit of the counting result; the output true random number can also be multiple digits in the counting result, such as the value corresponding to the combination of the lowest and second lowest digits in the counting result, the third and fifth digits in the counting result, the lowest and highest digits in the counting result, etc.
[0044] Therefore, the above-mentioned true random number generator circuit 100 includes a random self-calibration circuit 102, a physical unclonable function circuit 104, a counter 106 and a comparator 108, wherein the random self-calibration circuit 102 randomly generates configuration parameters to the physical unclonable function circuit 104 to configure the transmission path of the trigger signal input into the physical unclonable function circuit 104; when the physical unclonable function circuit 104 receives the trigger signal, the entropy source signal is output to the counter 106 via the transmission path corresponding to the configuration parameter; the counter 106 accumulates the metastable oscillation signal in the entropy source signal to generate and output the counting result to the comparator 108; when the counting result is less than the preset threshold, the comparator 108 triggers the random self-calibration module to work, so as to output new configuration parameters to the physical unclonable function circuit 104, and re-determine the counting result until the counting result is greater than or equal to the above-mentioned preset threshold, and then controls the counter 106 to output a true random number. Compared with the true random number generator circuit 100 of the traditional scheme, the true random number generator circuit 100 provided in the present application adopts the physical unclonable function circuit 104 as the entropy source, and accordingly, it is no longer necessary to set up a corresponding complex post-processing circuit to process the binary sequence, thereby greatly reducing the complexity and power consumption of the true random number generator circuit 100; and the random generation of the configuration parameters can ensure the randomness of the trigger signal transmission path, thereby making the output of the metastable oscillation signal also random, thereby increasing the randomness of the final true random number, and the counting result determined according to the metastable oscillation signal is greater than or equal to the preset threshold value, and the true random number is output, which can greatly improve the quality of the true random number. Further, high-quality true random numbers can resist the influence of environmental factors such as temperature and voltage, so the stability and reliability of the true random number generator circuit 100 of the present application are high.
[0045] In one embodiment, the true random number is the value of the lowest digit in the counting result.
[0046] When there is a counting result, the lowest digit in the counting result must exist. Therefore, outputting the value of the lowest digit in the counting result can ensure the normal output of the true random number.
[0047] In one embodiment, the counter 106 is configured to output a counting result when the entropy source signal is in a stable state.
[0048] When the entropy source signal is in a stable state, it can be considered that the metastable state of the physical unclonable function circuit 104 has disappeared, and the output entropy source signal enters a stable state as a stable signal. At this time, the counting result is no longer accumulated, and the determined counting result can be transmitted to the comparator 108 for comparison operation.
[0049] It should be noted that the conversion from the metastable state to the stable state of the physical unclonable function circuit 104 can be completed automatically without the input of other signals.
[0050] In one embodiment, the counter 106 is further configured to output a counting result when no metastable oscillation signal is continuously received within a preset time.
[0051] When no metastable oscillation signal is continuously received within a preset time, it can be considered that the metastable state of the physical unclonable function circuit 104 has disappeared, and the counting result at this time does not change any more, so the counting result is output to the comparator 108 .
[0052] In one embodiment, Figure 2 As shown, the number of rising edges in the entropy source signal is the number of metastable oscillation signals.
[0053] The low-level signal in the entropy source signal is a stable signal, and the high-level signal is a metastable oscillation signal. By accumulating the number of rising edges in the entropy source signal, the number of metastable oscillation signals can be determined.
[0054] In one embodiment, counter 106 is a binary counter.
[0055] The binary counter has a simple structure, can maintain good performance at high-speed operation, and can be seamlessly integrated with other parts of the computer, thereby improving data processing efficiency and compatibility with other circuits. Therefore, the use of a binary counter can improve the compatibility of the true random number generator circuit 100 with other external circuits and expand the scope of application.
[0056] In one embodiment, Figure 3 As shown, the physical unclonable function circuit 104 includes: a multi-stage delay circuit 1042 and an arbiter 1044 connected in series.
[0057] The controlled end of each delay circuit 1042 is connected to the output end of the random self-calibration circuit 102 , and the first input end and the second input end of the first-stage delay circuit 1042 are respectively used to access the trigger signal.
[0058] The first input terminal of the arbitrator 1044 is connected to the first output terminal of the last-stage delay circuit 1042, and the second input terminal of the arbitrator 1044 is connected to the second output terminal of the last-stage delay circuit 1042; the arbitrator 1044 is used to output a metastable oscillation signal when the two input terminals receive trigger signals at the same time.
[0059] Due to the process deviations in the manufacturing process of the chips of each delay circuit 1042, in actual application, the delays experienced by the two trigger signals are different, and the delay difference changes with the change of configuration parameters. Therefore, when the two input ends of the arbiter 1044 receive the trigger signal at the same time, the output end of the arbiter 1044 will be metastable, thereby outputting a metastable oscillation signal.
[0060] In one embodiment, Figure 3 As shown, each delay circuit 1042 includes two symmetrically placed two-to-one selectors (m1 and m2).
[0061] Each of the two-to-one selectors in the first-stage delay circuit 1042 is connected to the trigger signal via the first input terminal and the second input terminal of the first-stage delay circuit 1042 .
[0062] Specifically, the first input terminal A1 of the two-to-one selector m1 is connected to the first input terminal B1 of the two-to-one selector m2, and the first input terminal A1 of the two-to-one selector m1 is also used to access the trigger signal. The second input terminal A2 of the two-to-one selector m1 is connected to the second input terminal B2 of the two-to-one selector m2, and the second input terminal A2 of the two-to-one selector m1 is also used to access the trigger signal.
[0063] It should be noted that the connection method of the two symmetrically placed two-to-one selectors in each delay circuit 1042 is consistent with the connection method of the two two-to-one selectors in the first-stage delay circuit 1042, which will not be repeated here.
[0064] Based on the above connection method, the configuration parameters can determine whether the trigger signal passes through each stage of the delay circuit 1042 in a parallel transmission or a cross transmission manner.
[0065] In one embodiment, the random self-calibration circuit 102 is a pseudo-random number generator.
[0066] The pseudo-random number generator generates random numbers through an algorithm, and its output can remain stable and predictable over a long period of time. With the introduction of the self-calibration mechanism, the quality of the random numbers can be monitored and corrected in real time to ensure continuous output reliability, thereby improving the reliability of the true random number generator circuit 100.
[0067] In one embodiment, a true random number system includes: a signal verification module and the true random number generator circuit described above.
[0068] The input end of the signal verification module is connected to the second output end of the counter; the signal verification module is used to work when receiving a true random number output by the counter.
[0069] The signal verification module can be a reminder module with a reminder function, which can remind the staff through sound and light, etc. when receiving the true random number output by the counter, that a true random number has been output and the next step of work can be carried out; the signal verification module can also be a display module, which can display the generated true random number in a visual way through a display screen, etc. when the true random number is output by the counter.
[0070] In the description of this specification, the description with reference to the terms "some embodiments", "other embodiments", etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic description of the above terms does not necessarily refer to the same embodiment or example.
[0071] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0072] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A true random number generator circuit, characterized in that: include: A random self-calibration circuit, wherein the random self-calibration circuit is used to randomly generate configuration parameters; A physical unclonable function circuit, wherein a first input end of the physical unclonable function circuit is connected to an output end of the random self-calibration circuit, and a second input end of the physical unclonable function circuit is used to access a trigger signal; the physical unclonable function circuit is used to output an entropy source signal via a transmission path corresponding to the configuration parameter when receiving a trigger signal; A counter, wherein an input end of the counter is connected to an output end of the physical unclonable function circuit; The counter is used to count the metastable oscillation signal in the entropy source signal to generate and output a counting result; A comparator, wherein the input end of the comparator is connected to the first output end of the counter to receive the counting result, and when the counting result is greater than or equal to a preset threshold, the comparator controls the second output end of the counter to output a true random number, wherein the true random number is a value of at least one digit in the counting result; the output end of the comparator is connected to the input end of the random self-calibration circuit, and the comparator is used to trigger the random self-calibration module to work when the counting result is less than the preset threshold.
2. The true random number generator circuit according to claim 1, characterized in that: The true random number is the value of the lowest digit in the counting result.
3. The true random number generator circuit according to claim 1, characterized in that: The counter is used to output the counting result when the entropy source signal is in a stable state.
4. The true random number generator circuit according to claim 1, characterized in that: The counter is further configured to output the counting result when the metastable oscillation signal is not received continuously within a preset time.
5. The true random number generator circuit according to claim 1, characterized in that: The number of rising edges in the entropy source signal is the number of the metastable oscillation signals.
6. The true random number generator circuit according to claim 1, characterized in that: The counter is a binary counter.
7. The true random number generator circuit according to claim 1, characterized in that: The physical unclonable function circuit comprises: A plurality of delay circuits connected in series, wherein the controlled end of each delay circuit is connected to the output end of the random self-calibration circuit, and the first input end and the second input end of the first delay circuit are respectively used to access the trigger signal; An arbitrator, wherein the first input end of the arbitrator is connected to the first output end of the last-stage delay circuit, and the second input end of the arbitrator is connected to the second output end of the last-stage delay circuit; the arbitrator is used to output the metastable oscillation signal when the two input ends simultaneously receive the trigger signal.
8. The true random number generator circuit according to claim 7, characterized in that: Each of the delay circuits comprises two symmetrically placed two-to-one selectors; Wherein, each of the two-to-one selectors in the first-stage delay circuit is connected to the trigger signal via the first input terminal and the second input terminal of the first-stage delay circuit respectively.
9. The true random number generator circuit according to claim 1, characterized in that: The random self-calibration circuit is a pseudo-random number generator.
10. A true random number system, characterized in that: include: A signal verification module and a true random number generator circuit as claimed in any one of claims 1 to 9; The input end of the signal verification module is connected to the second output end of the counter; the signal verification module is used to work when receiving a true random number output by the counter.