Multi-party computing verification method and device based on block chain, equipment and storage medium
By introducing verification nodes, scheduling nodes and computing node clusters in multi-party computing systems, and selecting computing nodes using random number seeds, the consensus time-consuming problem of blockchain clustering system is solved when scale expansion is expanded, and the utilization rate of computing resources is improved and block production efficiency ensures the trustworthiness of the system and task security.
Patent Information
- Application Number
- CN202310785769.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-29
- Publication Date
- 2024-12-31
AI Technical Summary
When the scale of a clustered system based on blockchain expands, the consensus process consumes more time, resulting in limited computing resources, slow block production speed and low system efficiency.
A multi-party computing verification method based on blockchain is proposed. By verifying node clusters, scheduling node clusters and computing node clusters, they undertake blockchain consensus, computing scheduling and computing tasks respectively, and use random number seeds to select computing nodes to realize the computing task. Fairness and security, and verify the legitimacy of nodes through blockchain characteristics to reduce blocking of blocks.
It has improved the scalability of computing resources in multi-party computing systems, improved the efficiency of blockchain block production, and ensured the credibility of the system and the fairness and security of computing tasks.
Smart Images

Figure CN119225912A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to the field of multi-party computing technology, and provides a blockchain-based multi-party computing verification method, device, equipment, and storage medium. Background Art
[0002] At present, for computing tasks, clustered system methods are usually used to execute them, but clustered systems face the trust problem between cluster nodes in the system, that is, the task initiator cannot guarantee whether the computing process and the computing results are credible. With the introduction of blockchain technology, more and more clustered system solutions based on blockchain have been proposed. Blockchain is a chain data structure with two major characteristics: decentralization and data is difficult to tamper with. Based on these two characteristics, the information recorded by the blockchain is more authentic and reliable. When generating blocks, since multiple cluster nodes reach consensus, it can be considered that multiple parties maintain a trust relationship, so it can be used to help solve the problem of mutual distrust among nodes in the system.
[0003] However, in the current blockchain-based cluster system, cluster nodes not only need to carry out computing tasks, but also need to carry out blockchain-related consensus tasks and storage tasks. As the scale of the cluster system increases, the time consumption of the consensus process will continue to increase, which restricts the expansion of the system scale and makes the computing resources that the entire system can provide extremely limited.
[0004] To solve the above problems, some blockchain-based clustered system solutions have introduced outsourced computing into the system, that is, external computing service providers are specified in the smart contract of the blockchain, and cluster nodes no longer carry computing tasks. However, this solution still has disadvantages, that is, cluster nodes create blocks when they receive computing tasks, but they need to wait for the external computing service provider to return the calculation results of each computing task in the block before they can reach a consensus on the calculation results in the block. After the consensus is passed, the block can be put on the chain and the next block can be created. The calculation process is usually time-consuming, which will lead to slow block generation speed of the blockchain and low system efficiency. Summary of the invention
[0005] The embodiments of the present application provide a blockchain-based multi-party computing verification method, device, equipment and storage medium, which are used to improve the scalability of computing resources of a blockchain-based multi-party computing system, and to reduce the degree of block generation congestion in the blockchain and improve the efficiency of blockchain generation while ensuring the credibility of the system.
[0006] On the one hand, a blockchain-based multi-party computing verification method is provided, which is applied to any verification node in a verification node cluster included in a multi-party computing system, wherein the multi-party computing system also includes a scheduling node cluster and a computing node cluster; the method includes:
[0007] When the computing task is in a completed state, obtaining task event information of the computing task, the task event information including: signature information of the computing result of the computing task, and a random number seed provided by the task submitting end of the computing task;
[0008] Using a first random number set derived from the random number seed, determining a first computing node set that should execute the computing task from a set of candidate computing nodes;
[0009] Compare the first computing node set with the second computing node set actually executing the computing task indicated by the signature information to obtain a comparison result; wherein the second computing node set is selected from the candidate computing node set by the corresponding scheduling node using a second random number set derived based on the random number seed;
[0010] Based on the comparison result, a legitimacy verification result of the second set of computing nodes is obtained, and based on the legitimacy verification result, a new block is generated in the corresponding blockchain.
[0011] On the one hand, a blockchain-based multi-party computing verification method is provided, which is applied to any scheduling node in a scheduling node cluster included in a multi-party computing system, wherein the multi-party computing system also includes a verification node cluster and a computing node cluster; the method includes:
[0012] Receiving a computing request sent by a task submitting end, the computing request including: a random number seed provided by the task submitting end for a corresponding computing task;
[0013] Obtain a set of candidate computing nodes for the computing task, and determine a second set of computing nodes for executing the computing task from the set of candidate computing nodes based on a second set of random numbers derived from the random number seed;
[0014] Upon receiving a computing result obtained by each second computing node in the second computing node set executing the computing task, updating the computing task to a completed state;
[0015] The random number seed and the signature information of the calculation result are sent to the verification node connected to itself, so that the verification node verifies the legitimacy of the second computing node set based on the random number seed and the signature information.
[0016] On the one hand, a multi-party computing verification method based on blockchain is provided, which is applied to any computing node in a computing node cluster included in a multi-party computing system, wherein the multi-party computing system also includes a verification node cluster and a scheduling node cluster; the method includes:
[0017] Receive a computing request sent by a scheduling node connected to itself, the computing request indicating: executing the computing task submitted by the task submitting end, and the second computing node set executing the computing task is a second random number set derived by the scheduling node based on a random number seed provided by the task submitting end, and is selected from a set of candidate computing nodes;
[0018] Execute the computing task to obtain a corresponding computing result, and sign the computing result based on its own digital certificate to obtain corresponding signature information;
[0019] The calculation result and the signature information are sent to the scheduling node, so that after the scheduling node sends the signature information to the corresponding verification node, the verification node can verify the legitimacy of the second computing node set based on the signature information.
[0020] On the one hand, a multi-party computing verification device based on blockchain is provided, which is applied to any verification node in a verification node cluster included in a multi-party computing system, wherein the multi-party computing system also includes a scheduling node cluster and a computing node cluster; the device includes:
[0021] An event subscription unit, used for obtaining task event information of the computing task when the computing task is in a completed state, wherein the task event information includes: signature information of the computing result of the computing task, and a random number seed provided by the task submission end of the computing task;
[0022] A node selection unit, configured to determine a first set of computing nodes that should execute the computing task from a set of candidate computing nodes by using a first set of random numbers derived from the random number seed;
[0023] A comparing unit, configured to compare the first computing node set with a second computing node set actually executing the computing task indicated by the signature information, to obtain a comparison result; wherein the second computing node set is selected from the candidate computing node set by the corresponding scheduling node using a second random number set derived based on the random number seed;
[0024] A verification unit is used to obtain a legitimacy verification result of the second set of computing nodes based on the comparison result, and generate a new block in the corresponding blockchain based on the legitimacy verification result.
[0025] In one aspect, a multi-party computing verification device based on blockchain is provided, which is applied to any scheduling node in a scheduling node cluster included in a multi-party computing system, wherein the multi-party computing system also includes a verification node cluster and a computing node cluster; the device includes:
[0026] The task receiving unit is used to receive a computing request sent by a task submitting end, wherein the computing request includes: a random number seed provided by the task submitting end for a corresponding computing task;
[0027] a node selection unit, configured to obtain a set of candidate computing nodes for the computing task, and determine a second set of computing nodes for executing the computing task from the set of candidate computing nodes based on a second set of random numbers derived from the random number seed;
[0028] an event updating unit, configured to update the computing task to a completed state upon receiving a computing result obtained by each second computing node in the second computing node set executing the computing task;
[0029] An event notification unit is used to send the random number seed and the signature information of the calculation result to the verification node connected to itself, so that the verification node verifies the legitimacy of the second computing node set based on the random number seed and the signature information.
[0030] On the one hand, a multi-party computing verification device based on blockchain is provided, which is applied to any computing node in a computing node cluster included in a multi-party computing system, wherein the multi-party computing system also includes a verification node cluster and a scheduling node cluster; the device includes:
[0031] A task receiving unit, configured to receive a computing request sent by a scheduling node connected to the unit, wherein the computing request indicates that a computing task submitted by a task submitting end is to be executed, and a second computing node set to execute the computing task is a second random number set derived by the scheduling node based on a random number seed provided by the task submitting end, and is selected from a set of candidate computing nodes;
[0032] A task execution unit, used to execute the computing task to obtain a corresponding computing result, and to sign the computing result based on its own digital certificate to obtain corresponding signature information;
[0033] The result sending unit is used to send the calculation result and the signature information to the scheduling node, so that after the scheduling node sends the signature information to the corresponding verification node, the verification node can verify the legitimacy of the second computing node set based on the signature information.
[0034] On the one hand, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of any one of the above methods when executing the computer program.
[0035] In one aspect, a computer storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the steps of any of the above methods are implemented.
[0036] In one aspect, a computer program product is provided, the computer program product comprising a computer program, the computer program being stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium, and the processor executes the computer program, so that the computer device performs the steps of any of the above methods.
[0037] In an embodiment of the present application, a multi-party computing system supporting node expansion is provided, which includes a verification node cluster, a scheduling node cluster and a computing node cluster, which are respectively used to undertake blockchain consensus, computing scheduling and computing processes related to multi-party computing. In this way, the tasks related to multi-party computing are undertaken independently, making it easier to carry out targeted node expansion. For example, scheduling nodes and computing nodes can be flexibly expanded based on demand without considering the problem of low system efficiency caused by the increasing time of the consensus process due to the increase in nodes, thereby improving the scalability of computing resources of the blockchain-based multi-party computing system.
[0038] In addition, in the method based on the above-mentioned multi-party computing system provided in the embodiment of the present application, when submitting a computing task, the task submission end needs to synchronously submit a random number seed. When the scheduling node schedules the computing task submitted by it, it will select a second set of computing nodes to execute the computing task based on a second random number derived from the random number seed. After these computing nodes complete the computing task, they will sign the computing results. When the verification node performs consensus block generation, it can obtain the second set of computing nodes actually executed based on the signature information, and can also determine the first set of computing nodes that should be executed based on the random number seed, and then verify the legitimacy of the second set of computing nodes assigned by the scheduling node based on the two. Therefore, in the embodiment of the present application, the computing node is randomly selected according to the random number seed sent by the task submission end, thereby ensuring the fairness and security of the computing task. In addition, the embodiment of the present application not only solves the problem of system credibility through the characteristics of the blockchain through consensus verification of the set of computing nodes selected by the random number seed, but also, because the verification node does not need to perform consensus verification on the calculation result, but instead adopts a method of verifying whether the node allocation is legal, the computing resources required for the verification node to generate blocks are reduced, thereby reducing the block generation congestion of the blockchain, thereby improving the efficiency of the blockchain generation. BRIEF DESCRIPTION OF THE DRAWINGS
[0039] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the related technologies, the drawings required for use in the embodiments or the related technical descriptions are briefly introduced below. Obviously, the drawings described below are only the embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.
[0040] Figure 1 A schematic diagram of the structure of the blockchain provided in the embodiment of the present application;
[0041] Figure 2 A schematic diagram of an application scenario provided for an embodiment of the present application;
[0042] Figure 3a to Figure 3b A schematic diagram of the architecture of a multi-party computing system provided in an embodiment of the present application;
[0043] Figure 4a to Figure 4c A schematic diagram of the structure of each node provided in the embodiment of the present application;
[0044] Figure 5 A schematic diagram of a scheduling node deployment process provided in an embodiment of the present application;
[0045] Figure 6a-6b A schematic diagram of a scheduling node deployment page provided in an embodiment of the present application;
[0046] Figure 7 A flowchart of a computing node deployment process provided in an embodiment of the present application;
[0047] Figure 8 A flowchart of a multi-party computing verification method based on blockchain provided in an embodiment of the present application;
[0048] Figure 9a to Figure 9b A schematic diagram of relevant pages provided for embodiments of the present application;
[0049] Fig.10 A schematic diagram of a random selection process provided in an embodiment of the present application;
[0050] Fig.11 A flowchart of a computing task scheduling and allocation process provided in an embodiment of the present application;
[0051] Fig.12 A flowchart of a computing task scheduling and allocation process provided in an embodiment of the present application;
[0052] Fig.13 A schematic diagram of a multi-party computing verification device based on blockchain provided in an embodiment of the present application;
[0053] Fig.14A schematic diagram of the structure of another multi-party computing verification device based on blockchain provided in an embodiment of the present application;
[0054] Fig.15 A schematic diagram of the structure of another multi-party computing verification device based on blockchain provided in an embodiment of the present application;
[0055] Fig.16 A schematic diagram of the composition structure of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0056] In order to make the purpose, technical scheme and advantages of the present application clearer, the technical scheme in the embodiment of the present application will be clearly and completely described below in conjunction with the drawings in the embodiment of the present application. Obviously, the described embodiment is only a part of the embodiment of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application. In the absence of conflict, the embodiments in the present application and the features in the embodiments can be combined with each other arbitrarily. In addition, although the logical order is shown in the flow chart, in some cases, the steps shown or described can be performed in an order different from that here.
[0057] It is understandable that in the following specific implementation methods of this application, if data related to the target object is involved, when the various embodiments of this application are applied to specific products or technologies, relevant permissions or consents need to be obtained, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of relevant countries and regions.
[0058] To facilitate understanding of the technical solutions provided in the embodiments of the present application, some key terms used in the embodiments of the present application are explained here:
[0059] Blockchain: also known as distributed data record book, is a chain data structure that combines data blocks in a sequential manner in chronological order, and is cryptographically guaranteed to be tamper-proof and unforgeable, realizing a decentralized distributed account book. It is generally composed of consensus, block and state data storage, cryptographic identity security, etc. Since the account book is distributed and the blocks are agreed upon, it has the characteristics of being tamper-proof, traceable, and jointly maintained. Figure 1 As shown in , it is a schematic diagram of the structure of the blockchain provided in an embodiment of the present application. A blockchain is formed by connecting blocks in series in sequence.
[0060] Blocks are used to record data sets and status results divided according to certain conditions. They are formed after all nodes reach a consensus. In the embodiment of the present application, the data that needs to be recorded is mainly the legitimacy verification results randomly assigned to the computing nodes. Specifically, blocks can be divided by time, for example, a block is generated every 10 seconds (s), then this block records all data within these 10s; or, blocks can also be divided according to the number of computing tasks. For example, after receiving a specified number of computing tasks, a block is generated, then this block is used to record the legitimacy verification results corresponding to the specified number of computing tasks that have been received. Of course, the embodiment of the present application does not limit the specific way of dividing blocks. Please refer to Figure 1 As shown, a rectangular box represents a block, and a block can generally include a block header and a block body. Among them, the block header includes the previous block address (Prev-block), and the previous block address can usually be stored in the block header in the form of a previous block hash code (pre-hash). All blocks are connected in series through the pointing of the previous block address to form a blockchain. The block body is used to store specific data, such as the legality verification result in the embodiment of the present application.
[0061] Blockchain network: A blockchain network consists of multiple distributed devices. In blockchain technology, any device in the network can be used as a node of the blockchain and can participate in the recording and storage of the blockchain. The nodes jointly maintain the entire blockchain through competitive calculations based on the consensus mechanism. Since any node can have a complete copy of the blockchain data, if any node fails, the remaining nodes can still work normally, so the blockchain storage method has high reliability.
[0062] In addition, since the entire blockchain is maintained by numerous nodes in blockchain technology, the permissions of each node can be the same, so there is no centralized device or management agency. All data information in the blockchain is open and transparent. The modification of a single node or even multiple nodes to their own data cannot affect the data of other nodes, unless more than half of the nodes in the entire blockchain network can be controlled to make modifications, but this method is too difficult, and each block in the blockchain is associated with the two blocks before and after. If you want to tamper with the data of a block, you need to tamper with the data of multiple blocks related to it, which is difficult, so the data stored based on the blockchain is tamper-proof.
[0063] Secure multi-party computation (SMPC) refers to the collaborative calculation of an agreed function by multiple parties without a trusted third party, ensuring that each party only obtains its own calculation results and cannot infer the input and output data of any other party through the interactive data during the calculation process (unless the function itself can infer the input and output of other parties from its own input).
[0064] Random Seed: Seed means the initial value, which is used to generate pseudo-random numbers. Specifically, a random number seed is a random number that takes a random number as an object and a true random number (seed) as an initial condition. Generally, the random numbers of computers are pseudo-random numbers, which take a true random number (seed) as the initial condition, and then use a certain algorithm to iterate and generate random numbers.
[0065] Signature and signature verification: A signature is also called a digital signature or a public key digital signature. It is a string of numbers that can only be generated by the sender of the information and cannot be forged by others. This string of numbers is also a valid proof of the authenticity of the information sent by the sender. Signature verification is to verify the validity of the signature. The receiver needs to confirm whether the file he received is really sent by the sender. What needs to be confirmed is whether it has been tampered with in the middle. The final comparison is based on the message digest.
[0066] Digital Certificate: A digital certificate is an electronic file that uniquely identifies people and resources on the Internet. It enables secure and confidential communication between two entities. There are many types of certificates, such as personal certificates (used by individuals) and server certificates (used to establish secure sessions between servers and clients through Secure Sockets Layer (SSL) technology). Generally speaking, digital certificates are issued by trusted institutions or by trusted people in an organization.
[0067] Load balancing: Load balancing is a method of evenly distributing network traffic among the resource pools that support applications. Generally speaking, current applications must handle millions of users at the same time and return the correct text, video, image, and other data to each user in a fast and reliable manner. In order to handle such high traffic, most applications have many resource servers, which contain a lot of duplicate data. The load balancer is a device located between users and server groups, acting as an invisible coordinator to ensure equal use of all resource servers.
[0068] Process: It is a running activity of a program in a computer on a certain data set. It is the basic unit for resource allocation in the system and the foundation of the operating system structure. In the early computer structure designed for process, the process is the basic execution entity of the program; in the contemporary computer structure designed for thread, the process is the container of thread. The program is a description of instructions, data and their organizational form, and the process is the entity of the program.
[0069] Coroutine: Coroutine is not a system-level thread. Often, coroutines are called "lightweight threads", "microthreads", "fibers", etc. In simple terms, coroutines can be considered as different functions in a thread, and these functions can be quickly switched between each other. Coroutines are very similar to user-mode threads. Switching between user-mode threads does not require trapping into the kernel, but in some operating systems, switching between user-mode threads requires the assistance of kernel-mode threads.
[0070] The technical idea of the embodiments of the present application is briefly described below:
[0071] In related technologies, blockchain solves the problem of mutual distrust among nodes in clustered systems, but it also creates new problems. Traditional blockchain nodes need to carry blockchain-related consensus and storage tasks at the same time, and also need to carry cluster computing tasks. Therefore, when the scale of the cluster continues to expand, the time consumption of the consensus process of a large number of nodes will continue to increase, which restricts the increase in the scale of the system.
[0072] Therefore, in the related technology, an external computing service provider is specified in the smart contract of the blockchain, and the cluster nodes no longer carry computing tasks. However, in this solution, the cluster nodes create blocks when they receive computing tasks, but they need to wait for the external computing service provider to return the calculation results of each computing task in the block before they can reach a consensus on the calculation results in the block. Only after the consensus is passed can the block be put on the chain and the next block can be created. The calculation process is usually time-consuming, which will result in a slow block generation speed of the blockchain and low system efficiency.
[0073] Considering the constraints brought by the traditional blockchain system architecture in the relevant technology, if you want to improve the situation where computing power is difficult to expand, you need to improve the architecture of the blockchain system. Therefore, the embodiment of the present application provides a multi-party computing system that supports node expansion, which includes a verification node cluster, a scheduling node cluster and a computing node cluster, which are respectively used to undertake the blockchain consensus, computing scheduling and computing process related to multi-party computing. In this way, the tasks related to multi-party computing are independently undertaken, making it easier to carry out targeted node expansion. For example, scheduling nodes and computing nodes can be flexibly expanded based on demand without considering the problem of low system efficiency caused by the increasing time-consuming consensus process due to the increase in nodes, thereby improving the scalability of computing resources in the multi-party computing system based on blockchain. In actual scenarios, users can even add personal computers to the computing node cluster to provide computing power, so that computing resources can be infinitely expanded.
[0074] Based on the above system architecture, the embodiment of the present application proposes a multi-party computing verification method based on blockchain. When submitting a computing task, the task submission end needs to synchronously submit a random number seed. When the scheduling node schedules the computing task submitted by it, it will select a second set of computing nodes to execute the computing task based on a second random number derived from the random number seed. After these computing nodes complete the computing task, they will sign the computing results. When the verification node performs consensus and generates a block, it can obtain the second set of computing nodes actually executed based on the signature information, and can also determine the first set of computing nodes to be executed based on the random number seed, and then verify the legitimacy of the second set of computing nodes assigned by the scheduling node based on the two. Therefore, in the embodiment of the present application, the computing node is randomly selected according to the random number seed sent by the task submission end, thereby ensuring the fairness and security of the computing task. In addition, the embodiment of the present application not only solves the problem of system credibility through the characteristics of the blockchain through consensus verification of the set of computing nodes selected by the random number seed, but also, because the verification node does not need to perform consensus verification on the calculation result, but instead adopts a method of verifying whether the node allocation is legal, the computing resources required for the verification node to generate blocks are reduced, thereby reducing the block generation congestion of the blockchain, thereby improving the efficiency of the blockchain generation.
[0075] The embodiment of the present application, combined with the above-mentioned system architecture, can also provide infinite scalability of multi-party computing. Each user can connect his or her computer to the nearest scheduling node to provide a certain amount of computing power as a computing node. In addition, a multi-level authentication mechanism based on a multi-level blockchain architecture is also provided. By issuing certificates step by step, the legal authority of the node is guaranteed, allowing users to verify the identity of the node with credibility.
[0076] The following briefly introduces the application scenarios to which the technical solutions of the embodiments of the present application can be applied. It should be noted that the application scenarios introduced below are only used to illustrate the embodiments of the present application and are not limited. In the specific implementation process, the technical solutions provided by the embodiments of the present application can be flexibly applied according to actual needs.
[0077] The solution provided in the embodiments of the present application can be applied to most scenarios involving computing, such as big data computing scenarios or cloud computing scenarios. Figure 2 As shown, it is a schematic diagram of an application scenario provided by an embodiment of the present application. In this scenario, a terminal device 201 and a multi-party computing system 202 may be included.
[0078] The terminal device 201 can be, for example, any device capable of submitting computing tasks, such as a mobile phone, a tablet computer (PAD), a laptop computer, a desktop computer, a smart TV, a smart vehicle-mounted device, and a smart wearable device. The terminal device 201 can be installed with a target application, which has the function of presenting and submitting computing tasks. The application involved in the embodiment of the present application can be a software client, or a client such as a web page or a small program, and does not limit the specific type of the client.
[0079] The multi-party computing system 202 is used to provide actual task scheduling and execution, as well as to store status data related to the execution of the entire system tasks (e.g., the scheduling results for each computing task), to ensure the credibility between nodes in the system. The multi-party computing system 202 can be a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, i.e., content delivery networks (CDNs), and big data and artificial intelligence platforms, but is not limited thereto.
[0080] In an actual scenario, a user can submit his own computing task through the terminal device 201, and submit a random number seed for the computing task at the same time as submitting the computing task. Then, when the multi-party computing system 202 can be based on the random number seed, it can randomly schedule the computing nodes for the user to execute the computing task through these computing nodes. However, it should be noted that in computer technology, there are actually no real random numbers. All random numbers are pseudo-random numbers, that is, there are certain rules. Therefore, although the random number seed is submitted when submitting the computing task, in fact, a random number seed can specify some computing nodes. On the one hand, the user can choose the computing node he wants. On the other hand, this random allocation method can ensure the fairness of the allocation of computing nodes in the system. In addition, the pseudo-random number method makes the scheduling of computing nodes actually traceable, thereby providing the feasibility of verifying the scheduling results.
[0081] In the embodiment of the present application, the multi-party computing system 202 adopts a multi-party computing architecture based on a multi-level architecture blockchain, which consists of three parts: a verification node cluster, a scheduling node cluster, and a computing node cluster. Each cluster undertakes a system function, and by performing its duties, various functions in the system can be performed independently, laying the foundation for the scalability of the system.
[0082] In the embodiment of the present application, the terminal device 201 and the multi-party computing system 202 can be directly or indirectly connected in communication through one or more networks 203. The network 203 can be a wired network or a wireless network, for example, the wireless network can be a mobile cellular network, or a wireless fidelity (Wireless-Fidelity, WIFI) network, and of course, it can also be other possible networks, which are not limited in the embodiment of the present application.
[0083] See also Figure 3a , which is a schematic diagram of the architecture of a multi-party computing system 202 provided in an embodiment of the present application, wherein black circles represent verification nodes, gray circles represent scheduling nodes, and white circles represent computing nodes.
[0084] See also Figure 3a As shown, the verification node cluster includes multiple verification nodes, each verification node is connected to each other in pairs, each verification node is connected to at least one scheduling node in the scheduling node cluster, and each scheduling node is uniquely connected to one verification node, each scheduling node in the scheduling node cluster is connected to at least one computing node in the computing node cluster, and each computing node is uniquely connected to one scheduling node.
[0085] like Figure 3aAs shown, the multi-party computing system 202 is a top-down three-level architecture, wherein the verification node cluster is the first level, which is used to carry the central audit tasks of the entire system, including the consensus verification tasks of the blockchain; the scheduling node cluster is the second level, which is used to carry the scheduling tasks of the entire system, that is, to schedule the computing tasks to the corresponding computing nodes; the computing node cluster is the third level, which is used to realize the computing functions of the entire system.
[0086] In actual scenarios, in order to achieve a higher level of architecture expansion, the above clusters can actually be further layered, see Figure 3b As shown, it is a schematic diagram of the architecture of another multi-party computing system 202 provided in an embodiment of the present application, where the hierarchical structure of scheduling nodes is specifically illustrated as an example.
[0087] and Figure 3a Similarly, each verification node in the verification node cluster is connected to at least one scheduling node in the scheduling node cluster, and each scheduling node is uniquely connected to one verification node. Figure 3a The point is that a scheduling node cluster may include multiple scheduling node sub-clusters, each scheduling node sub-cluster includes N levels of scheduling nodes, the first level scheduling nodes connect the corresponding verification nodes with the next level scheduling nodes, the last level scheduling nodes connect the corresponding computing nodes with the previous level scheduling nodes, the i-th level scheduling nodes connect the i-1-th level scheduling nodes with the i+1-th level scheduling nodes, and i is a positive integer greater than 1 and less than N.
[0088] See also Figure 3b As shown in the figure, the scheduling node to which each verification node is connected is the root node in a scheduling node subcluster. After this scheduling node, multiple levels of scheduling nodes can be connected. Figure 3b Although only one level of scheduling nodes is shown in the figure, in actual application, more levels of scheduling nodes can be set according to actual conditions, and each scheduling node can manage and schedule the computing nodes connected to its child nodes.
[0089] It can be seen that in Figure 3b In the architecture shown, for computing nodes, users' own computing devices can be added to the computing node cluster, thereby expanding the computing power of the entire system.
[0090] It should be noted that the number of nodes in the above diagram is only an example. In actual scenarios, reasonable configuration can be performed according to the actual scenarios, and the embodiments of the present application do not limit this. In addition, in the actual process of node establishment, load balancing should be achieved as much as possible, that is, the number of subordinate nodes allocated to each node should be as equal as possible to avoid excessive load on a single node.
[0091] In actual application, the user can submit a computing task through the terminal device 201, and the computing task will arrive at one of the scheduling nodes in the above-mentioned scheduling node cluster. The scheduling node can be a node selected by the user or a scheduling node assigned to it by the system. The scheduling node will allocate a computing node to the user based on the random number seed submitted by the user when submitting the computing task. At the same time, the verification node will generate a corresponding random number verification task after the computing task is executed to verify the legality of the scheduling node's allocation of computing nodes. That is, the verification node will also determine the computing node allocated to the user based on the random number seed, and compare it with the computing node allocated by the scheduling node to confirm whether the scheduling is legal, so as to ensure the credibility of the nodes in the system.
[0092] The following is an introduction to each of the above nodes.
[0093] 1. Verification Node
[0094] Or it can be called the central audit blockchain node, which is a node in the verification node cluster. The verification node mainly undertakes blockchain-related tasks and is used to maintain the status of the blockchain, including verifying the random number calculation results of all scheduling nodes and synchronizing the status of all computing tasks.
[0095] See also Figure 4a As shown in FIG. 1 , a schematic diagram of the structure of a verification node provided in an embodiment of the present application is provided. Since the structure of each verification node is similar, only one verification node is used as an example for illustration, and the verification node includes the following modules:
[0096] (1) Network module, which is responsible for communicating with other verification nodes in the verification node cluster, as well as the scheduling node and the user's terminal device.
[0097] (2) A verification interface module, which is used to provide a verification interface to the outside world. It may include a single verification interface and a batch verification interface, which can be used to implement a single verification task and a batch verification task when called respectively. A single verification task may refer to when a user or other nodes in the system need to perform a single verification on the state stored in the blockchain, and then the single verification interface may be called to perform a single verification task; or a batch verification task may refer to when a user or other nodes in the system need to perform a batch verification on the state stored in the blockchain, and then the batch verification interface may be called to perform a batch verification task.
[0098] (3) Authentication module (level 1), which is responsible for functions such as verifying permissions, saving certificates, and issuing certificates. This module includes: a certificate and private key storage submodule, which is used to store the certificates of each role in the system and its own private keys, such as storing its own certificate and the certificate of the scheduling node; a certificate issuance submodule, which is used to issue certificates to the scheduling nodes of the next level when a new scheduling node is deployed; an authentication algorithm submodule, which is used to store relevant cryptographic algorithms for verifying the correctness of user signatures and the legitimacy of certificates, and call these algorithms to implement relevant signature verification and certificate verification processes. It should be noted that the level 1 here means that the verification node can be considered to be at the first level, and its corresponding authentication module is considered to be at the first level accordingly, so as to facilitate the distinction of the authentication modules of various nodes, and the authentication modules of the remaining nodes are correspondingly at the second or third level, etc.
[0099] (4) The random number event block verification module is responsible for verifying the random number tasks of the scheduling nodes, that is, verifying whether the scheduling nodes correctly allocate computing nodes based on the random number seeds provided by the user in accordance with the established rules. This module includes: a random number verification task scheduler, responsible for scheduling random number verification tasks; a random number verification task distributor, responsible for distributing random number verification tasks; a random number verification task executor, responsible for executing random number verification tasks; and a random number verification task processor, responsible for verifying whether the random number results are correct.
[0100] (5) Event subscription module, which is responsible for subscribing to target events from scheduling nodes. Target events include events related to computing tasks, such as computing task node allocation, computing task distribution, and computing task completion. This module includes: event registration submodule, which is responsible for registering subscription events with scheduling nodes; event monitoring submodule, which is responsible for monitoring event messages sent from scheduling nodes.
[0101] (6) A storage module is responsible for storing the verification results. Next time when there is an existing verification result, it can be directly obtained without repeating the verification calculation. This module includes: a verification result cache submodule, which is used to implement the caching of the verification results, that is, to store the verification results in the memory; a verification result storage submodule, which is used to implement the persistent storage of the verification results, such as storing the verification results in a database.
[0102] (II) Scheduling Node
[0103] The scheduling node can be used to perform tasks related to task scheduling, such as maintaining the status of each computing node, calculating the node corresponding to the user based on the random number seed provided by the user, and dispatching computing tasks to each computing node.
[0104] See also Figure 4bAs shown, it is a schematic diagram of the structure of the scheduling node provided in the embodiment of the present application. Since the structure of each scheduling node is similar, only one scheduling node is shown as an example here, which includes the following modules:
[0105] (1) Network module, which is responsible for communicating with verification nodes, user terminal devices, and computing nodes, including receiving computing tasks submitted by users and performing random calculations to assign computing nodes to them, receiving blocks from other scheduler nodes and verifying them, and communicating tasks and status with computing nodes.
[0106] (2) Authentication module (secondary level), which is responsible for storing the certificates of computing nodes and verifying the legitimacy of the identities of users, scheduling nodes, and verification nodes. This module includes: a certificate and private key storage submodule, which is used to store the certificates of each role and its own private key, such as its own certificate or the certificate of the computing node; a certificate issuance submodule, which is used to issue certificates to computing nodes; an authentication algorithm submodule, which is used to store the relevant cryptographic algorithms for verifying the correctness of user signatures and the legitimacy of certificates, and to call these algorithms to implement the relevant signature verification and certificate verification processes.
[0107] (3) The event server module is responsible for storing events and providing services for verification nodes to subscribe to events.
[0108] (4) Task queue module, which is responsible for scheduling the user's computing tasks. This module includes: a task verification submodule, which is used to verify the legitimacy of the task before it enters the task queue; a task queue submodule, which is used to maintain all computing tasks; a priority sorting submodule, which is used to prioritize computing tasks, for example, by the time consumption of the computing task, the conflict between tasks, or the pre-configured priority; and a task distribution submodule, which is used to distribute computing tasks to various computing nodes.
[0109] (5) Load balancing module, which is responsible for maintaining the computing node status table and distributing tasks to maintain the load balancing state of the system. This module includes: a random number derivation algorithm submodule, which is used to derive a random number algorithm for selecting computing nodes based on a random number seed provided by the user; and a node status table submodule, which is used to maintain the status of all nodes, for example, a table that can store the status of all nodes.
[0110] (6) Storage module, used to store the calculation results, task data, task code, etc. of all calculation tasks. This module includes: an execution result cache submodule, used to cache the calculation results obtained by each computing node when executing the calculation task, so that the result can be directly returned when the same calculation task is received; an execution task and data storage submodule, which caches the code and data when executing the task, so as to avoid the user having to send the code and data every time the calculation is performed.
[0111] (III) Computing Nodes
[0112] The computing node is the node that actually performs the calculation. It can be a node natively deployed by the system or a computer device added by the user. The calculation of computing tasks is implemented between each computing node based on the multi-party computing algorithm.
[0113] See also Figure 4c As shown, it is a schematic diagram of the structure of the computing node provided in the embodiment of the present application. Since the structure of each computing node is similar, only one computing node is shown as an example here, which includes the following modules:
[0114] (1) Network module, which is responsible for communicating with the scheduling node, receiving computing tasks distributed by the scheduling node and returning computing results, as well as sharing computing status and its own resource status with the scheduling node.
[0115] (2) Authentication module (level 3), which is responsible for storing the scheduling node's certificate and verifying the legitimacy of the scheduling node's identity when receiving the scheduling node's message. This module includes: a certificate and private key storage submodule, which is used to store the scheduling node's certificate and its own private key; an authentication algorithm submodule, which is used to store the relevant cryptographic algorithms for verifying the correctness of the user's signature and the legitimacy of the certificate, and calls these algorithms to implement the relevant signature verification and certificate verification process.
[0116] (3) Task queue module, which is responsible for temporarily storing the queue of computing tasks to be executed. This module includes: task queue: a queue module that stores all computing tasks; priority sorting submodule, which is used to sort the computing tasks in the task queue according to certain rules. The rules can be, for example, to sort the computing tasks according to the time consumption of the computing tasks, the conflict between tasks, or the pre-configured priority.
[0117] (4) Task execution module, which is the actual execution module of the computing task. This module includes: a resource scheduling submodule, which is used to schedule the computing task and the process or coroutine resources of the computing task when executing the computing task; the process or coroutine is the entity that actually executes the computing task;
[0118] (5) Monitoring module, which is used to collect information and monitor the status of node resources included in it. Node resources are mainly computing-related resources, such as memory or central processing unit (CPU) and other resources. This module may include: a node status monitoring submodule, which is a module for monitoring and displaying its own node status; a node information collection submodule, which is a module for collecting node status information.
[0119] Through the above-mentioned architecture, the various modules contained in each node cooperate with each other to ensure the infinite scalability of multi-party computing. Each user can connect his or her computer to the nearest scheduling node to provide a certain amount of computing power as a computing node. Users who want to perform calculations can send computing tasks to designated scheduling nodes, and randomly select computing nodes based on the random number seeds they send, ensuring the fairness and security of computing tasks. Finally, through a multi-layer certificate authority mechanism, the identity of all nodes can be guaranteed to be credible and can be widely reused in the industry.
[0120] In a possible implementation, each of the above clusters (such as the verification node cluster, the scheduling node cluster, and the computing node cluster) can adopt a distributed deployment architecture, or some clusters can adopt a distributed deployment architecture. For example, the distributed architecture can be a blockchain architecture.
[0121] Blockchain is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of network transactions (referring to operations performed in the system) information, which is used to verify the validity of its information (anti-counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, platform product service layer, and application service layer.
[0122] The underlying blockchain platform can include processing modules such as user management, basic services, smart contracts, and operation monitoring. Among them, the user management module is responsible for the identity information management of all blockchain participants, including maintaining public and private key generation (account management), key management, and the maintenance of the correspondence between the user's real identity and the blockchain address (authority management), etc., and, under authorization, supervises and audits the transactions of certain real identities and provides risk control rule configuration (risk control audit); the basic service module is deployed on all blockchain node devices to verify the validity of business requests, and records valid requests to storage after consensus is reached. For a new business request, the basic service first adapts the interface for parsing and authentication (interface adaptation), and then encrypts the business information through the consensus algorithm (consensus management). The smart contract module is responsible for the registration and issuance of contracts, as well as contract triggering and contract execution. Developers can define the contract logic in a programming language and publish it to the blockchain (contract registration). According to the logic of the contract terms, the key or other events are called to trigger the execution and complete the contract logic. It also provides the function of contract upgrade and cancellation. The operation monitoring module is mainly responsible for the deployment, configuration modification, contract setting, cloud adaptation and real-time status visualization output of the product during the product release process, such as alarm, network status monitoring, node equipment health status monitoring, etc.
[0123] The platform product service layer provides the basic capabilities and implementation framework of typical applications. Developers can superimpose business features based on these basic capabilities to complete the blockchain implementation of business logic. The application service layer provides application services based on blockchain solutions for business participants to use.
[0124] In the embodiment of the present application, a multi-party computing system with a multi-layered architecture based on blockchain is provided. The random scheduling tasks are audited by verifying the node cluster to ensure the credibility of the random generation of the scheduling nodes. The user's computing tasks are scheduled by the scheduling nodes in the middle layer, which shares the scheduling pressure and tries to ensure that the selection of computing nodes meets a certain degree of randomness. In addition, based on the above process, a multi-level authentication mechanism based on a multi-layered blockchain is proposed. By issuing certificates step by step, the legal authority of the nodes is guaranteed, allowing users to verify the identity of the nodes reliably.
[0125] Through the above solution, the infinite scalability of multi-party computing can be guaranteed. Each user can connect his or her computer to the nearest scheduling node to provide a certain amount of computing power as a computing node. Through the multi-layer certificate authority mechanism, the identity of all nodes can be guaranteed to be credible. The above system architecture is the operating basis of the entire environment. Through the above solution and system architecture, the system can be guaranteed to run efficiently and stably.
[0126] Based on the above architecture, the embodiment of the present application also provides a full life cycle process of multi-party computing based on a multi-level architecture blockchain, including: a scheduling node deployment process (a process for deploying and using scheduling nodes), a computing node deployment process (a process for deploying and using computing nodes), a computing task scheduling and allocation process (a process for randomly allocating and scheduling computing tasks), and a computing result event subscription and verification process (a process for the central audit blockchain node to subscribe to events for computing results and verify the legitimacy of events). The design of these processes can ensure the stable and efficient operation of the full life cycle of multi-party computing based on a multi-level architecture blockchain.
[0127] Below, in combination with the application scenarios and system architecture described above, the full life cycle process of multi-party computing based on a multi-level architecture blockchain provided by an exemplary embodiment of the present application is described with reference to the accompanying drawings. It should be noted that the above application scenarios are only shown to facilitate understanding of the spirit and principles of the present application, and the implementation methods of the present application are not limited in this respect.
[0128] In the embodiment of the present application, the scheduling of computing tasks is performed based on the scheduling nodes, so here we first introduce the deployment process of the scheduling nodes. The deployment of scheduling nodes refers to adding new scheduling nodes in the scheduling node cluster. Figure 5 FIG. 1 is a flow chart of a scheduling node deployment process provided in an embodiment of the present application, and the process includes the following steps:
[0129] Step 501: The deployment device prepares information required for scheduling node deployment.
[0130] In an embodiment of the present application, when deploying the scheduling node to be deployed, it is necessary to provide the necessary information required for deployment through the preparation stage, such as the public and private keys of the scheduling node, identity information, and interface information of the event notification interface.
[0131] In one possible implementation, the deployment device may be a terminal device of a user who initiates the deployment of a scheduling node, such as a personal computer, a tablet computer, etc. The device is used to initiate a deployment process for the scheduling node to be deployed. In the terminal device, a corresponding deployment page may be presented to the user, and the user may add or generate information related to the scheduling node to be deployed in the deployment page.
[0132] In a possible implementation, the deployment device may be the scheduling node to be deployed, and the subsequent deployment process may be initiated through the scheduling node. Figure 5 For example, relevant deployment software may be deployed on the scheduling node, and after configuring necessary information (such as the connected verification node, or the access device address of the system, etc.), the deployment software is started to start the deployment preparation work.
[0133] See also Figure 5 As shown, the preparation process may include the following processes:
[0134] Step 5011: Generate a public-private key pair of the scheduling node according to a cryptographic algorithm, wherein the private key is used to encrypt messages sent by the scheduling node, and the public key is open to other nodes and is used to verify whether the messages sent by the scheduling node have been tampered with.
[0135] Step 5012: attaching the identity information of the scheduling node may refer to attaching the identity information of the scheduling node in the initiated deployment request, such as the organization information to which the scheduling node belongs, which is used to determine the organization from which the scheduling node originates.
[0136] Step 5013: Start the event server of the scheduling node. The event server is used to store event-related information, such as the scheduling event of the computing task, the preparation completion event of the computing task, the computing completion event of the computing task, etc. It should be noted that although it is called an event server, it can be considered as the storage space of the scheduling node itself, which is used to store information related to system events and provide it to other nodes for subscription. Of course, the event server can also be a server external to the scheduling node, dedicated to the storage and notification of event-related information.
[0137] Step 5014: the interface information of the event notification interface of the additional scheduling node may refer to the interface information of the event notification interface of the additional scheduling node in the initiated deployment request, such as the Internet Protocol (IP) address and port information of the above event server.
[0138] Of course, the preparation node may also include other possible information, which is not limited in the embodiment of the present application. It should be noted that the above steps do not have a substantial order of precedence, and in actual application, they can be executed simultaneously or in sequence.
[0139] Step 502: The deployment device sends a scheduling node deployment request to the verification node, and the verification node receives the scheduling node deployment request.
[0140] The scheduling node deployment request may carry the identity information of the scheduling node to be deployed obtained in the above preparation phase and the interface information of the event notification interface.
[0141] In an embodiment of the present application, each scheduling node is connected to a verification node, and the user can select the verification node of the scheduling node to be deployed, for example, according to the distance, or according to the idleness of the load resources of the verification node.
[0142] See also Figure 6a-6b As shown, a schematic diagram of the scheduling node deployment page provided in an embodiment of the present application is shown, which shows the content related to the verification node selection, and the user can select the verification node to which the current verification node is connected through this page. Among them, in this selection page, the verification nodes can be sorted according to one or more selection factors.
[0143] See also Figure 6a In the figure, the distance sorting is used as an example. Users can choose to sort the optional verification nodes according to the distance between the scheduling nodes. For example, there are 4 verification nodes in the figure, which are 1km, 50km, 100km and 500km away from the scheduling node respectively. Considering that the closer the distance, the lowest the delay should be, therefore, verification node 1 has the highest recommendation degree. Figure 6a The 4-star recommendation shown can facilitate users to choose verification nodes.
[0144] See also Figure 6b In the figure, the idleness is used as an example. Users can choose to sort the optional verification nodes according to the idleness. For example, there are 4 verification nodes in the figure, and their resource utilization rates are 20%, 40%, 50% and 80% respectively. Considering that the higher the idleness, the higher the data processing efficiency should be, therefore, verification node 1 has the highest recommendation degree. Figure 6b The 4-star recommendation shown can facilitate users to choose verification nodes.
[0145] It should be noted that, although the above examples are respectively illustrated by taking distance or idleness as examples, in actual application, the comprehensive recommendation degree of each verification node can also be determined according to a combination of multiple factors.
[0146] Step 503: The verification node verifies the legitimacy of the identity information of the scheduling node to be deployed based on the information carried in the scheduling node deployment request.
[0147] Specifically, when a new scheduling node joins, it is necessary to authenticate the identity of the scheduling node, on the one hand to verify whether its identity information is true information, and on the other hand to verify whether its identity information meets the conditions for becoming a scheduling node.
[0148] See also Figure 5 As shown, the process of step 503 may include the following steps:
[0149] Step 5031: Determine whether the public and private key correctness verification of the scheduling node deployment request passes.
[0150] Among them, the public and private key correctness verification is usually used to verify whether the received message has been tampered with. Therefore, the first operation after receiving the message is to verify the correctness of the public and private keys. When the verification passes, it indicates that the message has not been tampered with and the subsequent process can continue. If the verification fails, jump to step 505 and return the verification error result to the deployment device.
[0151] Step 5032: If the public and private key correctness verification of step 5031 passes, determine whether the identity information verification of the scheduling node passes.
[0152] In specific applications, in order to improve the correctness of identity information verification, the verification of identity information can include two parts. One part is the automatic review part, that is, the identity information can be verified through the deployed software, such as verifying whether the organizational information in the identity information is real and whether it belongs to an organization that can be added to the scheduling node cluster, etc. The other part can also output the relevant review page to the administrator for review. For example, the review page can be displayed on the verification node, and the review information can be pushed to the corresponding administrator. After the administrator completes the review, the review result is returned. Manual review can be used to review identity information that cannot be recognized by the computer, or the content of the computer review can be secondary verified to avoid review errors and improve the accuracy of identity information verification.
[0153] If the verification is successful, the subsequent process can be continued. If the verification is not successful, the process jumps to step 505 and returns a verification error result to the deployment device.
[0154] Step 504: If the legitimacy verification of the identity information in step 503 is passed, the verification node performs an interface connectivity test on the scheduling node based on the interface information.
[0155] Among them, the interface information refers to the interface related information of the above-mentioned event server. When the scheduling node triggers a related event, it is necessary to send the event information to the verification node through the interface. Therefore, it is necessary to ensure that the path between the interface and the verification node is connected. The verification node needs to perform an interface connectivity test on the interface.
[0156] In one possible implementation, the verification node can subscribe to the events of the event server by subscription. When the event server triggers an event, the relevant event information will be sent to the verification node. The verification node will perform a connectivity test and monitor the event server to confirm whether the information of the event server can be successfully monitored.
[0157] In a possible implementation, the verification node can also actively obtain event information from the event server in a polling manner, that is, the verification node can send an information acquisition request to the event server of the scheduling node according to a certain information acquisition cycle to request it to send updated event information to the verification node. Then, the verification node can perform a connectivity test by sending an information acquisition request to the event server of the scheduling node, and obtaining the result of the interface connectivity test by whether it receives a response.
[0158] It should be noted that in actual scenarios, event information may be updated and sent in other possible ways, and the verification node may perform interface connectivity testing in a corresponding manner, which is not limited in the embodiments of the present application.
[0159] Specifically, when the interface connectivity test passes, the subsequent process can be continued, that is, jump to step 506. Otherwise, if the interface connectivity test fails, jump to step 505 and return the verification error result to the deployment device.
[0160] Step 505: The verification node returns a verification error result to the deployment device, the deployment fails, and the process ends.
[0161] Step 506: The verification node adds the scheduling node to the scheduling node cluster and issues a digital certificate to the scheduling node.
[0162] Specifically, the certificate issuance of the verification node can be implemented through the authentication module it contains. Therefore, the verification node can call its own authentication module to issue a digital certificate for the scheduling node, which will be used for the identity authentication of the scheduling node in subsequent actual processes, such as identity authentication when transmitting information.
[0163] Step 507: The verification node performs consensus verification on the digital certificate issuance result of the verification node cluster for the scheduling node.
[0164] In an embodiment of the present application, in order to improve the reliability of the digital certificate storage of the scheduling node, the digital certificate of the scheduling node can also be stored through the blockchain, so the process of issuing a digital certificate for the scheduling node can be performed by the entire verification node cluster, that is, in addition to the verification node that receives the deployment request, the remaining verification nodes also need to issue a digital certificate for the scheduling node, and each verification node needs to synchronize the digital certificate issued by itself to any verification node except itself, so that each verification node performs consensus verification on the digital certificate, and only when consensus is reached, it confirms that the consensus digital certificate will be issued to the scheduling node, and the digital certificate will be stored on the chain.
[0165] In one possible implementation, when a verification node receives a scheduling node deployment request, it can synchronize the scheduling node deployment request to other verification nodes. Other verification nodes will also perform relevant deployment processes for the scheduling node deployment request and issue digital certificates for it.
[0166] In one possible implementation, when a verification node receives a scheduling node deployment request, it may send a digital certificate issuance request to the remaining verification nodes after the relevant verification of the scheduling node deployment request is passed, requesting other verification nodes to issue a digital certificate for the scheduling node.
[0167] Step 508: When the consensus verification is passed, that is, when the verification nodes corresponding to the blockchain reach a consensus, the verification node generates the corresponding block and puts the block on the chain.
[0168] Step 509: The verification node sends a registration request for the event notification interface to the scheduling node, where the registration request is used to subscribe to target type events from the scheduling node.
[0169] In one possible implementation, considering that the event server of the scheduling node is dedicated to storing system event-related content in the scheduling node, the target type event may include all events of the event server, that is, the verification node may not select the required event type, but subscribe to all event updates of the event server by default.
[0170] In one possible implementation, the target type event may include event information related to the computing task, such as computing task preparation completion, computing node allocation, computing task distribution, and computing task completion related events. Of course, it may also include other possible event information, and the embodiments of the present application are not limited to this.
[0171] Step 510: The verification node starts monitoring the event notification interface. That is, when the registration is successful, the scheduling node can be considered to start working, and the verification node can start monitoring the event server of the scheduling node.
[0172] Step 511: The verification node returns deployment success indication information to the scheduling node, and the deployment success indication information carries a digital certificate.
[0173] Step 512: The scheduling node determines whether the result returned by the verification node is correct. If it is correct, jump to step 513. If it is not correct, the process ends.
[0174] Specifically, the scheduling node judgment process may include performing public and private key verification on the result returned by the verification node to verify whether the result returned by the verification node has been tampered with, or may also include determining the subsequent process based on whether the deployment is successful as indicated in the result returned by the verification node. For example, if a verification error result is received from the verification node, the process ends; if a deployment success indication is received from the verification node, step 513 is continued.
[0175] Step 513: The scheduling node obtains the digital certificate issued by the verification node, stores the certificate in its own authentication module, and formally provides services to the computing node.
[0176] In the embodiment of the present application, computing resources can be infinitely expanded, and users can flexibly add their own computing devices to the computing node cluster as computing resources of the multi-party computing system. When there are computing tasks to be processed, computing tasks can be performed based on these computing resources. Therefore, the deployment process of computing nodes is first introduced here. The deployment of computing nodes refers to adding new computing nodes in the computing node cluster. Figure 7 FIG. 1 is a flow chart of a computing node deployment process provided in an embodiment of the present application, and the process includes the following steps:
[0177] Step 701: The deployment device prepares information required for computing node deployment.
[0178] In an embodiment of the present application, when deploying the computing nodes to be deployed, it is necessary to provide the necessary information required for deployment through the preparation stage, such as the public and private keys of the computing nodes, identity information, and resource configuration information of the computing nodes. The resource configuration information is used to characterize the computing power of the computing node, that is, the amount of computing resources it has, such as memory size, CPU configuration, and graphics processing unit (GPU) capabilities and quantity.
[0179] In a possible implementation, the deployment device may be a terminal device of a user who initiates the deployment of a computing node, such as a personal computer, a tablet computer, etc. The device is used to initiate a deployment process for the computing node to be deployed. In the terminal device, a corresponding deployment page may be presented to the user, and the user may add or generate information related to the computing node to be deployed in the deployment page. It should be noted that the embodiment of the present application does not limit the number of computing nodes to be deployed, and one deployment process may deploy one or more computing nodes.
[0180] In a possible implementation, the deployment device may be the computing node to be deployed, and the subsequent deployment process may be initiated through the computing node. Figure 7For example, relevant deployment software may be deployed on the computing node, and after necessary information (such as information of the connected scheduling node) is configured, the deployment software is started to start the deployment preparation work.
[0181] See also Figure 7 As shown, the preparation process may include the following processes:
[0182] Step 7011: Generate a public-private key pair for the computing node according to a cryptographic algorithm, wherein the private key is used to encrypt messages sent by the computing node, and the public key is disclosed to other nodes and is used to verify whether the messages sent by the computing node have been tampered with.
[0183] Step 7012: attaching the identity information of the computing node may refer to attaching the identity information of the computing node in the initiated deployment request, such as the organization information to which the computing node belongs, to determine the organization from which the computing node originates.
[0184] Step 7013: Adding resource configuration information of the computing node may refer to adding resource configuration information of the computing node in the initiated deployment request.
[0185] Of course, the preparation node may also include other possible information, which is not limited in the embodiment of the present application. It should be noted that the above steps do not have a substantial order of precedence, and in actual application, they can be executed simultaneously or in sequence.
[0186] Step 702: The deployment device sends a computing node deployment request to the scheduling node, and the scheduling node receives the computing node deployment request.
[0187] The computing node deployment request may carry the identity information and resource configuration information of the computing node to be deployed obtained in the above preparation phase.
[0188] In a possible implementation, the event server is used as a notification method provided by the scheduling node to the outside world, and it can also be used as a notification method for the outside world to interact with the scheduling node. The deployment device can send the computing node deployment request to the event server of the scheduling node.
[0189] In a possible implementation, the deployment device may also send the computing node deployment request to the scheduling node by directly sending a message.
[0190] In an embodiment of the present application, each computing node is connected to a scheduling node, and the user can select the scheduling node corresponding to the computing node to be deployed. Similar to the selection of the verification node mentioned above, it can also be selected according to the distance, or according to the idleness of the load resources of the scheduling node. Or, when the user does not make a selection, it can also be allocated by the system.
[0191] Step 703: The scheduling node verifies the legitimacy of the identity information of the computing node to be deployed based on the information carried in the computing node deployment request.
[0192] Specifically, when a new computing node is added, it is necessary to authenticate the computing node. On the one hand, it is necessary to check whether the computing node deployment request has been tampered with, and on the other hand, it is also necessary to verify whether its identity information is authentic.
[0193] See also Figure 7 As shown, the process of step 703 may include the following steps:
[0194] Step 7031: Determine whether the public and private key correctness verification of the computing node deployment request passes.
[0195] Among them, the correctness verification of public and private keys is usually used to verify whether the received message has been tampered with. Therefore, the first operation after receiving the message is to verify the correctness of the public and private keys, that is, the signature verification operation. When the verification passes, it indicates that the message has not been tampered with and the subsequent process can continue. If the verification fails, jump to step 705 and return the verification error result to the deployment device.
[0196] Step 7032: If the public and private key correctness verification of step 7031 passes, determine whether the identity information verification of the computing node passes.
[0197] In specific applications, in order to improve the correctness of identity information verification, the verification of identity information can include two parts. One part is the automatic review part, that is, the identity information can be verified through the deployed software, such as verifying whether the organizational information in the identity information is real and whether it belongs to an organization that can be added to the computing node cluster, etc. The other part can also output the relevant review page to the administrator for review. For example, the review page can be displayed on the scheduling node, and the review information can be pushed to the corresponding administrator. After the administrator completes the review, the review result is returned. Manual review can be used to review identity information that cannot be recognized by the computer, or the content of the computer review can be secondary verified to avoid review errors and improve the accuracy of identity information verification.
[0198] If the verification is successful, the subsequent process can be continued. If the verification is not successful, the process jumps to step 705 and returns a verification error result to the deployment device.
[0199] Step 704: If the legitimacy verification of the identity information in step 703 is passed, the scheduling node determines whether the computing device meets the minimum configuration requirements of the computing node based on the resource configuration information.
[0200] Generally speaking, computing nodes need to be used to perform computing tasks, so there are certain requirements for their hardware configuration. If the hardware configuration cannot meet the requirements, it may be difficult to perform computing tasks, and it is not suitable to be a computing node. The configuration requirements can be set in advance, that is, added as the minimum computing resource requirements for computing nodes, so it is necessary to determine whether the computing devices meet the minimum computing resource requirements one by one, such as whether the memory is sufficient, or whether the CPU configuration meets the predetermined configuration requirements.
[0201] Specifically, when the computing device meets the configuration requirements of the computing node, the subsequent process can continue, that is, jump to step 706. Otherwise, if the computing device does not meet the configuration requirements of the computing node, jump to step 705 and return the verification error result to the deployment device.
[0202] Step 705: The scheduling node returns a verification error result to the deployment device, the deployment fails, and the process ends.
[0203] Step 706: The scheduling node adds the computing node to the computing node cluster and issues a digital certificate to the computing node.
[0204] The certificate issuance of the scheduling node can be specifically implemented through the authentication module it contains. Therefore, the scheduling node can call its own authentication module to issue a digital certificate for the computing node, which will be used for the identity authentication of the computing node in subsequent actual processes, such as identity authentication when transmitting information with other nodes.
[0205] Similar to the deployment of scheduling nodes, in order to improve the reliability of the digital certificate storage of computing nodes, the digital certificates of computing nodes can also be stored through blockchain. Then the process of issuing digital certificates for computing nodes can be carried out by the entire scheduling node cluster. That is to say, in addition to the scheduling node that receives the deployment request, the remaining scheduling nodes also need to issue digital certificates for the computing node, and each scheduling node needs to synchronize the digital certificate issued by itself to any scheduling node except itself, so that each scheduling node performs consensus verification on the digital certificate, and only when consensus is reached, it confirms that the consensus digital certificate will be issued to the computing node and the digital certificate will be stored on the chain.
[0206] In one possible implementation, when a scheduling node receives a computing node deployment request, it can synchronize the computing node deployment request to other scheduling nodes. Other scheduling nodes will also perform relevant deployment processes for the computing node deployment request and issue digital certificates for it.
[0207] In one possible implementation, when a scheduling node receives a computing node deployment request, it can send a digital certificate issuance request to other scheduling nodes after the relevant verification of the computing node deployment request is passed, requesting other scheduling nodes to issue a digital certificate for the computing node.
[0208] Step 707: Update the node status table with the computing device.
[0209] Specifically, the node status table is used to store the node status of each computing node connected to it. The node status can indicate whether the corresponding computing node is available, or indicate the status of the computing resources of the computing node, such as memory usage or CPU usage.
[0210] Step 708: The scheduling node returns deployment success indication information to the computing node, and the deployment success indication information carries a digital certificate.
[0211] Step 709: The computing node determines whether the result returned by the scheduling node is correct. If it is correct, the process jumps to step 710. If it is not correct, the process ends.
[0212] Specifically, the judgment process of the computing node may include performing public and private key verification on the result returned by the scheduling node to verify whether the result returned by the scheduling node has been tampered with, or may also include determining the subsequent process based on whether the deployment is successful as indicated in the result returned by the scheduling node. For example, if a verification error result is received from the scheduling node, the process ends; if a deployment success indication is received from the scheduling node, step 710 is continued.
[0213] Step 710: The computing node obtains the digital certificate issued by the scheduling node, stores the certificate in its own authentication module, and formally provides services to the scheduling node.
[0214] In the embodiment of the present application, the computing task scheduling and allocation process refers to the process of randomly allocating and scheduling computing tasks, that is, users who want to perform computing can send computing tasks to designated scheduling nodes, and randomly select computing nodes according to the random number seeds sent by themselves, thereby ensuring the fairness and security of computing tasks. The computing result event subscription and verification process refers to the process of the verification node subscribing to the computing result event and verifying the legitimacy of the event. There is a correlation in the execution of these two processes, so they are described in combination below. Figure 8As shown, it is a flowchart of a multi-party computing verification method based on blockchain provided in an embodiment of the present application. The process includes the above-mentioned computing task scheduling and allocation process and computing result event subscription and verification process. The specific implementation process of the method is as follows:
[0215] Step 801: The task submitting end submits a computing request, and the scheduling node receives the computing request sent by the task submitting end.
[0216] In an embodiment of the present application, after a user who wishes to perform calculations prepares the code and data required for the calculation task, he can complete the configuration in the calculation task submission page provided by the task submission end, and then perform the task calculation operation, which triggers the task submission end to send a calculation request to the scheduling node.
[0217] See also Figure 9a As shown, a schematic diagram of a computing task submission page provided in an embodiment of the present application is provided, which shows that when a computing task is submitted, it is necessary to provide the code and data required for the computing task, as well as the computing node configuration requirements expected by the user for the computing task, such as the number of computing nodes required (redundancy number) k, etc.
[0218] In order to ensure the fairness of task allocation, the user also needs to set the random number seed corresponding to the current computing task, which is used as the basis for the scheduling node to allocate computing nodes for the calculation. The computing request can include the random number seed provided by the task submission end for the corresponding computing task. For example, the user can select a random number r in [0, max) (max is a very large number).
[0219] It should be noted that although the selection here is based on random numbers, there are certain rules in the selection process. Therefore, when the user gives a random number, the computing node that should be selected for it is determined. Therefore, when the user provides a random number, the computing node that may be eventually assigned can be displayed to assist the user in making a selection. Figure 9b As shown, it is a schematic diagram of the interface for selecting computing nodes provided in an embodiment of the present application, which includes an input window for a random number seed. When the user enters the random number seed in the input window again, the system can determine a list of computing nodes corresponding to the random number seed according to the current system state, and then display it to the user. The user can then determine whether he wants these computing nodes to perform his computing tasks. If he wants, he can confirm. If he does not want, he can change the computing node by modifying the random number.
[0220] Alternatively, a random button could be provided, e.g. Figure 9bIf the user clicks the dice button shown, a random number can be generated for the user as a random number seed. In addition, if the user wants to specify a computing node, he can directly select the corresponding computing node to perform the computing task, or enter the information of the computing node and infer the random number seed for it.
[0221] After completing the relevant configuration, the user can sign the code, data and random number and send it to the corresponding scheduling node, and then the network module of the scheduling node receives the above computing request. The scheduling node can be selected by the user, for example, according to the distance or idleness, or the system can recommend the scheduling node for the user; or, when the user does not select the scheduling node, the system can also allocate the scheduling node for the user, for example, assigning the computing task to the corresponding scheduling node based on the load balancing algorithm.
[0222] Step 802: The scheduling node obtains a set of candidate computing nodes for the computing task, and determines a second set of computing nodes that execute the computing task from the set of candidate computing nodes based on a second set of random numbers derived from a random number seed.
[0223] In the embodiment of the present application, a random number seed is used to derive a second random number corresponding to the required number of computing nodes, and each second random number corresponds to a computing node, so that a corresponding number of computing nodes can be obtained.
[0224] In actual applications, each scheduling node can usually only schedule the computing nodes connected to itself, so it is necessary to select all or part of the computing nodes that it can schedule to form a candidate computing node set. Of course, when selecting some computing nodes to form a candidate computing node set, the selection can be based on the node status of the computing nodes. For example, relatively idle computing nodes or computing nodes that meet certain hardware conditions are selected to form a candidate computing node set. Then, the load balancing module can obtain all active computing nodes in the node status table to form a candidate computing node set.
[0225] In a possible implementation, in order to ensure the security of the computing request and avoid wasting computing resources, it is necessary to authenticate the received computing request. When the authentication is passed, a second random number set derived from a random number seed is used to determine a second computing node set to execute the computing task from a set of candidate computing nodes. This process can be specifically implemented by an authentication module of a scheduling node.
[0226] Specifically, when the scheduling node receives a computing request, it can use an authentication algorithm, such as a public-private key verification algorithm, to determine whether the computing request has been authenticated, that is, to decrypt the computing request using the public key of the task submitter, and obtain the first summary information carried by the computing request. At the same time, the information carried is abstracted to obtain the second summary information, and based on the first summary information and the second summary information, it is determined whether the verification has been passed. This authentication is mainly to prevent the computing task from being tampered with during transmission. At the same time, it can also be verified whether the task submitter has the authority to submit the computing task.
[0227] In a possible implementation, the computing task also needs to be verified. On the one hand, the validity of the computing task needs to be verified, such as verifying the timeliness of the task based on the timestamp, and whether the parameters of the computing task are legal. Only when the task is valid will the subsequent process continue to calculate; on the other hand, it is also necessary to verify whether the computing task already has a calculation result cache, that is, the computing task has been calculated in the past. If so, the historical calculation results can be directly reused to avoid repeated calculations and waste of computing resources. If not, the subsequent process will continue to calculate.
[0228] In actual applications, there may be multiple computing tasks that need to be scheduled in the scheduling node. Multiple task queues are cached in the task queue of the scheduling node waiting for execution. The scheduling node needs to sort the computing tasks in the queue so that each computing task can be scheduled and executed in sequence according to priority.
[0229] In one possible implementation, the priority of each computing task can be considered from multiple aspects. On the one hand, there is the conflict between computing tasks. Some computing tasks conflict with each other and cannot be executed in parallel, that is, they need to wait for the previous computing task to be completed before they can continue with the subsequent computing task. These computing tasks should be executed in order of conflict, such as the same transaction or related transactions of the same account; on the other hand, they can be sorted according to the time consumption of computing tasks. When a computing task is extremely time-consuming, it may block the execution of more computing tasks, so the time consumption needs to be considered during scheduling; on the other hand, they can be sorted according to pre-configured priorities, for example, the priority of a certain type of computing task is configured to be higher than that of another type of computing task.
[0230] In the embodiment of the present application, the random selection algorithm is initialized by a random number seed to derive a corresponding second random number set as a basis for selecting a computing node. The specific process of the random selection algorithm will be introduced in detail later, so it will not be repeated here.
[0231] Step 803: The scheduling node initiates a computing request to each computing node in the second computing node set, and the computing node receives the computing request.
[0232] Specifically, the scheduling node encapsulates and signs the message sent by the user, and sends the encapsulated computing request to each computing node in the second computing node set. Alternatively, the scheduling node can send the computing request to each computing node through the event server, that is, after the scheduling node encapsulates and signs the message sent by the user, it starts the subscription port and notifies the above computing nodes to obtain the task and execute it.
[0233] In one possible implementation, after receiving a computing request, the computing node can sign the computing task identity (ID) and return the signature information to the scheduling node. The scheduling node then collects the event task information of the computing task and stores it in the event server so that all nodes subscribed to the event server can perceive it. The event task information includes, for example, all signatures related to the computing task, task ID, user requests, request signatures, and other information.
[0234] Step 804: The computing node executes the computing task to obtain the corresponding computing result, and signs the computing result based on its own digital certificate to obtain the corresponding signature information.
[0235] It should be noted that, when there are multiple computing nodes in the second computing node set, the scheduling node divides the computing task into multiple subtasks and assigns them to different computing nodes respectively.
[0236] Step 805: The computing node returns the calculation result and signature information obtained by executing the computing task to the scheduling node.
[0237] The computing node sends the signature information of the computing result to the scheduling node connected to it, so that the verification node sends the random number seed and signature information to the verification node connected to it, and then the verification node verifies the legitimacy of the second computing node set based on the random number seed and signature information.
[0238] Step 806: When receiving the calculation results of all the second computing nodes in the second computing node set, the scheduling node updates the computing task to a completed state.
[0239] Step 807: The verification node confirms that the computing task is completed.
[0240] In a possible implementation, the scheduling node may send a notification message to the verification node that the computing task has been completed, so that the verification node can know that the computing task is in a completed state.
[0241] In one possible implementation, the event server of the scheduling node is an external message notification mechanism. Therefore, when the scheduling node can change the task status of the computing task in the event server to a completed state, the verification node subscribes to the event server and can accordingly learn that the status of the computing task has been updated to a completed state.
[0242] Step 808: The verification node obtains the task event information of the computing task.
[0243] Similar to the above, the verification node can request the scheduling node to send the task event information to itself, or it can also obtain the task event information through the event server of the scheduling node. Among them, the task event information may include: the signature information of the calculation result of the calculation task, and the random number seed provided by the task submission end of the calculation task.
[0244] Step 809: The verification node uses a first random number set derived from a random number seed to determine a first computing node set that should execute the computing task from the candidate computing node set.
[0245] In the embodiment of the present application, the consensus on the calculation results in the traditional blockchain-based cluster system is abandoned, and it is converted into verification of random events to ensure the credibility of the nodes in the system. Specifically, the random allocation process of the computing nodes of the scheduling node is verified to verify the legitimacy of the second computing node set allocated by the scheduling node.
[0246] Therefore, the verification node can allocate computing nodes again based on the same random allocation method, and further verify whether the second computing node set allocated by the scheduling node is legal.
[0247] Similarly, when the verification node receives the task event information sent by the scheduling node to which it is connected, it can obtain the signature information of the scheduling node for the task event information, and decrypt the signature information through the public key of the scheduling node (for example, it can be obtained through the certificate carried in the signature of the scheduling node) to obtain the first summary information of the task event information generated by the scheduling node; at the same time, the summary of the task event information is extracted to obtain the second summary information, and based on the first summary information and the second summary information, it is determined whether the signature information has passed the verification. Only when the signature information has passed the verification, the first random number set derived from the random number seed is used to determine the first computing node set that executes the computing task from the candidate computing node set. Otherwise, if the verification fails, it indicates that the task event information may have been tampered with and needs to be discarded.
[0248] Step 810: The verification node compares the first set of computing nodes with the second set of computing nodes actually executing the computing task indicated by the signature information to obtain a comparison result.
[0249] Among them, the second computing node set is selected from the candidate computing node set by the corresponding scheduling node using the second random number set derived from the random number seed, and the signature information is the signature of the computing result after the computing node actually executes, which can indicate which computing node is actually executing. Therefore, based on the signature information, the second computing node set that actually executes the computing task can be known. The first computing node set is selected from the candidate computing node set by the verification node using the first random number set derived from the random number seed. Therefore, by comparing whether the two are consistent, it can be determined whether the scheduling node correctly schedules the node.
[0250] Step 811: The verification node obtains the legitimacy verification result of the second computing node set based on the comparison result.
[0251] Specifically, when the first computing node set is consistent with the second computing node set indicated by the signature information, the legitimacy verification of the second computing node set assigned by the scheduling node is passed; otherwise, when the two are inconsistent, it indicates that the legitimacy verification of the second computing node set assigned by the scheduling node has failed.
[0252] Step 812: The verification node generates a new block in the corresponding blockchain based on the legitimacy verification result.
[0253] In an embodiment of the present application, the block generation process of the verification node can be divided according to time or the number of verification events. Taking the number of verification events as an example, when the number of completed computing tasks reaches the threshold required for block generation, a new block is created, and the scheduling allocation results of each computing task in the block are verified. After the legitimacy verification results are agreed upon among the verification nodes, the block is stored on the chain.
[0254] In the embodiment of the present application, the process of the verification node and the scheduling node deriving random numbers based on the random number seed to select the computing node is the same, so the following is a unified introduction to the process. Fig.10 As shown, it is a flow chart of the random selection process provided in an embodiment of the present application, wherein, in the following process, the random number seed is represented as r, and the number of computing nodes to be selected is k.
[0255] Step 1001: for each candidate computing node in the candidate computing node set, based on the evaluation value of each candidate computing node on the target resource attribute, determine the random number interval range corresponding to each candidate computing node.
[0256] The evaluation value of each computing node on the target resource attribute is used to divide the computing nodes, so as to locate the computing nodes on a unique random number interval, that is, the random number interval ranges corresponding to each candidate computing node do not overlap. The target resource attribute can refer to a combination of one or more resource attributes of the computing node, such as memory occupancy, CPU occupancy, or other computing resource attributes, and the evaluation value on the target resource attribute is the score of the node resource attribute, such as the node resource score, which can be used to characterize the resource availability of the computing node.
[0257] In one possible implementation, each candidate computing node can be divided into a plurality of random number intervals by the accumulated value of the evaluation value, so that subsequently, based on the random number intervals in which the derived random numbers (i.e., the first random number set or the second random number set mentioned above) are located, the candidate computing nodes corresponding to the random number intervals can be used as the computing nodes that need to be allocated (i.e., the first computing node set or the second computing node set mentioned above).
[0258] For example, taking the node resource score as an example, as shown in the following Table 1, for node 1, its node resource score is 90, and its corresponding random number interval range is 0 to 89; the node resource score of node 2 is 80, and the cumulative value of the two is 170, so the random number interval corresponding to node 2 is 90 to 169; the node resource score of node 3 is 85, and the cumulative value is 255, so the random number interval corresponding to node 3 is 170 to 254. When the number of nodes increases, the same applies.
[0259] Compute node ID Node Resource Score Random number range 1 90 0~89 2 80 90~169 3 85 170~254
[0260] Table 1
[0261] Step 1002: Initialize the random number selection factor with the random number seed, that is, set the random number selection factor p=r, and the currently selected node number is x=1.
[0262] In the embodiment of the present application, the process of deriving random numbers is an iterative process. If the number of computing nodes required for the computing task is k, k computing nodes need to be obtained, so K iterative selection processes are required, and each round of selection process is similar. Therefore, the following mainly takes one time as an example to introduce, where each round of selection process includes the following steps:.
[0263] Step 1003: Determine whether the value of the round number x is greater than K. If x is greater than K, the process ends; if not, proceed to step 1004.
[0264] Step 1004: Based on the sum of the evaluation values of the candidate computing node set and the random number selection factor p used in this round, obtain the random number corresponding to this round.
[0265] Specifically, the total sum of the evaluation values can be used as the divisor, and the random number selection factor used in this round can be used as the current divisor to obtain the remainder of the total sum of the evaluation values relative to the random number selection factor used in this round, and the remainder can be determined as the random number corresponding to this round, that is, the random number corresponding to this round is p / N, where N is the total sum of the evaluation values.
[0266] Step 1005: Select a computing node corresponding to this round from the candidate computing node set according to the random number interval range in which the random number is located.
[0267] Exemplarily, for example, if the remainder of this round is 70, then the random number interval in which it is located is 0 to 89, which corresponds to the above-mentioned node 1, so node 1 is the computing node corresponding to this round.
[0268] Step 1006: Update the random number selection factor used in this round to obtain the random number selection factor used in the next round.
[0269] Specifically, the update of the random number selection factor can select an update factor that is open, transparent and as large as possible to update the random number selection factor. For example, the block hash value at a certain height in the blockchain can be used as the update factor. In actual applications, other values can also be selected as the update factor, such as the height of the block, and the embodiments of the present application do not limit this.
[0270] Taking the block hash value at a certain height in the blockchain as an update factor as an example, the corresponding hash value can be obtained by performing hash value mapping processing on the czth block in the blockchain, and then based on the hash value, the random number selection factor used in this round is updated to obtain the random number selection factor used in the next round; where c is the serial number of the latest block in the blockchain, and x is the number of rounds of the iterative selection process.
[0271] In a possible implementation, updating the random number selection factor used in this round can be expressed as:
[0272] p=p*hash(cx)
[0273] Step 1007: the number of iteration rounds is increased by one, that is, x=x+1, and the process jumps to step 1003 to continue execution.
[0274] The following is an example to introduce the computing task scheduling and allocation process. Fig.11 As shown, a flow chart of the computing task scheduling and allocation process provided in an embodiment of the present application is provided.
[0275] Step 1101: The task submitter prepares the code and data required for the task.
[0276] Step 1102: The task submission end selects a random number seed r and the required number of computing nodes k.
[0277] Step 1103: The task submitter signs the code, data and random number seed and sends them to the selected scheduling node.
[0278] Step 1104: The network module of the scheduling node receives the above-mentioned computing request.
[0279] Step 1105: The authentication module of the scheduling node authenticates it and determines whether the authentication is passed, that is, it needs to verify whether the calculation request has been tampered with according to the signature of the calculation request, and verify whether the certificate is authentic. If yes, jump to step 1106 for execution, otherwise jump to step 1109 for execution.
[0280] Step 1106: The scheduling node confirms whether the task verification is passed, for example, whether the timestamp has timed out, whether the parameters are illegal, etc. If yes, jump to step 1107 to execute; otherwise, jump to step 1109 to execute.
[0281] Step 1107: The scheduling node confirms whether there is a calculation result cache for the computing task. If yes, jump to step 1108 for execution; otherwise, jump to step 1109 for execution.
[0282] If the same computing task has the same code number and data number, the code number and data number can be compared to determine whether they are the same. The code number and data number can be, for example, summary values obtained by performing hash calculation on the code and data.
[0283] Step 1108: The scheduling node returns the cached calculation result, and the process on the scheduling node side ends.
[0284] Step 1109: Return the verification error result, and the process on the scheduling node side ends.
[0285] Step 1110: The scheduling node puts the computing task into the task queue and waits for execution.
[0286] Step 1111: The scheduling node prioritizes the task queues.
[0287] Step 1112: The load balancing module of the scheduling node obtains all active nodes in the node status table as candidate computing nodes, and counts the node resource score and the total score N of each candidate computing node.
[0288] Step 1113: The load balancing module of the scheduling node prepares for distributing tasks to nodes for execution, such as packaging task data.
[0289] Step 1114: The load balancing module of the scheduling node performs the initialization operation of computing node selection, that is, k nodes from the candidate computing nodes execute the task, with the current node being represented by x, then initializing x=1, and initializing the selection factor p=r.
[0290] Step 1115: The scheduling node determines whether enough K computing nodes have been selected, that is, whether x>k is satisfied. If yes, jump to step 1119 to execute; otherwise, jump to step 1116 to execute.
[0291] Step 1116: The computing node selected by the scheduling node for the xth node is the computing node corresponding to p / N. That is, from 1 to N, each computing node can be divided into multiple random number range intervals, and the computing node ID is obtained according to the interval.
[0292] Step 1117: The scheduling node updates the random number selection factor, that is, p = p*hash(cx), where hash() represents the block hash value of a certain height, and c is the latest block in the blockchain.
[0293] Step 1118: The number of iteration rounds of the scheduling node is increased by one, x=x+1, and the process jumps to step 1115 for execution.
[0294] Step 1119: The scheduling node completes the selection of all computing nodes.
[0295] Step 1120: The scheduling node encapsulates the computing request message sent by the user and signs it.
[0296] Step 1121: The scheduling node starts the subscription port and notifies the above-selected computing node to obtain the task and execute it.
[0297] Step 1122: All computing nodes sign the computed task ID.
[0298] Step 1123: The scheduling node collects all signatures, task IDs, user requests, and request signatures and stores them in the event server.
[0299] Below, we will use a specific example to introduce the process of how the verification node subscribes to the calculation results and verifies the legitimacy of the event. Fig.12 As shown, a flow chart of the computing task scheduling and allocation process provided in an embodiment of the present application is provided.
[0300] Step 1201: The network module of the computing node subscribes to the computing task to be executed.
[0301] Step 1202: When a computing node is selected as a task execution node, its network module will receive the computing task distributed from the scheduling node.
[0302] Step 1203: The authentication module of the computing node authenticates it and determines whether the authentication is passed, that is, it needs to verify whether the computing request has been tampered with based on the signature of the scheduling node for the computing request, and whether the certificate verification is passed, etc. If yes, jump to step 1205 for execution, otherwise jump to step 1204 for execution.
[0303] Step 1204: The computing node returns a verification error result and the process ends.
[0304] Step 1205: The computing node places the computing tasks into the task queue in order of priority.
[0305] Step 1206: The task execution module of the computing node schedules the above computing task and executes it immediately if there are resources, otherwise waits for execution.
[0306] Step 1207: The process or coroutine in the task execution module of the computing node starts to execute the task.
[0307] Step 1208: The computing node returns the task execution result to the scheduling node. The task execution result includes the computing result and signature information for the computing result.
[0308] Step 1209: The scheduling node determines whether the tasks executed by all computing nodes are completed. If so, go to 1210, otherwise go to 1202 for execution.
[0309] Step 1210: The scheduling node stores the execution code and the result in the execution code and data storage of the storage module.
[0310] Step 1211: The scheduling node updates the execution status of the computing task in the event server to a completed status.
[0311] Step 1212: The event monitoring module of the verification node detects a new event of the scheduling node event server, that is, the execution status of the above computing task is completed.
[0312] Step 1213: The verification node receives the relevant information sent by the scheduling node and verifies whether the signature is passed. If yes, jump to 1215 to execute, otherwise jump to 1214 to execute.
[0313] Step 1214: The verification node discards the calculation result and the process ends.
[0314] Step 1215: The verification node places the computing task into the random number verification task scheduler.
[0315] Step 1216: After the scheduler completes scheduling, the computing task is placed in the random number verification task distributor.
[0316] Step 1217: The distributor distributes the random number verification task of the computing task to a specific executor, and the random number verification task executor performs the verification task.
[0317] Step 1218: The random number verification result processor processes the result of the random number verification.
[0318] Step 1219: Verify whether the result is correct. If so, jump to 1221 to execute; otherwise, jump to 1220 to execute.
[0319] Step 1220: The result of failed evidence verification is stored in the verification result storage, that is, the verification result is stored on the chain, and the process ends.
[0320] Step 1221: Store the correct verification result in the verification result storage, that is, the verification result is stored on the chain, and the process ends.
[0321] In summary, the embodiment of the present application provides a multi-party computing solution based on a multi-layered blockchain architecture, which can ensure the unlimited scalability of multi-party computing. Each user can connect his or her computer to the nearest scheduling node, which provides a certain amount of computing power as a computing node. Users who wish to perform calculations can send computing tasks to designated scheduling nodes, and randomly select computing nodes based on the random number seeds sent by themselves, thereby ensuring the fairness and security of computing tasks. Finally, through a multi-layer certificate authority mechanism, the identity of all nodes can be guaranteed to be credible.
[0322] See also Fig.13 Based on the same inventive concept, the embodiment of the present application further provides a blockchain-based multi-party computing verification device 130, which is applied to any verification node in a verification node cluster included in a multi-party computing system, and the multi-party computing system also includes a scheduling node cluster and a computing node cluster; the device includes:
[0323] The event subscription unit 1301 is used to obtain task event information of the computing task when the computing task is in the completed state, and the task event information includes: signature information of the computing result of the computing task, and a random number seed provided by the task submitting end of the computing task;
[0324] The node selection unit 1302 is used to determine a first computing node set that should execute the computing task from the candidate computing node set by using a first random number set derived from a random number seed;
[0325] The comparing unit 1303 is used to compare the first computing node set with the second computing node set actually executing the computing task indicated by the signature information to obtain a comparison result; wherein the second computing node set is selected from the candidate computing node set by the corresponding scheduling node using a second random number set derived based on a random number seed;
[0326] The verification unit 1304 is used to obtain a legitimacy verification result of the second computing node set based on the comparison result, and generate a new block in the corresponding blockchain based on the legitimacy verification result.
[0327] In one possible implementation,
[0328] Each verification node in the verification node cluster is connected to at least one scheduling node in the scheduling node cluster, and each scheduling node is uniquely connected to one verification node;
[0329] Each scheduling node in the scheduling node cluster is connected to at least one computing node in the computing node cluster, and each computing node is uniquely connected to one scheduling node; or,
[0330] The scheduling node cluster includes multiple scheduling node sub-clusters, each scheduling node sub-cluster includes N levels of scheduling nodes, the first level scheduling node connects the corresponding verification node with the next level scheduling node, the last level scheduling node connects the corresponding computing node with the previous level scheduling node, the i-th level scheduling node connects the i-1-th level scheduling node with the i+1-th level scheduling node, and i is a positive integer greater than 1 and less than N.
[0331] In a possible implementation manner, the node selection unit 1302 is specifically configured to:
[0332] For each candidate computing node in the candidate computing node set, based on each evaluation value on the target resource attribute, a random number interval range corresponding to each candidate computing node is determined respectively, and the random number interval ranges corresponding to each candidate computing node do not overlap with each other;
[0333] Based on each first random number in the first random number set, perform the following operations:
[0334] For each first random number, taking a candidate computing node corresponding to a random number interval in which the first random number is located as the first computing node;
[0335] A first computing node set is generated based on the obtained first computing nodes.
[0336] In a possible implementation manner, the node selection unit 1302 is specifically configured to:
[0337] The random number selection factor is initialized with a random number seed, and K rounds of iterative selection process are performed to obtain the first computing node set, where K is the number of computing nodes required for the computing task; wherein each round of selection process includes the following steps:
[0338] Based on the sum of the evaluation values of the candidate computing node set and the random number selection factor used in this round, the random number corresponding to this round is obtained;
[0339] Update the random number selection factor used in this round to obtain the random number selection factor used in the next round.
[0340] In a possible implementation manner, the node selection unit 1302 is specifically configured to:
[0341] The sum of the evaluation values is used as the divisor, and the random number selection factor used in this round is used as the current divisor to obtain the remainder of the sum of the evaluation values relative to the random number selection factor used in this round;
[0342] The remainder is determined as the random number corresponding to this round.
[0343] In a possible implementation manner, the node selection unit 1302 is specifically configured to:
[0344] Perform hash value mapping on the cxth block in the blockchain to obtain the corresponding hash value; where c is the serial number of the latest block in the blockchain, and x is the number of rounds of the iterative selection process;
[0345] Based on the hash value, the random number selection factor used in this round is updated to obtain the random number selection factor used in the next round.
[0346] In a possible implementation manner, the device further includes an authentication unit 1305, configured to:
[0347] When the task event information is sent by the scheduling node connected to itself, the signature information of the scheduling node for the task event information is obtained;
[0348] Decrypt the signature information using the public key of the scheduling node to obtain the first summary information of the task event information generated by the scheduling node;
[0349] Extracting a summary of the task event information to obtain second summary information, and determining whether the signature information passes verification based on the first summary information and the second summary information;
[0350] The node selection unit 1302 is specifically used to determine a first computing node set for executing a computing task from a set of candidate computing nodes using a first random number set derived from a random number seed when the signature information passes verification.
[0351] In a possible implementation manner, the device further includes a node deployment unit 1306, configured to:
[0352] Receive a scheduling node deployment request, the scheduling node deployment request carries: identity information of the scheduling node to be deployed and interface information of the event notification interface;
[0353] If the legitimacy of the identity information is verified, the scheduling node is tested for interface connectivity based on the interface information;
[0354] If the interface connectivity test passes, the scheduling node is added to the scheduling node cluster and a digital certificate is issued to the scheduling node;
[0355] When the consensus verification of the digital certificate issuance result of the scheduling node by the verification node cluster is passed, a registration request for the event notification interface is sent to the scheduling node. The registration request is used to subscribe to the target type event from the scheduling node;
[0356] When the registration is successful, a deployment success indication message is returned to the scheduling node, and the deployment success indication message carries a digital certificate.
[0357] The device can be used to execute the method executed by the verification node in each embodiment of the present application. Therefore, for the functions that can be implemented by each functional module of the device, please refer to the description of the aforementioned embodiments and no further details will be given.
[0358] See also Fig.14 Based on the same inventive concept, the embodiment of the present application further provides a blockchain-based multi-party computing verification device 140, which is applied to any scheduling node in a scheduling node cluster included in a multi-party computing system, and the multi-party computing system also includes a verification node cluster and a computing node cluster; the device includes:
[0359] The task receiving unit 1401 is used to receive a computing request sent by a task submitting end, where the computing request includes: a random number seed provided by the task submitting end for a corresponding computing task;
[0360] The node selection unit 1402 is used to obtain a candidate computing node set for the computing task, and determine a second computing node set for executing the computing task from the candidate computing node set based on a second random number set derived from the random number seed;
[0361] An event updating unit 1403 is configured to update the computing task to a completed state upon receiving a computing result obtained by each second computing node in the second computing node set executing the computing task;
[0362] The event notification unit 1404 is used to send the random number seed and the signature information of the calculation result to the verification node connected to itself, so that the verification node verifies the legitimacy of the second computing node set based on the random number seed and the signature information.
[0363] In a possible implementation manner, the device further includes a node deployment unit 1405, configured to:
[0364] Receive a computing node deployment request, the computing node deployment request carrying: identity information of the computing device to be deployed and resource configuration information;
[0365] If the legitimacy of the identity information is verified, then based on the resource configuration information, determine whether the computing device meets the configuration requirements of the computing node;
[0366] If the configuration requirements are met, the computing device is added to the computing node cluster, and the node status table is updated with the computing device. The node status table is used to store the node status of each computing node connected to it.
[0367] A digital certificate is issued to the computing device, and deployment success indication information is returned to the computing device, where the deployment success indication information carries the digital certificate.
[0368] The device can be used to execute the method executed by the scheduling node in each embodiment of the present application. Therefore, for the functions that can be implemented by each functional module of the device, please refer to the description of the aforementioned embodiments and no further details will be given.
[0369] See also Fig.15 Based on the same inventive concept, the embodiment of the present application further provides a blockchain-based multi-party computing verification device 150, which is applied to any computing node in a computing node cluster included in a multi-party computing system, and the multi-party computing system also includes a verification node cluster and a scheduling node cluster; the device includes:
[0370] The task receiving unit 1501 is used to receive a computing request sent by a scheduling node connected to the scheduling node, where the computing request indicates that the computing task submitted by the task submitting end is to be executed, and the second computing node set that executes the computing task is a second random number set derived by the scheduling node based on a random number seed provided by the task submitting end, and is selected from the candidate computing node set;
[0371] The task execution unit 1502 is used to execute the calculation task to obtain the corresponding calculation result, and sign the calculation result based on its own digital certificate to obtain the corresponding signature information;
[0372] The result sending unit 1503 is used to send the calculation result and signature information to the scheduling node, so that after the scheduling node sends the signature information to the corresponding verification node, the verification node can verify the legitimacy of the second computing node set based on the signature information.
[0373] The device can be used to execute the methods executed by the computing nodes in the various embodiments of the present application. Therefore, for the functions that can be implemented by the various functional modules of the device, reference can be made to the description of the aforementioned embodiments and no further details will be given.
[0374] Through the above device, the infinite scalability of multi-party computing can be guaranteed. Each user can connect his computer to the nearest scheduling node to provide a certain amount of computing power as a computing node. Users who want to perform calculations can send computing tasks to designated scheduling nodes and randomly select computing nodes based on the random number seeds they send, ensuring the fairness and security of computing tasks. Finally, through a multi-layer certificate authority mechanism, the identity of all nodes can be guaranteed to be credible.
[0375] See also Fig.16 Based on the same technical concept, the present application also provides a computer device. In one embodiment, the computer device may be the verification node, scheduling node or computing node mentioned above. Fig.16 As shown, it includes a memory 1601 , a communication module 1603 and one or more processors 1602 .
[0376] The memory 1601 is used to store computer programs executed by the processor 1602. The memory 1601 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and programs required to run the above functions, etc.; the data storage area may store various instant messaging information and operation instruction sets, etc.
[0377] The memory 1601 may be a volatile memory, such as a random-access memory (RAM); the memory 1601 may also be a non-volatile memory, such as a read-only memory, a flash memory, a hard disk drive (HDD) or a solid-state drive (SSD); or the memory 1601 may be any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto. The memory 1601 may be a combination of the above memories.
[0378] The processor 1602 may include one or more central processing units (CPU) or a digital processing unit, etc. The processor 1602 is used to implement the above-mentioned multi-party computing verification method based on blockchain when calling the computer program stored in the memory 1601.
[0379] The communication module 1603 is used to communicate with terminal devices and other nodes.
[0380] The specific connection medium between the memory 1601, the communication module 1603 and the processor 1602 is not limited in the embodiment of the present application. Fig.16 In the embodiment, the memory 1601 and the processor 1602 are connected via a bus 1604. The bus 1604 is connected to the processor 1602 via a bus 1604. Fig.16 The connections between the other components are only for illustration and are not intended to be limiting. The bus 1604 can be divided into an address bus, a data bus, a control bus, etc. For ease of description, Fig.16 The diagram shows that only one thick line is used, but this does not mean that there is only one bus or only one type of bus.
[0381] The memory 1601 stores a computer storage medium, and the computer storage medium stores computer executable instructions. The computer executable instructions are used to implement the multi-party computing verification method based on blockchain in the embodiments of the present application. The processor 1602 is used to execute the multi-party computing verification method based on blockchain in the above-mentioned embodiments.
[0382] Based on the same inventive concept, an embodiment of the present application also provides a storage medium, which stores a computer program. When the computer program runs on a computer, the computer executes the steps of the blockchain-based multi-party computing verification method described above in this specification according to various exemplary embodiments of the present application.
[0383] In some possible implementations, various aspects of the blockchain-based multi-party computing verification method provided by the present application can also be implemented in the form of a computer program product, which includes a computer program. When the program product is run on a computer device, the computer program is used to enable the computer device to execute the steps of the blockchain-based multi-party computing verification method according to various exemplary embodiments of the present application described above in this specification. For example, the computer device can execute the steps of each embodiment.
[0384] The program product may use any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of readable storage media (a non-exhaustive list) include: an electrical connection with one or more wires, a portable disk, 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 disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0385] The program product of the embodiment of the present application may adopt a portable compact disk read-only memory (CD-ROM) and include a computer program, and can be run on a computer device. However, the program product of the present application is not limited thereto. In the present application, the readable storage medium may be any tangible medium containing or storing a program, and the computer program included therein may be used by or in combination with a command execution system, apparatus or device.
[0386] A readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, wherein a readable computer program is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing. A readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with a command execution system, apparatus, or device.
[0387] The computer program embodied on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
[0388] Computer programs for performing the operations of the present application may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" language or similar programming languages.
[0389] It should be noted that, although several units or subunits of the device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to the embodiments of the present application, the features and functions of two or more units described above can be embodied in one unit. Conversely, the features and functions of one unit described above can be further divided into multiple units to be embodied.
[0390] In addition, although the operations of the method of the present application are described in a specific order in the drawings, this does not require or imply that the operations must be performed in this specific order, or that all the operations shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps.
[0391] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.
[0392] Although the preferred embodiments of the present application have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.
[0393] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.
Claims
1. A multi-party computing verification method based on blockchain, characterized in that: The method is applied to any verification node in a verification node cluster included in a multi-party computing system, wherein the multi-party computing system further includes a scheduling node cluster and a computing node cluster; the method includes: When the computing task is in a completed state, obtaining task event information of the computing task, the task event information including: signature information of the computing result of the computing task, and a random number seed provided by the task submitting end of the computing task; Using a first random number set derived from the random number seed, determining a first computing node set that should execute the computing task from a set of candidate computing nodes; Compare the first computing node set with the second computing node set actually executing the computing task indicated by the signature information to obtain a comparison result; wherein the second computing node set is selected from the candidate computing node set by the corresponding scheduling node using a second random number set derived based on the random number seed; Based on the comparison result, a legitimacy verification result of the second set of computing nodes is obtained, and based on the legitimacy verification result, a new block is generated in the corresponding blockchain.
2. The method according to claim 1, characterized in that Each verification node in the verification node cluster is connected to at least one scheduling node in the scheduling node cluster, and each scheduling node is uniquely connected to one verification node; Each scheduling node in the scheduling node cluster is connected to at least one computing node in the computing node cluster, and each computing node is uniquely connected to one scheduling node; or, The scheduling node cluster includes multiple scheduling node sub-clusters, each scheduling node sub-cluster includes N levels of scheduling nodes, the first level scheduling node connects the corresponding verification node and the next level scheduling node, the last level scheduling node connects the corresponding computing node and the previous level scheduling node, the i-th level scheduling node connects the i-1-th level scheduling node and the i+1-th level scheduling node, and i is a positive integer greater than 1 and less than N.
3. The method according to claim 1, characterized in that Using a first random number set derived from the random number seed to determine a first computing node set for executing the computing task from a set of candidate computing nodes includes: For each candidate computing node in the candidate computing node set, based on each evaluation value on the target resource attribute, respectively determine the random number interval range corresponding to each candidate computing node, and the random number interval ranges corresponding to each candidate computing node do not overlap with each other; Based on each first random number in the first random number set, perform the following operations: For each first random number, taking a candidate computing node corresponding to a random number interval in which the first random number is located as a first computing node; The first computing node set is generated based on the obtained first computing nodes.
4. The method according to claim 3, characterized in that Deriving the first set of random numbers based on the random number seed includes: The random number selection factor is initialized with the random number seed, and K rounds of iterative selection process are performed to obtain the first computing node set, where K is the number of computing nodes required for the computing task; wherein each round of selection process includes the following steps: Obtaining a random number corresponding to this round based on the sum of the evaluation values of the candidate computing node set and the random number selection factor used in this round; The random number selection factor used in the current round is updated to obtain the random number selection factor used in the next round.
5. The method according to claim 4, characterized in that Based on the sum of the evaluation values of the candidate computing node set and the random number selection factor used in this round, a corresponding random number is obtained, including: Taking the sum of the evaluation values as a divisor and the random number selection factor used in the current round as the current divisor, obtaining a remainder of the sum of the evaluation values with respect to the random number selection factor used in the current round; The remainder is determined as the random number corresponding to this round.
6. The method according to claim 4, characterized in that The random number selection factor used in the current round is updated to obtain the random number selection factor used in the next round, including: Perform hash value mapping processing on the cxth block in the blockchain to obtain a corresponding hash value; wherein c is the serial number of the latest block in the blockchain, and x is the number of rounds of the iterative selection process; Based on the hash value, the random number selection factor used in the current round is updated to obtain the random number selection factor used in the next round.
7. The method according to any one of claims 1 to 6, characterized in that: Using a first random number set derived from the random number seed to determine a first computing node set for executing the computing task from a set of candidate computing nodes includes: When the task event information is sent by the scheduling node connected to itself, obtaining signature information of the scheduling node for the task event information; Decrypting the signature information using the public key of the scheduling node to obtain first summary information of the task event information generated by the scheduling node; Extracting a summary of the task event information to obtain second summary information, and determining whether the signature information passes verification based on the first summary information and the second summary information; When the signature information passes the verification, a first set of random numbers derived from the random number seed is used to determine a first set of computing nodes for executing the computing task from a set of candidate computing nodes.
8. The method according to any one of claims 1 to 6, characterized in that: The method further comprises: Receive a scheduling node deployment request, the scheduling node deployment request carrying: identity information of a scheduling node to be deployed and interface information of an event notification interface; If the legitimacy verification of the identity information passes, then based on the interface information, an interface connectivity test is performed on the scheduling node; If the interface connectivity test passes, the scheduling node is added to the scheduling node cluster and a digital certificate is issued to the scheduling node; When the consensus verification of the digital certificate issuance result of the scheduling node by the verification node cluster is passed, sending a registration request for the event notification interface to the scheduling node, wherein the registration request is used to subscribe to a target type event from the scheduling node; When the registration is successful, a deployment success indication message is returned to the scheduling node, and the deployment success indication message carries the digital certificate.
9. A multi-party computing verification method based on blockchain, characterized in that: The method is applied to any scheduling node in a scheduling node cluster included in a multi-party computing system, wherein the multi-party computing system further includes a verification node cluster and a computing node cluster; the method includes: Receiving a computing request sent by a task submitting end, the computing request including: a random number seed provided by the task submitting end for a corresponding computing task; Obtain a set of candidate computing nodes for the computing task, and determine a second set of computing nodes for executing the computing task from the set of candidate computing nodes based on a second set of random numbers derived from the random number seed; Upon receiving a computing result obtained by each second computing node in the second computing node set executing the computing task, updating the computing task to a completed state; The random number seed and the signature information of the calculation result are sent to the verification node connected to itself, so that the verification node verifies the legitimacy of the second computing node set based on the random number seed and the signature information.
10. The method according to claim 9, characterized in that The method further comprises: Receive a computing node deployment request, the computing node deployment request carrying: identity information and resource configuration information of a computing device to be deployed; If the legitimacy verification of the identity information passes, determining whether the computing device meets the configuration requirements of the computing node based on the resource configuration information; If the configuration requirements are met, the computing device is added to the computing node cluster, and a node status table is updated with the computing device, wherein the node status table is used to store the node status of each computing node connected to the computing device; A digital certificate is issued to the computing device, and deployment success indication information is returned to the computing device, wherein the deployment success indication information carries the digital certificate.
11. A multi-party computing verification method based on blockchain, characterized in that: Applied to any computing node in a computing node cluster included in a multi-party computing system, the multi-party computing system also including a verification node cluster and a scheduling node cluster; the method includes: Receive a computing request sent by a scheduling node connected to itself, the computing request indicating: executing the computing task submitted by the task submitting end, and the second computing node set executing the computing task is a second random number set derived by the scheduling node based on a random number seed provided by the task submitting end, and is selected from a set of candidate computing nodes; Execute the computing task to obtain a corresponding computing result, and sign the computing result based on its own digital certificate to obtain corresponding signature information; The calculation result and the signature information are sent to the scheduling node, so that after the scheduling node sends the signature information to the corresponding verification node, the verification node can verify the legitimacy of the second computing node set based on the signature information.
12. A multi-party computing verification device based on blockchain, characterized in that: The device is applied to any verification node in a verification node cluster included in a multi-party computing system, wherein the multi-party computing system further includes a scheduling node cluster and a computing node cluster; the device includes: An event subscription unit, used for obtaining task event information of the computing task when the computing task is in a completed state, wherein the task event information includes: signature information of the computing result of the computing task, and a random number seed provided by the task submission end of the computing task; A node selection unit, configured to determine a first set of computing nodes that should execute the computing task from a set of candidate computing nodes by using a first set of random numbers derived from the random number seed; A comparing unit, configured to compare the first computing node set with a second computing node set actually executing the computing task indicated by the signature information, to obtain a comparison result; wherein the second computing node set is selected from the candidate computing node set by the corresponding scheduling node using a second random number set derived based on the random number seed; A verification unit is used to obtain a legitimacy verification result of the second set of computing nodes based on the comparison result, and generate a new block in the corresponding blockchain based on the legitimacy verification result.
13. A multi-party computing verification device based on blockchain, characterized in that: Applied to any scheduling node in a scheduling node cluster included in a multi-party computing system, wherein the multi-party computing system further includes a verification node cluster and a computing node cluster; The device comprises: Receiving a computing request sent by a task submitting end, the computing request including: a random number seed provided by the task submitting end for a corresponding computing task; Obtain a set of candidate computing nodes for the computing task, and determine a second set of computing nodes for executing the computing task from the set of candidate computing nodes based on a second set of random numbers derived from the random number seed; Upon receiving a computing result obtained by each second computing node in the second computing node set executing the computing task, updating the computing task to a completed state; The random number seed and the signature information of the calculation result are sent to the verification node connected to itself, so that the verification node verifies the legitimacy of the second computing node set based on the random number seed and the signature information.
14. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 8, 9 to 10 or 11 are implemented.
15. A computer storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method described in any one of claims 1 to 8, 9 to 10 or 11 are implemented.
16. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method described in any one of claims 1 to 8, 9 to 10 or 11 are implemented.
