Data sharing method based on cooperative game and computer device

By introducing a cooperative game mechanism into the blockchain network and utilizing reputation points and adaptive incentive adjustments, the problem of data authenticity and integrity caused by node distrust is solved, achieving high quality and security for the data sharing database.

CN116346830BActive Publication Date: 2026-02-03浙江环玛信息科技有限公司
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202310156050.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-02-23
Publication Date
2026-02-03
Estimated Expiration
2043-02-23

AI Technical Summary

Technical Problem

In blockchain networks, due to the lack of trust between nodes and their self-interested behavior, there is little participation in data consensus, making it difficult to guarantee the authenticity and integrity of data. Furthermore, nodes are vulnerable to attacks, leading to data quality issues in shared databases.

Method used

By using a data sharing method based on cooperative game theory, a success and failure payoff matrix is ​​constructed using reputation points provided by the client to incentivize nodes to participate in consensus. Furthermore, the authenticity and integrity of uploaded data are ensured through multi-dimensional authenticity assessment and adaptive adjustment of incentive parameters.

Benefits of technology

It improves the authenticity and stability of data within the blockchain shared database, enhances the participation of nodes, improves the ability to prevent attacks, and ensures data quality and the security of the shared database.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116346830B_ABST
    Figure CN116346830B_ABST
Patent Text Reader

Abstract

The application provides a data sharing method and computer equipment based on cooperative game, which comprises that a client initiates a data uploading request to a master node and provides credit points representing service fees; based on the credit points provided by the client, the master node constructs a game success income matrix and a game failure income matrix between any two nodes in the current round of cooperative consensus, and broadcasts the data uploading request to other nodes in the blockchain to initiate consensus; if the consensus is successful, all nodes participating in the consensus are allocated with integral income based on the game success income matrix, and the client initiating the data uploading request is matched with a credit value based on a preset credit distribution rule; if the consensus fails, all nodes participating in the consensus are allocated with integral rewards based on the game failure income matrix; wherein each client accesses a shared database formed after data is uploaded to the chain based on the credit value corresponding to the client, and downloads data in the shared database based on the credit points corresponding to the client.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of blockchain, and in particular to a data sharing method and computer device based on cooperative game theory. Background Technology

[0002] With the continuous development of computer technology, the construction of smart cities based on intelligent computing technologies such as the Internet of Things, blockchain, cloud computing, and big data has become the main direction of current urban and public service construction. The interconnection of multiple platforms and departments enables data sharing between different parts. However, currently, data within each department is not publicly available, and other departments still need various administrative approvals to access it, which is not only cumbersome but also inefficient.

[0003] To address this issue, some have proposed building data sharing systems based on the decentralization and tamper-proof nature of blockchain. Taking a government-court collaboration platform as an example, such a platform comprises a blockchain network of various nodes, including courts at all levels, procuratorates, other government departments, lawyers, and litigants. However, in practical applications, due to the lack of trust between nodes and their self-interested behavior, they are reluctant to actively participate in data consensus. A small number of participating nodes not only makes it difficult to guarantee the authenticity and integrity of the data uploaded, but also makes nodes highly vulnerable to attacks that could lead to the uploading of illegal data. Consequently, the shared database formed based on the blockchain suffers from data quality issues, making it difficult to determine the authenticity and accuracy of the data. Summary of the Invention

[0004] In order to overcome the shortcomings of the prior art, this invention provides a data sharing method and computer device based on cooperative game theory that can effectively improve the data quality in a blockchain shared database.

[0005] To achieve the above objectives, the present invention provides a data sharing method based on cooperative game theory, characterized in that it includes:

[0006] The client initiates a data upload request to the master node and provides a reputation score that represents the service fee;

[0007] Based on the reputation score provided by the client, the master node constructs the success payoff matrix and failure payoff matrix between any two nodes in this round of cooperation consensus and broadcasts the data upload request provided by the client to other nodes in the blockchain to initiate consensus;

