Under-chain computing privacy protection method based on hierarchical excitation
By introducing off-chain computing privacy protection method based on hierarchical incentives in blockchain technology, the problem of possible dishonest behavior and lack of flexibility in incentive mechanisms in off-chain computing nodes is solved, and it is carried out through ring signature technology and trustworthy execution The environment protects the privacy of computing nodes, achieving fair distribution and efficient execution of computing tasks.
Patent Information
- Application Number
- CN202411552681.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-01
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-11-01
AI Technical Summary
In the prior art, off-chain computing nodes may obtain additional profits through fraud or dishonest behavior, and the incentive mechanism lacks flexibility and is difficult to adapt to changes in computing requirements and the urgency of tasks; at the same time, the identity information and task allocation of computing nodes The lack of privacy protection of information increases the risk of being attacked or manipulated.
Using off-chain computing privacy protection method based on hierarchical incentives, through smart contracts and blockchain verification computing tasks, the computing node participates in the calculation by selecting tasks matching the level, and uses ring signature technology and trustworthy execution of environmental protection computing nodes. Identity privacy and task assignment information.
Ensure the fair distribution of computing tasks and rewards, improve the utilization rate of computing nodes and task execution efficiency, adapt to the dynamic changes of computing nodes and computing tasks in the blockchain system, and protect the privacy of the identity of computing nodes and task allocation information.
Smart Images

