A key negotiation method, device, equipment and computer-readable storage medium
By obtaining the key from the preset key pool and using the challenge-response mechanism for key negotiation, the complexity and security issues of Diffie-Hellman key negotiation in the multi-party situation are solved, achieving fast, secure and Low-cost key agreement process.
Patent Information
- Application Number
- CN202410971894.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-19
- Publication Date
- 2024-09-20
- Estimated Expiration
- 2044-07-19
AI Technical Summary
In multi-participant communications, the complexity of the Diffie-Hellman key agreement method increases when there are more than two parties. The security of information exchange is crucial. Once information is leaked, the key will be cracked, and traditional methods require complex protocols. and algorithms, resulting in high consumption of computing resources and excessive maintenance costs.
By obtaining multiple initiating keys from the preset key pool, using the challenge-response mechanism to obtain the shared keys corresponding to the negotiation participating nodes, and integrating them when the number of shared keys is greater than the threshold, the negotiation initiating nodes and negotiation participating nodes are obtained. The communication key of the node avoids key calculation and information exchange, reducing communication costs and resource consumption.
It improves the communication security between negotiation initiating nodes and negotiation participating nodes, reduces communication costs, avoids key cracking problems caused by information leakage, and realizes a fast and resource-saving key negotiation process.
Smart Images