[0008] If consensus is successful, points are allocated to all participating nodes based on the game success payoff matrix, and reputation values ​​are matched to the client that initiates the data upload request according to the preset reputation allocation rules; if consensus fails, points are allocated to all participating nodes based on the game failure payoff matrix.

[0009] Each client accesses the shared database formed after the data is uploaded to the blockchain based on its corresponding reputation value, and downloads the data in the shared database based on its corresponding reputation score.

[0010] According to one embodiment of the present invention, after receiving a data upload request, the master node performs a multi-dimensional authenticity assessment of the uploaded data, forms a reputation score package based on the assessment results and the reputation score representing the service fee provided by the client, and constructs a game success payoff matrix and a failure payoff matrix based on the reputation score package. The assessment indicators include the compliance of the data format, the legality of the data content, the legality of the user's identity, and the traceability of the data source.

[0011] According to one embodiment of the present invention, the reputation score package includes reputation scores representing service fees provided by the client and incentive adjustment parameter values. The master node adaptively and dynamically adjusts the incentive adjustment parameter values ​​based on multi-dimensional authenticity assessment of uploaded data and historical consensus.

[0012] According to one embodiment of the present invention, the master node determines whether the (k-1)th and kth consensuses are successful by adaptively adjusting the incentive adjustment parameter value of the (k+1)th consensus.

[0013] If the judgment indicates that both consensuses were successful, the incentive adjustment parameter value for the (k+1)th consensus will be reduced according to the preset rules.

[0014] If the judgment indicates that both consensus attempts have failed, then the parameter value of the consensus incentive for the (k+1)th attempt will be increased according to the preset rules.

[0015] If the judgment indicates that the (k-1)th consensus is successful while the kth consensus fails, then the incentive adjustment parameter value of the (k-1)th consensus is used as the incentive adjustment parameter value of the (k+1)th consensus, so that the blockchain works in the critical state of success / failure of consensus and is biased towards the cooperation side.

[0016] If the judgment indicates that the (k-1)th consensus failed while the kth consensus succeeded, then the incentive adjustment parameter value of the kth consensus will be used as the incentive adjustment parameter value of the (k+1)th consensus, so that the blockchain works in the critical state of success / failure of consensus and is biased towards the cooperation side.

[0017] According to an embodiment of the present invention, the number of failed consensus attempts initiated by the master node in each view is calculated. If the number of consecutive failures to reach consensus initiated by the node reaches a set consecutive threshold or the cumulative number of failures to reach consensus reaches a set cumulative threshold, then the master node in the view is determined to be a malicious node.

[0018] The blockchain updates its view and elects a new master node to await data upload requests from new clients.

[0019] According to an embodiment of the present invention, the payoff matrix for a successful game between any two nodes is set as follows:

[0020]

[0021] The payoff matrix for a failed game between any two nodes is defined as follows:

[0022]

[0023] Where n is the number of nodes in the blockchain network, including 1 master node and n-1 other nodes; c is the reputation score cost consumed by each node in participating in a round of consensus; θ is the credit score of the representation service fee provided by the client in each round of requests; and s is the incentive adjustment parameter value, s≥0.

[0024] According to one embodiment of the present invention, nodes in the blockchain network are classified into reputation levels according to a preset reputation classification rule, and the reputation points consumed by each node when downloading files in the shared database are adjusted based on the reputation level of each node.

[0025] According to one embodiment of the present invention, a reputation payoff coefficient is formed based on the reputation level of each node, and the reputation payoff coefficient is integrated into the game success payoff matrix and the game failure payoff matrix.

[0026] According to one embodiment of the present invention, the data upload request submitted by the client includes the upload request for new data that is not in the shared data and the modification and update request for existing data in the shared database.

[0027] On the other hand, the present invention also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of any of the above methods.