Figure CN119420484A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of blockchain, and specifically relates to an off-chain computing privacy protection method based on layered incentives. Background Art
[0002] With the rapid growth of blockchain technology, it faces huge challenges in scalability and efficiency. Off-chain computing solves the problems of blockchain by moving task processing outside the blockchain environment; on the one hand, it uses off-chain computing nodes with sufficient computing resources and processing power to increase transaction processing speed, thereby improving the scalability and efficiency of blockchain, especially in large-scale computing scenarios; on the other hand, it combines off-chain computing with cryptographic methods such as zero-knowledge proof, homomorphic encryption, and secure multi-party computing to promote blockchain scalability while protecting data privacy. In addition, the Trusted Execution Environment (TEE) also provides a secure execution environment for off-chain computing, ensuring that the code and data on the off-chain computing nodes are protected from malicious tampering or theft. With the support of the above cutting-edge technologies, off-chain computing has been regarded as one of the promising technologies to enhance the scalability of blockchain and support its widespread application.
[0003] In addition to the above-mentioned cutting-edge technologies for off-chain computing, incentive mechanisms play a special role in ensuring the trusted behavior and active participation of off-chain nodes. Although off-chain computing improves the scalability of blockchain, off-chain computing nodes may try to obtain additional profits through fraud, data tampering, or other dishonest behaviors. To ensure the correct execution of computing tasks during off-chain computing, incentive mechanisms have become a promising solution that can effectively constrain the behavior of computing nodes, making malicious behavior costly and honest behavior the optimal choice. In addition, incentive mechanisms can also encourage off-chain computing nodes to actively participate in off-chain computing, thereby ensuring that sufficient computing resources are provided for the blockchain. In recent years, related work has been devoted to studying incentive mechanisms for decentralized outsourced computing, such as incentive mechanisms in blockchain-based crowdsourcing and crowdsensing, which outsource computing tasks to workers outside the blockchain environment, while the blockchain is responsible for the management and public audit of crowdsourcing and crowdsensing systems. According to the allocation method of computing resources, the related work can be divided into two categories: market mechanism and auction algorithm; in the market mechanism, computing nodes independently select the computing tasks of interest, and submit the computing results to the verification nodes after completing the calculations off-chain, and the blockchain is ultimately responsible for auditing and settlement; in the auction algorithm, computing nodes bid for the qualification to perform computing tasks, and the blockchain selects the most suitable computing nodes according to different auction rules. However, among the existing schemes, some schemes do not fully consider the fairness of task allocation, resulting in some computing nodes may monopolize resources, while other nodes may feel marginalized and treated unfairly, thereby reducing their participation enthusiasm and contribution. Some methods focus on fixed allocation strategies and preset incentives, which makes the incentive mechanism lack the necessary flexibility and difficult to adapt to changes in computing needs and the urgency of tasks, thus affecting the stable participation of high-quality computing nodes and the response to complex and urgent tasks. In addition, although the existing schemes use blockchain addresses to provide anonymity for computing nodes, they still lack privacy protection for computing node identity information and task allocation information, which may cause nodes to face the risk of identity association or leakage when performing tasks, and make task allocation information easily accessible to attackers, increasing the risk of targeted attacks or manipulation of task results.
[0004] Therefore, there is an urgent need to provide an off-chain computing privacy protection method based on layered incentives to improve the defects in existing technologies. Summary of the invention
[0005] In order to solve the above problems existing in the prior art, the present invention provides a privacy protection method for off-chain computing based on hierarchical incentives. The technical problem to be solved by the present invention is achieved through the following technical solutions:
[0006] In a first aspect, the present invention provides a method for protecting privacy of off-chain computing based on hierarchical incentives, comprising:
[0007] The requesting node publishes computing tasks to the blockchain through smart contracts;
[0008] The blockchain verifies and publishes computing tasks;
[0009] Computing nodes select computing tasks that match their levels through smart contracts and participate in the acceptance of computing tasks;
[0010] A random selection algorithm is used to select any computing node from the same computing node level as the executor. The computing nodes other than the executor in the same computing node level use the auction information encrypted by the public key and the private key to generate a ring signature. After the ring signature is verified, the computing node sends the auction information to the executor's trusted execution environment, executes the task allocation process in the trusted execution environment, and feeds back the allocation result to the computing node.
[0011] The computing node completes the computing task and feeds back the computing results to the blockchain; among them, the executor can also be the computing node that executes the task.
[0012] Beneficial effects of the present invention:
[0013] The present invention provides an off-chain computing privacy protection method based on hierarchical incentives, which has the following beneficial effects:
[0014] 1. The present invention proposes a hierarchical incentive framework, which divides computing nodes and computing tasks into different levels according to their attributes. Multiple levels synchronously execute the allocation of computing tasks. By designing a hierarchical incentive mechanism for fair distribution of tasks, the fair distribution of computing tasks and rewards is ensured, and the off-chain computing resources can be reasonably allocated to adapt to the dynamic changes of computing nodes and computing tasks in the blockchain system, thereby improving the utilization rate of computing nodes and the efficiency of task execution.
[0015] 2. The present invention designs a secure and privacy-preserving task allocation method, which protects the identity privacy of computing nodes and the information privacy of task allocation by adopting ring signature technology and a trusted execution environment.
[0016] The present invention will be further described in detail below with reference to the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 It is a flow chart of an off-chain computing privacy protection system based on hierarchical incentives provided by an embodiment of the present invention;
[0018] Figure 2 It is a flow chart of the off-chain computing privacy protection method based on hierarchical incentives provided by an embodiment of the present invention;
[0019] Figure 3It is a schematic diagram of an off-chain computing privacy protection method based on layered incentives provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0020] The present invention is further described in detail below with reference to specific embodiments, but the embodiments of the present invention are not limited thereto.
[0021] See also Figure 1 , Figure 1 This is a flow chart of a privacy protection system for off-chain computing based on hierarchical incentives provided by an embodiment of the present invention. The present invention involves three entities, namely, a requesting node, a computing node and a blockchain node. The requesting node Compute Node The computing task issued by the requesting node is Computing tasks require computing nodes to be executed off-chain; specifically, each computing task needs to be completed by a specific computing node, and different computing nodes have different expertise and computing resources and are capable of performing some of these computing tasks; in addition, the computing costs of different computing nodes performing the same task may also be different.
[0022] Requesting nodes are system entities that request data-intensive tasks from the blockchain. Incentives in the form of certain compensation are provided to encourage computing nodes to actively engage in off-chain computing in order to obtain high-quality blockchain services.
[0023] Computing nodes, based on their own computing power and current availability, select computing tasks that match their interests. Computing nodes perform assigned computing tasks off-chain and generate computing results. After the computing results are verified and packaged into the blockchain, the computing nodes will receive rewards from the requesting nodes. It is worth noting that some computing nodes need to deploy a trusted execution environment locally to perform task assignments, and these computing nodes need to register the trusted execution environment on the blockchain to ensure a secure execution environment.
[0024] Blockchain nodes are responsible for task-related verification operations, such as issuing computing tasks, allocating computing tasks and computing results, and are also responsible for packaging verified transactions and generating blocks.
[0025] All request nodes and computing nodes of the system provided by the present invention are registered in the blockchain to request system services related to tasks (such as publishing and requesting computing tasks); after completing the registration, the requesting node can upload the pending computing tasks to the blockchain and describe the tasks in detail. The blockchain node verifies and publishes these tasks; the task allocation process is executed in a secure manner in the trusted execution environment of the computing node, and the task allocation results will be returned to the computing node; the selected computing node completes the computing task and submits the computing results before the deadline; after the blockchain node successfully verifies the results, the smart contract will automatically transfer the reward to the computing node.
[0026] The system provided by the present invention ensures the safe and stable operation of the system by defining the economic model and security model of the system; wherein,
[0027] The present invention establishes an economic model to quantitatively analyze the utility of system entities, including the impact of rewards, costs and incentive mechanisms.
[0028] Request Node R i After completing the calculation task T k After the benefit V i k The requesting node also needs to send the calculation node C j Provide incentives And pay the transaction fee F to the blockchain node i k In order to ensure that all nodes have something to gain, it can be determined Therefore, R i The utility function The definition is as follows:
[0029]
[0030] By introducing Represents the computational task T k Is it assigned to the computing node C? j Specifically, Indicates T k Assigned to C j , Indicates T k Not assigned to C j In addition, the introduction Represents C j Have you completed T k ,here, Represents C j Completed T k , Represents C j Not completed T k .
[0031] Compute Node C j From the requesting node R i receive C j Execute computing task T k The cost of express, Represents C j To execute T k Therefore, assuming K is the total number of tasks, the utility function of the computing node can be The definition is as follows:
[0032]
[0033] Assume that the computation task T k The completion of tasks will provide incentives to participants and will also contribute to social welfare by improving time efficiency, high task execution rate or other social value indicators. k Brings additional value. Therefore, the social welfare function can be expressed as the sum of utility and social welfare, as follows:
[0034]
[0035] The present invention ensures the safety and efficiency of the system by establishing a safety model.
[0036] 1. Blockchain security, assuming that the blockchain itself is secure, has no vulnerabilities or design flaws, and is therefore a trustworthy platform that can perform its intended functions without being vulnerable to potential attacks.
[0037] 2. Communication security, assuming that the information sent and received by both parties has not been tampered with during the transmission process. In addition, the receiver can verify that the content of the received information is exactly the same as the content of the information sent by the sender. This assumption can be ensured by applying secure communication protocols, such as Secure Sockets Layer and Transport Layer Security.
[0038] 3. Key security, assuming that the generation and distribution of relevant keys are secure and will not be attacked or cracked. This can be achieved by adopting a secure key distribution scheme, such as the Diffie-Hellman protocol, which can ensure that the key is securely transmitted between the communicating parties.
[0039] 4. Trusted Execution Environment Security: It is assumed that the code executed in the TEE is completely trusted, which means that the TEE can process and store confidential data securely and will not be compromised even under physical attacks. In addition, we also assume that there is a secure communication channel connecting the computing node and the TEE. This is usually achieved by adopting a strong encryption protocol to ensure the security of data during transmission.
[0040] The threat models that the system of the present invention may receive include the following:
[0041] 1. Collusion attack, where multiple computing nodes collude with each other to gain unfair competitive advantages and benefits. Colluding nodes may manipulate the task allocation process to ensure that the most advantageous and manageable tasks are assigned to them. On the contrary, more complex or less profitable tasks are assigned to non-colluding nodes.
[0042] 2. Replay attack, malicious computing nodes may impersonate legitimate nodes and replay their results by strategically resubmitting this information to the system to imitate real activities. This type of replay attack causes the system to repeat processing and incur unnecessary computing overhead.
[0043] 3. Free-rider attack: Malicious computing nodes may choose to perform only a few tasks or submit false contribution proofs to launch a free-rider attack. The attacker's goal is to obtain the maximum benefit from the system while minimizing the resources and energy spent. Therefore, despite minimal or no contribution, the attacker can receive the deserved reward like an honest node.
[0044] See also Figure 2 and Figure 3 , Figure 2 is a flow chart of an off-chain computing privacy protection method based on hierarchical incentives provided by an embodiment of the present invention. Figure 3 : is a schematic diagram of an off-chain computing privacy protection method based on hierarchical incentives provided by an embodiment of the present invention. The off-chain computing privacy protection method based on hierarchical incentives provided by the present invention includes:
[0045] The computing node and the requesting node apply for registration request to the blockchain, specifically:
[0046] Request Node R i Submit a registration request to the blockchain;
[0047] Request Node R i Use encryption algorithm to generate registration information, namely public key pk i and private key sk i ;
[0048] Request Node R i Submit the public key pk to the blockchain through a smart contract i and the required registration information, blockchain public key pk i and required registration information for verification;
[0049] If the verification is successful, the blockchain will i Record and request node R i Assign identifier R n _id and trust value Tv i , to complete the request node R i Registration request on the blockchain.
[0050] Compute Node C j Submit a registration request to the blockchain;
[0051] Compute Node C j Use encryption algorithm to generate registration information, namely public key pkj and private key sk j ;
[0052] Compute Node C j Submit the public key pk to the blockchain through a smart contract j and the required registration information, blockchain public key pk j and required registration information for verification;
[0053] If the verification is successful, the blockchain will j Record and calculate node C j Assign identifier C n _id and trust value Tv j , to complete the registration request of the computing node in the blockchain.
[0054] Optionally, when the requesting node and the computing node apply for registration requests to the blockchain, the public key and the private key are generated using the elliptic curve cryptography algorithm.
[0055] After the request node and computing node are registered on the blockchain, they can participate in various network activities, such as publishing tasks, querying tasks, and bidding tasks.
[0056] S101. The requesting node publishes a computing task to the blockchain through a smart contract.
[0057] Specifically, in this embodiment, the requesting node publishes a computing task to the blockchain through a smart contract, including:
[0058] Request Node R i Interact with the smart contract, which will calculate the task T k and task requirements are uploaded to the blockchain; the task requirements include computing tasks T k Resource consumption RC k and the computation task T k Deadline for DL k ;
[0059] At the same time, in order to reduce the risk of payment rejection and denial of service attacks, the request node R i The computing task T released for it k Providing security deposit to smart contracts Smart contract locks deposit
[0060] Blockchain Verification Bond The validity of the request node R i Feedback identifier task_id until the blockchain calculates the task T k If verification succeeds, the smart contract will deposit Return to the requesting node Ri .
[0061] S102. The blockchain verifies the computing task and publishes the computing task.
[0062] Specifically, in this embodiment, in the task publishing stage, the requesting node publishes the computing task to the blockchain through a smart contract, so that the computing node can clearly understand the task requirements.
[0063] S103. The computing node selects computing tasks that match its level through smart contracts and participates in receiving computing tasks.
[0064] Specifically, in this embodiment, considering the unfair task allocation process of the existing scheme, nodes with a large amount of computing resources tend to obtain as many computing tasks and rewards as possible, while computing nodes with scarce resources find it difficult to survive. On the one hand, unfair task allocation reduces the utilization rate of computing nodes, resulting in a decrease in node participation, which is not conducive to the participation of new nodes and the active contribution of computing nodes with limited resources. On the other hand, if most of the computing resources are monopolized by a few nodes, the entire network may fall into centralization risks. This is contrary to the core principle of decentralization of blockchain and may lead to problems inherent in centralization, such as single point failures. In view of this, the present invention proposes the concept of hierarchical construction. Hierarchical construction mainly involves hierarchical division of computing nodes and computing tasks to improve the rationality of computing task allocation, and divides them into different node layers and task layers according to the level values of computing nodes and computing tasks; first, it is necessary to construct a computing task hierarchy and a computing node hierarchy, including:
[0065] According to the level values of multiple preset computing tasks, Z computing task levels are divided, and according to the level values of multiple preset computing nodes, Z computing node levels are divided; the computing task level corresponds to the computing node level one by one, and the computing nodes in the corresponding computing node level receive the computing tasks in the task level. The computing task level set and the computing node level set are expressed as
[0066] The expression of the level value of the preset calculation task is:
[0067]
[0068] in, Indicates the level value of the preset computing task, RC k Indicates the resource consumption of computing tasks, DL k Indicates the deadline of the computing task, WT k Indicates the waiting time, which indicates the preset computing task T kThe interval from the release time to the current time reflects the system activity and node participation, ensuring that computing tasks are processed in a timely and effective manner.
[0069] According to the calculation node C j The impact of trust value decay on the level value, and the calculation of node C j Performance in the previous cycle. Performance is calculated based on the number of completed computing tasks, timeliness, and success rate of computing task completion. Timeliness quantifies the performance of computing nodes C. j Complete the calculation task T k The efficiency of the preset computing node is obtained by calculating the level value, which is expressed as:
[0070]
[0071] in, represents the level value of the preset computing node, β represents the decay factor, and Δt represents the trust value Tv j Update time interval, trust value Tv j is the trust value of the previous cycle, K represents the number of computing tasks, k represents the index of the computing task, and SR j Indicates the calculation node C in the previous cycle j The success rate of completing computing tasks, that is, the ratio of the number of completed computing tasks to the total number of computing tasks accepted, Represents the computing node C j Whether to accept the computing task T k , When it is 1, it means receiving. When it is 0, it means that the call is not received. k Represents the computational task T k Current time, RT k Represents the computational task T k The remaining time, DL k Indicates the deadline for the computation task.
[0072] It is understandable that during the hierarchical construction phase, the computing node C j and the computation task T k Initially, a grade value Ra is assigned to each. j and T k They are divided into specific computing node level and computing task level. Specifically, the function Layer C (Cj) and Layer T (Tk) represents the node level where Cj is located and T k The task level you are at. j It can only execute the computing tasks corresponding to the task layer, while T kIt can only be accessed and executed by computing nodes in the matching node layer. In addition, in order to adapt to the timeliness of computing tasks and the dynamic nature of computing nodes, a system variable with an update period of ε is introduced. ε is set in units of block height, which ensures that the update operation is closely synchronized with the blockchain state. The level values of computing nodes and tasks are updated in each cycle to ensure that the system adapts to changes in real time and adjusts the task allocation strategy accordingly. It should be noted that if C j After completing the registration in the current cycle, it can only bid for computing tasks in the next cycle.
[0073] In this embodiment, the computing node selects computing tasks that match its level through smart contracts, including:
[0074] For an update cycle ε, determine the calculation task T k Whether the deadline arrives before the next update cycle;
[0075] If it has not arrived, get the computing task T k The level value of the calculation task T k Corresponding computing task layer T (T k ) and determine the corresponding computing node layer Layer C (C j ), the corresponding computing node layer Layer C (C j ) receives the computing task T k ;
[0076] If it arrives, the computing task is divided into the common layer pub , all computing nodes C j All can accept the computing task T k .
[0077] It is understandable that the hierarchical division ensures that the computing nodes in a certain node layer can only undertake computing tasks in the corresponding task layer. It is worth noting that the deadlines of some computing tasks are shorter than the update period ε, which means that these computing tasks will reach the deadline before the next update period begins and may not attract computing nodes to participate in the bidding. Considering that these tasks may not be suitable for being divided into task layers, these tasks are assigned to the public task layer. pub , enabling all computing nodes to participate in the auction, thereby greatly increasing the chances of these computing tasks being selected.
[0078] In this embodiment, the computing nodes participate in receiving computing tasks, including:
[0079] Compute Node C j Accept the computing task T for itk Providing security deposit to smart contracts Smart contract locks deposit For the compute node C that was not successfully connected j , Margin Return to computing node C through smart contract j ; For the successfully connected computing node C j , after completing the calculation task T k After that, the deposit Return to computing node C through smart contract j .
[0080] S104. Use a random selection algorithm to select any computing node from the same computing node level as the executor. The computing nodes other than the executor in the same computing node level use the auction information encrypted by the public key and the private key to generate a ring signature. After the ring signature is verified, the computing node sends the auction information to the executor's trusted execution environment, executes the task allocation process in the trusted execution environment, and feeds back the allocation result to the computing node.
[0081] Specifically, in this embodiment, the task allocation in each computing node layer is completed by Vickrey-Clarke-Groves (VCG) combinatorial auction. During the auction, the computing node can make a combined bid for the computing tasks in the corresponding task layer, while considering the cost and expected profit of completing the computing tasks. Before participating in the auction, each computing node must lock a security deposit in the task settlement contract. This ensures the integrity of the node throughout the bidding process and prevents malicious bidding or withdrawal. For computing nodes that do not win the auction, the security deposit will be automatically refunded through the task settlement contract. Computing nodes that complete the task will receive rewards and deposit refunds. In addition, the present invention uses ring signature technology to protect the identity of computing nodes and transfers the auction algorithm to a trusted execution environment to maintain the security of the task allocation process and the confidentiality of the allocation results. Next, z Take as an example to illustrate the task allocation process of preserving privacy.
[0082] In this embodiment, it is considered that the existing technical solutions lack comprehensive privacy protection, including the identity privacy of computing nodes and data privacy in task allocation. The lack of identity information and data privacy exposes security threats and makes computing nodes vulnerable to attacks such as free riding and collusion. These threats provide convenience for attackers, allowing them to identify and target specific nodes for strategic manipulation or malicious collaboration. The present invention also includes:
[0083] Deploy a trusted execution environment locally on the computing node and register the trusted execution environment on the blockchain;
[0084] The trusted execution environment integrates the auction algorithm, and the computing task allocation process is completed in the trusted execution environment.
[0085] Specifically, computing nodes are randomly selected as executors from the same computing node hierarchy according to the trust ratio, and are marked as Executors in the same compute node hierarchy Deploy a trusted execution environment locally with the computing node and generate a public key in the trusted execution environment and private key And the public key Public; It should be noted that the higher the trust ratio, the greater the probability of being selected as an executor. The trust ratio is the ratio of the trust value of the computing node to the total trust value of all computing nodes;
[0086] All computing nodes in the same computing node level participate in the acceptance of computing tasks, marked as Compute Node When applying for registration to the blockchain, the registration information generated is the public key pk u and private key sk u , u∈(1,U), U represents the total number of computing nodes in the same computing node level;
[0087] Compute Node Generate auction information in auction algorithm And call the encryption function Enc(), using the private key Auction Information Encrypt and generate ciphertext Ciphertext Used as a ring signature message, As a ring member;
[0088] Compute Node Call the ring signature generation function SignGen(), using the public key pk u , generate Sign u , and verify the Sign through the ring signature verification contract u If the verification is qualified, the ring signature verification contract will verify the authenticity of the public key pk u and ciphertext Send to executor Trusted execution environment, executor Call the decryption function Dec(), using the private key Ciphertext Decrypt to retrieve
[0089] Executor Allocate computing tasks based on the auction information generated by computing nodes in the same computing node level, and generate task allocation results Executor Call the encryption function Enc(), using the public key pk u Assigning results to tasks Encrypt and generate ciphertext And feedback to the computing node
[0090] Compute Node Call the decryption function Dec(), using the private key sk u Ciphertext Decrypt to retrieve
[0091] It is understandable that computing node C j In l z There are two key events that may occur in C. The first event occurs at j The node is selected to execute the auction algorithm in the trusted execution environment. The second incident involves C j Submitting bidding information to participate in auctions and off-chain calculations is represented as u∈(1,U). Therefore, when C j When u is selected to execute the auction algorithm and participate in the bidding at the same time, u=s. The probability of being selected is its trust value Tv s With l Z The ratio of the total trust value of all nodes in , that is:
[0092]
[0093] S105. The computing node completes the computing task and feeds back the computing result to the blockchain; wherein the executor can also be the computing node that executes the task.
[0094] Specifically, in this embodiment, considering that most of the existing technical solutions adopt fixed incentive strategies and fail to flexibly adjust according to the real-time status and task characteristics of the computing nodes, the rigidity of this mechanism may result in the inability to effectively incentivize all nodes when the system environment and node status change. Usually, the behavior of nodes will change due to strategic adjustments and changes in economic interests. Considering that computing tasks usually have different priorities, dynamically adjusting incentive strategies, especially incentive strategies for off-chain computing, can more effectively optimize task allocation and improve overall computing efficiency. The present invention proposes a clear reward mechanism, specifically:
[0095] Compute Node After all computational tasks are completed, the computational results are submitted to the smart contract. Then, the relevant requesting nodes need to pay the smart contract. The number of requesting nodes involved depends on the number of nodes allocated to the smart contract. Once the calculation result is verified, the smart contract will and Provide incentive strategies while placing security deposits Return to According to the VCG combinatorial auction rules, the winning player's income depends on the impact of his participation on the potential income of other players. Specifically, the winning player (computing node C j ) The income obtained B j The calculation is as follows:
[0096] Bj=hj-(bid(S)-bid(S / {j}));
[0097] In the above formula, bid(S) is the total value of all winners, that is, the sum of all winners' bids. bid(S / {j}) represents the maximum total value of the remaining winners after removing Cj. In addition, hj is defined as the maximum total value of the bids of other computing nodes when Cj does not participate in the auction. According to the formula, Revenue B j . Will receive B j As a reward for facilitating task allocation, namely:
[0098]
[0099] Here, ρ represents the basic reward ratio to prevent unexpectedly high rewards due to excessively high trust value ratios. i After payment is completed, the task release contract will return the deposit And return the calculation result to R i .
[0100] In summary, the off-chain computing privacy protection method based on hierarchical incentives provided by the present invention has the following beneficial effects:
[0101] (1) The present invention proposes a hierarchical incentive framework, which divides computing nodes and computing tasks into different levels according to their attributes. Multiple levels synchronously execute the allocation of computing tasks. By designing a hierarchical incentive mechanism for fair task allocation, the fair allocation of computing tasks and rewards is ensured, and the off-chain computing resources can be reasonably allocated to adapt to the dynamic changes of computing nodes and computing tasks in the blockchain system, thereby improving the utilization rate of computing nodes and the efficiency of task execution.
[0102] (2) The present invention designs a flexible incentive mechanism that dynamically adjusts rewards based on factors such as node contribution, task resource consumption, and deadline, so that tasks are adapted to appropriate computing nodes, thereby improving computing efficiency.
[0103] (3) The present invention designs a secure and privacy-preserving task allocation method, which protects the identity privacy of computing nodes and the information privacy of task allocation by adopting ring signature technology and a trusted execution environment.
[0104] In an optional embodiment of the present invention, the off-chain computing privacy protection method based on hierarchical incentives provided in the above embodiment of the present invention can be applied to medical data management and sharing, smart grid energy management, and large-scale data crowdsourcing computing.
[0105] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is any such actual relationship or order between these entities or operations. Moreover, the term "include", "comprise" or any other variant is intended to cover non-exclusive inclusion, so that the article or device including a series of elements includes not only those elements, but also other elements that are not explicitly listed. In the absence of more restrictions, the elements defined by the sentence "including one..." do not exclude the existence of other identical elements in the article or device including the elements. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. The orientation or position relationship indicated by "up", "down", "left", "right", etc. is based on the orientation or position relationship shown in the accompanying drawings, which is only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation of the present invention.
[0106] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification.
[0107] The above contents are further detailed descriptions of the present invention in combination with specific preferred embodiments, and it cannot be determined that the specific implementation of the present invention is limited to these descriptions. For ordinary technicians in the technical field to which the present invention belongs, several simple deductions or substitutions can be made without departing from the concept of the present invention, which should be regarded as falling within the protection scope of the present invention.
Claims
1. A privacy protection method for off-chain computing based on hierarchical incentives, characterized in that: include: The requesting node publishes computing tasks to the blockchain through smart contracts; The blockchain verifies the computing task and publishes the computing task; The computing node selects the computing task that matches its level through the smart contract and participates in the acceptance of the computing task; A random selection algorithm is used to select any computing node from the same computing node level as an executor, and the computing nodes other than the executor in the same computing node level use the auction information encrypted by the public key and the private key to generate a ring signature. After the ring signature is verified, the computing node sends the auction information to the trusted execution environment of the executor, executes the task allocation process in the trusted execution environment, and feeds back the allocation result to the computing node; The computing node completes the computing task and feeds back the computing result to the blockchain; wherein the executor may also be the computing node that executes the task.
2. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: Also includes: The requesting node R i Submitting a registration request to the blockchain; The requesting node R i Use encryption algorithm to generate registration information, namely public key pk i and private key sk i ; The requesting node R i Submit the public key pk to the blockchain through a smart contract i and the required registration information, the blockchain has a public key pk i Verify the required registration information; If the verification is successful, the blockchain will i Record and provide the request node R i Assign identifier R n _id and trust value Tv i , to complete the request node R i A registration request on said blockchain.
3. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: Also includes: The computing node C j Submitting a registration request to the blockchain; The computing node C j Use encryption algorithm to generate registration information, namely public key pk j and private key sk j ; The computing node C j Submit the public key pk to the blockchain through a smart contract j and the required registration information, the blockchain has a public key pk j Verify the required registration information; If the verification is successful, the blockchain will j Record and calculate the node C j Assign identifier C n _id and trust value Tv j , to complete the registration request of the computing node in the blockchain.
4. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: The requesting node publishes a computing task to the blockchain through a smart contract, including: The requesting node R i Interact with the smart contract, and the smart contract converts the computing task T k and task requirements are uploaded to the blockchain; wherein the task requirements include computing tasks T k Resource consumption RC k and the computation task T k Deadline for DL k ; At the same time, the requesting node R i The computing task T released for it k Provide security deposit to said smart contract The smart contract locks the deposit The blockchain verifies the security deposit validity and sends the requesting node R i Feedback identifier task_id until the blockchain completes the computation task T k If the verification is successful, the smart contract will Return to the requesting node R i .
5. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: Also includes: Construct computing task level and computing node level; According to the level values of multiple preset computing tasks, Z computing task levels are divided, and according to the level values of multiple preset computing nodes, Z computing node levels are divided; The computing task level corresponds to the computing node level one by one, and the computing nodes in the corresponding computing node level can receive the computing tasks in the task level. The computing task level set and the computing node level set are expressed as The expression of the level value of the preset computing task is: in, Indicates the level value of the preset computing task, RC k Indicates the resource consumption of computing tasks, DL k Indicates the deadline of the computing task, WT k represents the waiting time, which represents the preset computing task T k The interval from the release time to the current time; The expression of the level value of the preset calculation node is: in, represents the level value of the preset computing node, β represents the decay factor, and Δt represents the trust value Tv j Update time interval, the trust value Tv j is the trust value of the previous cycle, K represents the number of computing tasks, k represents the index of the computing task, and SR j Indicates the calculation node C in the previous cycle j The success rate of completing the calculation task, Represents the computing node C j Whether to accept the computing task T k , CT k Represents the computational task T k Current time, RT k Represents the computational task T k The remaining time, DL k Indicates the deadline for the computation task.
6. The off-chain computing privacy protection method based on hierarchical incentives according to claim 5 is characterized in that: The computing node selects the computing task that matches its level through a smart contract, including: For an update cycle ε, determine the computing task T k Whether the deadline arrives before the next update cycle; If it has not arrived, get the computing task T k The level value determines the computing task T k Corresponding computing task layer T (T k ) and determine the corresponding computing node layer Layer C (C j ), the corresponding computing node layer Layer C (C j ) receives the computing task T k ; If it is reached, the computing task is divided into the common layer pub , all computing nodes C j can all accept the computing task T k .
7. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: The computing node participates in the allocation process of computing tasks, including: The computing node C j It accepts the computing task T k Provide security deposit to said smart contract The smart contract locks the deposit For the computing node C that was not successfully connected j , the security deposit Return to the computing node C through the smart contract j ; For the computing node C that is successfully accessed j , after completing the computing task T k After that, the deposit Return to the computing node C through the smart contract j .
8. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: Also includes: Deploy a trusted execution environment locally on the computing node, and register the trusted execution environment on the blockchain; The computing task allocation process is completed in the trusted execution environment, and the allocation result is returned to the computing node.
9. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: The method comprises: selecting any computing node from the same computing node level as an executor by using a random selection algorithm, generating a ring signature by using the auction information encrypted by a public key and a private key by the computing nodes other than the executor in the same computing node level, sending the auction information to the trusted execution environment of the executor after the ring signature is verified, executing the task allocation process in the trusted execution environment, and feeding back the allocation result to the computing node, including: The computing node is randomly selected as the executor from the same computing node level according to the trust ratio, and is marked as Executors in the same compute node hierarchy The computing node locally deploys a trusted execution environment and generates a public key in the trusted execution environment and private key and the public key public; All the computing nodes in the same computing node layer participate in the acceptance of the computing task, marked as The computing node When applying for a registration request to the blockchain, the registration information generated is the public key pk u and private key sk u , u∈(1,U), U represents the total number of computing nodes in the same computing node level; The computing node Generate auction information And call the encryption function Enc(), using the private key Auction information Encrypt and generate ciphertext The ciphertext Used as a ring signature message, As a ring member; The computing node Call the ring signature generation function SignGen(), using the public key pk u , generate Sign u , and verify the Sign through the ring signature verification contract u If the verification is qualified, the ring signature verification contract will verify the authenticity of the public key pk u and the ciphertext Send to executor Trusted execution environment, the executor Call the decryption function Dec(), using the private key For the ciphertext Decrypt to retrieve The executor Allocate computing tasks based on the auction information generated by computing nodes in the same computing node level, and generate task allocation results The executor Call the encryption function Enc(), using the public key pk u Assigning results to the tasks Encrypt and generate ciphertext and fed back to the computing node The computing node Call the decryption function Dec(), using the private key sk u For the ciphertext Decrypt to retrieve 10. The off-chain computing privacy protection method based on hierarchical incentives according to claim 1 is characterized in that: After the computing node completes the computing task, the method further includes: The computing node Complete the calculation task T k After that, the calculation result is submitted to the blockchain through the smart contract, and the requesting node executes the settlement process through the smart contract; The smart contract provides the executor and compute nodes Provide incentive strategies and Return to the computing node The computing node The income of B j The expression is: Bj=hj-(bid(S)-bid(S / {j})); The executor The expression of the profit is: Where bid(S) represents the total value of all winners, and bid(S / {j}) represents the elimination of computing node C. j After that, the maximum total value of the remaining winners, h j Represents the computing node C j The maximum total value of bids from other computing nodes when not participating in the computing task. ρ represents the basic reward ratio.
Citation Information
Patent Citations
Blockchain-based personalized k-anonymity privacy protection motivation method
CN107483211A
Excitation method for K anonymous position privacy protection based on blockchain smart contract
CN110557375A
Bank asset anonymous auction system and auction method based on block chain
CN114897602A
Block chain task allocation method and device
CN114979160A
Crowdsourcing system based on incentive mechanism for optimizing crowdsourcing timeliness and improving welfare
CN117350802A