Data transmission method of routing node and related equipment
By calculating the data throughput in the routing node and selecting the target verification packet for verification, the verification time overhead and transmission delay problems caused by the increase in the number of data packets are solved, and efficient data transmission is achieved.
Patent Information
- Application Number
- CN202411049948.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-01
- Publication Date
- 2024-11-26
AI Technical Summary
In a communication network, as the number of data packets increases, routing nodes need to perform security inspections on packet-by-packet basis, resulting in an increase in inspection time overhead and transmission delay.
By obtaining the data throughput of the current routing node, calculating the decisive verification probability, selecting the target verification packet from multiple transmission packets for verification, and performing data verification based on the path verification data, reducing the verification time overhead in the routing node.
While ensuring the security of data transmission, it reduces the data transmission delay and improves the efficiency of data transmission.
Smart Images

Figure CN119030753A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of network security technology, and in particular to a data transmission method and related equipment of a routing node. Background Art
[0002] When transmitting data in a communication network, the data is usually sent from the data sending end, and the data is forwarded by multiple routing nodes before arriving at the data receiving end. In order to further improve the security of the data transmission process, verification data is usually added to each data packet in the transmission data at the data sending end, and during the data transmission process, after each routing node receives the transmission data, the verification data in each data packet is verified. When the verification data of all data packets are verified, the transmission data is forwarded to the next routing node until the transmission data is transmitted to the data receiving end. When the number of data packets of the transmission data increases further, this type of data transmission method needs to perform security checks on each data packet at each routing node, which further increases the inspection time overhead at each routing node and increases the data transmission delay of the transmission data. Summary of the invention
[0003] The embodiments of the present application provide a data transmission method and related equipment for a routing node, which can reduce the data transmission delay while ensuring the security of data transmission.
[0004] To achieve the above-mentioned purpose, a first aspect of an embodiment of the present application provides a data transmission method of a routing node, wherein a plurality of the routing nodes are connected in sequence, and the method comprises:
[0005] Acquire transmission data and acquire an extraction verification probability of a current routing node, wherein the transmission data includes a plurality of transmission data packets, and the extraction verification probability is determined based on a data throughput of the routing node;
[0006] Selecting a target verification data packet from a plurality of the transmission data packets based on the extraction verification probability;
[0007] Obtain the path verification data in the target verification data packet, perform data verification based on the path verification data, obtain a data verification result of the transmission data, and transmit the transmission data to the next routing node based on the data verification result.
[0008] In some embodiments, obtaining the extraction verification probability of the current routing node includes:
[0009] Obtaining the data throughput of the current routing node, and obtaining a verification proportional coefficient and a verification scaling factor;
[0010] The extracted verification probability is generated based on the verification scaling factor, the verification proportional coefficient, and the data throughput.
[0011] In some embodiments, obtaining the verification scale coefficient and the verification scaling factor includes:
[0012] Acquire a plurality of preset proportional coefficients and a first throughput threshold corresponding to each of the preset proportional coefficients, and acquire a plurality of preset scaling factors and a second throughput threshold corresponding to each of the preset scaling factors;
[0013] Selecting a first throughput threshold matching the data throughput from the plurality of first throughput thresholds as a target first throughput threshold, and using a preset proportional coefficient corresponding to the target first throughput threshold as the verification proportional coefficient;
[0014] A second throughput threshold matching the data throughput is selected from the plurality of second throughput thresholds as the target second throughput threshold, and a preset scaling factor corresponding to the target second throughput threshold is used as the verification scaling factor.
[0015] In some embodiments, generating the extracted verification probability based on the verification scaling factor, the verification proportional coefficient, and the data throughput includes:
[0016] Obtain minimum verification parameters and baseline verification parameters;
[0017] Obtaining a scaled data volume based on a product of the verification scaling factor and the data throughput and adding the minimum verification parameter;
[0018] Based on the ratio of the verification scale coefficient and the scaled data volume, and adding the baseline verification parameter, the extraction verification probability is obtained.
[0019] In some embodiments, the path verification data includes verification information and a verification code, and performing data verification based on the path verification data to obtain a data verification result of the transmission data includes:
[0020] Acquire a symmetric key between the routing node and the previous routing node, and perform a hash verification calculation on the verification information based on the symmetric key to obtain a verification code;
[0021] The verification code is matched with the authentication code, and the data authentication result is obtained according to the matching result.
[0022] In some embodiments, performing a hash verification calculation on the verification information based on the symmetric key to obtain a verification code includes:
[0023] Obtaining the number of parallel executions of the verification processing pipeline and the verification data volume of the verification information, and obtaining the pipeline processing rounds of the verification processing pipeline based on the verification data volume and the parallel execution number, wherein the verification processing pipeline is used to perform compression and mixing processing on the verification information;
[0024] Based on the pipeline processing round, a hash verification calculation is performed on the verification information and the symmetric key to obtain the verification code.
[0025] In some embodiments, obtaining the number of parallel executions of the verification processing pipeline includes:
[0026] Acquire the parallel execution parameters of the verification processing pipeline, and obtain the pipeline parallel processing number based on the pipeline inlet and pipeline outlet of the verification processing pipeline;
[0027] The parallel execution number is obtained based on the product of the parallel execution parameter and the pipeline parallel processing number.
[0028] In some embodiments, the pipeline processing round includes a hybrid processing round and a compression processing round, and obtaining the pipeline processing round of the verification processing pipeline based on the verification data volume and the parallel execution number includes:
[0029] Get the mixing rounds, compression parameters, and number of parallel stages of the hash algorithm;
[0030] Based on the ratio of the hybrid round and the parallel execution number, obtaining the hybrid processing round;
[0031] Based on the ratio of the verification data volume to the number of parallel stages, multiplying by the compression parameter, a compression round is obtained, and based on the ratio of the compression round to the number of parallel executions, the compression processing round is obtained.
[0032] In some embodiments, performing hash verification calculation on the verification information and the symmetric key based on the pipeline processing round to obtain the verification code includes:
[0033] Obtaining a target hash function of the hash algorithm, and obtaining an input string based on the verification information and the symmetric key;
[0034] The input string is compressed at the pipeline entrance to obtain a first compressed string, the first compressed string is compressed at the pipeline exit to obtain a second compressed string, the second compressed string is used as the input string for the next round of compression processing, until the compression processing round reaches the compression processing round, and the input string after the compression processing is used as a mixed string;
[0035] Performing a mixing process on the mixed character string at the entrance of the pipeline to obtain a first mixed character string, performing the mixing process on the first mixed character string at the exit of the pipeline to obtain a second mixed character string, using the second mixed character string as the mixed character string for a next round of mixing process, until the processing round of the mixing process reaches the mixing process round, and using the input character string after the mixing process as an output character string;
[0036] The hash value of the output string is calculated based on the target hash function to obtain the verification code.
[0037] In some embodiments, the transmission data packet includes a plurality of data segments, and obtaining the path verification data in the target verification data packet includes:
[0038] Determine the node number preceding the previous routing node;
[0039] From the multiple data segments in the target verification data packet, a data segment whose data segment sequence number corresponds to the preceding node sequence number is selected as the target data segment, and path verification data is obtained from the target data segment.
[0040] In some embodiments, transmitting the transmission data to the next routing node based on the data verification result includes:
[0041] Determine the current node sequence number of the current routing node;
[0042] The data segments whose data segment sequence numbers correspond to the current node sequence number in all the transmission data packets are used as update data segments;
[0043] The data verification result is added to the update data segment, and the updated transmission data is transmitted to the next routing node.
[0044] To achieve the above-mentioned purpose, a second aspect of an embodiment of the present application provides a data transmission device of a routing node, an acquisition module, used to acquire transmission data and acquire an extraction verification probability of a current routing node, wherein the transmission data includes a plurality of transmission data packets, and the extraction verification probability is determined based on the data throughput of the routing node;
[0045] An extraction module, used for selecting a target verification data packet from a plurality of transmission data packets based on the extraction verification probability;
[0046] The verification processing module is used to obtain the path verification data in the target verification data packet, and perform data verification based on the path verification data to obtain the data verification result of the transmission data, and transmit the transmission data to the next routing node based on the data verification result.
[0047] To achieve the above-mentioned purpose, the third aspect of an embodiment of the present application proposes an electronic device, which includes a memory and a processor, the memory stores a computer program, and when the processor executes the computer program, it implements the data transmission method of the routing node as described in the first aspect.
[0048] To achieve the above-mentioned purpose, the fourth aspect of an embodiment of the present application proposes a storage medium, which is a computer-readable storage medium, and the storage medium stores a computer program. When the computer program is executed by a processor, it implements the data transmission method of the routing node described in the first aspect above.
[0049] The data transmission method and related equipment of the routing node proposed in the embodiment of the present application, multiple routing nodes are connected in sequence, and the method includes: first, obtaining transmission data and obtaining the extraction verification probability of the current routing node, the transmission data includes multiple transmission data packets, and the extraction verification probability is determined based on the data throughput of the routing node; then, selecting a target verification data packet from the multiple transmission data packets based on the extraction verification probability; finally, obtaining the path verification data in the target verification data packet, and performing data verification based on the path verification data to obtain the data verification result of the transmission data, and transmitting the transmission data to the next routing node based on the data verification result. After the routing node receives the transmission data, the embodiment of the present application uses the extraction verification probability determined by the data throughput of the routing node to perform data verification on the selected part of the transmission data packets in the transmission data, and combined with the data transmission process, when subjected to data interference, multiple transmission data packets in the transmission data usually change together, so the selected part of the transmission data packets for data verification can ensure reliable security inspection, so that the data verification result of the part of the transmission data packets is used as the transmission data, and there is no need to perform data verification on all the transmission data packets in the transmission data, so as to reduce the time overhead of inspection at the routing node, thereby reducing the data transmission delay of the transmission data while ensuring the security of data transmission.
[0050] Other features and advantages of the present application will be described in the following description, and partly become apparent from the description, or understood by practicing the present application. The purpose and other advantages of the present application can be realized and obtained by the structures specifically pointed out in the description, claims and drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] Figure 1 It is a structural diagram of a network system provided in one embodiment of the present application.
[0052] Figure 2 This is a flowchart of a data transmission method of a routing node provided by another embodiment of the present application.
[0053] Figure 3 yes Figure 2 Flow chart of step 201 in FIG.
[0054] Figure 4 yes Figure 3 Flow chart of step 301 in FIG.
[0055] Figure 5 yes Figure 3 Flow chart of step 302 in FIG.
[0056] Figure 6 It is a schematic diagram of selecting a target verification data packet provided by another embodiment of the present application.
[0057] Figure 7 It is a structural diagram of a transmission data packet provided by another embodiment of the present application.
[0058] Figure 8 This is a flowchart for obtaining path verification data provided by another embodiment of the present application.
[0059] Fig. 9 yes Figure 2 Flow chart of step 203 in FIG.
[0060] Fig.10 yes Fig. 9 Flowchart of step 901 in FIG.
[0061] Fig.11 yes Fig.10 Flowchart of step 1001 in FIG.
[0062] Fig.12 yes Fig.10 Another flow chart of step 1001 in FIG.
[0063] Fig.13 yes Fig.10 Flowchart of step 1002 in FIG.
[0064] Fig.14 yes Figure 2 Another flow chart of step 203 in FIG.
[0065] Fig.15 It is a schematic diagram of a control device for transmitting data provided in an embodiment of the present application.
[0066] Fig.16 It is a structural diagram of a data transmission device of a routing node provided in one embodiment of the present application.
[0067] Fig.17 It is a schematic diagram of the hardware structure of an electronic device provided in one embodiment of the present application. DETAILED DESCRIPTION
[0068] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0069] It should be noted that although the functional modules are divided in the device schematic and the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than the module division in the device or the order in the flowchart.
[0070] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0071] First, some nouns involved in this application are analyzed:
[0072] Data throughput refers to the amount of data that a system, network, device or application can transmit, process or store in a specific period of time. It is a key indicator to measure the working efficiency of communication systems, computer networks and storage devices. The unit is usually bits per second (bps), kilobits per second (kbps), megabits per second (Mbps), gigabits per second (Gbps), etc.
[0073] SipHash is a family of pseudo-random functions designed for short messages, mainly used for the calculation of message authentication codes (MAC) to ensure the integrity of data and the authenticity of the source. It was designed by Jean-Philippe Aumasson et al. in 2012 to find a good balance between speed and security, and is particularly suitable for defending against Hash Flooding type denial of service (DoS) attacks.
[0074] PBKDF2 (Password-Based Key Derivation Function 2) is a cryptographic key derivation function. It is designed to derive one or more encryption keys from a password (a simple password that the user remembers). This process is usually called key stretching, and its purpose is to resist brute force cracking and rainbow table attacks by increasing the computational strength.
[0075] When transmitting data in a communication network, the data is usually sent from the data sending end, and the data is forwarded by multiple routing nodes before arriving at the data receiving end. In order to further improve the security of the data transmission process, verification data is usually added to each data packet in the transmission data at the data sending end, and during the data transmission process, after each routing node receives the transmission data, the verification data in each data packet is verified. When the verification data of all data packets are verified, the transmission data is forwarded to the next routing node until the transmission data is transmitted to the data receiving end. When the number of data packets of the transmission data increases further, this type of data transmission method needs to perform security checks on each data packet at each routing node, which further increases the inspection time overhead at each routing node and increases the data transmission delay of the transmission data.
[0076] In order to reduce data transmission delay while ensuring data transmission security, the embodiment of the present application uses the extraction verification probability determined by the data throughput of the routing node to perform data verification on a selected portion of the transmission data packets in the transmission data after the routing node receives the transmission data. In combination with the fact that during the data transmission process, when subject to data interference, multiple transmission data packets in the transmission data usually change together, so selecting a portion of the transmission data packets for data verification can ensure reliable security inspection, thereby using the data verification results of the portion of the transmission data packets as the transmission data, and there is no need to perform data verification on all the transmission data packets in the transmission data, so as to reduce the time overhead of inspection at the routing node, thereby reducing the data transmission delay of the transmission data while ensuring the security of data transmission.
[0077] In order to better describe the data transmission method of the routing node provided by the present application, the following first describes the network system applied to the data transmission method of the routing node. Figure 1 , is a schematic diagram of the structure of a network system provided in an embodiment of the present application. Figure 1 As shown in , the network system includes a data sending end, multiple routing nodes and a data receiving end. The data sending end is used to send transmission data consisting of multiple transmission data packets, and sequentially pass through the physical layer communication link consisting of multiple routing nodes until the transmission data is transmitted to the data receiving end.
[0078] In conjunction with the above network system, the data transmission method of the routing node and related devices provided in the embodiment of the present application will be further described below. The data transmission method of the routing node provided in the embodiment of the present application can be applied to the routing node in the network system, or a controller connected to the routing node.
[0079] The data transmission method of the routing node in the embodiment of the present application will be described in detail below. Figure 2, is an optional flowchart of a data transmission method of a routing node provided in an embodiment of the present application, Figure 2 The method in the embodiment may include but is not limited to steps 201 to 203. Figure 2 The order of step 201 to step 203 is not specifically limited, and the order of steps can be adjusted or some steps can be reduced or added according to actual needs.
[0080] Step 201: Acquire transmission data and obtain the extraction verification probability of the current routing node.
[0081] The following is a detailed description of step 201.
[0082] In some embodiments, when the data transmission end sends out transmission data, and in the physical layer communication link composed of multiple routing nodes for data transmission, when any routing node in the physical layer communication link receives the transmission data, in order to ensure the security and reliability of the data transmission process, the routing node will perform data verification on the transmission data packets in the transmission data. When the number of transmission data packets of the transmission data is further increased, the verification time overhead of the data verification will inevitably increase, resulting in a further increase in the transmission delay of the transmission data. Therefore, in order to reduce the transmission delay of the transmission data, the extraction verification probability of the current routing node will be obtained, so as to facilitate the subsequent use of the extraction verification probability to extract the target verification data packet actually used for data verification from multiple transmission data packets, so as to reduce the verification time overhead of the data verification, thereby reducing the data transmission delay of the transmission data; and combined with the fact that in the data transmission process, when the transmission data is subject to data interference, multiple transmission data packets in the transmission data usually change together, so selecting part of the transmission data packets for data verification can ensure reliable security verification.
[0083] The extraction verification probability of the current routing node is determined based on the data throughput of the routing nodes in the network system. It is understandable that the data throughput may refer to the statistical average throughput of all routing nodes in the network system, or may refer to the real-time data throughput of the current routing node itself.
[0084] In some embodiments, when the data throughput is the statistical average throughput of all routing nodes in the network system, the extraction verification probability of the current routing node can be uniformly pre-set by all routing nodes. The specific implementation is as follows. Pre-set multiple throughput thresholds, and the preset extraction verification probability corresponding to each throughput threshold. For example, the throughput threshold is set to be divided into three levels: low throughput (less than 100M), medium throughput (greater than 100M and less than 1G), and high throughput (greater than 1G). The corresponding verification probabilities are P, P, and P, respectively. L =0.5,PM =0.25,P H =0.1. Then, the statistical average throughput is matched with the throughput threshold, and the preset extraction verification probability corresponding to the throughput threshold matching the statistical average throughput is used as the extraction verification probability of the actual application.
[0085] In addition, when the data throughput is the real-time data throughput of the current routing node itself, each routing node has its own independent adaptive real-time adjustable extraction verification probability, and the extraction verification probability is determined in real time according to the data throughput of the current routing node itself at that moment when the routing node receives the transmission data. How to determine the data throughput in real time will be further described below.
[0086] Reference Figure 3 , obtaining the extraction verification probability of the current routing node, including the following steps 301 to 302.
[0087] Step 301: Obtain the data throughput of the current routing node, and obtain the verification proportional coefficient and the verification scaling factor.
[0088] The following is a detailed description of step 301.
[0089] In some embodiments, after receiving the transmission data in the transmission process, the data throughput T of the current routing node is first obtained, as well as the verification proportional coefficient k and the verification scaling factor α, so as to calculate the real-time extraction verification probability of the current routing node using the data throughput T, the verification proportional coefficient k and the verification scaling factor α. How to obtain the verification proportional coefficient and the verification scaling factor will be further described below.
[0090] Reference Figure 4 , obtaining the verification scale coefficient and the verification scaling factor, including the following steps 401 to 403.
[0091] Step 401: Acquire a plurality of preset proportional coefficients and a first throughput threshold corresponding to each preset proportional coefficient, and acquire a plurality of preset scaling factors and a second throughput threshold corresponding to each preset scaling factor.
[0092] Step 402: Select a first throughput threshold matching the data throughput from a plurality of first throughput thresholds as a target first throughput threshold, and use a preset proportional coefficient corresponding to the target first throughput threshold as a verification proportional coefficient.
[0093] Step 403: Select a second throughput threshold matching the data throughput from the multiple second throughput thresholds as the target second throughput threshold, and use a preset scaling factor corresponding to the target second throughput threshold as the verification scaling factor.
[0094] Steps 401 to 403 are described in detail below.
[0095] In some embodiments, similar to the above-mentioned use of multiple throughput thresholds and preset extraction verification probabilities to determine the extraction verification probability corresponding to the statistical average throughput, first obtain multiple preset proportional coefficients and a first throughput threshold corresponding to each preset proportional coefficient, and obtain multiple preset scaling factors and a second throughput threshold corresponding to each preset scaling factor. For example, if the first throughput threshold is set to be divided into three levels: a first low throughput (less than 100M), a first medium throughput (greater than 100M and less than 1G), and a first high throughput (greater than 1G), the corresponding preset proportional coefficients are k, respectively. L =100,k M =300,k H =500, and if the second throughput threshold is set to be divided into three levels: the second low throughput (less than 100M), the second medium throughput (greater than 100M and less than 1G), and the second high throughput (greater than 1G), the corresponding preset scaling factors are α L =0.2,α M =0.15,α H =0.1.
[0096] Then, a first throughput threshold matching the data throughput is selected from multiple first throughput thresholds as the target first throughput threshold, and the preset proportional coefficient corresponding to the target first throughput threshold is used as the verification proportional coefficient k in the actual application; and, a second throughput threshold matching the data throughput is selected from multiple second throughput thresholds as the target second throughput threshold, and the preset scaling factor corresponding to the target second throughput threshold is used as the verification scaling factor α in the actual application.
[0097] Through the above steps 401 to 403, the data throughput of the current routing node that changes in real time is matched with multiple first throughput thresholds and second throughput thresholds to determine a verification proportion coefficient and a verification scaling factor that are more suitable for the data throughput. This facilitates the subsequent use of the verification proportion coefficient and the verification scaling factor to calculate the extraction verification probability, thereby further improving the correlation between the extraction verification probability and the data throughput, so as to obtain a more appropriate extraction verification probability, thereby effectively ensuring the security of the transmitted data during the transmission process while reducing the transmission delay.
[0098] Step 302: Generate an extracted verification probability based on the verification scaling factor, the verification proportional coefficient, and the data throughput.
[0099] Step 302 is described in detail below.
[0100] In some embodiments, after obtaining the data throughput T, and the verification scaling factor α and the verification proportional coefficient k that match the data throughput T, an extraction verification probability will be generated based on the verification scaling factor α, the verification proportional coefficient k and the data throughput T. How to generate the extraction verification probability will be further described below.
[0101] Reference Figure 5 , generating an extracted verification probability based on the verification scaling factor, the verification proportional coefficient and the data throughput, including the following steps 501 to 503.
[0102] Step 501: Obtain minimum verification parameters and baseline verification parameters.
[0103] Step 502: Based on the product of the verification scaling factor and the data throughput, and adding the minimum verification parameter, the scaled data volume is obtained.
[0104] Step 503: Based on the ratio of the verification scale factor and the scaled data volume, and adding the baseline verification parameter, the extraction verification probability is obtained.
[0105] Steps 501 to 503 are described in detail below.
[0106] In some embodiments, the minimum verification parameter a for adjusting the extraction verification probability corresponding to the data throughput and the baseline verification parameter b for ensuring the minimum verification probability are first obtained. Next, based on the product of the verification scaling factor α and the data throughput T and adding the minimum verification parameter a, the scaled data volume αT+a is obtained.
[0107] Then, based on the ratio of the verification ratio coefficient k and the scaled data volume, and adding the baseline verification parameter b, the extraction verification probability P is obtained. V As shown in the following formula (1).
[0108]
[0109] From formula (1), we can see that the proportional coefficient k is used to adjust the extraction verification probability P V The verification scaling factor α is used to adjust the data throughput T to adjust the extraction verification probability P V to adapt to the changes in different data throughputs; the minimum verification parameter a is used to prevent the denominator in formula (1) from being zero, and to adjust the extraction verification probability at extremely low data throughputs; the baseline verification parameter b is used to ensure a minimum extraction verification probability at extremely high data throughputs, to ensure the basic requirements of data security detection of transmitted data.
[0110] In order to determine the feasibility of parameters k, α, a, b, it is necessary to conduct experiments and adjustments based on the network environment of the actual network system. By observing the security and performance indicators of the network system at different data throughput levels, the expected security performance balance can be achieved. The extraction verification probability P is calculated based on the following formula (2): V The corresponding maximum threshold value N for the sum of data packets max And the minimum threshold N min .
[0111]
[0112] N max That is, how many transmission data packets are inserted into the verification mark during this transmission process, N min Indicates the minimum number of transmission packets to be selected for verification tag insertion. Inserting too many packets with tags will lead to performance degradation, while too few may make it impossible to ensure the security of the entire link.
[0113] Through the above steps 301 to 302 and 501 to 503, the real-time data throughput of the current routing node, the verification scaling factor matching the data throughput, the verification proportional coefficient, the minimum verification parameters and the baseline verification parameters are used to calculate the extraction verification probability matching the data throughput, so as to facilitate the subsequent use of the extraction verification probability to select the target verification data packet from multiple transmission data packets for data verification, thereby effectively ensuring the security of the transmission data during the transmission process while reducing the transmission delay.
[0114] Step 202: Select a target verification data packet from multiple transmission data packets based on the extracted verification probability.
[0115] Step 202 is described in detail below.
[0116] In some embodiments, after obtaining the extraction verification probability P of the current routing node V Afterwards, based on the extraction verification probability P V A target verification data packet is selected from a plurality of transmission data packets in the transmission data, so that the routing node can subsequently perform data verification on these target verification data packets.
[0117] Reference Figure 6 , is a schematic diagram of selecting a target verification data packet provided by an embodiment of the present application. Figure 6 As shown in FIG. 1 , the transmission data includes four transmission data packets (such as Figure 6 The transmission data packet 1, transmission data packet 2, transmission data packet 3 and transmission data packet 4 in the example are taken as examples. V=0.5, a target verification data packet that matches the extraction verification probability is randomly selected from the four transmission data packets for data verification, and after random extraction, transmission data packet 2 and transmission data packet 3 are selected as the target verification data packets.
[0118] Step 203: Obtain the path verification data in the target verification data packet, perform data verification based on the path verification data, obtain a data verification result of the transmission data, and transmit the transmission data to the next routing node based on the data verification result.
[0119] Step 203 is described in detail below.
[0120] In some embodiments, after determining a target verification data packet for data verification, the path verification data in the target verification data packet is first obtained, so as to facilitate subsequent routing nodes to perform data verification based on the path verification data.
[0121] Reference Figure 7 , is a schematic diagram of the structure of the transmission data packet provided in the embodiment of the present application. Figure 7 As shown in FIG, the transmission data packet of the transmission data includes multiple data segments, which include a basic IP protocol packet header (i.e., the starting frame header Ethernet Header, Ethernet frame header Ipv4 Header) and multiple verification data segments (i.e., PAC i ) and data frames; wherein the path verification data is stored in the verification data segment. The serial number of each verification data segment corresponds to the serial number of the routing node in the physical layer communication link, and each verification data segment includes the switch (routing node) number Switch ID, the timestamp Timestamp, and the path verification code PMAC, the lengths of which are 8 bits, 32 bits, and 32 bits respectively, wherein the Switch ID is mainly used for abnormal location and PMAC calculation; the timestamp field is used for PMAC calculation, and PMAC is the path verification code obtained after calculation. Among them, the inspection information includes the switch number and the timestamp, and the verification code is the path verification code.
[0122] Based on the structural diagram of the transmission data packet, the following first further describes how to obtain the path verification data in the target verification data packet.
[0123] Reference Figure 8 , obtaining the path verification data in the target verification data packet, including the following steps 801 to 802.
[0124] Step 801: Determine the predecessor node number of the previous routing node.
[0125] Step 802: Select a data segment whose data segment sequence number corresponds to the previous node sequence number from among multiple data segments in the target verification data packet as the target data segment, and obtain path verification data from the target data segment.
[0126] Steps 801 to 802 are described in detail below.
[0127] In some embodiments, after determining the target verification data packet, first determine the predecessor node sequence number of the previous routing node of the current routing node in the physical layer communication link, and then select the data segment whose data segment sequence number corresponds to the predecessor node sequence number from the multiple data segments in the target verification data packet as the target data segment, and then obtain path verification data from the target data segment, so as to use the path verification data for subsequent data verification.
[0128] Reference Fig. 9 , performing data verification based on the path verification data to obtain a data verification result of the transmission data, including the following steps 901 to 902.
[0129] Step 901: Obtain the symmetric key between the routing node and the previous routing node, perform hash verification calculation on the verification information based on the symmetric key, and obtain a verification code.
[0130] Step 901 is described in detail below.
[0131] In some embodiments, the controller in the network system generates a key pair for each managed switch (i.e., routing node) and negotiates the key with the switch through a secure southbound channel. Each switch will obtain the symmetric key of the switch directly connected to it, that is, for the current routing node, the symmetric key includes the symmetric key between the current routing node and the previous routing node, and the symmetric key between the current routing node and the next routing node.
[0132] Considering the data security, timeliness of key update and the characteristics of key pair mapping table, the non-relational memory database Redis is used as the backend database for key storage. The names of the table items stored in Redis include switch number, key pair, issuance time, validity period and status information. The switch number is specified by the controller, and the key pair is the key pair of the adjacent switch that each switch needs to retain. And the issuance time and validity period of each key pair, as well as the current key status.
[0133] Therefore, when performing data verification based on the path verification data set, it is necessary to first obtain the symmetric key between the current routing node and the previous routing node, and then perform hash verification calculation on the verification information based on the symmetric key to obtain the verification code. The following will further describe the process of performing hash verification calculation on the verification information based on the symmetric key.
[0134] Reference Fig.10 , performing hash verification calculation on the verification information based on the symmetric key to obtain a verification code, including the following steps 1001 to 1002.
[0135] Step 1001: Obtain the number of parallel executions of the verification processing pipeline and the amount of verification data of the verification information, and obtain the pipeline processing rounds of the verification processing pipeline based on the amount of verification data and the number of parallel executions.
[0136] Step 1001 is described in detail below.
[0137] In some embodiments, the SipHash algorithm is used to perform hash verification calculations on the verification information. During the SipHash algorithm processing, the verification information needs to be compressed and mixed multiple times in the verification processing pipeline, and then the compressed and mixed verification information is hashed to obtain a verification code.
[0138] In order to further improve the accuracy of hash calculations and to improve the security and reliability of data verification, it is necessary to obtain appropriate pipeline processing rounds based on relevant parameters of the verification processing pipeline (including the number of parallel executions of the verification processing pipeline) in order to perform compressed and mixed processing on the verification information pipeline processing rounds.
[0139] The SipHash algorithm is further described below. The SipHash algorithm is implemented by dividing it into k×4 stages for SipRounds calculation, and an additional s stage for initialization and termination of the algorithm. In a given S-stage total verification pipeline length, each pass of the verification pipeline executes k SipRounds, where k is calculated by the following formula (3):
[0140] k=(Ss) / 4 (3)
[0141] Considering an input string of M bytes of verification information, the number of passes n required for the verification processing pipeline is calculated using the following formula (4).
[0142] n=(M / 4×2+d) / k (4)
[0143] In a specific implementation, each verification processing pipeline transfer executes k=2 SipRounds (i.e., parallel execution parameters). For example, for an input string of M=16 bytes, combined with the recommended security parameters (including compression parameter c=2 and mixing rounds d=4), a total of n times (i.e., compression processing rounds) of pipeline transfers are required to complete all 12 compressions and the final SipRounds, and an example value of n is n=(16 / 4×2+4) / 2=6.
[0144] It is worth noting that since the pipeline transfer of a single verification processing pipeline cannot complete all the SipRounds required by the SipHash algorithm (for a 16-byte input, 6 pipeline transfers are required), this embodiment uses the packet recirculation feature of the programmable switch. This feature enables the data packet to be sent to a special recirculation port, so that the data packet re-enters the starting position of the inlet pipeline. Before the data packet is recirculated, we will add a special metadata header to the data packet to store the internal state and the current round number, and retain the original output port information to ensure that the data packet can be correctly routed to the target port after completing the HalfSipHash calculation. In addition, we implement high-level logical control of each recirculation, as well as the execution of the correct number of compression and finalization SipRounds by defining a match-action table with exact matching rules.
[0145] In order to further improve the processing efficiency of the data verification process, the present application optimizes the SipHash algorithm, specifically processing the verification information at the pipeline inlet and pipeline outlet of the verification processing pipeline together, thereby optimizing the number of parallel executions. Therefore, the following will further describe how to obtain the number of parallel executions of the verification processing pipeline.
[0146] Reference Fig.11 , obtaining the number of parallel executions of the verification processing pipeline, including the following steps 1101 to 1102.
[0147] Step 1101: Obtain the parallel execution parameters of the verification processing pipeline, and obtain the pipeline parallel processing number based on the pipeline inlet and pipeline outlet of the verification processing pipeline.
[0148] Step 1102: Based on the product of the parallel execution parameter and the pipeline parallel processing number, the parallel execution number is obtained.
[0149] Steps 1101 to 1102 are described in detail below.
[0150] In some embodiments, a parallel execution parameter u of the verification processing pipeline is obtained, that is, the number of times the compression mixing operation can be performed when passing through a verification processing pipeline, and then the pipeline parallel processing number (that is, 2) is obtained based on the pipeline inlet and pipeline outlet of the verification processing pipeline. Next, based on the product of the parallel execution parameter and the pipeline parallel processing number, the parallel execution number g=2u is obtained.
[0151] Through the above steps 1101 to 1102, the verification data is compressed and mixed by utilizing the pipeline inlet and pipeline outlet of the verification processing pipeline, thereby effectively reducing the processing rounds that require mixed compression operations, thereby effectively reducing the processing time of data verification.
[0152] In some embodiments, after obtaining the parallel execution number of the optimized verification processing pipeline, based on the verification data volume M of the verification information that needs to be compressed and mixed processed and the parallel execution number g, the pipeline processing rounds that need to be compressed and mixed processed in the verification processing pipeline can be further obtained. The following will further describe how to obtain the pipeline processing rounds.
[0153] Reference Fig.12 , based on the verification data volume and the number of parallel executions, the pipeline processing rounds of the verification processing pipeline are obtained, including the following steps 1201 to 1203.
[0154] Step 1201: Obtain the mixing rounds, compression parameters and number of parallel stages of the hash algorithm.
[0155] Step 1202: Based on the ratio of the hybrid round and the number of parallel executions, obtain the hybrid processing round.
[0156] Step 1203: Based on the ratio of the verification data volume and the number of parallel stages, multiply by the compression parameter to obtain the compression round, and based on the ratio of the compression round and the number of parallel executions, obtain the compression processing round.
[0157] Steps 1201 to 1203 are described in detail below.
[0158] In some embodiments, the pipeline processing round includes a compression processing round and a hybrid processing round. First, the hybrid round d, the compression parameter c, and the number of parallel stages (i.e., 4) of the hash algorithm (i.e., SipHash algorithm) are determined. Next, based on the ratio of the hybrid round d and the number of parallel executions g, the hybrid processing round d / g is obtained.
[0159] Then, based on the ratio of the verification data volume M to the number of parallel stages M / 4, multiplied by the compression parameter, the compression round cM / 4 is obtained, and based on the ratio of the compression round cM / 4 to the number of parallel executions g, the compression processing round cM / 4g is obtained.
[0160] Step 1002: Based on the pipeline processing round, perform hash verification calculation on the verification information and the symmetric key to obtain a verification code.
[0161] 1002 is described in detail below.
[0162] In some embodiments, after determining the pipeline processing round, the optimized verification processing pipeline is used to perform hash verification calculation on the verification information and the symmetric key to obtain a verification code. The following further describes how to use the optimized verification processing pipeline to perform hash verification calculation on the verification information and the symmetric key to obtain a verification code.
[0163] Reference Fig.13, based on the pipeline processing rounds, hash verification calculation is performed on the verification information and the symmetric key to obtain a verification code, including the following steps 1301 to 1304.
[0164] Step 1301: Obtain a target hash function of a hash algorithm, and obtain an input string based on verification information and a symmetric key.
[0165] Step 1302: compress the input string at the pipeline entrance to obtain a first compressed string, compress the first compressed string at the pipeline exit to obtain a second compressed string, and use the second compressed string as the input string for the next round of compression processing until the compression processing round reaches the compression processing round, and use the compressed input string as the mixed string.
[0166] Step 1303: Perform mixing processing on the mixed string at the pipeline entrance to obtain a first mixed string, perform mixing processing on the first mixed string at the pipeline exit to obtain a second mixed string, and use the second mixed string as the mixed string for the next round of mixing processing until the mixing processing round reaches the mixing processing round, and use the input string after the mixing processing as the output string.
[0167] Step 1304: Calculate the hash value of the output string based on the target hash function to obtain a verification code.
[0168] Steps 1301 to 1304 are described in detail below.
[0169] In some embodiments, a target hash function of a hash algorithm (ie, SipHash algorithm) is first obtained for actually performing hash calculation, and it is understandable that the target hash function can be any one of the commonly used hash functions. Then, an input string is obtained based on the verification information and the symmetric key.
[0170] Afterwards, the input string is first compressed at the compression mixing pipeline, which specifically includes compressing the input string at the pipeline entrance to obtain a first compressed string, compressing the first compressed string at the pipeline exit to obtain a second compressed string, and using the second compressed string as the input string for the next round of compression processing, until the compression processing round reaches the compression processing round, and using the compressed input string as the mixed string.
[0171] After compression processing of the input string is performed at the compression mixing pipeline to obtain a mixed string, mixing processing of the mixed string is performed at the compression mixing pipeline, which specifically includes performing mixing processing on the mixed string at the pipeline entrance to obtain a first mixed string, performing mixing processing on the first mixed string at the pipeline exit to obtain a second mixed string, and using the second mixed string as the mixed string for the next round of mixing processing, until the processing round of mixing processing reaches the mixing processing round, and using the input string after mixing processing as the output string.
[0172] Through multiple rounds of mixed compression processing, it is possible to ensure that the verification information and the symmetric key are fully mixed, and then the hash value of the output string is calculated based on the target hash function to obtain the verification code, such as calculating the final hash value as the verification code from the values of the four registers through a specific combination operation (such as XOR). In addition, according to the requirements of the application scenario, the hash value can be truncated to adapt to the specific bit width requirements.
[0173] Through the above steps 1101 to 1120, 1201 to 1203, and 1301 to 1304, the verification data is compressed and mixed by utilizing the pipeline inlet and pipeline outlet of the verification processing pipeline to reduce the time cost of the compression and mixing operation, thereby optimizing the SipHash algorithm to obtain the HalfSipHash algorithm, and in the process of compressing and mixing the verification data using the HalfSipHash algorithm, the verification information and the symmetric key are fully mixed, and the fully mixed output string is used for hash calculation to improve the accuracy of the verification code, thereby effectively reducing the processing time of data verification while ensuring the security of data verification.
[0174] Step 902: Match the verification code and the validation code, and obtain a data validation result based on the matching result.
[0175] Step 902 is described in detail below.
[0176] In some embodiments, after obtaining the verification code, the verification code and the verification code are matched, and the matching result is used as the data packet verification result of the target verification data packet; then based on the data packet verification results of all target verification data packets, the data verification result of the transmission data is obtained.
[0177] Next, when the data verification result indicates that the check code and the verification code in the data packet verification result of all target verification data packets match, it means that the transmission data is safe and reliable during the transmission from the data sending end to the current routing node. At this time, based on the safe and reliable data verification result, the transmission data is transmitted to the next routing node of the physical layer communication link, and the data security verification is performed at the next routing node. In addition, combined with Figure 7 The transmission data packet shown, in order to further improve the security and reliability of the data transmission process, needs to update the transmission data according to the data verification result after obtaining the data verification result, and then send the updated transmission data to the next routing node, which will be further described in detail below.
[0178] Reference Fig.14 , transmitting the transmission data to the next routing node based on the data verification result, including the following steps 1401 to 1403.
[0179] Step 1401: Determine the current node sequence number of the current routing node.
[0180] Step 1402: The data segments in all transmission data packets whose data segment numbers correspond to the current node number are used as updated data segments.
[0181] Step 1403: Add the data verification result to the update data segment, and transmit the updated transmission data to the next routing node.
[0182] Steps 1401 to 1403 are described in detail below.
[0183] In some embodiments, in addition to obtaining the data verification result of the transmission data, it is also necessary to determine the current node sequence number of the current routing node, and then use the data segment sequence number corresponding to the current node sequence number in all transmission data packets in the transmission data as the updated data segment, and then add the data verification result to the updated data segment in all transmission data packets, and transmit the updated transmission data to the next routing node. This makes it easier for the next routing node to obtain the path verification data using the current node sequence number after receiving the transmission data, and perform data verification based on the path verification data, thereby improving the security and reliability of the data transmission process.
[0184] Reference Fig.15 , is a schematic diagram of a control device for transmitting data provided in an embodiment of the present application. Fig.15 As shown, on the control device, it is for Figure 1The control implemented in the data transmission process of the network system shown in the figure includes that after the data sending end sends the transmission data to the data receiving end, the policy execution module first determines the physical layer communication link (including multiple routing nodes) between the data sending end and the data receiving end according to the matching forwarding rule, and performs traffic information statistics in real time; and uses the key management module to generate a key pair for every two adjacent routing nodes, and sends the key pair to the corresponding routing node and updates it; next, in the transmission process of the transmission data, when any routing node receives the transmission data, the extraction verification probability is calculated according to the identification probability calculation module and the path information collection module, and the target verification data packet is selected according to the extraction verification probability, and the target verification data packet is data verified to obtain the data verification result of the routing node; when the data verification result representation of a routing node is incorrect, the abnormal node (such as Fig.15 The abnormal node is skipped and the updated forwarding rules are implemented, thereby providing a safe, reliable and efficient transmission channel for data transmission.
[0185] The data transmission method and related device of the routing node proposed in the embodiment of the present application, multiple routing nodes are connected in sequence, and the method includes: first, obtaining transmission data, obtaining the data throughput of the current routing node, and obtaining multiple preset proportional coefficients and a first throughput threshold corresponding to each preset proportional coefficient, and obtaining multiple preset scaling factors and a second throughput threshold corresponding to each preset scaling factor, selecting a preset proportional coefficient corresponding to the first throughput threshold matching the data throughput from the multiple preset proportional coefficients as a verification proportional coefficient, selecting a preset scaling factor corresponding to the second throughput threshold matching the data throughput from the multiple preset scaling factors as a verification scaling factor, obtaining a minimum verification parameter and a baseline verification parameter, obtaining a scaled data volume based on the product of the verification scaling factor and the data throughput, and adding the minimum verification parameter, and obtaining an extraction verification probability based on the ratio of the verification proportional coefficient to the scaled data volume and adding the baseline verification parameter; then, selecting a target verification data packet from multiple transmission data packets based on the extraction verification probability;Finally, determine the predecessor node sequence number of the previous routing node, select the data segment corresponding to the data segment sequence number and the predecessor node sequence number from multiple data segments in the target verification data packet as the target data segment, obtain the path verification data from the target data segment, and obtain the symmetric key between the routing node and the previous routing node, obtain the parallel execution parameter of the verification processing pipeline, obtain the pipeline parallel processing number based on the pipeline inlet and pipeline outlet of the verification processing pipeline, obtain the parallel execution number based on the product of the parallel execution parameter and the pipeline parallel processing number, obtain the verification data volume of the verification information, obtain the mixing round, compression parameter and parallel stage number of the hash algorithm, obtain the mixing round based on the ratio of the mixing round and the parallel execution number, multiply the compression round based on the ratio of the verification data volume and the parallel stage number by the compression parameter, and obtain the compression processing round based on the ratio of the compression round and the parallel execution number. The verification processing pipeline is used to compress and mix the verification information, obtain the target hash function of the hash algorithm, and obtain the compression round based on the verification information and the symmetric key. The key obtains an input string, compresses the input string at the pipeline entrance to obtain a first compressed string, compresses the first compressed string at the pipeline exit to obtain a second compressed string, uses the second compressed string as the input string for the next round of compression processing, until the compression processing round reaches the compression processing round, uses the compressed input string as a mixed string, mixes the mixed string at the pipeline entrance to obtain a first mixed string, mixes the first mixed string at the pipeline exit to obtain a second mixed string, uses the second mixed string as the mixed string for the next round of mixing processing, until the mixing processing round reaches the mixing processing round, uses the mixed input string as the output string, calculates the hash value of the output string based on the target hash function, obtains a check code, matches the check code and the check code, obtains a data verification result according to the matching result, and transmits the transmission data to the next routing node based on the data verification result. ;
[0186] In the embodiment of the present application, after a routing node receives transmission data, the real-time data throughput of the current routing node, the verification scaling factor and verification ratio coefficient that match the data throughput, as well as the minimum verification parameters and the baseline verification parameters are used to calculate an extraction verification probability that matches the data throughput, so as to facilitate the subsequent use of the extraction verification probability to select a target verification data packet from multiple transmission data packets for data verification. In combination with the fact that during the data transmission process, when data interference occurs, multiple transmission data packets in the transmission data usually change together, so selecting part of the transmission data packets for data verification can ensure reliable security verification, thereby using the data verification results of the part of the transmission data packets as the transmission data, and there is no need to perform data verification on all the transmission data packets in the transmission data, so as to reduce the time overhead of verification at the routing node, thereby reducing the data transmission delay of the transmission data while ensuring the security of data transmission; at the same time, by The data throughput of the routing node is matched with a plurality of first throughput thresholds and a second throughput threshold, so as to determine a verification ratio coefficient and a verification scaling factor that are more suitable for the data throughput, so as to facilitate the subsequent use of the verification ratio coefficient and the verification scaling factor to perform extraction verification probability calculation, and further improve the correlation between the extraction verification probability and the data throughput; then, the verification data is compressed and mixed by using the pipeline inlet and the pipeline outlet of the verification processing pipeline to reduce the time cost of the compression and mixing operation, so as to optimize the SipHash algorithm to obtain the HalfSipHash algorithm, and in the process of compressing and mixing the verification data by using the HalfSipHash algorithm, the verification information and the symmetric key are fully mixed, so as to perform hash calculation using the fully mixed output string, so as to improve the accuracy of the verification code, thereby effectively reducing the processing time of the data verification while ensuring the security of the data verification.
[0187] The embodiment of the present application also provides a data transmission device of a routing node, which can implement the data transmission method of the routing node. Fig.16 , the device 1600 comprises:
[0188] An acquisition module 1610 is used to acquire transmission data and an extraction verification probability of a current routing node, wherein the transmission data includes a plurality of transmission data packets, and the extraction verification probability is determined based on a data throughput of the routing node;
[0189] An extraction module 1620, configured to select a target verification data packet from a plurality of transmission data packets based on an extraction verification probability;
[0190] The verification processing module 1630 is used to obtain the path verification data in the target verification data packet, and perform data verification based on the path verification data to obtain the data verification result of the transmission data, and transmit the transmission data to the next routing node based on the data verification result.
[0191] In some embodiments, the acquisition module 1610 is further configured to:
[0192] Obtain the data throughput of the current routing node, as well as the verification ratio coefficient and verification scaling factor;
[0193] The extracted verification probability is generated based on the verification scaling factor, the verification proportional coefficient, and the data throughput.
[0194] In some embodiments, the acquisition module 1610 is further configured to:
[0195] Acquire a plurality of preset proportional coefficients and a first throughput threshold corresponding to each preset proportional coefficient, and acquire a plurality of preset scaling factors and a second throughput threshold corresponding to each preset scaling factor;
[0196] Selecting a preset proportionality coefficient corresponding to a first throughput threshold matching the data throughput from a plurality of preset proportionality coefficients as a verification proportionality coefficient;
[0197] A preset scaling factor corresponding to a second throughput threshold matching the data throughput is selected from a plurality of preset scaling factors as a verification scaling factor.
[0198] In some embodiments, the acquisition module 1610 is further configured to:
[0199] Obtain minimum verification parameters and baseline verification parameters;
[0200] Based on the product of the verification scaling factor and the data throughput, and adding the minimum verification parameter, the scaled data volume is obtained;
[0201] Based on the ratio of the verification scale factor and the amount of scaled data, and adding the baseline verification parameters, the extraction verification probability is obtained.
[0202] In some embodiments, the verification processing module 1630 is further configured to:
[0203] Obtain the symmetric key between the routing node and the previous routing node, perform hash verification calculation on the verification information based on the symmetric key, and obtain a verification code;
[0204] The verification code and the validation code are matched, and a data validation result is obtained based on the matching result.
[0205] In some embodiments, the verification processing module 1630 is further configured to:
[0206] The number of parallel executions of the verification processing pipeline and the amount of verification data of the verification information are obtained, and based on the amount of verification data and the number of parallel executions, the pipeline processing rounds of the verification processing pipeline are obtained, and the verification processing pipeline is used to perform compression and mixing processing on the verification information;
[0207] Based on the pipeline processing rounds, hash verification calculation is performed on the verification information and the symmetric key to obtain a verification code.
[0208] In some embodiments, the verification processing module 1630 is further configured to:
[0209] Obtaining a parallel execution parameter of the verification processing pipeline, and obtaining a pipeline parallel processing number based on a pipeline inlet and a pipeline outlet of the verification processing pipeline;
[0210] The parallel execution number is obtained based on the product of the parallel execution parameter and the pipeline parallel processing number.
[0211] In some embodiments, the verification processing module 1630 is further configured to:
[0212] Get the mixing rounds, compression parameters, and number of parallel stages of the hash algorithm;
[0213] Based on the ratio of the hybrid rounds and the number of parallel executions, the hybrid processing rounds are obtained;
[0214] Based on the ratio of the verification data volume and the number of parallel stages, the compression round is obtained by multiplying it by the compression parameter, and based on the ratio of the compression round and the number of parallel executions, the compression processing round is obtained.
[0215] In some embodiments, the verification processing module 1630 is further configured to:
[0216] Obtain a target hash function of the hash algorithm, and obtain an input string based on the verification information and the symmetric key;
[0217] The input string is compressed at the pipeline entrance to obtain a first compressed string, the first compressed string is compressed at the pipeline exit to obtain a second compressed string, the second compressed string is used as the input string for the next round of compression processing, until the compression processing round reaches the compression processing round, and the input string after the compression processing is used as the mixed string;
[0218] Performing a mixing process on the mixed character string at the pipeline entrance to obtain a first mixed character string, performing a mixing process on the first mixed character string at the pipeline exit to obtain a second mixed character string, and using the second mixed character string as the mixed character string for the next round of mixing process, until the processing round of the mixing process reaches the mixing processing round, and using the input character string after the mixing process as the output character string;
[0219] The hash value of the output string is calculated based on the target hash function to obtain the check code.
[0220] In some embodiments, the verification processing module 1630 is further configured to:
[0221] Determine the node number preceding the previous routing node;
[0222] From multiple data segments in the target verification data packet, a data segment whose data segment sequence number corresponds to the previous node sequence number is selected as the target data segment, and path verification data is obtained from the target data segment.
[0223] In some embodiments, the verification processing module 1630 is further configured to:
[0224] Determine the current node sequence number of the current routing node;
[0225] The data segment whose data segment sequence number corresponds to the current node sequence number in all transmission data packets is used as the update data segment;
[0226] The data verification result is added to the update data segment, and the updated transmission data is transmitted to the next routing node.
[0227] In the above embodiments, the description of each embodiment has its own emphasis. For the part that is not described in detail in a certain embodiment, the specific implementation method of the data transmission device of the routing node is basically the same as the specific implementation method of the data transmission method of the routing node, and will not be repeated here.
[0228] In an embodiment of the present application, after the routing node receives the transmission data, the data transmission device of the routing node uses the real-time data throughput of the current routing node, the verification scaling factor matching the data throughput, the verification proportional coefficient, the minimum verification parameters, and the baseline verification parameters to calculate an extraction verification probability that matches the data throughput, so as to facilitate the subsequent use of the extraction verification probability to select a target verification data packet from multiple transmission data packets for data verification, and combined with the fact that in the data transmission process, when subject to data interference, multiple transmission data packets in the transmission data usually change together, so selecting part of the transmission data packets for data verification can ensure reliable security verification, thereby using the data verification results of the part of the transmission data packets as the transmission data, and there is no need to perform data verification on all the transmission data packets in the transmission data, so as to reduce the time overhead of verification at the routing node, thereby reducing the data transmission delay of the transmission data while ensuring the security of data transmission; at the same time, by The data throughput of the current routing node, which changes in real time, is matched with a plurality of first throughput thresholds and a second throughput threshold, so as to determine a verification ratio coefficient and a verification scaling factor that are more suitable for the data throughput, so as to facilitate the subsequent use of the verification ratio coefficient and the verification scaling factor to perform extraction verification probability calculation, and further improve the correlation between the extraction verification probability and the data throughput; then, the verification data is compressed and mixed by using the pipeline inlet and the pipeline outlet of the verification processing pipeline to reduce the time cost of the compression and mixing operation, so as to optimize the SipHash algorithm to obtain the HalfSipHash algorithm, and in the process of compressing and mixing the verification data by using the HalfSipHash algorithm, the verification information and the symmetric key are fully mixed, so as to perform hash calculation using the fully mixed output character string, so as to improve the accuracy of the verification code, thereby effectively reducing the processing time of the data verification while ensuring the security of the data verification.
[0229] The present application also provides an electronic device, including:
[0230] at least one memory;
[0231] at least one processor;
[0232] at least one program;
[0233] The program is stored in the memory, and the processor executes the at least one program to implement the data transmission method of the routing node implemented in the present application. The electronic device can be any intelligent terminal including a mobile phone, a tablet computer, a personal digital assistant (PDA), a car computer, etc.
[0234] See also Fig.17 , Fig.17 The hardware structure of an electronic device of another embodiment is illustrated, and the electronic device includes:
[0235] The processor 1701 may be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of the present application;
[0236] The memory 1702 can be implemented in the form of ROM (Read Only Memory), static storage device, dynamic storage device or RAM (Random Access Memory). The memory 1702 can store operating systems and other applications. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 1702, and the processor 1701 calls and executes the data transmission method of the routing node in the embodiments of this application;
[0237] Input / output interface 1703, used to implement information input and output;
[0238] Communication interface 1704, used to realize communication interaction between the device and other devices, which can be realized through wired mode (such as USB, network cable, etc.) or wireless mode (such as mobile network, WIFI, Bluetooth, etc.);
[0239] A bus 1705 that transmits information between the various components of the device (e.g., the processor 1701, the memory 1702, the input / output interface 1703, and the communication interface 1704);
[0240] The processor 1701 , the memory 1702 , the input / output interface 1703 and the communication interface 1704 are connected to each other in communication within the device via the bus 1705 .
[0241] An embodiment of the present application further provides a storage medium, which is a computer-readable storage medium and stores a computer program. When the computer program is executed by a processor, the data transmission method of the routing node is implemented.
[0242] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0243] The embodiments described in the embodiments of the present application are intended to more clearly illustrate the technical solutions of the embodiments of the present application and do not constitute a limitation on the technical solutions provided in the embodiments of the present application. Those skilled in the art will appreciate that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
[0244] Those skilled in the art will appreciate that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.
[0245] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0246] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.
[0247] The terms "first", "second", "third", "fourth", etc. (if any) in the specification 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 interchangeable 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. 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 comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0248] It should be understood that in the present application, "at least one (item)" means one or more, and "plurality" means two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can mean: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the objects associated before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single 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.
[0249] In the several embodiments provided in the present application, it should be understood that the disclosed 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 above units 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. 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.
[0250] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0251] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0252] If the integrated unit 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, or the part that contributes to the prior art, or all 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 multiple instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods of various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random Access Memory, referred to as RAM), disk or optical disk and other media that can store programs.
[0253] The preferred embodiments of the present application are described above with reference to the accompanying drawings, but the scope of the rights of the present application is not limited thereto. Any modification, equivalent substitution and improvement made by a person skilled in the art without departing from the scope and essence of the present application should be within the scope of the rights of the present application.
Claims
1. A data transmission method of a routing node, characterized in that: A plurality of the routing nodes are connected in sequence, and the method comprises: Acquire transmission data and acquire an extraction verification probability of a current routing node, wherein the transmission data includes a plurality of transmission data packets, and the extraction verification probability is determined based on a data throughput of the routing node; Selecting a target verification data packet from a plurality of the transmission data packets based on the extraction verification probability; The path verification data in the target verification data packet is obtained, and data verification is performed based on the path verification data to obtain a data verification result of the transmission data, and the transmission data is transmitted to the next routing node based on the data verification result.
2. The data transmission method of the routing node according to claim 1, characterized in that: The obtaining of the extraction verification probability of the current routing node includes: Obtaining the data throughput of the current routing node, and obtaining a verification proportional coefficient and a verification scaling factor; The extracted verification probability is generated based on the verification scaling factor, the verification proportional coefficient, and the data throughput.
3. The data transmission method of the routing node according to claim 2, characterized in that: The obtaining of the verification scale coefficient and the verification scaling factor comprises: Acquire a plurality of preset proportional coefficients and a first throughput threshold corresponding to each of the preset proportional coefficients, and acquire a plurality of preset scaling factors and a second throughput threshold corresponding to each of the preset scaling factors; Selecting a first throughput threshold matching the data throughput from the plurality of first throughput thresholds as a target first throughput threshold, and using a preset proportional coefficient corresponding to the target first throughput threshold as the verification proportional coefficient; A second throughput threshold matching the data throughput is selected from the plurality of second throughput thresholds as the target second throughput threshold, and a preset scaling factor corresponding to the target second throughput threshold is used as the verification scaling factor.
4. The data transmission method of the routing node according to claim 2, characterized in that: The generating the extracted verification probability based on the verification scaling factor, the verification proportional coefficient and the data throughput comprises: Obtain minimum verification parameters and baseline verification parameters; Obtaining a scaled data volume based on a product of the verification scaling factor and the data throughput and adding the minimum verification parameter; Based on the ratio of the verification scale coefficient and the scaled data volume, and adding the baseline verification parameter, the extraction verification probability is obtained.
5. The data transmission method of the routing node according to claim 1, characterized in that: The path verification data includes verification information and a verification code, and the data verification is performed based on the path verification data to obtain a data verification result of the transmission data, including: Acquire a symmetric key between the routing node and the previous routing node, and perform a hash verification calculation on the verification information based on the symmetric key to obtain a verification code; The verification code is matched with the authentication code, and the data authentication result is obtained according to the matching result.
6. The data transmission method of the routing node according to claim 5, characterized in that: The performing hash verification calculation on the verification information based on the symmetric key to obtain a verification code includes: Obtaining the number of parallel executions of the verification processing pipeline and the verification data volume of the verification information, and obtaining the pipeline processing rounds of the verification processing pipeline based on the verification data volume and the parallel execution number, wherein the verification processing pipeline is used to perform compression and mixing processing on the verification information; Based on the pipeline processing round, a hash verification calculation is performed on the verification information and the symmetric key to obtain the verification code.
7. The data transmission method of the routing node according to claim 6, characterized in that: The obtaining of the number of parallel executions of the verification processing pipeline includes: Acquire the parallel execution parameters of the verification processing pipeline, and obtain the pipeline parallel processing number based on the pipeline inlet and pipeline outlet of the verification processing pipeline; The parallel execution number is obtained based on the product of the parallel execution parameter and the pipeline parallel processing number.
8. The data transmission method of the routing node according to claim 7, characterized in that: The pipeline processing rounds include a hybrid processing round and a compression processing round. The pipeline processing rounds of the verification processing pipeline are obtained based on the verification data volume and the parallel execution number, including: Get the mixing rounds, compression parameters, and number of parallel stages of the hash algorithm; Based on the ratio of the hybrid round and the parallel execution number, obtaining the hybrid processing round; Based on the ratio of the verification data volume to the number of parallel stages, multiplying by the compression parameter, a compression round is obtained, and based on the ratio of the compression round to the number of parallel executions, the compression processing round is obtained.
9. The data transmission method of the routing node according to claim 8, characterized in that: The step of performing hash verification calculation on the verification information and the symmetric key based on the pipeline processing round to obtain the verification code includes: Obtaining a target hash function of the hash algorithm, and obtaining an input string based on the verification information and the symmetric key; The input string is compressed at the pipeline entrance to obtain a first compressed string, the first compressed string is compressed at the pipeline exit to obtain a second compressed string, the second compressed string is used as the input string for the next round of compression processing, until the compression processing round reaches the compression processing round, and the input string after the compression processing is used as a mixed string; Performing a mixing process on the mixed character string at the entrance of the pipeline to obtain a first mixed character string, performing the mixing process on the first mixed character string at the exit of the pipeline to obtain a second mixed character string, using the second mixed character string as the mixed character string for a next round of mixing process, until the processing round of the mixing process reaches the mixing process round, and using the input character string after the mixing process as an output character string; The hash value of the output string is calculated based on the target hash function to obtain the verification code.
10. The data transmission method of a routing node according to claim 1, characterized in that: The transmission data packet includes a plurality of data segments, and the obtaining of the path verification data in the target verification data packet includes: Determine the node number preceding the previous routing node; From the multiple data segments in the target verification data packet, a data segment whose data segment sequence number corresponds to the preceding node sequence number is selected as the target data segment, and path verification data is obtained from the target data segment.
11. The data transmission method of the routing node according to claim 10, characterized in that: The transmitting the transmission data to the next routing node based on the data verification result comprises: Determine the current node sequence number of the current routing node; The data segments whose data segment sequence numbers correspond to the current node sequence number in all the transmission data packets are used as update data segments; The data verification result is added to the update data segment, and the updated transmission data is transmitted to the next routing node.
12. A data transmission device for a routing node, characterized in that: The device comprises: An acquisition module, used to acquire transmission data and an extraction verification probability of a current routing node, wherein the transmission data includes a plurality of transmission data packets, and the extraction verification probability is determined based on a data throughput of the routing node; An extraction module, used for selecting a target verification data packet from a plurality of transmission data packets based on the extraction verification probability; The verification processing module is used to obtain the path verification data in the target verification data packet, and perform data verification based on the path verification data to obtain the data verification result of the transmission data, and transmit the transmission data to the next routing node based on the data verification result.
13. An electronic device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the data transmission method of the routing node according to any one of claims 1 to 11 is implemented.
14. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the data transmission method of the routing node according to any one of claims 1 to 11 is implemented.
Citation Information
Cited By
Data transmission method and system among multiple sorting devices
CN120111081A
