Symmetric key generation method and device, equipment, medium and product
By exchanging signals generated by random number sequences in the wireless sensor network, the problem of insufficient randomness of symmetric keys between wireless sensors and network devices is solved, and the security performance and stability of the network are improved.
Patent Information
- Application Number
- CN202411944209.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-27
- Publication Date
- 2025-02-28
- Estimated Expiration
- 2044-12-27
AI Technical Summary
The symmetric keys used between wireless sensors and network devices in wireless sensor networks are poorly random, resulting in poor network security performance.
By exchanging signals generated by a random sequence of numbers between the wireless sensor and the network device, symmetric keys of the wireless sensor and the network device are generated respectively. This method enhances the randomness of channel eigenvalues, thereby improving the randomness of symmetric keys.
It improves the security performance of data transmission in wireless sensor networks, increases the difficulty of cracking symmetric keys, and enhances the security and stability of the network.
Smart Images

Figure CN119545338A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a symmetric key generation method, device, equipment, medium and product. Background Art
[0002] A wireless sensor network includes different numbers of wireless sensors and network devices. The network devices can also be called entry points or aggregation points, etc. Among them, the wireless sensors are connected to the network devices through wireless communication connections. The wireless sensors can send data to the network devices through wireless communication connections. The network devices can process the data or send it to the upper-level devices. The network devices can also send instructions to the wireless sensors through wireless communication connections.
[0003] In order to ensure the communication security between wireless sensors and network devices, wireless sensors and network devices can encrypt and decrypt data transmitted between them through symmetric keys. In the prior art, wireless sensors and network devices send pilot signals to each other, and calculate the channel characteristic values of the communication connection between the two based on the received pilot signals, and then generate keys for encrypting and decrypting data based on the channel characteristic values.
[0004] However, since the pilot signal is relatively simple and the mobility of wireless sensors is relatively low, the channel characteristic values determined by wireless sensors and network devices based on the pilot signal change little, making it easier for other attackers to determine the same channel characteristic values based on the pilot signal, and then crack the symmetric key between the wireless sensor and the network device, resulting in poor security performance of the wireless sensor network. Summary of the invention
[0005] The present application provides a symmetric key generation method, apparatus, device, medium and product to solve the technical problem of poor performance of the wireless sensor network caused by poor randomness of the symmetric key used between wireless sensors and network devices in the wireless sensor network.
[0006] The first aspect of the present application provides a symmetric key generation method, which is applied to a network device, comprising sending a first signal to a wireless sensor according to a target key generation sequence, so that the wireless sensor generates a first symmetric key of the wireless sensor according to the first signal, wherein the target key generation sequence is a random number sequence; receiving a second signal from the wireless sensor; the second signal is sent by the wireless sensor according to the target key generation sequence; and generating a second symmetric key of the network device according to the second signal.
[0007] A second aspect of the present application provides a symmetric key generation method, which is applied to a wireless sensor, comprising: sending a second signal to a network device according to a target key generation sequence, so that the network device generates a second symmetric key according to the second signal, wherein the target key generation sequence is a random number sequence; receiving a first signal from the network device, wherein the first signal is sent by the network device according to the target key generation sequence; and generating a first symmetric key of the wireless sensor according to the first signal.
[0008] The third aspect of the present application provides a symmetric key generation device, which can be used to execute the symmetric key generation method provided in the first aspect of the present application, the symmetric key generation device includes a sending module, which is used to send a first signal to a wireless sensor according to a target key generation sequence, so that the wireless sensor generates a first symmetric key of the wireless sensor according to the first signal, wherein the target key generation sequence is a random number sequence; a receiving module, which is used to receive a second signal from the wireless sensor; the second signal is sent by the wireless sensor according to the target key generation sequence; and a processing module, which is used to generate a second symmetric key of the network device according to the second signal.
[0009] The fourth aspect of the present application provides a symmetric key generation device, which can be used to execute the symmetric key generation method provided in the second aspect of the present application, the symmetric key generation device includes a sending module, which is used to send a second signal to a network device according to a target key generation sequence, so that the network device generates a second symmetric key according to the second signal, wherein the target key generation sequence is a random number sequence; a receiving module, which is used to receive a first signal from the network device, the first signal is sent by the network device according to the target key generation sequence; a processing module, which is used to generate a first symmetric key of the wireless sensor according to the first signal.
[0010] The fifth aspect of the present application provides an electronic device, comprising: a memory and a processor; the memory stores computer-executable instructions; the processor executes the computer-executable instructions stored in the memory, so that the processor executes the symmetric key generation method as described in the first aspect or the second aspect of the present application.
[0011] A sixth aspect of the present application provides a computer-readable storage medium storing computer-executable instructions, which, when executed, implement the symmetric key generation method as described in the first aspect or the second aspect of the present application.
[0012] The seventh aspect of the present application provides a computer program product, including a computer program, which, when executed, implements the symmetric key generation method as described in the first aspect or the second aspect of the present application.
[0013] In summary, the symmetric key generation method, device, equipment, medium and product provided by the present application, the network device sends a first signal to the wireless sensor according to the target key generation sequence, and the wireless sensor sends a second signal to the network device according to the target key generation sequence, so that the network device generates a first symmetric key according to the first signal, and the wireless sensor generates a second symmetric key according to the second signal. Among them, since the target key generation sequence is a random number sequence, and the random number sequence has a stronger randomness than the pilot signal in the prior art, its change is greater than the pilot signal. Even if the mobility of the wireless sensor in the wireless sensor network is poor, the channel change between the wireless sensor and the network device can be further enhanced and amplified by the change of the target key generation sequence, so that the randomness of the channel characteristic value extracted by the wireless sensor and the network device according to the first signal and the second signal sent to each other is stronger, thereby enhancing the randomness of the symmetric key generated based on the channel characteristic value, making the symmetric key more effective, and increasing the difficulty for other attackers to determine the same channel characteristic value according to the pilot signal and crack the symmetric key between the wireless sensor and the network device, thereby enhancing the security performance of the data transmitted between the wireless sensor and the network device, and ensuring the security and stability of the entire wireless sensor network. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be 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 paying creative labor.
[0015] Figure 1 A schematic diagram of the application scenario of this application;
[0016] Figure 2 A schematic diagram of a flow chart of an embodiment of a symmetric key generation method provided by the present application;
[0017] Figure 3 A schematic diagram of a process for generating a first symmetric key for a wireless sensor provided in the present application;
[0018] Figure 4 A schematic diagram of a process for generating a second symmetric key for a network device provided in the present application;
[0019] Figure 5 A schematic diagram of the communication process between the wireless sensor and the network device provided in this application;
[0020] Figure 6 A schematic diagram of the process of determining the target key generation sequence provided by this application;
[0021] Figure 7 A schematic diagram of the mapping relationship for determining the target key sequence provided by this application;
[0022] Figure 8 A schematic diagram of the channel characteristic values provided by this application;
[0023] Fig. 9 A schematic diagram of an embodiment of an AI model provided in this application;
[0024] Fig.10 A schematic diagram of the structure of an embodiment of a symmetric key generation device provided by the present application;
[0025] Fig.11 A schematic diagram of the structure of an electronic device provided in this application. DETAILED DESCRIPTION
[0026] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0027] The terms "first", "second", "third", "fourth", etc. (if any) in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein, for example. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0028] Figure 1 This is a schematic diagram of the application scenario of this application. A wireless sensor network generally includes wireless sensor nodes, aggregation nodes, and management nodes, such as Figure 1 The network device 10 shown is specifically a convergence node, which may also be called a convergence point, a data entry point, etc. The convergence point may be a base station, or a server arranged in a base station, etc.
[0029] The wireless sensor 20 may be a micro-node that integrates the functions of a sensor, a data processing unit, and a communication module. When implementing a specific function, a plurality of wireless sensors 20 are distributed in a specific or random manner, for example, Figure 1 In the illustrated system, N wireless sensors 20 are taken as an example, which are denoted as wireless sensor A, wireless sensor B, ... wireless sensor N. Each wireless sensor 20 is connected to the network device 10 through a network, and communicates based on the communication connection established between the wireless sensor 20 and the network device 10 .
[0030] The wireless sensor 20 and the network device 10 can communicate via 5G or 6G. In order to ensure the security of data transmitted through the network when the wireless sensor 20 and the network device 10 communicate with each other, the wireless sensor 20 and the network device 10 respectively obtain the channel characteristic values between the two, and generate symmetric keys based on the channel characteristic values, thereby using the generated symmetric keys to encrypt and decrypt data.
[0031] For example, when the physical channel technology between the wireless sensor 20 and the network device 10 is orthogonal frequency division multiplexing (OFDM), the wireless sensor 20 extracts the channel characteristic value based on the pilot signal sent by the network device 10 and generates a first symmetric key, and the network device 10 extracts the channel characteristic value based on the pilot signal sent by the wireless sensor 20 and generates a second symmetric key. Subsequently, the network device 10 encrypts the data using the second symmetric key and sends it to the wireless sensor 20, and the wireless sensor 20 decrypts the received data using the first symmetric key. Accordingly, the wireless sensor 20 encrypts the data using the first symmetric key and sends it to the network device 10, and the network device 10 decrypts the received data using the second symmetric key.
[0032] The above-mentioned method of extracting channel characteristic values through pilot signals to generate symmetric keys guarantees the security performance of data transmitted in the network to a certain extent. However, due to the poor mobility of the wireless sensor 20 in the wireless sensor network, the channel between the wireless sensor 20 and the network device 10 changes slightly, and the pilot signal transmitted in the channel also changes slightly, resulting in the channel characteristic values extracted by the wireless sensor 20 and the network device 10 based on the pilot signal being relatively fixed, resulting in the poor randomness of the symmetric key generated based on the relatively fixed channel characteristic value. For other attackers, it is relatively easy to determine the same channel characteristic value based on the pilot signal, and then crack the symmetric key between the wireless sensor 20 and the network device 10, thereby reducing the security performance of the data transmitted between the wireless sensor 20 and the network device 10, and further affecting the security and stability of the entire wireless sensor network.
[0033] Based on this, the present application provides a symmetric key generation method applicable to a wireless sensor network to increase the randomness of the symmetric key generated by the wireless sensor 20 and the network device 10 based on the channel characteristic value, thereby improving the security performance of the wireless sensor network. The technical solution of the present application is described in detail with specific embodiments below. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.
[0034] Figure 2 A schematic diagram of a flow chart of an embodiment of a symmetric key generation method provided in this application, such as Figure 2 The method shown can be applied to Figure 1 In the scenario shown, it is performed by the network device 10 and the wireless sensor 20. Specifically, Figure 2 The symmetric key generation method shown includes:
[0035] S100: The network device 10 and the wireless sensor 20 respectively determine a target key generation sequence. The target key generation sequence provided in this embodiment is a digital sequence of several digits, and specifically may be a random number sequence of several digits (payload).
[0036] In one embodiment, the target key generation sequence may be specified by the network device 10 or the wireless sensor 20, may be preset, or may be one determined by the network device 10 or the wireless sensor 20 from a plurality of preset key generation sequences. The present application also provides a method for the network device 10 to determine the target key generation sequence based on the AI model, see the subsequent Figure 7 The embodiment shown.
[0037] S201: The network device 10 sends a first signal to the wireless sensor 20 according to the target key generation sequence determined in S100.
[0038] In one embodiment, the network device 10 modulates the amplitude, phase, frequency and other parameters of the carrier signal according to the target key generation sequence to obtain a first signal carrying the target key generation sequence, and sends the first signal to the wireless sensor 20 through the communication connection between the network device 10 and the wireless sensor 20.
[0039] S202: The wireless sensor 20 sends a second signal to the network device 10 according to the target key generation sequence determined in S100.
[0040] In one embodiment, the wireless sensor 20 modulates the amplitude, phase, frequency and other parameters of the carrier signal according to the target key generation sequence to obtain a second signal carrying the target key generation sequence, and sends the second signal to the network device 10 through the communication connection between the wireless sensor 20 and the network device 10.
[0041] S203: The wireless sensor 20 generates a first symmetric key according to the first signal received in S201.
[0042] Specifically, Figure 3 A schematic diagram of a process for generating a first symmetric key for a wireless sensor provided in this application, such as Figure 3 A specific implementation method of S203 is shown, wherein, when the wireless sensor 20 receives the first signal, the first signal can be analyzed through S2031, so as to calculate the first channel characteristic value of the communication channel between the wireless sensor 20 and the network device 10 according to the first signal. Then, a first symmetric key is generated according to the first channel characteristic value through S2032. The present application emphasizes that the channel characteristic value extracted from the signal generated based on the target key symmetric sequence has stronger randomness, so the method of generating the first symmetric key according to the first channel characteristic value in S2032 is not limited, and the method of generating the symmetric key according to the first channel characteristic value in the related art can be referred to, which will not be repeated here.
[0043] In one embodiment, the first channel characteristic value includes a channel parameter of a communication channel between the wireless sensor 20 and the network device 10, a signal parameter of a signal transmitted by the communication channel, and the like. Among them, since the network device 10 and the wireless sensor 20 need to determine the first channel characteristic value respectively, and generate a symmetric key respectively according to the first channel characteristic value, the first channel characteristic value is specifically determined by the network device 10 and the wireless sensor 20 respectively and is the same. For example, the first channel characteristic value may be at least one of received signal strength (RSS), channel state information (CSI), or carrier frequency offset (CFO). The network device 10 may determine the first channel characteristic value according to the communication channel or the signal transmitted by the communication channel, and the wireless sensor 20 may also determine the first channel characteristic value according to the communication channel or the signal transmitted by the communication channel. Due to the symmetry of the channel between the wireless sensor 20 and the network device 10, the first channel characteristic values respectively determined by the network device 10 and the wireless sensor 20 are also the same.
[0044] S204: The network device 10 generates a second symmetric key according to the second signal received in S202.
[0045] Specifically, Figure 4 A schematic diagram of a process for generating a second symmetric key for a network device provided in the present application, such as Figure 4 A specific implementation method of S204 is shown, wherein, when the network device 10 receives the second signal, the second signal can be analyzed through S2041, so as to calculate the first channel characteristic value of the communication channel between the network device 10 and the wireless sensor 20 according to the second signal. Then, a second symmetric key is generated according to the first channel characteristic value through S2042. The present application emphasizes that the channel characteristic value extracted from the signal generated based on the target key symmetric sequence has stronger randomness, so the method of generating the second symmetric key according to the first channel characteristic value in S2042 is not limited, and the method of generating the symmetric key in the related art can be referred to, which will not be repeated here.
[0046] In one embodiment, the network device 10 provided by the present application and the wireless sensor 20 include a pilot channel and a data channel, etc. The pilot channel can be used to transmit a pilot signal, and the data channel can be used to transmit a data signal. Then the network device 10 and the wireless sensor 20 can respectively test the relevant parameters based on the data signal transmitted on the data channel through the test capability of the data signal provided on the data channel, thereby obtaining the first channel characteristic. In other words, the data channel between the network device 10 and the wireless sensor 20 provided by the present application provides the ability to test data signals, which can be specifically implemented through the design of the underlying equipment between the network device 10 and the wireless sensor 20.
[0047] In summary, in the symmetric key generation method provided in this embodiment, the network device 10 sends a first signal to the wireless sensor 20 according to the target key generation sequence, and the wireless sensor 20 sends a second signal to the network device 10 according to the target key generation sequence, so that the network device 10 generates a first symmetric key according to the first signal, and the wireless sensor 20 generates a second symmetric key according to the second signal. Among them, since the target key generation sequence is a random number sequence, and the random number sequence has stronger randomness than the pilot signal in the prior art, its change is greater than that of the pilot signal. Even if the mobility of the wireless sensor 20 in the wireless sensor network is poor, the channel change between the wireless sensor 20 and the network device 10 can be further enhanced and amplified by changing the target key generation sequence, so that the randomness of the channel characteristic values extracted by the wireless sensor 20 and the network device 10 based on the first signal and the second signal sent to each other is stronger, thereby enhancing the randomness of the symmetric key generated based on the channel characteristic value, making the symmetric key more effective, and increasing the difficulty for other attackers to determine the same channel characteristic value based on the pilot signal and crack the symmetric key between the wireless sensor 20 and the network device 10, thereby enhancing the security performance of the data transmitted between the wireless sensor 20 and the network device 10, and ensuring the security and stability of the entire wireless sensor network.
[0048] At the same time, the symmetric key generation method provided by the present application does not make major changes to the communication method and encryption method of the wireless sensor 20 and the network device 10 in the prior art, but only adds relevant processing of random numbers, so that the embodiment of the present application also has the characteristics of low cost and easier implementation, which is more conducive to the application and promotion of the embodiment of the present application.
[0049] Furthermore, if Figure 2 As shown, after the wireless sensor 20 generates the first symmetric key and the network device 10 generates the second symmetric key, in S300 , the wireless sensor 20 and the network device 10 can communicate based on the first symmetric key and the second symmetric key.
[0050] In one embodiment, Figure 5 A schematic diagram of the communication process between the wireless sensor and the network device provided in this application shows Figure 2 In the illustrated embodiment, S300 is implemented in a specific manner.
[0051] Based on the symmetry of the channel between the wireless sensor 20 and the network device 10, the first channel feature determined by the wireless sensor 20 according to the first signal is the same as the first channel feature determined by the network device 10 according to the second signal, so that the first symmetric key generated by the wireless sensor 20 is also the same as the second symmetric key generated by the network device 10. Only based on the same symmetric key can the wireless sensor 20 and the network device 10 perform encrypted communication. Therefore, Figure 5 As shown, after the wireless sensor 20 generates the first symmetric key and the network device 10 generates the second symmetric key, they also exchange symmetric keys for key verification. In S301, the network device 10 sends the second symmetric key generated in S204 to the wireless sensor 20, and in S302, the wireless sensor 20 sends the first symmetric key generated in S203 to the network device 10.
[0052] Subsequently, the network device 10 verifies the two symmetric keys in S303. When the network device 10 determines that the second symmetric key is the same as the first symmetric key, it indicates that the verification is successful, and the network device 10 and the wireless sensor 20 can communicate with each other through the first symmetric key and the second symmetric key. Specifically, the network device 10 uses the second symmetric key to encrypt the data and sends it to the wireless sensor 20, and the wireless sensor 20 uses the first symmetric key to decrypt the received data. Correspondingly, the wireless sensor 20 uses the first symmetric key to encrypt the data and sends it to the network device 10, and the network device 10 uses the second symmetric key to decrypt the received data.
[0053] When the network device 10 determines that the second symmetric key is not the same as the first symmetric key, it indicates that the verification fails, and the network device 10 and the wireless sensor 20 need to regenerate the symmetric key. The network device 10 can then return to execute the following steps: Figure 2 S100 shown in FIG. 1 is used to redefine the target key generation sequence and re-execute the steps as shown in FIG. Figure 2 The method shown enables the network device 10 to generate a new second symmetric key and the wireless sensor 20 to generate a new first symmetric key.
[0054] It should be noted that if Figure 5 In the example shown, the network device 10 performs verification of the first symmetric key and the second symmetric key as an example. In other possible implementations, the wireless sensor 20 may also perform verification of the first symmetric key and the second symmetric key to improve the flexibility of the configuration of the embodiment of the present application.
[0055] In summary, in the symmetric key generation method provided in this embodiment, after the wireless sensor 20 generates the first symmetric key and the network device 10 generates the second symmetric key, they also exchange the symmetric keys with each other for key verification, and communicate only after the verification is successful. If the verification fails, the symmetric key needs to be regenerated, thereby ensuring the validity of the generated symmetric key and preventing the wireless sensor 20 and the network device 10 from being unable to communicate due to key problems, thereby ensuring the stability and reliability of the wireless sensor network.
[0056] Furthermore, the present application also provides a method for determining a target key generation sequence by the network device 10. For example, Figure 6 A schematic diagram of a process for determining a target key generation sequence provided in this application, such as Figure 6 Shows Figure 2 In the illustrated embodiment, S100 is implemented in a specific manner.
[0057] Specifically, Figure 6 As shown, the network device 10 first determines the second channel characteristic value of the communication channel between the network device 10 and the wireless sensor 20 through S101. When the physical channel technology between the network device 10 and the wireless sensor 20 is OFDM, the network device 10 receives the pilot signal sent by the wireless sensor 20, and calculates and extracts the second channel characteristic value according to the pilot signal.
[0058] In one embodiment, the second channel characteristic value includes at least one of RSS, CSI or CFO. The network device 10 can obtain the second channel characteristic based on the pilot signal transmitted on the pilot channel by using the test capability of the pilot signal provided on the pilot channel.
[0059] Subsequently, the network device 10 determines, in S102 , a target key generation sequence corresponding to the second channel characteristic value from a plurality of preset key generation sequences according to the second channel characteristic value determined in S101 .
[0060] In one embodiment, Figure 7 The schematic diagram of the mapping relationship of determining the target key sequence provided by the present application, the network device 10 can store the following Figure 7 The mapping relationship shown includes multiple second channel characteristic values, recorded as second channel characteristic value-1, second channel characteristic value-2...second channel characteristic value-N, each second channel characteristic value corresponds to one of multiple key generation sequences, for example, the second channel characteristic value-1 has a corresponding relationship with the key generation sequence-1, the second channel characteristic value-2 has a corresponding relationship with the key generation sequence-2...the second channel characteristic value-N has a corresponding relationship with the key generation sequence-N.
[0061] Therefore, after the network device 10 determines the second channel characteristic value, it can combine the currently determined second channel characteristic value with the Figure 7The mapping relationship shown in the figure determines the key generation sequence corresponding to the current second channel characteristic value as the target key generation sequence. That is to say, the network device 10 supports the use of multiple different key generation sequences when communicating with the wireless sensor 20, and each key generation sequence is a random number sequence. The network device 10 can store multiple different key generation sequences. In S102, the network device 10 determines one from the candidate key generation sequences as the target key generation sequence according to the current second channel characteristic value, and subsequently generates a symmetric key only according to the one target key generation sequence.
[0062] like Figure 6 As shown, after the network device 10 determines the target key generation sequence, it can send the target key generation sequence to the wireless sensor 20, so that the wireless sensor 20 receives and determines the target key generation sequence. Alternatively, the network device 10 can also send indication information to the wireless sensor 20, and after the wireless sensor 20 receives the indication information, it determines the target key generation sequence from multiple key generation sequences according to the indication information. It is understandable that the wireless sensor 20 can also store multiple key generation sequences and perform subsequent key generation and other processing according to the target key generation sequence determined by the network device 10.
[0063] It should be noted that if Figure 6 In the example shown, the network device 10 is used as an example to determine the target key generation sequence. This method is based on the stronger computing power of the network device 10. In other possible implementations, the wireless sensor 20 may also determine the target key generation sequence. This method may have stronger flexibility.
[0064] In summary, in the symmetric key generation method provided in this embodiment, the network device 10 can more flexibly determine the target key generation sequence from multiple different key generation sequences according to the current channel characteristic value, so that the determined target key generation sequence is more suitable for the current channel, thereby ensuring the effectiveness of the subsequent target key generation sequence. In addition, the network device 10 can actively determine the target key generation sequence without user configuration, thereby improving the intelligence level of the network device 10.
[0065] Furthermore, in the above embodiment, if Figure 7The mapping relationship shown can be obtained by the following steps: first, multiple second channel characteristic values are obtained, and the multiple channel characteristic values are combined with each key generation sequence in multiple key generation sequences in turn, and then all the combinations are input into the AI model in turn, and the key quality information of each second channel characteristic value output by the AI model and the combination of multiple key generation sequences is obtained. Subsequently, each second channel characteristic value output by the AI model is compared with a key generation sequence in multiple key generation sequences, and the key quality information meets the preset conditions as the target key generation sequence corresponding to the second characteristic value in the mapping relationship. The above steps can be performed by an electronic device with relevant data processing capabilities, such as a computer, workstation, server, etc., or can also be performed by the network device 10. The above AI model is introduced below in conjunction with the accompanying drawings.
[0066] Specifically, Figure 8 This is a schematic diagram of the channel characteristic values provided in the present application. When the wireless sensor 20 sends a pilot signal to the network device 10, the pilot channel received by the network device 10 carries the channel characteristic value after transmission through the channel h(t). The network device 10 can record it as the second channel characteristic value based on the extreme RSS, CSI or CFO parameters of the pilot signal in the manner of the aforementioned embodiments of the present application.
[0067] Then, it can be determined that Figure 8 The different multiple second channel characteristic values shown, for example, the first second channel characteristic value is recorded as RSS_1, CSI_1, CFO_1, the second second channel characteristic value is recorded as RSS_2, CSI_2, CFO_2, and so on, and a total of v second channel characteristic values are determined.
[0068] Subsequently, each second channel characteristic value is combined with multiple different key generation sequences. For example, assuming that the network device 10 supports n key generation sequences, denoted as n1, n2...nn, the first second channel characteristic value is combined with the n key generation sequences respectively to obtain RSS_1, CSI_1, CFO_1, n1, RSS_1, CSI_1, CFO_1, n2...RSS_1, CSI_1, CFO_1, nn, and the second second channel characteristic value is combined with the n key generation sequences respectively to obtain RSS_2, CSI_2, CFO_2, n1, RSS_2, CSI_2, CFO_2, n2...RSS_2, CSI_2, CFO_2, nn, and so on.
[0069] Then, each of the above combinations is input into the AI model separately. Fig. 9 A schematic diagram of an embodiment of an AI model provided in this application, such as Fig. 9As shown, when all combinations are sequentially input into the AI model C, the AI model C can output key quality information of each second channel characteristic value combined with different key generation sequences. For example, for the first second channel characteristic value, there are n key quality information X1-1, X1-2...X1-n respectively combined with n key generation sequences, and correspondingly, for the second second channel characteristic value, there are n key quality information X2-1, X2-2...X2-n respectively combined with n key generation sequences, and so on.
[0070] In one embodiment, the random number sequence may be generated according to a certain random number generation algorithm. For example, different random number sequences are generated as key generation sequences by means of a maximum random bit stream generation file or the like. For example, the generated random number sequence may be a continuous identical 1-n bit, wherein when the length of the minimum data unit is k, the next k bits may be determined to be all 0 or all 1 according to random changes, thereby generating a bit sequence of a certain length as a key generation sequence. For another example, the generated random number sequence may be that each data unit is flipped according to a certain probability, and the probability distribution function includes a Poisson distribution or a normal distribution. By changing the parameters of the probability distribution function, different random number sequences may be obtained as key generation sequences. Among them, the probability distribution function may be a lognormal distribution, a Bernoulli distribution, an alpha distribution, etc., which is not limited in this application.
[0071] Finally, the key quality is evaluated according to the n key quality information X1-1, X1-2...X1-n output by the AI model C, so as to determine a target key generation sequence that meets the preset conditions from the n key generation sequences. For example, for the first second channel characteristic value and the n key generation sequences, the n key quality information X1-1, X1-2...X1-n respectively represent the probability information of each key generation sequence, and then the key generation sequence with the largest probability information can be determined from the probability information as the target key generation sequence. For example, the probability information of the key quality information X1-1 of the first key generation sequence determined by the first second channel characteristic value is the largest, then the target key generation sequence of the first second channel characteristic value RSS_1, CSI_1, CFO_1 is determined to be the first of the n key generation sequences, and the correspondence between the first second channel characteristic value and the first key generation sequence is added to the mapping relationship. In the same way as above, the correspondence between each of the n second channel characteristic values and one of the target key generation sequences in the n key generation sequences can be obtained, and finally the following is obtained. Figure 7 The mapping relationship shown.
[0072] Among them, the quality information of the key generation sequence is judged based on its randomness, that is, the higher the randomness of a key generation sequence under a channel characteristic value, the higher its quality; the lower the randomness of a key generation sequence under a channel characteristic value, the lower its quality. In one embodiment, supervised training can be used during the training process of the AI model to achieve supervised training of the AI model. For example, the output result of the AI model is the probability information of each key generation sequence. The quality of the probability information of each key generation sequence can be marked, and the marked content can be returned to the AI model, so that the AI model can obtain a more accurate output result through feedback training, thereby more effectively determining a key generation sequence with the best quality under each different channel environment as the target key generation sequence.
[0073] In summary, in the symmetric key generation method provided in this embodiment, the target key generation sequence used under different second channel characteristic values is obtained through AI model training, thereby ensuring that the target key generation sequence determined based on the mapping relationship is more suitable for the current channel and has higher randomness in the current channel environment, thereby ensuring the effectiveness of the subsequent target key generation sequence.
[0074] In the aforementioned embodiments of the present application, the symmetric key generation method provided by the embodiments of the present application is introduced. In order to implement the symmetric key generation method provided by the embodiments of the present application, the source network device 10 and the wireless sensor 20 as the execution subject may include a hardware structure and / or a software module, and implement the above-mentioned symmetric key generation methods in the form of a hardware structure, a software module, or a hardware structure plus a software module. Whether a method or step in the above-mentioned symmetric key generation methods is executed in the form of a hardware structure, a software module, or a hardware structure plus a software module depends on the specific application and design constraints of the technical solution.
[0075] For example, Fig.10 This is a schematic diagram of the structure of an embodiment of a symmetric key generation device provided by the present application, such as Fig.10 The symmetric key generation device 100 shown can be used to execute the symmetric key generation method provided by any of the aforementioned embodiments of the present application. Specifically, the symmetric key generation device 100 provided by this embodiment includes: a receiving module 101, a processing module 102 and a sending module 103.
[0076] When Fig.10When the symmetric key generation device 100 shown executes the symmetric key generation method executed by the network device 10, the sending module 103 is used to send a first signal to the wireless sensor according to the target key generation sequence, so that the wireless sensor generates the first symmetric key of the wireless sensor according to the first signal. The receiving module 101 is used to receive a second signal from the wireless sensor; the processing module 102 is used to generate a second symmetric key of the network device according to the second signal.
[0077] When Fig.10 When the symmetric key generation device 100 shown executes the symmetric key generation method executed by the wireless sensor 20, the sending module 103 is used to send a second signal to the network device according to the target key generation sequence, so that the network device generates a second symmetric key according to the second signal. The receiving module 101 is used to receive a first signal from the network device. The processing module 102 is used to generate a first symmetric key of the wireless sensor according to the first signal.
[0078] The specific implementation method and principle of the symmetric key generation device 100 for the above database refer to the description of the above symmetric key generation method, which will not be repeated here.
[0079] It should be noted that it should be understood that the division of the various modules of the above device is only a division of logical functions. In actual implementation, they can be fully or partially integrated into one physical entity, or they can be physically separated. And these modules can all be implemented in the form of software called by processing elements; they can also be all implemented in the form of hardware; some modules can also be implemented in the form of software called by processing elements, and some modules can be implemented in the form of hardware. For example, the processing module can be a separately established processing element, or it can be integrated in a chip of the above device. In addition, it can also be stored in the memory of the above device in the form of program code, and called and executed by a processing element of the above device. The function of the above-mentioned module is determined. The implementation of other modules is similar. In addition, these modules can be fully or partially integrated together, or they can be implemented independently. The processing element described here can be an integrated circuit with signal processing capabilities. In the implementation process, each step of the above method or each module above can be completed by an integrated logic circuit of hardware in the processor element or instructions in the form of software.
[0080] For example, the above modules may be one or more integrated circuits configured to implement the above methods, such as one or more application specific integrated circuits (ASIC), or one or more microprocessors (digital signal processors, DSP), or one or more field programmable gate arrays (FPGA), etc. For another example, when a module above is implemented in the form of a processing element scheduling program code, the processing element may be a general-purpose processor, such as a central processing unit (CPU) or other processor that can call program code. For another example, these modules may be integrated together and implemented in the form of a system-on-a-chip (SOC).
[0081] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state disk (SSD)).
[0082] For example, Fig.11 A schematic diagram of the structure of an electronic device provided in this application, such as Fig.11 The electronic device shown can be used to execute the symmetric key generation method shown in any of the above embodiments of the present application. In one embodiment, Fig.11The electronic device 2000 shown includes one or more processors 2001 and a memory 2002; wherein the memory 2002 is used to store computer executable instructions, and the processor 2001 can execute the computer executable instructions stored in the memory 2002. When the computer executable instructions are executed by the processor 2001, the processor 2001 implements the symmetric key generation method executed by the network device 10 in any of the aforementioned embodiments of the present application; or, when the computer executable instructions are executed by the processor 2001, the processor 2001 implements the symmetric key generation method executed by the wireless sensor 20 in any of the aforementioned embodiments of the present application.
[0083] In one embodiment, if Fig.11 The electronic device 2000 shown further includes a communication interface 2003 , wherein the processor 2001 can communicate with other devices through the communication interface 2003 , for example, the processor 2001 transmits a first signal and a second signal through the communication interface 2003 .
[0084] The present application also provides a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are executed, they can be used to implement any symmetric key generation method in the aforementioned embodiments of the present application.
[0085] An embodiment of the present application also provides a chip for executing instructions, wherein the chip is used to execute any of the symmetric key generation methods described above in the present application.
[0086] An embodiment of the present application also provides a computer program product, including a computer program, which, when executed, implements any of the symmetric key generation methods described above in the present application.
[0087] The method provided in the above embodiment can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product may include one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function according to the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital user (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic disk), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state disk (SSD)), etc.
[0088] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application. Those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working process of the above-described system, device and unit can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0089] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the unit is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms. The unit described as a separate component may or may not be physically separated, and the component displayed as a unit may or may not be a physical unit, and may be located in one place, or may be distributed on multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the scheme of this embodiment.
[0090] In addition, each functional unit in each embodiment of the present application can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. If the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application can essentially or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method of each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory, a random access memory, a magnetic disk or an optical disk.
[0091] In addition, in the present application, first, indications include explicit indications (also called direct indications) and implicit indications (also called indirect indications). Among them, explicit indication information A refers to including the information A; implicit indication information A refers to indicating information A through the correspondence between information A and information B and directly indicating information B. The correspondence between information A and information B can be predefined, pre-stored, pre-burned, or pre-configured; or, it can also refer to indicating information A through information B and preset rules. Second, information C is used to determine information D, including information D being determined only based on information C, and information D being determined based on information C and other information. In addition, information C is used to determine information D, and it can also be indirectly determined, for example, information D is determined based on information E, and information E is determined based on information C. Third, "at least one" means one or more, and "more" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship, but it does not exclude the situation where the previous and next associated objects are in an "and" relationship. The specific meaning can be understood in combination with the context. "At least one of the following items" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, or c can mean: a, b, c; a and b; a and c; b and c; or a and b and c. Where a, b, c can be single or multiple.
[0092] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein with equivalents. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.
Claims
1. A symmetric key generation method, applied to a network device, characterized in that: include: Sending a first signal to the wireless sensor according to a target key generation sequence, so that the wireless sensor generates a first symmetric key of the wireless sensor according to the first signal, wherein the target key generation sequence is a random number sequence; receiving a second signal from the wireless sensor; the second signal is sent by the wireless sensor according to the target key generation sequence; A second symmetric key of the network device is generated according to the second signal.
2. The method according to claim 1, characterized in that Generating a second symmetric key of the network device according to the second signal includes: calculating a first channel characteristic value of a communication channel between the network device and the wireless sensor according to the second signal; The second symmetric key is generated according to the first channel characteristic value.
3. The method according to claim 1, characterized in that Before sending the first signal to the wireless sensor according to the target key generation sequence, the method further includes: The target key generation sequence is determined from a plurality of preset key generation sequences, wherein the plurality of key generation sequences are all random number sequences.
4. The method according to claim 3, characterized in that: The step of determining the target key generation sequence from a plurality of preset key generation sequences comprises: Calculating a second channel characteristic value of a communication channel between the network device and the wireless sensor according to the pilot signal sent by the wireless sensor; According to the second channel characteristic value, the target key generation sequence corresponding to the second channel characteristic value is determined from a plurality of preset key generation sequences.
5. The method according to claim 4, characterized in that The determining, according to the second channel characteristic value, the target key generation sequence corresponding to the second channel characteristic value from a plurality of preset key generation sequences includes: According to the second channel characteristic value and the mapping relationship, the target key generation sequence corresponding to the second channel characteristic value is determined, wherein the mapping relationship includes multiple second channel characteristic values and a corresponding relationship between each of the second channel characteristic values and one of the target key generation sequences in the multiple key generation sequences.
6. The method according to claim 5, characterized in that The mapping relationship is obtained through the following steps: After combining each of the multiple second channel characteristic values with each of the multiple key generation sequences in sequence, all the combinations are input into the AI model in sequence, and key quality information of each second channel characteristic value output by the AI model combined with the multiple key generation sequences is obtained; Each second channel characteristic value output by the AI model and a key generation sequence whose key quality information meets a preset condition in the multiple key generation sequences are used as a target key generation sequence corresponding to the second channel characteristic value in the mapping relationship.
7. The method according to any one of claims 4 to 6, characterized in that: The second channel characteristic value includes: at least one of received signal strength RSS, channel state information CSI or carrier frequency offset CFO.
8. The method according to claim 1, characterized in that The sending a first signal to the wireless sensor according to the target key generation sequence includes: Modulating a carrier signal according to the target key generation sequence to generate the first signal; The first signal is sent to the wireless sensor.
9. The method according to claim 3, characterized in that: After determining the target key generation sequence from a plurality of preset key generation sequences, the method further includes: sending the target key generation sequence to the wireless sensor; Alternatively, instruction information is sent to the wireless sensor, so that the wireless sensor determines the target key generation sequence from the multiple key generation sequences according to the instruction information.
10. The method according to claim 2, characterized in that After the second symmetric key is generated according to the first channel characteristic value, the method further includes: receiving the first symmetric key sent by the wireless sensor; When the second symmetric key is the same as the first symmetric key, using the first symmetric key to communicate with the wireless sensor; When the second symmetric key is different from the first symmetric key, the second symmetric key is regenerated.
11. The method according to claim 2, characterized in that The first channel characteristic value includes at least one same channel parameter or signal parameter determined by signals transmitted by the network device and the wireless sensor through the communication channel respectively.
12. A symmetric key generation method, applied to a wireless sensor, characterized in that: include: Sending a second signal to the network device according to a target key generation sequence, so that the network device generates a second symmetric key according to the second signal, wherein the target key generation sequence is a random number sequence; receiving a first signal from the network device, wherein the first signal is sent by the network device according to the target key generation sequence; A first symmetric key of the wireless sensor is generated according to the first signal.
13. The method according to claim 12, characterized in that Generating a first symmetric key of the wireless sensor according to the first signal includes: Calculating a first channel characteristic value of a communication channel between the wireless sensor and the network device according to the first signal; The second symmetric key is generated according to the first channel characteristic value.
14. The method according to claim 12 or 13, characterized in that Before sending the second signal to the network device according to the target key generation sequence, the method further includes: Receiving the target key generation sequence sent by the network device; Alternatively, indication information sent by the network device is received, and the target key generation sequence is determined from a plurality of key generation sequences according to the indication information.
15. The method according to claim 12, characterized in that The sending a second signal to the network device according to the target key generation sequence includes: Modulating a carrier signal according to the target key generation sequence to generate the second signal; The second signal is sent to the network device.
16. The method according to claim 12, characterized in that After generating the first symmetric key according to the first signal, the method further includes: The first symmetric key is sent to the network device.
17. The method according to claim 12, characterized in that The first channel characteristic value includes at least one same channel parameter or signal parameter determined by signals transmitted by the network device and the wireless sensor through communication channels respectively.
18. A symmetric key generating device, characterized in that: include: A sending module, configured to send a first signal to the wireless sensor according to a target key generation sequence, so that the wireless sensor generates a first symmetric key of the wireless sensor according to the first signal, wherein the target key generation sequence is a random number sequence; A receiving module, used for receiving a second signal from the wireless sensor; the second signal is sent by the wireless sensor according to the target key generation sequence; The processing module is used to generate a second symmetric key of the network device according to the second signal.
19. A symmetric key generation device, characterized in that: include: A sending module, configured to send a second signal to a network device according to a target key generation sequence, so that the network device generates a second symmetric key according to the second signal, wherein the target key generation sequence is a random number sequence; A receiving module, configured to receive a first signal from the network device, wherein the first signal is sent by the network device according to the target key generation sequence; The processing module is used to generate a first symmetric key of the wireless sensor according to the first signal.
20. An electronic device, characterized in that: include: Memory and processor; The memory stores computer executable instructions; The processor executes the computer executable instructions stored in the memory, so that the processor executes the symmetric key generation method as described in any one of claims 1-17.
21. A computer-readable storage medium, characterized in that: Computer executable instructions are stored, and when the computer executable instructions are executed, the symmetric key generation method as described in any one of claims 1 to 17 is implemented.
22. A computer program product, characterized in that It comprises a computer program, which implements the symmetric key generation method according to any one of claims 1 to 17 when being executed.
Citation Information
Patent Citations
Pilot frequency sequence generation method and system
CN102238116A
Data protection method, data generation method, data transmission method, equipment and storage medium
CN111209575A
Symmetric key generation method and device and medium thereof
CN113114455A
Hybrid key system and method based on wireless channel feature simulation
CN113194466A
Secret key generation method and data processing method, device and system based on secret key generation method
CN114513779A