Data processing method and device

By generating and distributing preprocessed data shards in the blockchain data processing system, the data sharding restriction problem in privacy data protection is solved, the continuous processing and security of privacy data is realized, and the privacy data processing needs are met.

CN112685750BActive Publication Date: 2024-12-20LENOVO (BEIJING) LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202011562224.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-12-25
Publication Date
2024-12-20
Estimated Expiration
2040-12-25

AI Technical Summary

Technical Problem

Blockchain data is difficult to meet the needs of open and transparent privacy data protection. Current technologies such as coin mixers, ring signatures, homomorphic encryption, etc. are restricted by data sharding and cannot effectively protect privacy data.

Method used

In the blockchain data processing system, by generating preprocessed data shards and distributing them among computing nodes, the computing node can determine whether to generate data shards based on the number of remaining shards after the first stage, ensuring data shards Continuous generation and security of privacy data.

Benefits of technology

It realizes the continuous processing and protection of private data in the blockchain, ensures that computing nodes can meet the needs of private data processing, and enhances data security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112685750B_ABST
    Figure CN112685750B_ABST
Patent Text Reader

Abstract

The present application discloses a data processing method and device, which is applied to a blockchain data processing system including multiple nodes, wherein the multiple nodes include at least two computing nodes. The method includes generating pre-processed data shards so that the computing nodes obtain the pre-processed data shards; in response to the computing nodes completing the first stage of calculation using the pre-processed data shards, obtaining the number of the pre-processed data shards; if the number of the pre-processed data shards is less than a first preset number threshold, generating data shards. The security of private data in the blockchain can be guaranteed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of blockchain technology, and in particular to a data processing method and device. Background Art

[0002] Blockchain is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. In order to protect the privacy of all blockchain data on the chain and make it public and transparent, technical means such as mixers, ring signatures, homomorphic encryption, zero-knowledge proofs or secure multi-party computing are usually used.

[0003] If privacy data is protected through computing nodes on the blockchain, it will be limited by the data shards involved in the calculation, making it impossible to better meet the processing needs of privacy data. Summary of the invention

[0004] In view of this, the present application provides a data processing method and device as follows:

[0005] A data processing method is applied to a blockchain data processing system including multiple nodes, wherein the multiple nodes include at least two computing nodes, and the method comprises:

[0006] Generate preprocessed data slices so that the computing nodes obtain the preprocessed data slices;

[0007] In response to the computing node completing the first phase of computing using the preprocessed data slices, obtaining the number of the preprocessed data slices;

[0008] If the number of the pre-processed data slices is less than the first preset number threshold, data slices are generated.

[0009] Optionally, the method further comprises:

[0010] Determine the target computing nodes that will participate in the second phase of computing;

[0011] The intermediate parameters matching the data slice are sent to the target computing node, so that the target computing node generates a data slice matching the data slice.

[0012] Optionally, obtaining the number of preprocessed data shards includes obtaining the number of preprocessed data shards of each computing node, wherein if the number of preprocessed data shards is less than a first preset number threshold, generating data shards includes:

[0013] If the number of preprocessed data shards of the first computing node is less than a first preset threshold, the first computing node generates data shards;

[0014] The intermediate parameters of the data slice generated by the first computing node are sent to other target computing nodes for the second phase of calculation, so that the other target computing nodes generate data slices that match the data slice.

[0015] Optionally, generating preprocessed data slices includes:

[0016] The first node performs sharding processing on the random number to obtain a plurality of pre-processed data shards, wherein the sharding processing is to cut the random number into a plurality of data shards and obfuscate the association relationship between the data shards, and the first node is any node in the blockchain data processing system except the computing node;

[0017] The preprocessed data slices are sent to the computing nodes respectively, so that the preprocessed data slices obtained by each computing node are different from the preprocessed data slices of other computing nodes.

[0018] Optionally, the method further comprises:

[0019] Obtain a first node group other than computing nodes in the blockchain data processing system;

[0020] Based on the demand parameters calculated in the first stage, the nodes in the first node group determine the first node.

[0021] Optionally, generating preprocessed data slices includes:

[0022] The computing node generates preprocessed data slices, and stores the preprocessed data slices in a private data storage area of ​​the computing node.

[0023] Optionally, the preprocessed data slices include a first preprocessed data slice having a first attribute feature and a second preprocessed data slice having a second attribute feature, and the method further includes:

[0024] Get the calculation mode of the first stage calculation;

[0025] If the computing mode matches the first attribute feature, sending the first preprocessed data slice to the computing node;

