Data transmission method and device, medium and electronic equipment

By adopting the UDP protocol in the data transmission component and using the blockchain network for data verification, the contradiction between data transmission delay and reliability is solved, and data transmission with low latency, high reliability and security is achieved.

CN120281528APending Publication Date: 2025-07-08LINGSHU TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510407160.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-02
Publication Date
2025-07-08

AI Technical Summary

Technical Problem

The existing data transmission protocols have latency problems when ensuring reliability. The TCP protocol has high latency, while the UDP protocol has low latency but lacks reliability, making it difficult to find a balance between low latency and reliability.

Method used

Data transmission is carried out using the User Datagram Protocol (UDP) and the file shard data is verified through blockchain nodes in the blockchain network. Using the traceability and immutability of the blockchain, the first and second verification information are generated and compared to ensure the accuracy and security of data transmission.

Benefits of technology

It realizes data transmission with low latency, while ensuring the reliability and security of data transmission, reducing the complexity of system design and implementation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120281528A_ABST
    Figure CN120281528A_ABST
Patent Text Reader

Abstract

The invention discloses a data transmission method, which comprises the following steps: in response to file fragment data received from a server of a data transmission component, generating first verification information of the file fragment data based on the file fragment data, and generating a fragment verification transaction request; the file fragment data is obtained by performing fragment processing on target file data through a server side of the data transmission component; calling a data verification contract based on the fragment verification transaction request through a block chain node in the block chain network, and determining a data verification result of the file fragment data based on the first verification information and the second verification information; the second verification information is generated by the server side of the data transmission component based on the file fragment data; determining a file transmission state of the target file data based on the data verification result; and data transmission is carried out between the client and the server of the data transmission component by adopting a user datagram protocol. According to the invention, the reliability and security of data transmission are ensured while low-delay data transmission is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the technical fields of data transmission, blockchain, and trusted computing, and particularly relates to a data transmission method, apparatus, medium, and electronic device. Background Art

[0002] In related technologies, most data transmissions use the TCP protocol (Transmission Control Protocol). Although it ensures the reliability of data transmission, due to its handshake, congestion control, and other mechanisms, it causes delays in data transmission. The UDP protocol (User Datagram Protocol) has the characteristics of being connectionless and having low latency, and the data transmission speed is relatively fast. However, due to the characteristics of UDP, packet loss, duplication, or out-of-order situations may occur, and the reliability of its data transmission is somewhat lacking. Summary of the Invention

[0003] This application provides a data transmission method, apparatus, medium, and electronic device, which can achieve the purpose of ensuring the reliability and security of data transmission while realizing low-latency data transmission.

[0004] According to the first aspect of this application, a data transmission method is provided, which is executed by the client of the data transmission component. The method includes:

[0005] In response to receiving file shard data from the server of the data transmission component, generating first verification information for the file shard data, and generating a shard verification transaction request; wherein, the file shard data is obtained by the server of the data transmission component in response to a data transmission request for target file data and performing sharding processing on the target file data;

[0006] Invoking a data verification contract by a blockchain node in the blockchain network based on the shard verification transaction request, and determining a data verification result of the file shard data based on the first verification information and second verification information; wherein, the second verification information is generated by the server of the data transmission component based on the file shard data and stored in the blockchain network;

[0007] Based on the data verification result, determining a file transmission status of the target file data; wherein, the user datagram protocol is used for data transmission between the client and the server of the data transmission component.

[0008] According to the second aspect of this application, a data transmission apparatus is provided, which is configured in the client of the data transmission component. The apparatus includes:

[0009] A verification information generation module, configured to generate first verification information of the file shard data based on the file shard data in response to receiving the file shard data from the server of the data transmission component, and generate a shard verification transaction request; wherein, the file shard data is obtained by the server of the data transmission component performing sharding processing on the target file data in response to a data transmission request for the target file data.

[0010] A verification result determination module, configured to call a data verification contract based on the shard verification transaction request through a blockchain node in the blockchain network, and determine a data verification result of the file shard data based on the first verification information and the second verification information; wherein, the second verification information is generated by the server of the data transmission component based on the file shard data and stored in the blockchain network.

[0011] A transmission status determination module, configured to determine a file transmission status of the target file data based on the data verification result; wherein, the user datagram protocol is used for data transmission between the client and the server of the data transmission component.

[0012] According to the third aspect of the present invention, an embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, it implements the data transmission method as described in the embodiment of the present application.

[0013] According to the fourth aspect of the present invention, an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements the data transmission method as described in the embodiment of the present application.