Figure CN118509167B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information security technology, and in particular to a key negotiation method, device, equipment and computer-readable storage medium. Background Art
[0002] Key negotiation refers to the process of securely generating and sharing one or more keys between multiple parties. These keys are then used to encrypt and decrypt the communication content, thereby achieving confidential communication between multiple parties. Key negotiation usually involves a series of protocols and algorithms, such as the Deffie-Hellman protocol.
[0003] The Diffie-Hellman key negotiation method is to let the communicating parties exchange information with each other to jointly calculate the same session key. Even if part of the information transmitted in the middle is intercepted, the session key cannot be calculated based on it, because the other part of the information used to calculate the session key is at the receiver, and the receiver does not disclose this part of information. Therefore, the middle party does not have enough information to obtain the session key and then crack the subsequent communication ciphertext.
[0004] However, when there are more than two parties in the communication, the complexity of Diffie-Hellman key negotiation increases greatly, and more information needs to be exchanged between the members. Therefore, the security of the information exchange and key negotiation process will be crucial. Once the exchanged information is leaked, the key will be cracked. Summary of the invention
[0005] In view of this, the purpose of the present invention is to provide a key negotiation method, device, equipment and computer-readable storage medium, which avoids the problem of key cracking due to leakage of exchanged information, reduces the communication cost between the negotiation initiating node and the negotiation participating nodes, and improves the communication security between the negotiation initiating node and the negotiation participating nodes. The specific technical solution is as follows:
[0006] In a first aspect, the present invention provides a key negotiation method, which is applied to a negotiation initiating node of a communication system, wherein the communication system further includes a negotiation participating node, and the method comprises:
[0007] Obtain multiple initiation keys from a preset key pool;
[0008] Using the multiple initiation keys to obtain a shared key corresponding to the negotiation participating node through a challenge-response mechanism, the shared key being a key among the multiple initiation keys that is the same as a participation key of the negotiation participating node;
[0009] When the number of the shared keys is greater than a preset threshold, the shared keys are integrated to obtain communication keys between the negotiation initiating node and the negotiation participating nodes.
[0010] In a possible implementation manner, the using the multiple initiation keys to obtain a shared key corresponding to the negotiation participating node through a challenge-response mechanism includes:
[0011] Broadcasting a key negotiation request, where the key negotiation request is used to request key negotiation with the negotiation participating node;
[0012] Receiving request response information broadcasted by the negotiation participating node, the request response information including a participation plaintext and a plurality of participation ciphertexts, the plurality of participation ciphertexts being obtained by the negotiation participating node encrypting the participation plaintexts respectively using a plurality of the participation keys, the plurality of the participation keys being obtained by the negotiation participating node from the preset key pool;
[0013] Decrypting each of the participating ciphertexts using the multiple initiating keys to obtain multiple plaintexts to be analyzed;
[0014] In the case that there is a plaintext to be analyzed that is the same as the participating plaintext among the multiple plaintexts to be analyzed, an initiation key corresponding to the plaintext to be analyzed that is the same as the participating plaintext is determined as the shared key.
[0015] In a possible implementation manner, the integrating the shared keys to obtain the communication keys of the negotiation initiating node and the negotiation participating nodes includes:
[0016] An XOR operation is performed on the shared key to obtain the communication key.
[0017] In a possible implementation, the communication system further includes a negotiation completion node, where the negotiation completion node is a node that completes key negotiation with the negotiation initiating node and the negotiation participating node respectively;
[0018] After acquiring the shared key corresponding to the negotiation participating node through the challenge-response mechanism, the method further includes:
[0019] When the number of the shared keys is not greater than the preset threshold, receiving a process key sent by the negotiation completion node, where the process key is used to assist the negotiation initiating node and the negotiation participating node in completing key negotiation;
[0020] updating the plurality of initiation keys based on the process key;
[0021] Re-acquire the shared keys corresponding to the negotiation participating nodes by using the updated multiple initiation keys through a challenge-response mechanism;
[0022] In a case where the number of the re-acquired shared keys is greater than the preset threshold, the shared keys are integrated to obtain the communication keys of the negotiation initiating node and the negotiation participating nodes.
[0023] In a possible implementation manner, after integrating the shared keys to obtain the communication keys of the negotiation initiating node and the negotiation participating nodes, the method further includes:
[0024] In the case where the negotiation participating node fails, the shared key corresponding to the negotiation participating node among the multiple initiating keys is deleted.
[0025] In a second aspect, the present invention further provides a key negotiation device, which is applied to a negotiation initiating node of a communication system, wherein the communication system further includes a negotiation participating node, and the device includes:
[0026] An initiation key acquisition module, used to obtain multiple initiation keys from a preset key pool;
[0027] a shared key acquisition module, configured to use the multiple initiation keys to acquire a shared key corresponding to the negotiation participating node through a challenge-response mechanism, wherein the shared key is a key among the multiple initiation keys that is the same as a participation key of the negotiation participating node;
[0028] The key integration module is used to integrate the shared keys when the number of the shared keys is greater than a preset threshold, so as to obtain the communication keys between the negotiation initiating node and the negotiation participating nodes.
[0029] In a possible implementation, the shared key acquisition module includes:
[0030] A broadcast unit, used for broadcasting a key negotiation request, wherein the key negotiation request is used for requesting to perform key negotiation with the negotiation participating node;
[0031] a receiving unit, configured to receive request response information broadcasted by the negotiation participating node, wherein the request response information includes a participation plaintext and a plurality of participation ciphertexts, wherein the plurality of participation ciphertexts are obtained by the negotiation participating node encrypting the participation plaintexts respectively using a plurality of the participation keys, and the plurality of the participation keys are obtained by the negotiation participating node from the preset key pool;
[0032] A decryption unit, used to use the multiple initiation keys to decrypt each of the participating ciphertexts respectively to obtain multiple plaintexts to be analyzed;
[0033] The determining unit is configured to determine, when there is a plaintext to be analyzed that is identical to the participating plaintext among the multiple plaintexts to be analyzed, an initiating key corresponding to the plaintext to be analyzed that is identical to the participating plaintext as the shared key.
[0034] In a possible implementation manner, the device further includes:
[0035] The key deletion module is used to delete the shared key corresponding to the negotiation participating node from the multiple initiating keys when the negotiation participating node fails.
[0036] In a third aspect, the present invention further provides a computer device, comprising: a memory and a processor;
[0037] Wherein, the memory is used to store computer programs;
[0038] The processor is used to execute the computer program in the memory to implement the method described in the first aspect or any one of the first aspects.
[0039] In a fourth aspect, the present invention further provides a computer-readable storage medium storing instructions, which, when executed on a computer, enables the computer to execute the method described in the first aspect or any one of the first aspects.
[0040] In the present invention, the negotiation initiating node obtains multiple initiation keys from a preset key pool; uses multiple initiation keys to obtain shared keys corresponding to the negotiation participating nodes through a challenge-response mechanism, and the shared key is a key among multiple initiation keys that is the same as multiple participating keys of the negotiation participating nodes; when the number of shared keys is greater than a preset threshold, the shared keys are integrated to obtain the communication key between the negotiation initiating node and the negotiation participating nodes. The present invention directly obtains and uses keys from a preset key pool, and the negotiation initiating node does not need to use any protocol or algorithm to calculate the key, thereby avoiding the problem of key cracking due to leakage of exchanged information. The present invention uses a challenge-response mechanism to obtain shared keys, and the calculation speed is faster than that of keys obtained using protocols or algorithms, and it occupies fewer resources and has lower costs, thereby reducing the communication cost between the negotiation initiating node and the negotiation participating nodes, and improving the communication security between the negotiation initiating node and the negotiation participating nodes. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the embodiments of the present invention 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 some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0042] Figure 1 A flowchart of a key negotiation method provided by an embodiment of the present invention is shown;
[0043] Figure 2 A flowchart of another key negotiation method provided by an embodiment of the present invention is shown;
[0044] Figure 3 A schematic structural diagram of a key negotiation device provided by an embodiment of the present invention is shown. DETAILED DESCRIPTION
[0045] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0046] Key agreement refers to the process of securely generating and sharing one or more keys between multiple parties. These keys are then used to encrypt and decrypt the communication content, thereby achieving confidential communication between multiple parties. Key agreement is very necessary to achieve confidential data communication in the open network environment of the Internet. Key agreement can be applied to various scenarios that require multiple parties to communicate.
[0047] Unmanned aerial vehicles, or UAVs for short, are unmanned aircraft that are controlled using radio remote control technology and a control device embedded in the drone. UAVs are widely used in remote sensing mapping, express delivery, pipeline inspection, environmental testing, and military reconnaissance.
[0048] With the development of drone technology, it has become a reality for drones to collaborate to complete designated tasks. Multiple drones are combined according to a certain scale and structure, and information sharing between drones produces a cooperative effect to achieve intelligent collaborative execution of tasks. This model of collaboration between drones is widely used in many fields, such as disaster relief. When drones carry out search and rescue work in mountainous areas, due to the complex and changeable environment in the area, communication signals will be blocked. Using drone collaboration, different drones can communicate with each other and share data, which can effectively avoid communication blockage problems and improve search and rescue efficiency.
[0049] The drone collaboration model provides many benefits for production and life, but attention should be paid to the security issues of communication between drones.
[0050] At present, the methods for key negotiation between drones are as follows: the ground station generates public parameters and its own private key, the drone registers at the ground station, the ground station generates authentication information for each drone based on the public parameters and its own private key, the drones authenticate each other and negotiate the session key. This key negotiation method includes drones and ground stations, which use the ground station to generate authentication information for drones, so that drones can authenticate each other and negotiate keys, thereby ensuring future secure communication between the two. The ground station refers to a system that can provide registration services for drones and generate parameters required for authentication.
[0051] However, due to the involvement of the ground station, the scalability of the communication system where the drone is located is poor. When a new drone joins the communication system, it is necessary to consider the compatibility with the ground station to prevent communication conflicts and other problems. In addition, the ground station needs to support the key distribution of all drones, which has high requirements for the computing performance and communication performance of the ground station, which easily leads to excessive maintenance costs for the communication system where the drone is located. In addition, when the ground station is attacked or down, the security of the entire communication system will be threatened.
[0052] In addition, the key negotiation process usually involves a series of protocols and algorithms, which can be symmetric key negotiation and asymmetric key negotiation. In the symmetric key negotiation process, the same key is used for encryption and decryption, while in the asymmetric key negotiation process, a pair of public and private keys are used for encryption and decryption. Traditional asymmetric encryption key exchange protocols, such as the Deffie-Hellman protocol, require modular exponential operations. Modular exponential operations require complex circuits and a large amount of computing resource overhead, which is very costly for drone systems.
[0053] There is also a key pre-distribution scheme. Before the network is deployed, a key pool is generated. Each key corresponds to a unique identifier. The node randomly selects a group of keys from this key pool to build its own key ring. The node will broadcast the key identifier of the key in its key ring to the adjacent nodes. If the adjacent nodes have the same key identifier, the key corresponding to the key identifier will be used as the communication key between the node and the adjacent node. If there is no identical key identifier, a secure communication channel is established through other adjacent nodes with a common key. However, in this scheme, if the attacker controls enough nodes, it is likely to infer the communication key between each node through probability analysis. In addition, in the process of key pre-distribution, as long as the attacker obtains the key pool, he can directly obtain the corresponding relationship between the key identifier and the key. When other nodes negotiate keys again, the attacker can directly find the key through the key identifier.
[0054] Based on this, an embodiment of the present invention provides a key negotiation method to decentralize the UAV communication system, that is, key negotiation can be achieved without a ground station, and during the key negotiation process, key matching is performed through a challenge-response mechanism to improve the security of the UAV communication system. When a new UAV node joins the UAV communication system, it only needs to generate a communication key through a challenge-response mechanism, which can realize node expansion of the UAV communication system and improve the scalability of the UAV communication system.
[0055] See also Figure 1 , showing a flow chart of a key negotiation method provided by an embodiment of the present invention, the embodiment of the present invention is applied to a negotiation initiating node of a communication system, and the communication system also includes a negotiation participating node. In the embodiment of the present invention, each node in the communication system can serve as a negotiation initiating node or as a negotiation participating node. For example, when a node in the communication system needs to perform key negotiation with other nodes, the node can serve as a negotiation initiating node; when other nodes need to perform key negotiation with the node, the node can serve as a negotiation participating node. When the key negotiation method of the embodiment of the present invention is applied to drone communication, the negotiation initiating node can be a negotiation initiating drone, and the negotiation participating node can be a negotiation participating drone.
[0056] The embodiment of the present invention at least includes the following steps:
[0057] S11, obtaining multiple initiation keys from a preset key pool.
[0058] In the communication system of the embodiment of the present invention, a large offline key pool P is preset, and the preset key pool P includes N keys and identifiers corresponding to the N keys, where N is a positive integer.
[0059] The i-th negotiation initiating node randomly extracts m keys from the preset key pool P, and determines the key obtained by the negotiation initiating node from the preset key pool P as the initiating key. The embodiment of the present invention can also construct a key ring according to the m initiating keys. . i and m are both positive integers.
[0060] S12, using multiple initiation keys to obtain shared keys corresponding to the negotiation participating nodes through a challenge-response mechanism.
[0061] The negotiation initiating node can use multiple initiation keys obtained from the preset key pool P to obtain the shared key corresponding to the negotiation participating node through a challenge-response mechanism, wherein the shared key is a key among the multiple initiation keys that is the same as the participation key of the negotiation participating node.
[0062] Since each node in the communication system can serve as a negotiation initiating node or a negotiation participating node, the negotiation participating node can also obtain multiple keys from the preset key pool P like the negotiation initiating node, and determine the key obtained by the negotiation participating node from the preset key pool P as the participating key.
[0063] A challenge-response mechanism involves one entity proving to another that it has a secret key, but without directly revealing the secret key it possesses to prove its identity.
[0064] The challenge-response mechanism process usually includes: the verifier sends a verification request to the challenger, the challenger generates a random value after receiving the verification request, and sends the random value as a "challenge" to the verifier, the verifier uses the key to encrypt the random value to obtain a string, and sends the string as a "response" to the challenger, the challenger uses the verifier's key stored in itself to encrypt the random value to obtain an expected response value, and the challenger compares the response value encrypted by itself with the response value sent by the verifier to determine whether the verifier actually possesses the key.
[0065] Based on this, an implementation method of using multiple initiation keys to obtain a shared key corresponding to a negotiation participating node through a challenge-response mechanism may include the following steps:
[0066] S121, broadcasting a key negotiation request, where the key negotiation request is used to request key negotiation with the negotiation participating nodes;
[0067] S122, receiving request response information broadcasted by the negotiation participating node, where the request response information includes a participation plaintext and multiple participation ciphertexts, where the multiple participation ciphertexts are obtained by the negotiation participating node encrypting the participation plaintexts using multiple participation keys respectively, and the multiple participation keys are obtained by the negotiation participating node from a preset key pool;
[0068] S123, using multiple initiating keys to decrypt each participating ciphertext respectively to obtain multiple plaintexts to be analyzed;
[0069] S124, when there is a plaintext to be analyzed that is the same as the participating plaintext among the multiple plaintexts to be analyzed, determine the initiating key corresponding to the plaintext to be analyzed that is the same as the participating plaintext as the shared key.
[0070] In the embodiment of the present invention, the negotiation initiating node requests to conduct key negotiation with the negotiation participating nodes, and the negotiation participating nodes return the participating plaintext and multiple participating ciphertexts. The negotiation initiating node uses its own key to decrypt the multiple participating ciphertexts to obtain multiple plaintexts to be analyzed. The negotiation initiating node compares the multiple plaintexts to be analyzed with the participating plaintexts to obtain the same plaintext to be analyzed as the participating plaintexts. Then, the initiating key obtained by decrypting the plaintext to be analyzed is the shared key. It can be understood that only when the same key is used to decrypt the same ciphertext can the same plaintext be obtained.
[0071] Another implementation method of using multiple initiation keys to obtain shared keys corresponding to negotiation participating nodes through a challenge-response mechanism may include the following steps:
[0072] S125, broadcasting a key negotiation request, where the key negotiation request is used to request key negotiation with the negotiation participating nodes;
[0073] S126, receiving request response information broadcasted by the negotiation participating node, the request response information including a participation plaintext and multiple participation ciphertexts, the multiple participation ciphertexts are obtained by the negotiation participating node using multiple participation keys to encrypt the participation plaintexts respectively, and the multiple participation keys are obtained by the negotiation participating node from a preset key pool;
[0074] S127, using multiple initiating keys to encrypt the participating plaintexts respectively, to obtain multiple ciphertexts to be analyzed;
[0075] S128, when there is a ciphertext to be analyzed that is the same as the participating ciphertext among the multiple ciphertexts to be analyzed, determine the initiating key corresponding to the ciphertext to be analyzed that is the same as the participating ciphertext as the shared key.
[0076] In the embodiment of the present invention, the negotiation initiating node requests to conduct key negotiation with the negotiation participating nodes, and the negotiation participating nodes return the participating plaintext and multiple participating ciphertexts. The negotiation initiating node encrypts the participating plaintext with its own key to obtain multiple ciphertexts to be analyzed. The negotiation initiating node compares the multiple ciphertexts to be analyzed with the multiple participating ciphertexts to obtain the ciphertext to be analyzed that is the same as the participating ciphertext. Then, the initiating key used to encrypt the ciphertext to be analyzed is the shared key. It can be understood that only when the same key is used to encrypt the same plaintext can the same ciphertext be obtained.
[0077] The embodiment of the present invention uses a challenge-response mechanism in the key negotiation process to implement key exchange based on symmetric encryption, rather than asymmetric encryption like the Deffie-Hellman protocol, which has faster calculation speed, less resource usage and lower cost. The public key encryption scheme can only support negotiation between hosts or large systems such as the Internet of Vehicles, while the embodiment of the present invention can support micro devices (such as unmanned devices such as drones) whose computing power is insufficient to perform modular exponential operations.
[0078] S13, when the number of shared keys is greater than a preset threshold, the shared keys are integrated to obtain communication keys of the negotiation initiating node and the negotiation participating nodes.
[0079] The embodiment of the present invention pre-sets a threshold value. If the number of shared keys is greater than the preset threshold value, the shared keys are integrated to obtain a communication key, so that the negotiation initiating node and the negotiation participating node can encrypt the communication content based on the communication key to improve the security of the communication. The preset threshold value can be set by the technician according to the actual scenario needs, and the embodiment of the present invention does not limit it. There are many integration methods in actual applications, which are not limited here.
[0080] The key negotiation process is mutual. Both the negotiation initiating node and the negotiation participating nodes can obtain the shared key and communication key corresponding to the other party. As long as the multiple initiation keys of the negotiation initiating node remain unchanged and the multiple participation keys of the negotiation participating nodes remain unchanged, the shared key and communication key obtained by the negotiation initiating node are the same as those obtained by the negotiation participating nodes.
[0081] In an embodiment of the present invention, a negotiation initiating node obtains multiple initiation keys from a preset key pool; uses multiple initiation keys to obtain shared keys corresponding to negotiation participating nodes through a challenge-response mechanism, and the shared key is a key among multiple initiation keys that is the same as multiple participating keys of the negotiation participating nodes; when the number of shared keys is greater than a preset threshold, the shared keys are integrated to obtain communication keys between the negotiation initiating node and the negotiation participating nodes. The embodiment of the present invention directly obtains and uses keys from a preset key pool, and the negotiation initiating node does not need to use any protocol or algorithm to calculate the key, thereby avoiding the problem of key cracking due to leakage of exchanged information. The embodiment of the present invention uses a challenge-response mechanism to obtain shared keys, which has a faster calculation speed than keys obtained using protocols or algorithms, occupies fewer resources, and has a lower cost, thereby reducing the communication cost between the negotiation initiating node and the negotiation participating nodes, and improving the communication security between the negotiation initiating node and the negotiation participating nodes.
[0082] As mentioned above, the key negotiation process is mutual, the negotiation initiating node can obtain the shared key and communication key corresponding to the negotiation participating node, and the negotiation participating node can also obtain the shared key and communication key corresponding to the negotiation initiating node. In order to facilitate further understanding of the technical solution provided by the embodiment of the present invention, the key negotiation method provided by the embodiment of the present invention is applied to the key negotiation between drones as an example, and the key negotiation method provided by the embodiment of the present invention is introduced as a whole.
[0083] The UAV communication system includes U drones , U is a positive integer. To initiate the negotiation, the drone To explain the negotiation nodes, drones It can be U drones except drones Some or all drones outside the and drones A drone that performs the same task. For one or more drones For one or more, .
[0084] See also Figure 2 , shows a flow chart of another key agreement method provided by an embodiment of the present invention, and the embodiment of the present invention at least includes the following steps:
[0085] S21, extracting the key. S21 includes:
[0086] S21a, drone Randomly extract m keys from the preset key pool P, and construct an initiating key ring based on the m keys ,The key in the initiating key ring is called the initiating key;
[0087] S21b, drone Randomly extract n keys from the preset key pool P, and build a participating key ring based on the n keys , the key participating in the key ring is called the participating key. n is a positive integer, and the value of n can be the same as or different from the value of m.
[0088] Drones and drones The drone can be acquired through a challenge-response mechanism With drones The shared key.
[0089] S22, encrypted plaintext. S22 includes:
[0090] S22a, drone Using the initiation keyring All the keys in the plaintext Encryption is expressed as ;
[0091] S22b, drone Utilizing the Participation Keyring All the keys in the Encryption is expressed as .in, is a symmetric encryption algorithm. To initiate the ciphertext, To participate in the ciphertext.
[0092] S23, broadcasting a key negotiation request. S23 includes:
[0093] S23a, drone Initiate plain text and the initiating ciphertext Combine and get ,Will Carried in the key negotiation request and broadcast;
[0094] S23b, drone Participation in plain text and participation ciphertext Combine and get ,Will The key is carried in the key agreement request and broadcast.
[0095] S24, obtaining a shared key. S24 includes:
[0096] S24a, for drones Broadcast : The drone receiving the broadcast Using the initiation keyring All the keys in the ciphertext Decrypted, expressed as , drones Compare the decrypted plaintext with the participating plaintext in the broadcast message , you can get and drone Same key , called the shared key;
[0097] S24b, for drones Broadcast : The drone receiving the broadcast Utilizing the Participation Keyring All the keys in the ciphertext Decrypted, expressed as , drones Compare the decrypted plaintext with the initiating plaintext in the broadcast message , you can get and drone Same key .in, is a symmetric encryption algorithm. is a set of non-negative integers. It should be noted that and Similarly, the specific symmetric encryption algorithm can be set according to the actual scenario needs, and the embodiment of the present invention does not limit it.
[0098] S25, determining the communication key. S25 includes:
[0099] S25a, when the number of shared keys is greater than a preset threshold In the case of drones Perform XOR operation on the shared key to obtain the communication key ;
[0100] S25b, when the number of shared keys is greater than a preset threshold In the case of drones Perform XOR operation on the shared key to obtain the communication key .
[0101] When the number of shared keys is not greater than the preset threshold In the case of drones Receive the first process key sent by the third-party drone, the drone Receive the second process key sent by the third-party drone.
[0102] The third-party drone serves as the negotiation completion node, and and drones The nodes that have completed the key negotiation. The process key is used to assist the drone and drones The key negotiation is completed. The process key includes a first process key and a second process key.
[0103] To improve security, the process key is encrypted. Specifically, the third-party drone sends the drone The first process key is passed through the third-party drone and drone The shared key is encrypted; the third-party drone sends it to the drone The second process key is passed through the third-party drone and the drone The shared key is encrypted. Correspondingly, the drone After receiving the first process key, use the third party drone to The shared key of the drone decrypts the first process key; After receiving the second process key, use the third party drone to The second process key is decrypted using the shared key.
[0104] Third-party drones sent to drones The first process key is sent to the drone with the third party drone The second process key can be the same or different. The process key can be part or all of the keys in the key ring of the third-party drone. If the process key is part of the key ring of the third-party drone, then the third-party drone sends the drone The first process key must include the third party drone and drone The shared key between the third party drone and the drone The shared key of the third-party drone is sent to the drone. The second process key must include the third party drone and drone The shared key between the third party drone and the drone The shared key does not have a key to make the drone and drones There are enough shared keys between them.
[0105] Drones Based on the first process key update initiation key, the initiation key ring is rebuilt; UAV The participating key is updated based on the second process key, and the participating key ring is rebuilt.
[0106] Update the initiation key, that is, add the key in the first process key that is different from the initiation key to the initiation key ring. Update the participation key, that is, add the key in the second process key that is different from the participation key to the participation key ring.
[0107] Repeat S22-S24 using the updated initiation key and the updated participation key to reacquire the shared key until the drone With drones The number of shared keys is greater than the preset threshold , integrate the shared key and get the drone With drones The communication key.
[0108] S26, drone Use the communication key to encrypt the communication content, obtain the encrypted information, and send the encrypted information to the drone .
[0109] S27, drone The encrypted information is decrypted using the communication key to obtain the communication content.
[0110] The embodiment of the present invention adopts a decentralized solution, and key negotiation can be achieved without the participation of ground stations. The threat to the ground station will not spread to unattacked drones, thereby improving the security of the drone communication system.
[0111] Drones that perform the same task can form a drone group. If a new drone needs to join an existing drone group, the new drone can serve as a negotiation initiating node to execute S21-S25 to generate communication keys between the new drone and each drone in the existing drone group. It should be noted that when a new drone joins a drone group, the original drones in the drone group do not need to rebuild the key ring. Only when the shared key between the new drone and the original drone is not greater than a preset threshold, the original drone needs to update its own key ring. The embodiment of the present invention can realize the expansion of nodes in a drone group without considering the compatibility between the new drone and the ground station, thereby improving the scalability of the drone group.
[0112] When a drone in a drone group is attacked and fails, considering that the key ring in the attacked drone may leak the key rings of other drones communicating with the attacked drone, the drone communication system deletes the key that is identical to the key in the key ring of the attacked drone in the preset key pool after determining that the attacked drone has failed based on the status of the drone, and broadcasts a failure request in the drone communication system. The failure request includes the identification of the attacked drone, so that other drones in the drone group including the attacked drone, except the attacked drone, determine their shared keys with the attacked drone based on the identification of the attacked drone, and delete these shared keys from their own key rings.
[0113] Assuming that the drone group includes drone A, drone B and drone C, and drone A is the attacked drone, drone B and drone C need to delete the shared key with drone A from their respective key rings. If after deleting the shared key, the shared key between drone B and drone C is not greater than the preset threshold, since there is no third-party drone in the drone group, drone B and drone C need to renegotiate the key, that is, execute S21-S25.
[0114] Assuming that the drone group includes drone A, drone B, drone C and drone D, and drone A is the attacked drone, drone B, drone C and drone D need to delete the shared key with drone A from their respective key rings. If after deleting the shared key, the shared key between drone B and drone C is not greater than the preset threshold, since there is a third-party drone in the drone group, drone B and drone C need to renegotiate the key, that is, drone D is regarded as a third-party drone, and S25 is executed.
[0115] The embodiment of the present invention also introduces a key destruction mechanism to avoid communication key leakage and system paralysis that may occur when the drone is hijacked, thereby improving the robustness of the drone group.
[0116] The embodiment of the present invention uses a challenge-response mechanism to negotiate keys instead of directly broadcasting key identifiers. Even if an attacker controls multiple nodes, he cannot directly obtain the communication keys between other nodes that have not been attacked. And even if the attacker obtains a key pool, he cannot directly match the key in the key pool with the ciphertext in the challenge-response mechanism process, thereby improving the security of the key negotiation process.
[0117] Next, a key negotiation device provided by the present invention is introduced. The key negotiation device introduced below and the key negotiation method introduced above can correspond to each other.
[0118] See also Figure 3 , showing a schematic diagram of the structure of a key agreement device provided by the present invention, the device comprising:
[0119] The initiation key acquisition module 301 is used to obtain multiple initiation keys from a preset key pool;
[0120] A shared key acquisition module 302, configured to use the multiple initiation keys to acquire a shared key corresponding to the negotiation participating node through a challenge-response mechanism, wherein the shared key is a key among the multiple initiation keys that is the same as a participation key of the negotiation participating node;
[0121] The key integration module 303 is used to integrate the shared keys when the number of the shared keys is greater than a preset threshold, so as to obtain the communication keys between the negotiation initiating node and the negotiation participating nodes.
[0122] In the embodiment of the present invention, the shared key acquisition module 302 includes:
[0123] A broadcast unit, used for broadcasting a key negotiation request, wherein the key negotiation request is used for requesting to perform key negotiation with the negotiation participating node;
[0124] a receiving unit, configured to receive request response information broadcasted by the negotiation participating node, wherein the request response information includes a participation plaintext and a plurality of participation ciphertexts, wherein the plurality of participation ciphertexts are obtained by the negotiation participating node encrypting the participation plaintexts respectively using a plurality of the participation keys, and the plurality of the participation keys are obtained by the negotiation participating node from the preset key pool;
[0125] A decryption unit, used to use the multiple initiation keys to decrypt each of the participating ciphertexts respectively to obtain multiple plaintexts to be analyzed;
[0126] The determining unit is configured to determine, when there is a plaintext to be analyzed that is identical to the participating plaintext among the multiple plaintexts to be analyzed, an initiating key corresponding to the plaintext to be analyzed that is identical to the participating plaintext as the shared key.
[0127] In the embodiment of the present invention, the key integration module 303 is specifically used for:
[0128] An XOR operation is performed on the shared key to obtain the communication key.
[0129] In an embodiment of the present invention, the device further includes:
[0130] a receiving module, configured to receive, when the number of the shared keys is not greater than the preset threshold, a process key sent by a negotiation completion node, wherein the negotiation completion node is a node that completes key negotiation with the negotiation initiating node and the negotiation participating node respectively, and the process key is used to assist the negotiation initiating node and the negotiation participating node in completing key negotiation;
[0131] An updating module, configured to update the plurality of initiation keys based on the process key;
[0132] An acquisition module, used to reacquire a shared key corresponding to the negotiation participating node by using the updated multiple initiation keys through a challenge-response mechanism;
[0133] The integration module is used to integrate the shared keys when the number of the re-acquired shared keys is greater than the preset threshold value, so as to obtain the communication keys of the negotiation initiating node and the negotiation participating nodes.
[0134] In an embodiment of the present invention, the device further includes:
[0135] The key deletion module is used to delete the shared key corresponding to the negotiation participating node from the multiple initiating keys when the negotiation participating node fails.
[0136] An embodiment of the present invention further provides a computer device, comprising: a memory and a processor;
[0137] Wherein, the memory is used to store computer programs;
[0138] The processor is used to execute the computer program in the memory to implement the method described in the above method embodiment.
[0139] An embodiment of the present invention further provides a computer-readable storage medium storing instructions, which, when executed on a computer, enables the computer to execute the method described in the above method embodiment.
[0140] In an embodiment of the present invention, the initiating key acquisition module obtains multiple initiating keys from a preset key pool; the shared key acquisition module uses multiple initiating keys to obtain shared keys corresponding to the negotiation participating nodes through a challenge-response mechanism, and the shared key is a key among multiple initiating keys that is the same as multiple participating keys of the negotiation participating nodes; the key integration module integrates the shared keys when the number of shared keys is greater than a preset threshold, and obtains the communication key between the negotiation initiating node and the negotiation participating nodes. The embodiment of the present invention directly obtains and uses keys from a preset key pool, and the negotiation initiating node does not need to use any protocol or algorithm to calculate the key, thereby avoiding the problem of key cracking due to leakage of exchanged information. The embodiment of the present invention uses a challenge-response mechanism to obtain shared keys, which has a faster calculation speed than keys obtained using protocols or algorithms, occupies fewer resources, and has a lower cost, thereby reducing the communication cost between the negotiation initiating node and the negotiation participating nodes, and improving the communication security between the negotiation initiating node and the negotiation participating nodes.
[0141] It should be noted that the same or similar parts between the various embodiments can be referred to each other. As for the device embodiment and the system embodiment, since they are basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0142] For the above-mentioned embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the order of the actions described, because according to the present invention, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
[0143] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0144] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features disclosed herein.
[0145] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principle of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A key negotiation method, characterized in that: A negotiation initiating node applied to a communication system, wherein the communication system further comprises a negotiation participating node and a negotiation completing node, wherein the negotiation completing node is a node that completes key negotiation with the negotiation initiating node and the negotiation participating node respectively, and the method comprises: Obtain multiple initiation keys from a preset key pool; Using the multiple initiation keys to obtain a shared key corresponding to the negotiation participating node through a challenge-response mechanism, the shared key being a key among the multiple initiation keys that is the same as a participation key of the negotiation participating node; In the case where the number of the shared keys is greater than a preset threshold, integrating the shared keys to obtain a communication key between the negotiation initiating node and the negotiation participating nodes; When the number of the shared keys is not greater than the preset threshold, receiving a process key sent by the negotiation completion node, where the process key is used to assist the negotiation initiating node and the negotiation participating node in completing key negotiation; updating the plurality of initiation keys based on the process key; Re-acquire the shared keys corresponding to the negotiation participating nodes by using the updated multiple initiation keys through a challenge-response mechanism; In the case where the number of the re-acquired shared keys is greater than the preset threshold, performing a step of integrating the shared keys to obtain a communication key between the negotiation initiating node and the negotiation participating nodes; The step of using the multiple initiation keys to obtain a shared key corresponding to the negotiation participating node through a challenge-response mechanism includes: Broadcasting a key negotiation request, where the key negotiation request is used to request key negotiation with the negotiation participating node; Receiving request response information broadcasted by the negotiation participating node, the request response information including a participation plaintext and a plurality of participation ciphertexts, the plurality of participation ciphertexts being obtained by the negotiation participating node encrypting the participation plaintexts respectively using a plurality of the participation keys, the plurality of the participation keys being obtained by the negotiation participating node from the preset key pool; Decrypting each of the participating ciphertexts using the multiple initiating keys to obtain multiple plaintexts to be analyzed; In the case that there is a plaintext to be analyzed that is the same as the participating plaintext among the multiple plaintexts to be analyzed, an initiation key corresponding to the plaintext to be analyzed that is the same as the participating plaintext is determined as the shared key.
2. The method according to claim 1, characterized in that The step of integrating the shared keys to obtain the communication keys of the negotiation initiating node and the negotiation participating nodes includes: An XOR operation is performed on the shared key to obtain the communication key.
3. The method according to claim 1 or 2, characterized in that: After integrating the shared keys to obtain the communication keys of the negotiation initiating node and the negotiation participating nodes, the method further includes: In the case where the negotiation participating node fails, the shared key corresponding to the negotiation participating node among the multiple initiating keys is deleted.
4. A key agreement device, characterized in that: A negotiation initiating node applied to a communication system, wherein the communication system further comprises a negotiation participating node and a negotiation completing node, wherein the negotiation completing node is a node that completes key negotiation with the negotiation initiating node and the negotiation participating node respectively, and the device comprises: An initiation key acquisition module, used to obtain multiple initiation keys from a preset key pool; a shared key acquisition module, configured to use the multiple initiation keys to acquire a shared key corresponding to the negotiation participating node through a challenge-response mechanism, wherein the shared key is a key among the multiple initiation keys that is the same as a participation key of the negotiation participating node; A key integration module, used to integrate the shared keys when the number of the shared keys is greater than a preset threshold, so as to obtain the communication keys between the negotiation initiating node and the negotiation participating nodes; The shared key acquisition module includes: A broadcast unit, used for broadcasting a key negotiation request, wherein the key negotiation request is used for requesting to perform key negotiation with the negotiation participating node; a receiving unit, configured to receive request response information broadcasted by the negotiation participating node, wherein the request response information includes a participation plaintext and a plurality of participation ciphertexts, wherein the plurality of participation ciphertexts are obtained by the negotiation participating node encrypting the participation plaintexts respectively using a plurality of the participation keys, and the plurality of the participation keys are obtained by the negotiation participating node from the preset key pool; A decryption unit, used to use the multiple initiation keys to decrypt each of the participating ciphertexts respectively to obtain multiple plaintexts to be analyzed; a determining unit, configured to determine, when there is a plaintext to be analyzed that is identical to the participating plaintext among the multiple plaintexts to be analyzed, an initiating key corresponding to the plaintext to be analyzed that is identical to the participating plaintext as the shared key; The device also includes: a receiving module, configured to receive, when the number of the shared keys is not greater than the preset threshold, a process key sent by a negotiation completion node, wherein the negotiation completion node is a node that completes key negotiation with the negotiation initiating node and the negotiation participating node respectively, and the process key is used to assist the negotiation initiating node and the negotiation participating node in completing key negotiation; An updating module, configured to update the plurality of initiation keys based on the process key; An acquisition module, used to reacquire a shared key corresponding to the negotiation participating node by using the updated multiple initiation keys through a challenge-response mechanism; The integration module is used to integrate the shared keys when the number of the re-acquired shared keys is greater than the preset threshold value, so as to obtain the communication keys of the negotiation initiating node and the negotiation participating nodes.
5. The device according to claim 4, characterized in that The device also includes: The key deletion module is used to delete the shared key corresponding to the negotiation participating node from the multiple initiating keys when the negotiation participating node fails.
6. A computer device, characterized in that: include: Memory and processor; The memory is used to store computer programs; The processor is configured to execute the computer program in the memory to implement the method according to any one of claims 1 to 3.
7. A computer-readable storage medium, characterized in that: The device stores instructions which, when executed on a computer, cause the computer to execute the method according to any one of claims 1 to 3.