[0026] If the computing mode matches the second attribute feature, the second preprocessed data slice is sent to the computing node.

[0027] Optionally, the computing node uses the preprocessed data shards to complete the first stage of calculation, including: processing the first information obtained by each computing node to obtain a processing result corresponding to the data to be processed, the first information being information calculated by each computing node for a data segment of the data to be processed using its own preprocessed data shards.

[0028] Optionally, the method further comprises:

[0029] If the number of generated data slices is greater than or equal to a second preset number threshold, stop generating data slices.

[0030] A data processing device is applied to a blockchain data processing system including multiple nodes, wherein the multiple nodes include at least two computing nodes, and the device includes:

[0031] A first generating unit, configured to generate a pre-processed data slice, so that the computing node acquires the pre-processed data slice;

[0032] an acquiring unit, configured to acquire the number of the preprocessed data slices in response to the computing node completing the first stage of computing using the preprocessed data slices;

[0033] The second generating unit is used to generate data slices if the number of the pre-processed data slices is less than a first preset number threshold.

[0034] It can be seen from the above technical scheme that a data processing method and device disclosed in the present application are applied to a blockchain data processing system including multiple nodes, and the multiple nodes include at least two computing nodes. The method includes generating pre-processed data shards so that the computing node obtains the pre-processed data shards; in response to the computing node completing the first stage calculation using the pre-processed data shards, obtaining the number of the pre-processed data shards; if the number of the pre-processed data shards is less than the first preset number threshold, generating data shards. Therefore, when the computing node participates in the processing of private data, even if the acquired pre-processed data shards are consumed in the first stage calculation, the nodes in the blockchain data processing system can continue to generate data shards for use in subsequent calculations, so that data shards can be continuously generated, ensuring the needs of each computing node in the process of processing private data, thereby ensuring the security of private data in the blockchain. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.

[0036] Figure 1 A flowchart of a data processing method provided in an embodiment of the present application;

[0037] Figure 2A schematic diagram of generating a preprocessed data slice provided in an embodiment of the present application;

[0038] Figure 3 A schematic diagram of a pre-processing data slicing application provided in an embodiment of the present application;

[0039] Figure 4 A schematic diagram of the structure of a data processing device provided in an embodiment of the present application;

[0040] Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0041] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0042] A data processing method provided in an embodiment of the present application is applied to a blockchain data processing system including multiple nodes. Among them, the node can be a node in a blockchain network or a node in a non-blockchain network. If it is a node in a blockchain network, it can be a computer and a server in the blockchain network. For example, multiple nodes can refer to various clients in the blockchain data processing system. Each node can receive input information when performing normal work, and perform data processing in the blockchain data processing system based on the received input information. The computing node is any node among the multiple nodes, or a node specified by the computing scenario requirements, which is used to calculate data with specific attributes, such as calculating privacy data. It should be noted that in the embodiment of the present application, there are at least two computing nodes, because if there is only one computing node, if the data of the computing node is stolen, it will affect the protection of privacy data. When multiple computing nodes are used to process privacy data, it is ensured that each computing node only processes part of the data, so that no computing node can obtain complete privacy data. The blockchain node has a storage space, including private data storage space and ordinary data storage space. The private data storage space can only be accessed by the node itself, and the ordinary data storage space can be accessed by any node on the blockchain.

[0043] See also Figure 1 , which shows a flow chart of a data processing method provided by an embodiment of the present application, the method may include the following steps:

[0044] S101. Generate preprocessed data slices so that computing nodes can obtain the preprocessed data slices.

[0045] Among them, any node in the blockchain data processing system can generate a preprocessed data shard. The timing of generating the preprocessed data shard is when the blockchain computing node has not yet started computing, that is, it can be understood that the preprocessed data shard is pre-generated for subsequent computing node computing. A random number can be split into several preprocessed data shards, for example, a random number r is split into a Lagrangian function of order t. The subsequent embodiments of this application will describe this process.

[0046] S102: In response to the computing node completing the first stage of computing using the preprocessed data slices, obtaining the number of preprocessed data slices.

[0047] The first phase of calculation can be the calculation phase when the blockchain is started. The calculation phase when the blockchain is started refers to the calculation phase that needs to be completed in advance when entering the data processing in the blockchain. For example, a lending platform based on blockchain needs to first verify the assets of the lending applicant, but the actual assets of the lending applicant belong to their private data and are not expected to be known by other users. Therefore, the asset verification process of the lending user needs to be completed in a privacy data protection processing method. In order to achieve this goal, it needs to be verified by multiple computing nodes. In essence, the asset shards corresponding to the actual assets are calculated separately, and the calculation results of each computing node are summarized and analyzed to determine whether the lending user meets the lending authentication conditions. After the authentication is completed, it may be necessary to calculate and process the loan amount, repayment amount, etc. Therefore, asset verification of the lending applicant is the first phase of calculation, and the computing node uses the pre-processed data shards to complete the calculation of this phase.