[0028] In summary, the data sharing method based on cooperative game theory provided by this invention integrates the reputation score required for clients to access the shared database and the reputation score points for downloading resources within the database into the blockchain consensus mechanism. By driving nodes to actively participate in consensus based on their demand for shared data, it effectively solves the problems of poor authenticity of on-chain data and vulnerability to attacks caused by a small number of participating nodes, ensuring the authenticity and stability of the shared database formed based on the blockchain. Furthermore, based on the reputation score provided by the client requesting data upload, the master node forms both a success payoff matrix and a failure payoff matrix before consensus is reached. Reputation score incentives are applied to participating nodes based on the failure payoff matrix to further enhance the enthusiasm of each client to participate in consensus at each stage, thereby further improving the authenticity of the shared data. If the number of consecutive consensus failures reaches a set consecutive threshold X, or the cumulative number of consensus failures reaches a set cumulative threshold Y (usually Y > X), the system initiates a master node update strategy, using a random or targeted strategy to reselect the master node. This master node update trigger strategy can improve the security of the master node.

[0029] To make the above and other objects, features and advantages of the present invention more apparent and understandable, preferred embodiments are described below in detail with reference to the accompanying drawings. Attached Figure Description

[0030] Figure 1 The diagram shown is a flowchart of a data sharing method based on cooperative game theory provided in an embodiment of the present invention.

[0031] Figure 2 The diagram illustrates the process of achieving a collaborative consensus using blockchain in one embodiment of the present invention.

[0032] Figure 3 As shown Figure 1 The specific execution flow of the data sharing method based on cooperative game theory is shown.

[0033] Figure 4 The diagram illustrates the specific process of adaptively and dynamically adjusting incentive adjustment parameter values ​​based on historical consensus in a data sharing method based on cooperative game theory provided by an embodiment of the present invention.

[0034] Figure 5 The diagram shown is a schematic diagram of the view switching process of blockchain consensus in a data sharing method based on cooperative game theory provided in an embodiment of the present invention. Detailed Implementation

[0035] like Figure 1As shown, the data sharing method based on cooperative game theory provided by the present invention includes: a client initiating a data upload request to the master node and providing a reputation score representing the service fee (step S10); based on the reputation score provided by the client, the master node constructs a success payoff matrix and a failure payoff matrix between any two nodes in this round of cooperative consensus and broadcasts the data upload request provided by the client to other nodes in the blockchain to initiate consensus (step S20); if the consensus is successful, the master node allocates point rewards to all nodes participating in the consensus based on the success payoff matrix and matches a reputation score value to the client that initiated the data upload request according to a preset reputation score allocation rule (step S30); if the consensus fails, the master node allocates point rewards to all nodes participating in the consensus based on the failure payoff matrix (step S40); wherein, each client accesses the shared database formed after the data is uploaded to the blockchain based on its corresponding reputation score and downloads the data in the shared database based on its corresponding reputation score (step S50).

[0036] A two-parameter cooperative game based on access to the shared database (reputation value) and conditions for downloading shared database files (reputation score) will further drive nodes to actively participate in cooperative consensus and data uploads, building upon the consensus rewards. The more nodes participate, the more the authenticity and completeness of the data uploaded to the blockchain, as evaluated by each node, will be significantly improved, while also effectively enhancing the blockchain network's anti-attack capabilities. Furthermore, matching reputation values ​​to clients initiating data upload requests according to preset reputation allocation rules after successful consensus effectively incentivizes nodes to actively upload data, achieving full aggregation and sharing of data on the smart platform. Simultaneously, related data uploads from multiple nodes can further verify the authenticity of data within the shared database and supplement incomplete data.

[0037] This embodiment uses a typical PBFT cooperative consensus mechanism as an example for illustration. However, the present invention does not limit this in any way. In other embodiments, two-parameter cooperative game theory based on shared database access and download can be integrated into other consensus algorithms.

[0038] like Figure 2 As shown, the blockchain network has four nodes: the master node, and three other nodes, Node 2, Node 3, and Node 4. For ease of description, it is assumed that Node 2 and Node 3 are nodes actively participating in the consensus process; while Node 4 is a faulty or malicious node, meaning it passively does not respond to the consensus or opposes it. In a typical PBFT consensus mechanism, the process of completing a data upload to the blockchain is usually initiated by the client and led by the master node, requiring five stages: request, pre-prepare, prepare, commit, and reply.