[0014] In the technical solution of the embodiment of the present application, by designing a data transmission component, the data transmission is decoupled from the service implementation, and the data transmission component focuses on data transmission, reducing the complexity of system design and the difficulty of system implementation. In the embodiment of the present application, the user datagram protocol is used for data transmission between the client and the server of the data transmission component, and the blockchain network is introduced during the data transmission process. Through the blockchain nodes in the blockchain network, the file shard data is verified based on the first verification information and the second verification information generated by the client and the server for the file shard data. During the data transmission process, the traceability and immutability of the blockchain network are fully utilized to ensure the reliability and security of data transmission while achieving low-latency data transmission.

[0015] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present application, nor is it used to limit the scope of the present application. Other features of the present application will become easily understood through the following description. Brief Description of the Drawings

[0016] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0017] Figure 1 is a flowchart of the data transmission method provided in Embodiment 1;

[0018] Figure 2A is a flowchart of the data transmission method provided in Embodiment 2;

[0019] Figure 2B is a schematic structural diagram of the data transmission system provided in the embodiments of the present application;

[0020] Figure 3 is a schematic structural diagram of the data transmission device provided in Embodiment 3 of the present application;

[0021] Figure 4 is a schematic structural diagram of an electronic device provided in Embodiment 4 of the present application. Detailed Description of the Embodiments

[0022] In order to enable those skilled in the art to better understand the solutions of the present application, the following will clearly and completely describe the technical solutions in the embodiments of the present application in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the scope of protection of the present application.

[0023] It should be noted that the terms "first", "second", "target", and "candidate" in the specification, claims, and drawings of the present application are used to distinguish similar objects, and do not necessarily need to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments of the present application described here can be implemented in an order other than those illustrated or described here. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or are inherent to these processes, methods, products, or devices.

[0024] Embodiment 1

[0025] Figure 1 It is a flowchart of the data transmission method provided in the first embodiment. This embodiment is applicable to the situation where the data requester and the data provider perform data transmission in the trusted data space. This method can be executed by a data transmission device, which is implemented in the form of hardware and / or software and can be integrated into the electronic device running this system.

[0026] As Figure 1 shown, the method includes:

[0027] S110. In response to receiving file shard data from the server of the data transmission component, generate the first check information of the file shard data based on the file shard data, and generate a shard check transaction request; wherein, the file shard data is obtained by the server of the data transmission component in response to a data transmission request for the target file data and performing sharding processing on the target file data.

[0028] S120. Invoke a data verification contract based on the shard check transaction request through a blockchain node in the blockchain network, and determine the data verification result of the file shard data based on the first check information and the second check information; wherein, the second check information is generated by the server of the data transmission component based on the file shard data and stored in the blockchain network.

[0029] S130. Based on the data verification result, determine the file transmission status of the target file data; wherein, the user datagram protocol is used for data transmission between the client and the server of the data transmission component.

[0030] Among them, the data transmission component is decoupled from the business implementation and focuses on data transmission. The client of the data transmission component belongs to the data requester, and the server of the data transmission component belongs to the data provider. The data transmission component is deployed on the trusted data space node. Among them, the user datagram protocol is used for data transmission between the client and the server of the data transmission component. It can be known that the user datagram protocol has the characteristics of low latency and simplicity and high efficiency, and is applicable to data transmission scenarios with high requirements for real-time performance.

[0031] In an alternative embodiment, the server and the client of the data transmission component are respectively configured in the trusted data space nodes of the data provider and the data requester.

[0032] Among them, a connector is set in the trusted data space node, and the connector of the trusted data space node interacts with the client of the data transmission component based on the restful interface. Among them, the restful interface is built based on the restful protocol.

[0033] A data transmission request for target file data is initiated by the client of the data transmission component to the server of the data transmission component. Among them, the data transmission request is used to request the target file data from the data provider.

[0034] In an optional embodiment, the file size of the target file data is greater than the upper limit value of the data volume supported by the User Datagram Protocol (UDP). The file size of the target file data is not limited here and is specifically determined according to business requirements. Optionally, the file size of the target file data is measured in gigabytes (G). Exemplarily, the file size of the target file data can be 5G. The technical solution provided by the embodiments of the present application is applicable to the scenario of data transmission of ultra-large files in a trusted data space.

[0035] It can be known that the User Datagram Protocol is suitable for small packet transmission. When using the User Datagram Protocol to transmit the target file data, it is necessary to fragment the target file data. The server of the data transmission component responds to the received data transmission request for the target file data, fragments the target file data, and obtains at least two file fragment data. The data volume of the file fragment data is less than or equal to the upper limit value of the data volume supported by the User Datagram Protocol. The number of file fragment data is not limited here and is specifically determined according to the file size of the target file data and the data volume of the file fragment data.

[0036] Since the data transmission between the client and the server of the data transmission component is based on the User Datagram Protocol, and the User Datagram Protocol is an unreliable transport layer communication protocol, the file fragment data received by the client may be incorrect. Therefore, it is necessary to verify the accuracy of the file fragment data.