[0048] After completing the first stage of calculation, the preprocessed data shards will be consumed by the computing nodes. Since the computing nodes also need to complete the subsequent stage of calculation, the number of remaining preprocessed data shards needs to be obtained to obtain the number of preprocessed data shards of each current computing node.

[0049] S103: If the number of pre-processed data slices is less than a first preset number threshold, generate data slices.

[0050] The first preset quantity threshold can be determined based on the application scenario of the current blockchain data processing system, or it can be a universal fixed value. At this time, the number of preprocessed data shards refers to the number of preprocessed data shards remaining after the first stage of calculation, which can be obtained by obtaining the number of preprocessed data shards of the computing nodes in the first stage of calculation. It can also be the total number of preprocessed data shards of all computing nodes participating in the first stage of calculation, because a group of computing nodes completes the protection processing of the same privacy data, and the total preprocessed data shards can be used to determine whether the subsequent computing requirements can be met. If the number of preprocessed data shards is less than the first preset quantity threshold, the data shards can be generated by a designated node, or by a computing node.

[0051] The calculation involving multiple computing nodes is divided into two stages. The first stage of calculation can be the calculation in the blockchain startup stage using pre-processed data shards. After the blockchain is started, that is, after the first stage of calculation is completed, the computing nodes can participate in the generation of data shards, and can continuously provide data shards for subsequent stage calculations of multiple computing nodes.

[0052] A data processing method and device disclosed in an embodiment of the present application are applied to a blockchain data processing system including multiple nodes, wherein the multiple nodes include at least two computing nodes. The method includes generating pre-processed data shards so that the computing node obtains the pre-processed data shards; in response to the computing node completing the first stage calculation using the pre-processed data shards, obtaining the number of the pre-processed data shards; if the number of the pre-processed data shards is less than the first preset number threshold, generating data shards. Thus, when the computing node participates in the processing of private data, even if the acquired pre-processed data shards are consumed in the first stage calculation, the nodes in the blockchain data processing system can continue to generate data shards for use in subsequent calculations, so that data shards can be continuously generated, ensuring the needs of each computing node in the process of processing private data, thereby ensuring the security of private data in the blockchain.

[0053] It should be noted that the data processing method provided in the embodiment of the present application can be applied to the application scenario of privacy data protection of blockchain. Since all blockchain data is on-chain and open and transparent, the privacy data in the blockchain node cannot be better protected. Therefore, multiple computing nodes can be used to process part of the privacy data respectively, and then generate hidden information for the privacy data based on the processing results of each computing node. When the hidden information is on-chain, there is no risk of leaking the privacy data of the node. That is, in the embodiment of the present application, the user's privacy data is only known by the data provider node corresponding to the user, and other nodes cannot know the privacy data. When processing the privacy data, the computing node needs to use data sharding and data fragments of the privacy data to complete the calculation. Among them, the data fragment of the privacy data can be the data fragment obtained by the data provider node randomly splitting the privacy data, or it can be the data fragment obtained by the data provider node after processing the privacy data based on the data fragment received from the computing node. The embodiment of the present application does not limit this, as long as the data fragments of the privacy data received by each computing node are different.

[0054] The following is an example of an implementation method for generating preprocessed data shards. It should be noted that the process of generating data shards is similar to the process of generating preprocessed data shards, and the process of generating data shards will not be repeated. The only difference is the timing of their generation.

[0055] In the embodiment of the present application, any node of the blockchain data processing system can generate pre-processed data shards so that the computing node can complete the first stage of calculation.

[0056] In a possible implementation, the first node performs sharding processing on the random number to obtain a plurality of pre-processed data shards, wherein the sharding processing is to divide the random number into a plurality of data shards and obfuscate the association between the data shards.