[0039] The following will combine Figures 2 to 4This embodiment will provide a detailed description of the cooperative game-theoretic data sharing method based on two parameters: shared database access and download.

[0040] According to the blockchain consensus mechanism based on cooperative subsidy game strategy in this embodiment, a data upload request is initiated by the client in the request phase. The client sends a message to the master node, requesting the data to be uploaded to the blockchain and simultaneously providing a reputation score θ representing the service fee. The data upload requests submitted by the client include requests to upload new data not yet in the shared data and requests to modify and update existing data in the shared database.

[0041] After receiving the request message from the client, the master node initiates a cooperative consensus process. At the very beginning of the pre-prepare phase, the master node, on behalf of the system, establishes a successful game payoff matrix and a failed game payoff matrix (step S201); then, it broadcasts the successful game payoff matrix, the failed game payoff matrix, as well as the view number, the sequence number of the request message, and the message digest to other nodes 2, 3, and 4 in the blockchain network (step S202).

[0042] In this embodiment, after receiving a data upload request from the client, the master node performs a multi-dimensional authenticity assessment of the uploaded data. Based on the assessment results and the reputation score θ representing the service fee provided by the client, a reputation score package is formed. A success payoff matrix and a failure payoff matrix are then constructed based on the reputation score package. The assessment indicators include the compliance of the data format, the legality of the data content, the legality of the user's identity, and the traceability of the data source. Specifically, the reputation score package includes the reputation score θ representing the service fee provided by the client and an incentive adjustment parameter value s. The master node adaptively and dynamically adjusts the incentive adjustment parameter value s based on the multi-dimensional authenticity assessment of the uploaded data and historical consensus.

[0043] The payoff matrix for successful games between any two nodes is set as follows:

[0044]

[0045] The payoff matrix for a failed game between any two nodes is defined as follows:

[0046]

[0047]

[0048] Where n represents the number of nodes in the blockchain network, including one master node and n-1 other nodes; θ represents the reputation score for the representation service fee provided by the client in each round of requests; s is the incentive adjustment parameter value, s≥0; c is the reputation score cost consumed by each node in participating in a round of cooperative consensus. This value is related to the node type. Different nodes are assigned a c value by the shared data management provider that manages the shared database during registration, and this value remains unchanged. Specifically, taking the government-court linkage platform as an example, institutional nodes include courts, procuratorates, and other government functional departments at all levels; while individual nodes include lawyers, litigants, and other individual users. Each type of node has a reputation score C, which is determined by the initial reputation score C0 and the incentive adjustment parameter value s. The initial reputation score C0 of institutional nodes is greater than that of individual nodes. At the same time, each role has a reputation level A, which starts at A0.

[0049] In the prepare phase, nodes other than the master node receive the pre-prepare message and broadcast it to other nodes. For example, node 2 broadcasts the prepare message to the master node, node 3, and node 4. However, node 4 is a faulty or malicious node, so it will not send the prepare message or will send an incorrect one. In the commit phase, each node votes to participate in the consensus process (step S203). Specifically, each node verifies the request and order, executes the consensus, and broadcasts its consensus decision to other nodes. For example, the master node broadcasts the consensus result "agree to cooperate / not cooperate" to nodes 2, 3, and 4; however, node 4 is a faulty or malicious node, so it will not send "agree to cooperate / not cooperate" or will not cooperate. Based on the final consensus result, it is determined whether the number of nodes agreeing to cooperate is greater than 2n / 3 (step S204); where n is the total number of nodes in the blockchain network, which is 4 in this embodiment. If the judgment result is yes, then a consensus is reached (step S205), the data is uploaded to the blockchain, and the message is returned to the client via reply. If the judgment result indicates that the number of nodes agreeing to cooperate is ≤2n / 3, then a consensus is not reached (step S206), and reply will not be executed.