[0037] After the server of the data transmission component splits the target file data into at least two file fragment data, it generates the second verification information for the file fragment data, and then generates a chain storage transaction request based on the second verification information and sends the chain storage transaction request to the blockchain network to store the second verification information in the blockchain network.

[0038] The server of the data transmission component transmits the file fragment data to the client of the data transmission component. The client of the data transmission component responds to the received file fragment data and generates the first verification information for the file fragment data. The client of the data transmission component generates a fragment verification transaction request based on the first verification information and sends the fragment verification transaction request to the blockchain network. Among them, the fragment verification transaction request is used to trigger the blockchain nodes in the blockchain network to call the data verification contract to verify the accuracy of the file fragment data.

[0039] Among them, the data verification contract is used to verify the accuracy of the file shard data. The blockchain nodes in the blockchain network call the data verification contract based on the shard verification transaction request, and determine the data verification result of the file shard data based on the first verification information and the second verification information. The first verification data is generated by the client of the data transmission component based on the received file shard data; the second verification data is generated by the server of the data transmission component based on the generated file shard data. Both the first verification data and the second verification data include the unique fingerprint of the file shard data. The second verification data is stored on the chain, and the second verification data is tamper-proof and reliable. By comparing the first verification data and the second verification data, the verification of the accuracy of the file shard data can be realized, and the data verification result can be obtained.

[0040] Among them, the data verification result is used to measure whether the file shard data received by the client is accurate. Each piece of file shard data received by the client has a corresponding data verification result. Based on the data verification result, the file transmission status of the target file data can be determined.

[0041] Among them, the file transmission status is used to determine whether the target file data has been transmitted. Optionally, the file transmission status includes that the transmission has not been completed and the transmission has been completed. When all the file shard data obtained by splitting the target file data are received by the client of the data transmission component, and all the file shard data received by the client pass the verification, it is determined that the file transmission status of the target file data is that the transmission has been completed. If the file transmission status is that the transmission has been completed, then the client of the data transmission component merges the files according to the file shard index of the file shard data to obtain the shard recombined file.

[0042] If there is file shard data obtained by splitting the target file data that has not been received by the client of the data transmission component, or if there is file shard data received by the client that fails the verification, it is determined that the file transmission status of the target file data is that the transmission has not been completed.

[0043] If the file transmission status is that the transmission has not been completed, it indicates that the client of the data transmission component has received a part of the accurate file shard data. At this time, the client of the data transmission component requests the data transmission component server for the remaining file shard data that has not been successfully received.

[0044] In the technical solution of the embodiment of the present application, by designing a data transmission component, the data transmission is decoupled from the service implementation. The data transmission component focuses on data transmission, reducing the complexity of system design and the difficulty of system implementation. In the embodiment of the present application, the User Datagram Protocol is used for data transmission between the client and the server of the data transmission component, and a blockchain network is introduced during the data transmission process. Through the blockchain nodes in the blockchain network, the file shard data is verified based on the first verification information and the second verification information generated by the client and the server for the file shard data. During the data transmission process, the traceability and immutability of the blockchain network are fully utilized to ensure the reliability and security of data transmission while achieving low-latency data transmission.

[0045] In an optional embodiment, generating the first verification information of the file shard data based on the file shard data includes: determining the file shard index of the file shard data based on the shard size and offset of the file shard data; calculating the shard hash value of the file shard data using a cryptographic hash function; associating the shard hash value with the file shard index to generate the first verification information of the file shard data.

[0046] Among them, the shard size of the file shard data is related to the upper limit value of the data volume supported by the User Datagram Protocol. The shard size of the file shard data is agreed upon by the server and the client of the data transmission component through a protocol.

[0047] Optionally, the server of the data transmission component compresses the file shard data obtained by splitting the target file data in the form of a byte array, and packages the file size of the target file data, the shard size and offset of the file shard data with the byte array of the file shard data and transmits it as a message to the client of the data transmission component.

[0048] After receiving the file shard data, the client of the data transmission component determines the file shard index of the file shard data based on the shard size and offset of the file shard data. Among them, the file shard index is the unique identifier of the file shard data, used to distinguish different file shard data. The client of the data transmission component calculates the shard hash value of the file shard data using a cryptographic hash function. Among them, the shard hash value is the unique fingerprint of the file shard data, used to verify the accuracy of the received file shard data. Optionally, the shard hash value of the file shard data is the MD5 value of the file shard data.

[0049] The client of the data transmission component associates the shard hash value with the file shard index to generate the first verification information of the file shard data, and stores the first verification information in the blockchain network. Based on the first verification information, it can be determined what the unique fingerprint of which file shard data is.