[0057] It should be noted that the first node can be any node of the blockchain data processing system, or in order not to occupy too many computing resources of the computing node, the pre-processed data shards can be generated by any node other than the computing node in the blockchain data processing system. This requires the first node to generate multiple pre-processed data shards, but the association between the pre-processed data shards at the time of output is confusing. For example, for the random number m, the secret sharing algorithm k (T, N) can be used to divide it into N data shards, that is, any T data shards can be used to restore the original random number through the interpolation algorithm. It is also possible to directly divide the random number m into N parts, and the original random number m can be obtained by combining all N pre-processed data shards. However, it should be noted that in the embodiment of the present application, after the pre-processed shards are generated, they need to be sent to each computing node, and the computing nodes cannot know each other's pre-processed data shards. That is, the computing nodes cannot interact with each other's pre-processed data shards.

[0058] After the preprocessed data slices are generated, the multiple preprocessed data slices are sent to different computing nodes respectively, so that each computing node receives one preprocessed data slice, and each preprocessed data slice can only be sent to one computing node.

[0059] When the first computing node is not a computing node in the blockchain data processing system, the first node group other than the computing node in the blockchain data processing system can be obtained first, and the first node can be determined from the nodes in the first node group based on the demand parameters calculated in the first stage. Among them, the demand parameters calculated in the first stage can represent the scenario demand parameters calculated in the first stage, as well as the number parameters of the participating computing nodes that can be calculated in the first stage, and can also include authentication parameters for the first node. If the first stage is the calculation stage for user asset authentication, and the number of users who need to be authenticated is large, the number of corresponding computing nodes is also large, then it is necessary to require the first node to be able to generate more pre-processed data fragments. Therefore, there will be some requirements for the processing ability of the first computing node to generate pre-processed fragments. At this time, the demand parameters may include memory parameters and processing efficiency parameters, that is, it is necessary to select a node with high-performance computing in the first node group as the first node. It can also be that the demand parameters include authentication level parameters, that is, identity authentication is performed on each node in the first node group, and the corresponding level parameters are matched according to the identity authentication results, and the node with a level parameter greater than the parameter threshold is used as the first node.

[0060] In another possible implementation, the preprocessed data slices may be generated by the computing nodes, in which each computing node generates a preprocessed data slice, but the preprocessed data slices generated by each node can restore the original sliced ​​data. In order to prevent the preprocessed data slices from being stolen or obtained by other nodes, the computing node stores the generated preprocessed data slices in its own private data storage area, which can only be accessed by the computing node itself, and other nodes cannot access the storage content of the private data storage area.

[0061] In order to enable the preprocessed data slices generated by each computing node to be restored to the same data, the preprocessed slices generated by each computing node need to be associated. This allows each computing node to interact with information in the process of generating preprocessed slices. After the first computing node generates a preprocessed slice, the intermediate parameters for generating the preprocessed data slice can be sent to other target computing nodes, so that the preprocessed slices generated by other computing nodes match the preprocessed data slices generated by the first computing node, that is, they are associated. Among them, the intermediate parameters can be the algorithm identifier, algorithm parameters, and other public data for generating preprocessed data slices.

[0062] Similarly, when the number of preprocessed data shards is less than the first preset number threshold, when generating data shards, the target computing nodes participating in the second stage calculation can be determined; the intermediate parameters matching the data shards are sent to the target computing nodes, so that the target computing nodes generate data shards matching the data shards. Specifically, if the number of preprocessed data shards of the first computing node is less than the first preset threshold, the first computing node generates the data shards, and the intermediate parameters of the data shards generated by the first computing node are sent to other target computing nodes for the second stage calculation, so that the other target computing nodes generate data shards matching the data shards.

[0063] In the embodiment of the present invention, the first-stage computing requirements of the blockchain data processing system can be met by generating pre-processed data shards. As the first-stage computing consumes the pre-processed data shards, the nodes continue to generate data shards to meet the subsequent computing requirements of the blockchain data processing system, thereby achieving sustainable provision of data shards to meet the needs of multiple computing nodes and better protecting privacy data during data processing.

[0064] Since different application scenarios have different requirements for data sharding, the data shards generated in the embodiments of the present application may have different attribute characteristics. For example, the preprocessed data shards include a first preprocessed data shard with a first attribute characteristic and a second preprocessed data shard with a second attribute characteristic. In this way, the corresponding preprocessed data shards can be issued according to the calculation mode. The calculation mode of the first stage calculation can be obtained. If the calculation mode matches the first attribute characteristic, the first preprocessed data shard is sent to the calculation node; if the calculation mode matches the second attribute characteristic, the second preprocessed data shard is sent to the calculation result.

[0065] The computing nodes use the preprocessed data slices to complete the first stage of computing, including: processing the first information obtained by each computing node to obtain a processing result corresponding to the data to be processed, wherein the first information is information obtained by each computing node using its own preprocessed data slices to calculate the data fragments of the data to be processed. The data to be processed is private data, that is, the computing node uses the preprocessed data to process the private data and obtains the hidden information corresponding to the private data, that is, the processing result.