[0050] If step S205 indicates that a consensus has been reached, then step S301 is executed: determine whether each node in the blockchain network is a cooperating node. For nodes participating in cooperation in this round, a reputation score reward of θ / n-c+s*c will be assigned according to the pre-set game success payoff matrix (step S302), while non-cooperating nodes will still be assigned a score reward of θ / n (step S303). Simultaneously, a reputation value is matched for the client initiating the data upload request (step S304); specifically, the reputation value of the client uploading data changes to A. m=A m-1 +A k1 (Initially A1 = A0 + A) k A k1 The value takes the range (-∞, +∞). Where A... m For the client's credibility after the m-th round of cooperation consensus, A m-1 The client's credibility after the (m-1)th round of cooperation consensus; A k1 The reputation increment is given to the client that uploads data after each round of cooperation consensus is reached.

[0051] In this embodiment, the shared data manager, which manages the shared database, only provides a reputation increment to the client that uploaded the data after the data is on the blockchain. However, this invention does not limit this in any way. In other embodiments, malicious clients may be penalized for maliciously uploading or uploading low-quality information. Specifically, if the consensus process fails, the shared data manager may reject the data upload request and simultaneously grant the client that uploaded the data another reputation penalty increment A. k2 To lower the client's credibility, A k2 The value of A is (-∞, 0). k1 and A k2 Satisfy | A k1 |<<|A k2 |

[0052] If step S206 indicates that no consensus has been reached, then step S401 is executed: determine whether each node in the blockchain network is a cooperating node. For nodes that participate in cooperation in this round, a reputation score incentive of -c+s*c will be assigned according to the pre-set game failure payoff matrix (step S402), while nodes that do not cooperate will not be allocated a reputation score incentive (step S403).

[0053] Thus, in the first round of consensus-building during data upload, a two-parameter update was achieved for both the reputation score representing the client's access to the database and the reputation score representing each node's download permission from the database. Each node in the blockchain network will access the shared database or download the necessary data resources based on the two parameters obtained during the consensus-building process. Specifically, only when the client's reputation score A > reputation threshold A... thFurthermore, only when a character's reputation score C > 0 will the shared data management provider, which manages the shared database, grant the client access interface and download permissions. Based on the limitations of shared database access and download permissions, the acquisition of rewards from the successful game theory payoff matrix, and the incentives from the failed game theory payoff matrix, the data sharing method based on cooperative game theory provided in this embodiment will encourage all nodes within the blockchain to actively participate in consensus and submit data upload requests, thereby continuously improving the data quality within the shared database. The demand for high-quality data among different parts will also drive each node to actively participate in consensus, forming a virtuous cycle.

[0054] like Figure 3 As shown in this embodiment, during the consensus-building process, the number of failed consensus-building attempts initiated by the master node in each view is accumulated in the form of a counter (step S404), and it is determined whether there are consecutive failures (step S405). If so, the number of consecutive failures is accumulated (step S406). The count of failures in steps S404 and S406 provides a basis for judging malicious nodes.

[0055] In one round of cooperation consensus, regardless of whether cooperation is reached, the incentive adjustment parameter value s for the next round of cooperation consensus will be adaptively adjusted in step S407; then the current round of cooperation consensus will end.

[0056] The master node can adjust the incentive adjustment parameter 's' based on a multi-dimensional authenticity assessment when receiving uploaded data. Specifically, if the assessment indicates some flaws in the data format compliance, the master node can assign a lower incentive adjustment parameter 's'; if the assessment indicates that the data submitted by the client meets the multi-dimensional authenticity requirements, a higher incentive adjustment parameter 's' is assigned to increase the benefits each node can obtain after reaching a consensus, thereby encouraging more nodes to participate in the consensus process. Furthermore, based on this, the master node can also adaptively and dynamically adjust the incentive adjustment parameter 's' for each round of consensus based on historical consensus outcomes.

[0057] Figure 4 The diagram illustrates the specific process of adaptively and dynamically adjusting incentive adjustment parameter values ​​based on historical consensus in a data sharing method based on cooperative game theory provided by an embodiment of the present invention. The following will combine... Figure 4 right Figure 3 The execution process of step S407, adaptive adjustment of excitation adjustment parameter value s, is explained in detail.