[0050] The process of the server of the data transmission component generating the second verification information is the same as the process of the client of the data transmission component generating the first verification information. Both are based on the shard size and offset of the file shard data to determine the file shard index of the file shard data; use a cryptographic hash function to calculate the shard hash value of the file shard data; and associate the shard hash value with the generated file shard index. The difference is that the first verification information is generated by the client for the received file shard data, and the second verification information is generated by the server for the generated file shard data.

[0051] The above technical solution provides a feasible first verification information generation scheme, which is not only applicable to the client of the data transmission component to generate the first verification information, but also applicable to the server of the data transmission component to generate the second verification information, providing technical support and data support for subsequent verification of the accuracy of the file shard data based on the first verification information and the second verification information.

[0052] In an optional embodiment, the blockchain node in the blockchain network invokes the data verification contract based on the shard verification transaction request, and determines the data verification result of the file shard data based on the first verification information and the second verification information, including: the blockchain node in the blockchain network invokes the data verification contract based on the shard verification transaction request, and extracts the file shard index and the shard hash value from the first verification information and the second verification information respectively; the blockchain node uses the data verification contract to compare the shard hash value based on the file shard index; and the blockchain node determines the data verification result of the file shard data based on the obtained shard hash value comparison result.

[0053] Among them, the data verification contract is used to verify the accuracy of the file shard data. The data verification contract is deployed in the blockchain network and is called through the shard verification transaction request. The blockchain node calls the data verification contract based on the shard verification transaction request, and extracts the file shard index and the shard hash value from the first verification information and the second verification information. The file shard indexes are matched. When the file shard indexes are successfully matched, it indicates that the shard hash values associated with the file shard indexes belong to the same file shard data. The shard hash value in the first verification information and the shard hash value in the second verification information are compared according to the file shard index to obtain the shard hash value comparison result. Among them, the shard hash value comparison result is used to determine whether an error occurs during the data transmission of the file shard data. Optionally, the shard hash value comparison result includes that the hash values are the same and the hash values are different. If no error occurs during the data transmission of the file shard data, it indicates that the file shard data received by the client is the same as the file shard data generated by the server, then the shard hash value comparison result is that the hash values are the same; otherwise, the shard hash value comparison result is that the hash values are different.

[0054] The above technical solution provides a data verification result determination solution, which is applicable to verifying the accuracy of file shard data. The accuracy verification of file shard data is completed by blockchain nodes in the blockchain network, providing technical support and data support for ensuring the reliability and security of data transmission.

[0055] In an optional embodiment, the method further includes: the server of the data transmission component generates an authorization verification transaction request based on the data transmission request received from the client of the data transmission component; the blockchain node in the blockchain network calls the data circulation contract based on the authorization verification transaction request, and performs authorization verification on the data requester based on the data transmission request; if the authorization verification result is passed, the server of the data transmission component performs sharding processing on the target file data to obtain at least two pieces of the file shard data; among them, the data circulation contract is negotiated by the data requester and the data provider through the connector in the trusted data space node and stored in the blockchain network.

[0056] After the server of the data transmission component receives the data transmission request from the client of the data transmission component, it is necessary to verify the authorization of the data requester.

[0057] Optionally, the data transmission request carries the authentication information of the data requester. The server generates an authorization verification transaction request based on the data transmission request, where the authorization verification transaction request is used to invoke the data circulation contract. The data circulation contract is negotiated by the data requester and the data provider through the connector in the trusted data space node and stored in the blockchain network. After the data circulation contract is negotiated and determined by the data requester and the data provider, the data requester notifies the client of the data transmission component through the connector in the trusted data space to send the data transmission request for the target file data to the server of the data transmission component based on the restful interface.

[0058] The server of the data transmission component receives the data transmission request for the target file data, generates an authorization verification transaction request based on the data transmission request, and sends the authorization verification transaction request to the blockchain network. The blockchain node in the blockchain network invokes the data circulation contract based on the authorization verification transaction request and performs authorization verification on the data requester based on the data transmission request to obtain an authorization verification result.

[0059] If the authorization verification result is verification passed, indicating that the data requester has the usage right for the target file data, the server of the data transmission component performs slicing processing on the target file data to obtain at least two file slice data, and transmits the file slice data to the client of the data transmission component.

[0060] In the above technical solution, before the server of the data transmission component slices the target file data and transmits the obtained file slice data, by invoking the data circulation contract negotiated by the data requester and the data provider in the blockchain network to perform authorization verification on the data requester, the security of data transmission is ensured.

[0061] Embodiment 2

[0062] Figure 2A It is a flowchart of the data transmission method provided according to Embodiment 2. This embodiment is further optimized based on the above embodiment.