[0066] See also Figure 2 , which shows a schematic diagram of generating a preprocessed data slice provided by an embodiment of the present application. Figure 2 The blockchain data processing system includes n nodes, represented by Peer1, Peer2, and Peern respectively. The nodes randomly generate first-order shards [a] t , [b] t , [r] t and second-order sharding [R] 2t , where [r] t and [R] 2tSatisfy random double sharing. Where a, b, c represent different numbers respectively, [a], [b], [c] represent the shards of a, b, c, [c] is associated with [a] and [b], and can generate a first-order shard [c] through the triple algorithm. Specifically, [a] and [b] are first-order shards, then [a]*[b] is second-order. For example, in step (1), the computing node can calculate the local shard of the computing node through the calculation formula [D] = [a][b] + [R], that is, [D] makes the multiplication of two numbers plus a second-order random shard; in step (2), the interpolation result D can be obtained through [D] of each calculation method, that is, D = open (2t, [D]). D will not leak any information about a and b; in step (3), the shard of [c] is a subtraction operation, that is, [c] = D-[r]. After the above calculation, the first-order shard can be obtained, and the existing public data can be processed. Among them, [c] has a certain association with [a] and [b], and [a][b][c] is called a set of triples. Each computing node has a triple corresponding to a different number of data shards. When a triple is used, a triple in the existing triple list can be selected according to the random number generated by the data provider as the triple used this time. In this way, in the process of using triples for multiplication calculations, the confidentiality of the use of triples can be effectively guaranteed, thereby further enhancing the security of calculations of multiple computing nodes. The product can be finally calculated using the shards through the Lagrangian algorithm. The first-order shard is a first-order shard, which will be used if the computing node adopts the addition or subtraction operation mode. The second-order shard is a second-order shard, such as a*a, which will be used when the computing node adopts the multiplication and division operation mode. Random double sharing means that a number r can be decomposed into a Lagrangian function of order t, and can also be decomposed into a Lagrangian function of order 2t.

[0067] See also Figure 3 , which shows a schematic diagram of a pre-processing data sharding application provided by an embodiment of the present application. Figure 3 The computing nodes include Peer1, Peer2, ... Peern, data providers A and B, which can provide privacy data that needs to be protected. Each computing node has a corresponding pre-processed data shard for computing. For example, the pre-processed data shards of peer1 are [a1], [b1], and [c1], the pre-processed data shards of peer2 are [a2], [b2], and [c2] ... the pre-processed data shards of peer1 are [a1], [b1], and [c1], the pre-processed data shards of peer2 are [a2], [b2], and [c2] ... n ]、[b n ] and [c n ]. The original data to be processed by data provider A is A, and the original data to be processed by data provider B is B. Data provider A receives the pre-processed data fragments [a] sent by each computing node, which include [a1], [a2], ... [an ], data provider A interpolates the pre-processed data slices sent by each computing node to obtain data a, and uses a to process its original data A to obtain the corresponding hidden data d, that is, d = Aa; data provider B receives the pre-processed data slices [b] sent by each computing node, which include [b1], [b2], ... [b n ], data provider B interpolates the pre-processed data slices sent by each computing node to obtain data b, and uses b to process its original data B to obtain the corresponding hidden data e, that is, e=Bb. Then data provider A sends its hidden data d to each computing node, and data provider B sends its hidden data e to each computing node. Then each computing node calculates the product of the hidden data using the pre-processed data slices. Finally, the product of the hidden data calculated by each computing node is interpolated and restored to obtain the product of the data provider's original data, thereby realizing the hidden processing of the original data A and B. The calculation process of each computing node is represented below, where the displayed calculation process is only a part of the calculation of each computing node, and its specific calculation form can also be changed according to the actual application scenario. Figure 3 This is just an example.

[0068] Peer1 node uses the preprocessing shard to multiply the hidden information of the data provider as follows:

[0069] [(A*B)1]=de+d[b1]+e[a1]+[c1]

[0070] Peer2 node uses the preprocessing shard to multiply the hidden information of the data provider as follows:

[0071] [(A*B)2]=de+d[b2]+e[a2]+[c2]

[0072] …

[0073] The Peern node uses the preprocessing shards to multiply the hidden information of the data provider as follows:

[0074] [(A*B) n ]=de+d[b n ]+e[a n ]+[c n ]