[0058] Specifically, during the adaptive incentive parameter adjustment process, it is first determined whether the consensus reached in the current round (round k) was successful (step S4071), and then it is further determined whether the consensus reached in the previous round (round k-1) was successful (steps S4072 and S4073). If the consensus reached in round k-1 and round k is successful, then step S4074 is executed: the incentive adjustment parameter value s of the consensus reached in round k+1 is reduced to reduce the incentive cost.

[0059] If step S4072 determines that the (k-1)th round of cooperation consensus fails, but step S4071 determines that the kth round of cooperation consensus succeeds, then step S4075 is executed: the incentive adjustment parameter value s of the kth round of cooperation is used as the incentive adjustment parameter value s of the (k+1)th round of cooperation consensus and updated and stored, as a relatively stable critical value s so that the blockchain network works in the critical state of success / failure of cooperation consensus and is biased towards the cooperation side.

[0060] If step S4071 indicates that the k-th consensus failed and step S4073 indicates that the (k-1)-th consensus also failed, then step S4076 is executed to increase the incentive adjustment parameter value s and update and store it as the incentive adjustment parameter value for the (k+1)-th consensus, thereby increasing the incentive cost.

[0061] If step S4071 indicates that the k-th consensus failed, but step S4073 indicates that the (k-1)-th consensus was successful, then step S4077 is executed: the incentive adjustment parameter s of the (k-1)-th consensus is used as the incentive adjustment parameter s of the (k+1)-th consensus to make the blockchain network in a critical state of success / failure of consensus and biased towards the cooperation side.

[0062] The incentive adjustment parameter value s is adaptively adjusted based on the historical consensus results. This encourages each node to actively participate in the consensus and obtain consensus benefits while effectively controlling the cost of consensus. This ensures that each round of consensus can work as much as possible and reach the critical state of success / failure of cooperative consensus, with a bias towards the cooperative side.

[0063] exist Figure 2 In the cooperative consensus process shown, after the cooperative consensus fails, steps S404 and S406 will count the number of cooperative failures to trace and determine whether the master node in the current view is a malicious node; if the current master node is determined to be a malicious node, the view will be switched to replace the new master node (S60), which effectively improves the security and stability of the blockchain network. Figure 5 The flowchart of the view switching method for blockchain consensus in this embodiment is given.

[0064] Specifically, in step S60, after the blockchain network starts, the cumulative counter for failed consensus in this round of the view is set to 0 (y = 0) and the counter for consecutive failed consensus is set to 0 (x = 0) (step S61). Then, the view switching mechanism is activated (step S62), and view updates begin. According to the formula p = v mod |n|, one node is selected as the master node from all n nodes, completing the first view switch (step S63). Here, v is the view number, n is the total number of nodes, and p is the master node number. After completing the first view switch, the process continues... Figure 2 The cooperative consensus mode is shown. In the cooperative consensus mode, based on the value of the cumulative counter y for cooperative consensus failure in step S404, it is determined whether the master node satisfies y>Y (step S64), where Y is a preset threshold for the cumulative number of cooperative consensus failures of the master node in this round of view. If y>Y, it indicates that the master node in the current master view is a malicious node. Then, a new node is selected as a candidate master node using the formula p = (p+1)mod|n| (step S65), and step S64 is re-executed to determine whether the candidate master node is a malicious node. If the determination shows that the candidate master node satisfies y≤Y, then the candidate master node is determined as the official master node, and the x counter and y counter are reset to zero (step S66). After step S66, it is further determined whether the number of consecutive cooperative consensus failures x of the master node is greater than the preset threshold X for the number of consecutive cooperative consensus failures of the master node in this round of view (step S67). If the determination shows that x≤X, then the cooperative consensus process is started (step S68), and it is determined whether this round of cooperative consensus process has been achieved (step S69). If consensus is reached in this round, proceed directly to step S67. If consensus is not reached in this round, increment the counter x by 1 (step S610) and continue to step S67. If step S67 indicates that x > X, it means that the master node has failed to cooperate too many times consecutively, and the view switching strategy should be restarted (step S62). In summary, during the view switching process of blockchain consensus, counters x and y can be used to determine the cumulative number of errors and consecutive errors in the consensus cooperation led by the master node, thereby determining whether it is necessary to update the view and replace the master node to prevent malicious nodes from continuously causing harm, ensuring the authenticity and accuracy of the data on the chain. A random strategy or a targeted strategy can be applied to the master node update strategy.