[0063] As Figure 2A shown, the method includes:

[0064] S210. In response to receiving the file slice data from the server of the data transmission component, generate first verification information for the file slice data and generate a slice verification transaction request; wherein, the file slice data is obtained by the server of the data transmission component performing slicing processing on the target file data in response to a data transmission request for the target file data.

[0065] S220. Based on the shard verification transaction request, the blockchain nodes in the blockchain network call the data verification contract, and determine the data verification result of the file shard data based on the first verification information and the second verification information; wherein, the second verification information is generated by the server of the data transmission component based on the file shard data and stored in the blockchain network.

[0066] S230. Determine the shard reception status of the file shard data based on the data verification result.

[0067] Among them, the shard reception status is used to measure whether the file shard data is successfully received. The shard reception status of the file shard data is related to two aspects: whether the client of the data transmission component receives the file shard data and whether the received file shard data is accurate. Optionally, the shard reception status includes received and not received.

[0068] S240. In response to detecting a communication connection interruption, determine the file transmission status of the target file data based on the shard reception status.

[0069] When the client of the data transmission component detects a communication connection interruption between it and the server, the client of the data transmission component determines the file transmission status of the target file data based on the shard reception status. Among them, the communication connection interruption may be caused by file reception timeout or network disconnection and reconnection.

[0070] Optionally, the client of the data transmission component determines the number of file shards based on the file size of the target file data and the shard size of the file shard data. The file size of the target file data and the shard size of the file shard data can be agreed upon by the server and the client of the data transmission component through a protocol, or can be provided to the client by the server during the process of transmitting the file shard data to the client.

[0071] When the number of file shards is determined, the client of the data transmission component maintains a shard status array. Among them, the shard status array is used to record the shard reception status of the file shard data. The number of elements in the shard status array is determined according to the number of file shards. The element index in the shard status array is determined according to the file shard index of the file shard data.

[0072] When the shard reception status of the file shard data is determined, update the array element corresponding to the file shard data in the shard status array based on the file shard index of the file shard data.

[0073] Optionally, if the shard reception status of the file shard data is received, set the array element corresponding to the file shard data to 1; if the shard reception status of the file shard data is not received, set the array element corresponding to the file shard data to 0.

[0074] When a communication connection interruption is detected at the client of the data transmission component, the client counts the numerical values of the array elements in the shard status array, and then the file transmission status of the target file data can be determined.

[0075] S250. If the file transmission status is that the transmission has not been completed, a differential transmission request is generated based on the shard reception status, and the differential transmission request is sent to the server of the data transmission component; wherein, the user datagram protocol is used for data transmission between the client and the server of the data transmission component.

[0076] The communication connection is interrupted but the transmission of the target file data has not been completed. The client of the data transmission component generates a differential transmission request based on the shard reception status of the file shard data, and sends the differential transmission request to the server of the data transmission component, requesting the server to retransmit the file shard data with the shard reception status of not received.

[0077] The technical solution of this application determines the shard reception status of the file shard data based on the data verification result. In response to detecting a communication connection interruption, the file transmission status of the target file data is determined based on the shard reception status. If the file transmission status is that the transmission has not been completed, a differential transmission request is generated based on the shard reception status, and the differential transmission request is sent to the server of the data transmission component to request differential data from the server. This avoids the situation of retransmitting the entire file when an incomplete file is received, supports requesting differential data, realizes high-speed, secure and reliable data transmission, solves the latency problem existing in data transmission based on the TCP protocol in the related art, and at the same time can ensure the integrity, security and reliability of the data.

[0078] In an optional embodiment, generating a differential transmission request based on the shard reception status and sending the differential transmission request to the server of the data transmission component includes: determining the file shard data with the shard reception status of not received as the target file shard; generating a differential transmission request based on the file shard index of the target file shard, and sending the differential transmission request to the server of the data transmission component.

[0079] Among them, the target file shard is the file shard data that needs to request the server to retransmit. The file shard index of the target file shard is used to inform the server of the data transmission component which file shard data needs to be retransmitted.

[0080] Optionally, the differential transmission request includes the file shard index of the target file shard. In response to receiving the differential transmission request, the server of the data transmission component retransmits the file shard data corresponding to the file shard index in the differential transmission request to the client of the data transmission component.

[0081] In the above technical solution, when the communication connection is interrupted but the transmission of the target file data has not been completed, the client of the data transmission component is supported to request differential data from the server, avoiding the overall retransmission of the entire file, which is beneficial to improving the efficiency of data transmission and realizing high-speed, secure and reliable data transmission.

[0082] In a specific embodiment, the data transmission method provided in the embodiments of the present application is deployed to a data transmission system. Figure 2B It is a schematic structural diagram of the data transmission system provided in the embodiments of the present application.