[0075] By combining the calculation results of each computing node, the product of the original data can be expressed as:

[0076] A*B=Open([(A*B)1]…[(A*B) n ]).

[0077] It can be seen that in the embodiment of the present application, during the calculation process of the computing node, addition and subtraction operations consume first-order data slices, and multiplication and division consume first-order and second-order data slices, thereby generating corresponding forms of pre-processed data slices, which can ensure various application requirements of the computing node.

[0078] The data processing method of the embodiment of the present application is described below with reference to a specific application example.

[0079] Taking the electronic lending platform as an example, if the blockchain smart contract technology is used to authenticate the assets of the borrower, the personal financial information of the borrower will be included, and the effective protection of the borrower's privacy information cannot be guaranteed. Using the data processing method provided by the embodiment of the present application, the electronic lending platform includes computing nodes, loan nodes, etc. The first stage of calculation can refer to the audit process of the borrower that needs to be audited by the current electronic lending platform, and can be determined based on the borrower's loan request to be audited. Since the actual asset data of the borrower needs to be protected in this audit stage, each computing node needs to use pre-processing shards for audit authentication. First, each computing node sends its own pre-processing data shards to each borrower, so that the borrower hides the actual asset data according to the pre-processing data shards received from each computing node, and obtains asset hidden data. Then, the asset hidden data is sent to each computing node, and each computing node uses its own pre-processing data shards to restore the asset hidden data of each borrower to obtain total asset data, which can determine whether it meets the loan conditions. Calculating total asset data is suitable for application scenarios where the current borrower has several subsidiaries.

[0080] The second stage of calculation can be the process of authenticating the newly received borrower's loan application. Since the pre-processed data shards are consumed when authenticating the previous borrower, the computing node can generate new data shards without shutting down the electronic lending platform to implement asset verification for the borrower corresponding to the newly received loan application.

[0081] Correspondingly, the second-stage calculation can also be applied to the loan processing after the borrower is verified. For some application scenarios, the borrower does not expect to make the loan amount he received public. Therefore, the actual loan amount of the lending platform can also be processed for privacy data to ensure that other nodes except the borrower cannot obtain the actual loan amount. Since the pre-processed data shards are consumed in the asset authentication process, the remaining pre-processed data shards cannot complete the privacy data processing of the loan amount, so the computing nodes need to continue to generate data shards to ensure the completion of the privacy data processing of this process.

[0082] It should be noted that the calculation stages in the above application scenarios are only examples. The first-stage calculation of the blockchain data processing system in the embodiment of the present application can be the calculation that needs to be completed in the startup phase of the system, such as the data calculation process to be processed in the system. The subsequent second-stage calculation refers to the processing of the privacy data received by the blockchain data processing system in real time, or it can be a calculation process associated with the first-stage calculation. The nodes in the system can continuously generate data shards based on the number of remaining data shards during the operation of the system, and stop generating data shards when the number of generated data shards is greater than or equal to the second preset threshold. Among them, the second preset threshold can be determined according to the actual application scenario, such as determined according to the number of computing nodes, so that the number of generated data shards is greater than or equal to the number of computing nodes. To ensure the computing needs of each computing node, thereby ensuring that the system can complete the processing of privacy data in real time.

[0083] In an embodiment of the present application, a data processing device is also provided, which is applied to a blockchain data processing system including multiple nodes, wherein the multiple nodes include at least two computing nodes, see Figure 4 , the device comprises:

[0084] A first generating unit 10 is used to generate a pre-processed data slice so that the computing node obtains the pre-processed data slice;

[0085] An acquiring unit 20 is configured to acquire the number of the preprocessed data slices in response to the computing node completing the first stage of computing using the preprocessed data slices;

[0086] The second generating unit 30 is configured to generate data slices if the number of the pre-processed data slices is less than a first preset number threshold.

[0087] A data processing device provided in an embodiment of the present application is applied to a blockchain data processing system including multiple nodes, wherein the multiple nodes include at least two computing nodes. The device generates pre-processed data shards so that the computing node obtains the pre-processed data shards; in response to the computing node completing the first-stage calculation using the pre-processed data shards, the number of pre-processed data shards is obtained; if the number of pre-processed data shards is less than the first preset number threshold, data shards are generated. Thus, when the computing node participates in the processing of private data, even if the acquired pre-processed data shards are consumed in the first-stage calculation, data shards can continue to be generated through the nodes in the blockchain data processing system for use in subsequent calculations, so that data shards can be continuously generated, ensuring the needs of each computing node in the process of processing private data, thereby ensuring the security of private data in the blockchain.