[0065] In this embodiment, after each node in the blockchain obtains reputation and reputation points through cooperative game theory, the shared data management provider, which manages the shared database, will classify the nodes in the blockchain network into reputation levels based on reputation classification rules, and adjust the reputation points consumed by each node when downloading files in the shared database based on its reputation level. Specifically, for example, reputation levels can be divided into three levels: high, normal, and low. High-reputation users can enjoy rewards during the reward period, and the reputation points consumed during their access and download processes will be reduced according to certain rules compared to normal-reputation users; while low-reputation users will receive penalties during the penalty period, and the reputation points consumed during their access and download processes will be increased according to certain rules compared to normal-reputation users.

[0066] Furthermore, in other embodiments, a reputation payoff coefficient e can be formed based on the reputation level of each node, and this reputation payoff coefficient e can be integrated into the game success payoff matrix and the game failure payoff matrix, as shown in the following two tables:

[0067] The payoff matrix for a successful game between any two nodes is set as follows:

[0068]

[0069] The payoff matrix for a failed game between any two nodes is defined as follows:

[0070]

[0071] For example, based on the client's reputation score, the reputation gain coefficient e = 1.2 during the reward period, e = 1 during the normal period, and e = 0.8 during the penalty period. When accessing and downloading shared databases, this coefficient will be multiplied by (2-e) on the base reputation score.

[0072] On the other hand, this embodiment also provides a computer device including a memory and a processor, wherein the memory stores a computer program. When the processor executes the computer program, it implements the steps of the data sharing method based on cooperative game theory provided in this embodiment.

[0073] In summary, the data sharing method based on cooperative game theory provided by this invention integrates the reputation score required for clients to access the shared database and the reputation score points for downloading resources within the database into the blockchain consensus mechanism. By driving nodes to actively participate in consensus based on their demand for shared data, it effectively solves the problems of poor authenticity of on-chain data and vulnerability to attacks caused by a small number of participating nodes, ensuring the authenticity and stability of the shared database formed based on the blockchain. Furthermore, based on the reputation score provided by the client requesting data upload, the master node forms both a success payoff matrix and a failure payoff matrix before consensus is reached. The failure payoff matrix incentivizes participating nodes with reputation score points to further enhance the enthusiasm of each client to participate in consensus at each stage, thereby further improving the authenticity of the shared data.

[0074] If the number of consecutive consensus failures reaches the set consecutive threshold X, or the cumulative number of consensus failures reaches the set cumulative threshold Y (usually Y > X), the system initiates a master node update strategy, using a random or targeted strategy to reselect the master node. The master node update trigger strategy can improve the security of the master node.

[0075] Although the present invention has been disclosed above by way of preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art may make some modifications and refinements without departing from the spirit and scope of the present invention. Therefore, the scope of protection of the present invention shall be determined by the scope of protection claimed in the claims.

Claims

