Detailed Description
The invention provides a segmented key distribution method for a hybrid relay QKD network, which fully utilizes the security characteristic of a trusted relay, reduces the path length of key distribution, thereby improving the security and reducing the consumption of key resources on a link.
The present invention will be further described in detail below with reference to the accompanying drawings by way of specific embodiments in order to make the objects, technical solutions and advantages of the present invention more apparent.
Example 1
As shown in fig. 1, the method for distributing the segment key for the hybrid relay QKD network according to the embodiment of the present invention includes the following steps:
Step S1, after any terminal node in a QKD network sends a user key distribution request, a key distribution path and a segmentation path thereof are constructed, wherein the key distribution path comprises a source node, a destination node, a trusted relay node and an untrusted relay node;
Step S2, carrying out key distribution on each sub-segment path contained in each segment of segment path in parallel, reconstructing the key by adopting a key reconstruction function on an end node of the segment path, and synchronously generating a segment key corresponding to each segment of segment path;
and S3, along the key distribution path, using the first segment key as a user key of the key distribution path, using the other segment keys as encryption keys, and forwarding the user key through a trusted relay to finish the user key distribution from the source node to the destination node.
In one embodiment, step S1, after any terminal node in the QKD network sends a user key distribution request, a key distribution path and a segment path thereof are constructed, where the key distribution path includes a source node, a destination node, a trusted relay node, and an untrusted relay node, and each segment of segment path includes at least one sub-segment path, and specifically includes:
The method comprises the steps that a centralized controller obtains position information of a trusted relay node serving as a convergence point, a key distribution path is constructed according to a routing algorithm, the key distribution path comprises N trusted relay nodes, and therefore N+1 segmented paths are formed, wherein an end node of each segmented path is a source node, a destination node or a trusted relay node, when the segmented path comprises a plurality of sub-segmented paths, the sub-segmented paths are parallel paths, namely, the sub-segmented paths share a start end node and a stop end node of the segmented path. In particular, when n=0, the path between the source node and the destination node is constituted by a single segment path.
The centralized controller is widely used in the existing QKD network, as shown in fig. 2, and the centralized controller can acquire the network status of the whole QKD network, including the network topology and whether the relay node is trusted, and send routing information and reconfiguration instructions to the relay node. The centralized controller establishes a key distribution path and its segment path according to the actual conditions of the source node, destination node, and network included in the key distribution request of any terminal node in the QKD network. The key distribution path is composed of a plurality of segmented paths in series, and each segmented path comprises a plurality of parallel sub-segmented paths.
The steps of the routing algorithm based on the segmentation in the embodiment of the invention are as follows:
1) And finding the segmented trusted relay node. The initial set of trusted relays is empty. A Dijkstra algorithm is used to find a trusted relay node that is not in the set of trusted relays and that has the smallest sum of hops between the source node and the destination node. And then using an extended Dijkstra algorithm taking the key distribution security probability of the path as the path cost to find the optimal two paths between the source node and the destination node and calculate the security probability of user key distribution between the source node and the destination node, and then also finding the optimal two segmentation paths from the source node to the trusted relay node and the trusted relay node to the destination node and calculate the security probability of user key distribution after segmentation. If the security probability after segmentation is larger, adding the trusted relay node into the set, setting the node as a new source node, and continuously repeating the step 1), otherwise, stopping the step 1).
2) The path of the segment is found. Starting to circularly search available paths in the segment by using the trusted relay set found in the step 1) as a path convergence point. Each round of looping finds a sub-segment path on each segment and updates the topology until the algorithm is aborted when no additional paths are found in a round of looping or the security requirements are met.
The embodiment of the invention calculates the safety of each sub-segment path according to the following formula:
P l is the security probability of a distribution key of a certain sub-segment path on a segment path, l is a relay node set contained in the sub-segment path and comprises a trusted relay node and an untrusted relay node, ρ i is the security probability of a relay node i on the sub-segment path, the probability that the relay node i is not controlled by an attacker is represented, the higher the value of ρ i is, the safer the relay node i is, and when the relay node i is the trusted relay node, ρ i =1 is represented as the absolute security of the trusted relay node;
the security of each segment of the segmented path is calculated according to the following formula:
Wherein s j is a sub-segment path set on the jth segment path, and MP j is the security probability of the segment key obtained by key reconstruction on the jth segment path through the keys on the multiple parallel sub-segment paths.
The security of the user key on the key distribution path is calculated according to the following formula:
wherein, the The SP is the security probability of the user key obtained through the distribution of the segmented key.
In the QKD network shown in fig. 3, the relay nodes except the source node S, the destination node D and one trusted relay node R are all untrusted relay nodes, i.e. the number of trusted relay nodes n=1, and the network includes 2 segment paths S-R and R-D, where the segment path S-R includes three parallel sub-segment paths S-A-R, S-B-R and S-C-R, and the segment path R-D includes two parallel sub-segment paths R-H-D and R-G-D.
In one embodiment, the step S2 includes performing key distribution on each sub-segment path included in each segment of segment path in parallel, and reconstructing a key on an end node of the segment path by using a key reconstruction function, so as to synchronously generate a segment key corresponding to each segment of segment path, where the method specifically includes:
Step S21, regarding a key shared between a starting end node and a next adjacent relay node of each segment of the segmented path as a key of the segmented path, regarding keys shared among other relay nodes on the segmented path as encryption keys, and forwarding the keys in a hop-by-hop encryption and decryption mode through the relay nodes on the segmented path, namely, adopting the key shared with the previous adjacent node to decrypt the keys on the segmented path and adopting the key shared with the next adjacent node to encrypt the keys until reaching a termination end node of the segmented path;
s22, generating a segmented key for obtaining the segmented path by adopting the same key reconstruction function at the end node, namely the initial end node and the end node, on the segmented path;
When the non-segmented key distribution method based on multipath in the existing method is adopted, in order to avoid that an attacker controls a single unreliable relay node and can steal multiple keys, the searched paths are node-disjoint. As shown in fig. 3, when the source node S needs to send the user key KA to the destination node D, only two paths which are not intersected by the source node S and the destination node D can be found, taking paths S-A-R-H-D and S-C-E-F-G-D as examples, the keys A1 and A2 are respectively distributed through the paths, and finally the consistent user key KA can be obtained by performing exclusive or operation on the keys A1 and A2 at the source node S and the destination node D. Assuming that the unit key amount generated between adjacent links is 128 bits and the security probability ρ i =0.9 of the untrusted relay node, considering that the hop numbers of the two paths are 4 hops and 5 hops respectively, the key amount required to be consumed for realizing end-to-end user key distribution on the key distribution path by adopting A one-time pad method is 9 x 128 bits, the security probability of the key A1 after the path S-A-R-H-D hop-by-hop encryption forwarding is 1x 0.9 x 1=0.81, the security probability of the key A2 after the path S-C-E-F-G-D hop-by-hop encryption forwarding is 1x 0.9 x 1=0.6561, the security probability of the end user key after the exclusive-or reconstruction operation is 1- (1-0.81) × (1-0.6561) = 0.9347.
Fig. 4 shows A key distribution method based on A segmented path, which is provided by the invention, wherein A trusted relay node R is used as A segmented point, three parallel sub-segmented paths, namely, S-A-R, S-B-R and S-C-R, are established between A source node S and the trusted relay node R to distribute keys A1, A2 and A3 respectively, and A shared segmented key kA is reconstructed between the source node S and the trusted relay node R through the keys. And constructing two parallel sub-segment paths between the trusted relay node R and the destination node D, namely respectively distributing path keys b1 and b2 by the R-H-D and the R-G-D, reconstructing a shared segment key Kb by the trusted relay node R and the destination node D through the keys, and finally distributing a user key Ka to the destination node D by the trusted relay R by using Ka and Kb in an encryption forwarding method.
Firstly, even if only two parallel sub-segment paths S-A-R, S-B-R are used between the source node S and the trusted relay node R, at this time, according to the security calculation formulA, the security probabilities of the keys A1 and A2 distributed through the two parallel sub-segment paths S-A-R and S-B-R are both 1×0.9×1=0.9, and then the security probability of the segment key kA after the exclusive or reconstruction operation is 1- (1-0.9) ×1-0.9) =0.99. Similarly, two parallel sub-segment paths are used between the trusted relay node R and the destination node D, the security probability of the keys b1 and b2 distributed through the two parallel sub-segment paths R-H-D R and R-G-D is 1×0.9×1=0.9 according to a security calculation formula, and then the security probability of Kb of the segment key after the exclusive or reconstruction operation is 1- (1-0.9) ×1-0.9) =0.99, and finally, ka is used as a user key and Kb is used as an encryption key, and the security probability of the user key obtained by forwarding through the trusted relay node R is 0.99×0.99= 0.9801. Also assuming that the unit key amount generated between adjacent links is 128 bits, the segmentation-based key distribution method adopted by the invention uses A total of four sub-segmentation paths with 2 hops, namely S-A-R, S-B-R, R-H-D, R-G-D, so that the consumed key amount is 8 x 128 bits. Compared with the prior art, the method provided by the invention not only consumes less link key resources, but also has better security for key distribution than the conventional multipath distribution method.
Secondly, the method provided by the invention provides an option with better security, and when the sub-segment path S-C-R is further adopted, the security can be further improved under the condition of consuming more key resources, namely 10 x 128 bits. At this time, according to the security calculation formula, the security probability of the keys a1, a2 and a3 is 0.9, the security probability of the segmented key Ka after the exclusive-or reconstruction operation is 1- (1-0.9) × (1-0.9) =0.999, the security probability of the keys b1 and b2 is 0.9, the security probability of the segmented key Kb after the exclusive-or reconstruction operation is 1- (1-0.9) × (1-0.9) =0.99, and finally, the security probability of the user key forwarded by the trusted relay node R is 0.999×0.99= 0.98901 with Ka as the user key and Kb as the encryption key.
And when the distribution of the path keys is completed on all paths between nodes at two ends of the path of the segment, generating and obtaining the key of the segment by adopting a key reconstruction function aiming at the path keys on all paths of the segment. The method for reconstructing the segmented key in the embodiment of the invention comprises an exclusive OR, a HASH, (t, n) threshold algorithm and the like. As shown in fig. 4, the path keys a1, a2, and a3 generate the segment key Ka through key reconstruction, and the path keys b1, b2, and b3 generate the segment key Kb through key reconstruction.
The segmented key distribution method for the hybrid relay QKD network can utilize more residual paths in the network, shortens the path length by multiplexing the trusted relay nodes, reduces the risk of key leakage, improves the security of key distribution, and reduces the consumption of key resources on links.
In one embodiment, the step S3 includes using a first segment key as a user key of the key distribution path along the key distribution path, using the other segment keys as encryption keys, forwarding the user key via a trusted relay, and completing user key distribution from a source node to a destination node, where the method specifically includes:
Starting from a source node, taking a first segment key as a user key of the key distribution path, adopting a hop-by-hop encryption and decryption mode at a trusted relay node along the key distribution path, namely decrypting by the trusted relay node by adopting a segment key of a former segment path, encrypting by using a segment key of a latter segment path, and then transmitting to a next trusted relay node until reaching a destination node, and obtaining the user key of the key distribution path.
For a key distribution path formed by a plurality of segments, the segment key of the first segment is used as a user key of the key distribution path, and the subsequent aggregation trusted relay node realizes key distribution in a hop-by-hop forwarding mode. In the forwarding process, the key is encrypted and decrypted by the segment key of each segment. As shown in fig. 4, when the segment key Ka is used as the user key Ka of the key distribution path, the trusted relay node R encrypts Ka using the segment key Kb and transmits the encrypted result to the destination node D through the network, and the destination node D decrypts the received encrypted information using Kb to obtain Ka. Finally, the user key Ka of the key distribution path meeting certain security requirements is obtained.
In the embodiment of the invention, the same unreliable relay node is assumed to be controlled by an attacker, and when the segmented key distribution method is adopted, the sub-segmented path keys a 1and b2 are assumed to be leaked if the node A and the node G are attacked at the moment, but the segmented keys Ka and Kb still remain safe. When the non-segmented key distribution method based on multipath in the existing method is adopted, it is also assumed that the node A and the node G are attacked at the moment, the keys a 1and a2 distributed by the two paths are leaked, and the final user key is reconstructed by the keys a 1and a2, so that the security is not ensured.
The invention discloses a segmented key distribution method for a hybrid relay QKD network, which segments a key distribution path based on a trusted relay, distributes the risk of key leakage of one key distribution path to each segment, avoids that a single node on the path is attacked to influence the security of the distributed key on the whole path, fully utilizes the security characteristic of the trusted relay, reduces the length of the key distribution path, thereby improving the security of the key distribution process and reducing the consumption of key resources on a link.
Example two
As shown in fig. 5, an embodiment of the present invention provides a segmented key distribution system for a hybrid relay QKD network, including the following modules:
the routing module 41 for constructing a key distribution path and a segmentation path thereof is used for constructing the key distribution path and the segmentation path thereof after any terminal node in the QKD network sends a user key distribution request, wherein the key distribution path comprises a source node, a destination node, a trusted relay node and an untrusted relay node;
A segmented path key distribution and reconstruction module 42, configured to perform key distribution on each sub-segmented path included in each segmented path in parallel, reconstruct the key at an end node of the segmented path by using a key reconstruction function, and synchronously generate a segmented key corresponding to each segmented path;
the segment key forwarding module 43 is configured to forward the user key along the key distribution path with the first segment key as the user key of the key distribution path and the other segment keys as the encryption keys via a trusted relay, thereby completing user key distribution from the source node to the destination node.
The above examples are provided for the purpose of describing the present invention only and are not intended to limit the scope of the present invention. The scope of the invention is defined by the appended claims. Various equivalents and modifications that do not depart from the spirit and principles of the invention are intended to be included within the scope of the invention.