[0088] exist Figure 4On the basis of the corresponding embodiment, the device further includes:

[0089] A first determining unit, used to determine a target computing node participating in the second stage of computing;

[0090] The first sending unit is used to send the intermediate parameters matching the data slice to the target computing node, so that the target computing node generates the data slice matching the data slice.

[0091] Optionally, the obtaining the number of the preprocessed data slices includes obtaining the number of the preprocessed data slices of each computing node, wherein the second generating unit is specifically configured to:

[0092] If the number of preprocessed data slices of the first computing node is less than a first preset threshold, the first computing node generates data slices; the intermediate parameters of the data slices generated by the first computing node are sent to other target computing nodes for the second stage calculation, so that the other target computing nodes generate data slices that match the data slices.

[0093] Optionally, the first generating unit is specifically configured to:

[0094] The first node performs sharding processing on the random number to obtain a plurality of pre-processed data shards, wherein the sharding processing is to cut the random number into a plurality of data shards and obfuscate the association relationship between the data shards, and the first node is any node in the blockchain data processing system except the computing node;

[0095] The preprocessed data slices are sent to the computing nodes respectively, so that the preprocessed data slices obtained by each computing node are different from the preprocessed data slices of other computing nodes.

[0096] exist Figure 4 On the basis of the embodiment shown, the device further includes:

[0097] A node acquisition unit, used to acquire a first node group other than computing nodes in the blockchain data processing system;

[0098] The second determining unit is configured to determine a first node from among the nodes in the first node group based on the demand parameters calculated in the first stage.

[0099] Optionally, the first generating unit is specifically configured to:

[0100] The computing node generates preprocessed data slices, and stores the preprocessed data slices in a private data storage area of ​​the computing node.

[0101] Optionally, the preprocessed data slices include a first preprocessed data slice having a first attribute feature and a second preprocessed data slice having a second attribute feature, and the device further includes:

[0102] A mode acquisition unit, used for acquiring a calculation mode of the first stage calculation;

[0103] A second sending unit, configured to send the first pre-processed data slice to the computing node if the computing mode matches the first attribute feature;

[0104] A third sending unit is used to send the second pre-processed data slice to the computing node if the computing mode matches the second attribute feature.

[0105] Optionally, the computing node uses the preprocessed data shards to complete the first stage of calculation, including: processing the first information obtained by each computing node to obtain a processing result corresponding to the data to be processed, the first information being information calculated by each computing node for a data segment of the data to be processed using its own preprocessed data shards.

[0106] Optionally, the device further comprises:

[0107] The shard stopping unit is used to stop generating data shards if the number of generated data shards is greater than or equal to a second preset number threshold.

[0108] It should be noted that the specific implementation of each unit in this embodiment can refer to the corresponding content in the previous text and will not be described in detail here.

[0109] See also Figure 5 , is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application, the electronic device may be a blockchain data processing system, the blockchain data processing system includes multiple nodes, and the multiple nodes include at least two computing nodes. The technical solution provided in this embodiment is mainly used to realize the security of continuously generating data shards to protect privacy data.

[0110] Specifically, the electronic device in this embodiment may include the following structure:

[0111] The memory 501 is used to store the application program and the data generated by the operation of the application program;

[0112] The processor 502 is configured to execute the application program to implement:

[0113] Generate preprocessed data slices so that the computing nodes obtain the preprocessed data slices;

[0114] In response to the computing node completing the first phase of computing using the preprocessed data slices, obtaining the number of the preprocessed data slices;

[0115] If the number of the pre-processed data slices is less than the first preset number threshold, data slices are generated.

[0116] It can be seen from the above technical solution that an electronic device provided by this embodiment is applied to a blockchain data processing system including multiple nodes, and the multiple nodes include at least two computing nodes. The method includes generating pre-processed data shards so that the computing node obtains the pre-processed data shards; in response to the computing node completing the first stage calculation using the pre-processed data shards, obtaining the number of the pre-processed data shards; if the number of the pre-processed data shards is less than the first preset number threshold, generating data shards. Thus, when the computing node participates in the processing of private data, even if the acquired pre-processed data shards are consumed in the first stage calculation, the nodes in the blockchain data processing system can continue to generate data shards for use in subsequent calculations, so that data shards can be continuously generated, ensuring the needs of each computing node in the process of processing private data, thereby ensuring the security of private data in the blockchain.

[0117] It should be noted that the specific implementation of the processor in this embodiment can refer to the corresponding content in the previous text and will not be described in detail here.