1. A data sharing method based on cooperative game theory, characterized in that, include: The client initiates a data upload request to the master node and provides a reputation score that represents the service fee; Based on the reputation score provided by the client, the master node constructs the success payoff matrix and failure payoff matrix between any two nodes in this round of cooperation consensus and broadcasts the data upload request provided by the client to other nodes in the blockchain to initiate consensus; If consensus is successful, then based on the game success payoff matrix, all nodes participating in the consensus are allocated points and the client initiating the data upload request is matched with a reputation value according to the preset reputation allocation rules; if consensus fails, then based on the game failure payoff matrix, all nodes participating in the consensus and cooperation are allocated points; the game success payoff matrix and the game failure payoff matrix are both related to the reputation points θ representing the service fee provided by the client and the incentive adjustment parameter value s. Each client accesses the shared database formed after the data is uploaded to the blockchain based on its corresponding reputation value and downloads the data in the shared database based on its corresponding reputation score. Upon receiving a data upload request, the master node performs a multi-dimensional authenticity assessment of the uploaded data. Based on the assessment results and the reputation score representing the service fee provided by the client, a reputation score package is formed. A success payoff matrix and a failure payoff matrix are then constructed based on the reputation score package. The assessment indicators include the compliance of the data format, the legality of the data content, the legality of the user's identity, and the traceability of the data source. The reputation score package includes the reputation score representing the service fee provided by the client and incentive adjustment parameter values. The master node adaptively and dynamically adjusts the incentive adjustment parameter values ​​based on the multi-dimensional authenticity assessment of the uploaded data and historical consensus.

2. The data sharing method based on cooperative game theory according to claim 1, characterized in that, The master node determines whether the (k-1)th and kth consensuses are successful by adaptively adjusting the incentive adjustment parameter value for the (k+1)th consensus. If the judgment indicates that both consensuses were successful, the incentive adjustment parameter value for the (k+1)th consensus will be reduced according to the preset rules. If the judgment indicates that both consensus attempts have failed, then the parameter value of the consensus incentive for the (k+1)th attempt will be increased according to the preset rules. If the judgment indicates that the (k-1)th consensus is successful while the kth consensus fails, then the incentive adjustment parameter value of the (k-1)th consensus is used as the incentive adjustment parameter value of the (k+1)th consensus, so that the blockchain works in the critical state of success / failure of consensus and is biased towards the cooperation side. If the judgment indicates that the (k-1)th consensus failed while the kth consensus succeeded, then the incentive adjustment parameter value of the kth consensus will be used as the incentive adjustment parameter value of the (k+1)th consensus, so that the blockchain works in the critical state of success / failure of consensus and is biased towards the cooperation side.

3. The data sharing method based on cooperative game theory according to claim 1, characterized in that, Calculate the number of failed consensus attempts initiated by the master node in each view. If the number of consecutive failures to reach consensus by the node reaches a set consecutive threshold or the cumulative number of failures to reach consensus reaches a set cumulative threshold, then the master node in the view is determined to be a malicious node. The blockchain updates its view and elects a new master node to await data upload requests from new clients.

4. The data sharing method based on cooperative game theory according to claim 1, characterized in that, The payoff matrix for a successful game between any two nodes is set as follows: The payoff matrix for a failed game between any two nodes is defined as follows: Where n is the number of nodes in the blockchain network, including 1 master node and n-1 other nodes; c is the reputation score cost consumed by each node in participating in a round of consensus; θ is the credit score of the representation service fee provided by the client in each round of requests; and s is the incentive adjustment parameter value, s≥0.

5. The data sharing method based on cooperative game theory according to claim 1, characterized in that, The nodes in the blockchain network are classified into reputation levels according to the preset reputation level classification rules, and the reputation points consumed by each node when downloading files in the shared database are adjusted based on the reputation level of each node.

6. The data sharing method based on cooperative game theory according to claim 5, characterized in that, A reputation payoff coefficient is generated based on the reputation level of each node, and the reputation payoff coefficient is integrated into the game success payoff matrix and the game failure payoff matrix.

7. The data sharing method based on cooperative game theory according to claim 1, characterized in that, The data upload requests submitted by the client include requests to upload new data that is not in the shared data and requests to modify and update existing data in the shared database.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Data sharing method based on federation chain storage check and integral incentive mechanism

    CN108848081A

  • Reward and punishment method applied to block consensus, device, apparatus and storage medium

    CN108961055A

  • Internet of Things dynamic data tracing method and device based on alliance chain

    CN110008720A