[0083] See Figure 2B , the data transmission system includes a trusted data space node of the data requester and a trusted data space node of the data provider. The trusted data space node includes a connector and a data transmission component. The client of the data transmission component is deployed in the trusted data space node of the data requester, and the server of the data transmission component is deployed in the trusted data space node of the data provider.

[0084] The connector and the data transmission component in the trusted data space node interact based on the restful interface. Data transmission between the client of the data transmission component and the server of the data transmission component is based on the User Datagram Protocol. The data requester and the data provider negotiate a data circulation contract through the connector in the trusted data space. After the data circulation contract is determined through negotiation, the data requester notifies the client of the data transmission component through the connector in the trusted data space to send a data transmission request for the target file data to the server of the data transmission component.

[0085] The data transmission system further includes a blockchain network, which is used to store the data circulation contract, the data verification contract, the first verification information, and the second verification information. The blockchain network includes n blockchain nodes, where n is greater than or equal to 2. Before data transmission, the blockchain node is used to call the data circulation contract to perform permission verification on the data requester. During data transmission, the blockchain node is used to call the data verification contract to verify the accuracy of the file shard data based on the first verification information and the second verification information.

[0086] Embodiment III

[0087] Figure 3 It is a schematic structural diagram of the data transmission device provided in Embodiment III of the present application. This embodiment is applicable to the situation where data is transmitted between a data requester and a data provider in a trusted data space. The device can be implemented by software and / or hardware and can be integrated into electronic devices such as intelligent terminals.

[0088] As Figure 3As shown, the device, configured on the client side of the data transmission component, may include:

[0089] A verification information generation module 310, configured to, in response to receiving file shard data from the server side of the data transmission component, generate first verification information for the file shard data based on the file shard data, and generate a shard verification transaction request; wherein, the file shard data is obtained by the server side of the data transmission component performing sharding processing on the target file data in response to a data transmission request for the target file data.

[0090] A verification result determination module 320, configured to, through a blockchain node in the blockchain network, call a data verification contract based on the shard verification transaction request, and determine a data verification result of the file shard data based on the first verification information and second verification information; wherein, the second verification information is generated by the server side of the data transmission component based on the file shard data and stored in the blockchain network.

[0091] A transmission status determination module 330, configured to determine a file transmission status of the target file data based on the data verification result; wherein, the user datagram protocol is used for data transmission between the client side and the server side of the data transmission component.

[0092] In the technical solution of the embodiment of the present application, by designing a data transmission component, data transmission is decoupled from service implementation, and the data transmission component focuses on data transmission, reducing the complexity of system design and the difficulty of system implementation. In the embodiment of the present application, the user datagram protocol is used for data transmission between the client side and the server side of the data transmission component, and a blockchain network is introduced during the data transmission process. Through the blockchain nodes in the blockchain network, the file shard data is verified based on the first verification information and second verification information generated by the client side and the server side for the file shard data. During the data transmission process, the traceability and immutability of the blockchain network are fully utilized, ensuring the reliability and security of data transmission while achieving low-latency data transmission.

[0093] Optionally, the transmission status determination module 330 includes: a reception status determination sub-module, configured to determine a shard reception status of the file shard data based on the data verification result; a transmission status determination sub-module, configured to, in response to detecting a communication connection interruption, determine the file transmission status of the target file data based on the shard reception status; a differential transmission request sub-module, configured to, if the file transmission status is that the transmission has not been completed, generate a differential transmission request based on the shard reception status and send the differential transmission request to the server side of the data transmission component.

[0094] Optionally, the differential transmission request sub-module includes: a target shard determination unit, configured to determine the file shard data with the shard reception status of un-received as the target file shard; a differential request generation unit, configured to generate a differential transmission request based on the file shard index of the target file shard, and send the differential transmission request to the server of the data transmission component.

[0095] Optionally, the verification information generation module 310 includes: a shard index determination sub-module, configured to determine the file shard index of the file shard data based on the shard size and offset of the file shard data; a hash value determination sub-module, configured to calculate the shard hash value of the file shard data by using a cryptographic hash function; a verification information generation sub-module, configured to associate the shard hash value with the file shard index to generate the first verification information of the file shard data.

[0096] Optionally, the verification result determination module 320 includes: an information extraction sub-module, configured to respectively extract the file shard index and the shard hash value from the first verification information and the second verification information by invoking a data verification contract through a blockchain node in the blockchain network based on the shard verification transaction request; a hash value comparison sub-module, configured to compare the shard hash values based on the file shard index by using the data verification contract through the blockchain node; a verification result determination sub-module, configured to determine the data verification result of the file shard data based on the obtained shard hash value comparison result through the blockchain node.