[0118] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.

[0119] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.

[0120] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0121] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A data processing method, applied to a blockchain data processing system including a plurality of nodes, wherein the plurality of nodes include at least two computing nodes, the method comprising: Generate preprocessed data slices so that the computing nodes obtain the preprocessed data slices; In response to the computing node completing the first phase of computing using the preprocessed data slices, obtaining the number of the preprocessed data slices; If the number of the pre-processed data slices is less than a first preset number threshold, generating data slices; The step of generating preprocessed data fragments includes: The first node performs sharding processing on the random number to obtain a plurality of pre-processed data shards, wherein the sharding processing is to cut the random number into a plurality of data shards and obfuscate the association relationship between the data shards, and the first node is any node in the blockchain data processing system except the computing node; The preprocessed data slices are sent to the computing nodes respectively, so that the preprocessed data slices obtained by each computing node are different from the preprocessed data slices of other computing nodes.

2. The method according to claim 1, further comprising: Determine the target computing nodes that will participate in the second phase of computing; The intermediate parameters matching the data slice are sent to the target computing node, so that the target computing node generates a data slice matching the data slice.

3. The method according to claim 2, wherein obtaining the number of preprocessed data slices comprises obtaining the number of preprocessed data slices of each computing node, wherein: If the number of the pre-processed data slices is less than a first preset number threshold, generating data slices includes: If the number of preprocessed data shards of the first computing node is less than a first preset threshold, the first computing node generates data shards; The intermediate parameters of the data slice generated by the first computing node are sent to other target computing nodes for the second phase of calculation, so that the other target computing nodes generate data slices that match the data slice.

4. The method according to claim 1, further comprising: Obtain a first node group other than computing nodes in the blockchain data processing system; Based on the demand parameters calculated in the first stage, the nodes in the first node group determine the first node.

5. According to the method of claim 1, the generating of preprocessed data slices comprises: The computing node generates preprocessed data slices, and stores the preprocessed data slices in a private data storage area of ​​the computing node.

6. According to the method of claim 1, the computing node uses the preprocessed data slices to complete the first stage of computing, comprising: The first information calculated by each computing node is processed to obtain a processing result corresponding to the data to be processed, wherein the first information is information calculated by each computing node on a data segment of the data to be processed using its own pre-processed data slice.

7. The method according to claim 1, further comprising: If the number of generated data slices is greater than or equal to a second preset number threshold, stop generating data slices.

8. A data processing method, applied to a blockchain data processing system including a plurality of nodes, wherein the plurality of nodes include at least two computing nodes, the method comprising: Generate preprocessed data slices so that the computing nodes obtain the preprocessed data slices; In response to the computing node completing the first phase of computing using the preprocessed data slices, obtaining the number of the preprocessed data slices; If the number of the pre-processed data slices is less than a first preset number threshold, generating data slices; The preprocessed data slices include a first preprocessed data slice having a first attribute feature and a second preprocessed data slice having a second attribute feature, and the method further includes: Get the calculation mode of the first stage calculation; If the computing mode matches the first attribute feature, sending the first pre-processed data slice to the computing node; If the computing mode matches the second attribute feature, the second preprocessed data slice is sent to the computing node.

9. A data processing device, applied to a blockchain data processing system including a plurality of nodes, wherein the plurality of nodes include at least two computing nodes, the device comprising: A first generating unit, configured to generate a pre-processed data slice, so that the computing node acquires the pre-processed data slice; an acquiring unit, configured to acquire the number of the preprocessed data slices in response to the computing node completing the first stage of computing using the preprocessed data slices; A second generating unit, configured to generate data slices if the number of the pre-processed data slices is less than a first preset number threshold; Wherein, the first generating unit is specifically used for: The first node performs sharding processing on the random number to obtain a plurality of pre-processed data shards, wherein the sharding processing is to cut the random number into a plurality of data shards and obfuscate the association relationship between the data shards, and the first node is any node in the blockchain data processing system except the computing node; The preprocessed data slices are sent to the computing nodes respectively, so that the preprocessed data slices obtained by each computing node are different from the preprocessed data slices of other computing nodes.

Citation Information

Patent Citations

  • Method for cloud storage of data and system

    CN103414682A

  • ID generation method and device, storage medium, and electronic device

    CN109376155A

  • Identification generation method and device, electronic equipment and storage medium

    CN111949666A

  • Intelligent contract calling method and device

    CN112015577A

  • Transaction type-based receipt storage method and node

    WO2020233631A1