[0097] Optionally, the server and the client of the data transmission component are respectively configured in the trusted data space nodes of the data provider and the data requester; the file size of the target file data is greater than the upper limit value of the data volume supported by the User Datagram Protocol.

[0098] Optionally, the device further includes: a permission verification request module, configured to generate a permission verification transaction request through the server of the data transmission component based on the data transmission request received from the client of the data transmission component; a circulation contract invocation module, configured to invoke a data circulation contract through a blockchain node in the blockchain network based on the permission verification transaction request to perform permission verification on the data requester based on the data transmission request; a file shard processing module, configured to, if the permission verification result is passed, perform shard processing on the target file data through the server of the data transmission component to obtain at least two pieces of the file shard data; wherein, the data circulation contract is negotiated by the data requester and the data provider through a connector in the trusted data space node and stored in the blockchain network.

[0099] The data transmission device provided by the invention embodiment can execute the data transmission method provided by any embodiment of the present application, and has corresponding performance modules and beneficial effects for executing the data transmission method.

[0100] Embodiment 4

[0101] According to the embodiments of the present application, the present application also provides an electronic device, a readable storage medium, and a computer program product.

[0102] Figure 4 FIG. shows a schematic structural diagram of an electronic device 410 that can be used to implement the embodiments. The electronic device 410 includes at least one processor 411, and a memory communicatively connected to the at least one processor 411, such as a read-only memory (ROM) 412, a random access memory (RAM) 413, etc. Among them, the memory stores a computer program executable by the at least one processor. The processor 411 can execute various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 412 or the computer program loaded from the storage unit 418 into the random access memory (RAM) 413. In the RAM 413, various programs and data required for the operation of the electronic device 410 can also be stored. The processor 411, the ROM 412, and the RAM 413 are connected to each other through a bus 414. The input / output (I / O) interface 415 is also connected to the bus 414.

[0103] Multiple components in the electronic device 410 are connected to the I / O interface 415, including: an input unit 416, such as a keyboard, a mouse, etc.; an output unit 417, such as various types of displays, speakers, etc.; a storage unit 418, such as a magnetic disk, an optical disk, etc.; and a communication unit 419, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 419 allows the electronic device 410 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0104] The processor 411 can be various general and / or special processing components with processing and computing capabilities. Some examples of the processor 411 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 411 executes the various methods and processes described above, such as the data transmission method.

[0105] In some embodiments, the data transmission method may be implemented as a computer program tangibly embodied in a computer-readable storage medium, such as storage unit 418. In some embodiments, part or all of the computer program may be loaded and / or installed onto the electronic device 410 via the ROM 412 and / or the communication unit 419. When the computer program is loaded into the RAM 413 and executed by the processor 411, one or more steps of the data transmission method described above may be performed. Alternatively, in other embodiments, the processor 411 may be configured to execute the data transmission method by any other suitable means (e.g., by means of firmware).

[0106] The various embodiments of the systems and techniques described above in this document may be implemented in digital electronic circuitry, integrated circuit systems, field programmable gate arrays (FPGA), application specific integrated circuits (ASIC), application specific standard products (ASSP), systems on a chip (SOC), complex programmable logic devices (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include: implemented in one or more computer programs that may be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a special-purpose or general-purpose programmable processor that receives data and instructions from a storage system, at least one input device, and at least one output device, and transmits the data and instructions to the storage system, the at least one input device, and the at least one output device.

[0107] The computer program for implementing the method of this application may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data transmission device, such that when the computer programs are executed by the processor, the functions / operations specified in the flowchart and / or block diagram are implemented. The computer programs may be executed entirely on the machine, partially on the machine, as a stand-alone software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.

[0108] In the context of this application, a computer-readable storage medium can be a tangible medium that can contain or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer-readable storage medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. Alternatively, the computer-readable storage medium can be a machine-readable signal medium. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0109] To provide for interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the electronic device. Other kinds of devices can also be used to provide for interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, speech input, or tactile input).

[0110] The systems and techniques described herein can be implemented in a computing system that includes backend components (e.g., as a data transfer server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes frontend components (e.g., a user computer having a graphical user interface or a web browser through which the user can interact with an implementation of the systems and techniques described herein), or a computing system that includes any combination of such backend components, middleware components, or frontend components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of a communication network include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.

[0111] A computing system may include a client and a server. The client and the server are generally far from each other and usually interact via a communication network. The relationship between the client and the server is created by computer programs running on respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or a cloud host, which is a host product in the cloud computing service system, solving the defects of difficult management and weak business scalability existing in traditional physical hosts and VPS services.

[0112] An embodiment of the present application also discloses a computer program product. The computer program product includes a computer program which, when executed by a processor, implements the data transmission method provided in any embodiment of the present application. This program product and the data transmission methods disclosed in the embodiments of the present application belong to the same inventive concept, and thus will not be elaborated herein.

[0113] It should be understood that various forms of the processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in the present application can be executed in parallel, sequentially, or in a different order, as long as the desired results of the technical solution of the present application can be achieved, and no limitation is imposed herein.

[0114] The above specific embodiments do not constitute a limitation on the protection scope of the present application. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present application shall be included within the protection scope of the present application.

Claims

1. A data transmission method, characterized in that, Executed by the client of the data transmission component, the method includes: In response to receiving file shard data from the server of the data transmission component, generating first verification information of the file shard data based on the file shard data, and generating a shard verification transaction request; wherein, the file shard data is obtained by the server of the data transmission component in response to a data transmission request for target file data and performing sharding processing on the target file data; Invoking a data verification contract by a blockchain node in the blockchain network based on the shard verification transaction request, and determining a data verification result of the file shard data based on the first verification information and the second verification information; wherein, the second verification information is generated by the server of the data transmission component based on the file shard data and stored in the blockchain network; Based on the data verification result, determining a file transmission status of the target file data; wherein, the user datagram protocol is used for data transmission between the client and the server of the data transmission component.

2. The method according to claim 1, characterized in that, The determining the file transmission status of the target file data based on the data verification result includes: Based on the data verification result, determining a shard reception status of the file shard data; In response to detecting a communication connection interruption, determining the file transmission status of the target file data based on the shard reception status; If the file transmission status is that the transmission has not been completed, generating a differential transmission request based on the shard reception status, and sending the differential transmission request to the server of the data transmission component.

3. The method according to claim 2, characterized in that, The generating a differential transmission request based on the shard reception status and sending the differential transmission request to the server of the data transmission component includes: Determining the file shard data with the shard reception status of not received as the target file shard; Generating a differential transmission request based on the file shard index of the target file shard, and sending the differential transmission request to the server of the data transmission component.

4. The method according to claim 1, wherein The generating the first verification information of the file shard data based on the file shard data includes: Based on the shard size and offset of the file shard data, determining the file shard index of the file shard data; Calculating a shard hash value of the file shard data using a cryptographic hash function; Associating the shard hash value with the file shard index to generate the first verification information of the file shard data.

5. The method according to claim 1, wherein The invoking a data verification contract by a blockchain node in the blockchain network based on the shard verification transaction request and determining the data verification result of the file shard data based on the first verification information and the second verification information includes: Invoking a data verification contract by a blockchain node in the blockchain network based on the shard verification transaction request, and respectively extracting a file shard index and a shard hash value from the first verification information and the second verification information; Using the data verification contract by the blockchain node to compare the shard hash values based on the file shard index; Based on the obtained shard hash value comparison result, determining the data verification result of the file shard data by the blockchain node.

6. The method according to claim 1, wherein The server and client of the data transmission component are respectively configured in the trusted data space nodes of the data provider and the data requester; the file size of the target file data is greater than the upper limit of the data volume supported by the User Datagram Protocol.

7. The method according to claim 6, characterized in that The method further includes: Generating a permission verification transaction request by the server of the data transmission component based on the data transmission request received from the client of the data transmission component; Invoking a data circulation contract by a blockchain node in the blockchain network based on the permission verification transaction request, and performing permission verification on the data requester based on the data transmission request; If the permission verification result is passed, performing fragmentation processing on the target file data by the server of the data transmission component to obtain at least two file fragmentation data; Among them, the data circulation contract is negotiated by the data requester and the data provider through a connector in the trusted data space node and stored in the blockchain network.

8. A data transmission device, characterized in that, Configured in the client of the data transmission component, the device includes: A verification information generation module, configured to generate first verification information of the file fragmentation data based on the file fragmentation data in response to receiving the file fragmentation data from the server of the data transmission component, and generate a fragmentation verification transaction request; wherein, the file fragmentation data is obtained by the server of the data transmission component performing fragmentation processing on the target file data in response to a data transmission request for the target file data; A verification result determination module, configured to determine a data verification result of the file fragmentation data by a blockchain node in the blockchain network based on the fragmentation verification transaction request, based on the first verification information and second verification information; wherein, the second verification information is generated by the server of the data transmission component based on the file fragmentation data and stored in the blockchain network; A transmission state determination module, configured to determine a file transmission state of the target file data based on the data verification result; wherein, the User Datagram Protocol is used for data transmission between the client and the server of the data transmission component.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by a processor, it implements the data transmission method according to any one of claims 1-7.

10. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the data transmission method according to any one of claims 1-7.

Citation Information

Cited By

  • Data transmission method, cloud desktop system, equipment, storage medium and program product

    CN121691315A