CN112651830A - Block chain consensus method applied to power resource sharing network - Google Patents

Block chain consensus method applied to power resource sharing network Download PDF

Info

Publication number
CN112651830A
CN112651830A CN202011393625.0A CN202011393625A CN112651830A CN 112651830 A CN112651830 A CN 112651830A CN 202011393625 A CN202011393625 A CN 202011393625A CN 112651830 A CN112651830 A CN 112651830A
Authority
CN
China
Prior art keywords
node
verifier
nodes
alliance
leader
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202011393625.0A
Other languages
Chinese (zh)
Other versions
CN112651830B (en
Inventor
禹继国
张玉姣
闫碧薇
韩玉冰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Qilu University of Technology
Original Assignee
Qilu University of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Qilu University of Technology filed Critical Qilu University of Technology
Priority to CN202011393625.0A priority Critical patent/CN112651830B/en
Publication of CN112651830A publication Critical patent/CN112651830A/en
Application granted granted Critical
Publication of CN112651830B publication Critical patent/CN112651830B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/602Providing cryptographic facilities or services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/382Payment protocols; Details thereof insuring higher security of transaction
    • G06Q20/3829Payment protocols; Details thereof insuring higher security of transaction involving key management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/06Energy or water supply
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y04INFORMATION OR COMMUNICATION TECHNOLOGIES HAVING AN IMPACT ON OTHER TECHNOLOGY AREAS
    • Y04SSYSTEMS INTEGRATING TECHNOLOGIES RELATED TO POWER NETWORK OPERATION, COMMUNICATION OR INFORMATION TECHNOLOGIES FOR IMPROVING THE ELECTRICAL POWER GENERATION, TRANSMISSION, DISTRIBUTION, MANAGEMENT OR USAGE, i.e. SMART GRIDS
    • Y04S10/00Systems supporting electrical power generation, transmission or distribution
    • Y04S10/50Systems or methods supporting the power network operation or management, involving a certain degree of interaction with the load-side end user applications
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y04INFORMATION OR COMMUNICATION TECHNOLOGIES HAVING AN IMPACT ON OTHER TECHNOLOGY AREAS
    • Y04SSYSTEMS INTEGRATING TECHNOLOGIES RELATED TO POWER NETWORK OPERATION, COMMUNICATION OR INFORMATION TECHNOLOGIES FOR IMPROVING THE ELECTRICAL POWER GENERATION, TRANSMISSION, DISTRIBUTION, MANAGEMENT OR USAGE, i.e. SMART GRIDS
    • Y04S50/00Market activities related to the operation of systems integrating technologies related to power network operation or related to communication or information technologies
    • Y04S50/12Billing, invoicing, buying or selling transactions or other related activities, e.g. cost or usage evaluation

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Accounting & Taxation (AREA)
  • Health & Medical Sciences (AREA)
  • Computer Security & Cryptography (AREA)
  • Economics (AREA)
  • Finance (AREA)
  • General Engineering & Computer Science (AREA)
  • Strategic Management (AREA)
  • General Health & Medical Sciences (AREA)
  • General Business, Economics & Management (AREA)
  • Bioethics (AREA)
  • Software Systems (AREA)
  • Databases & Information Systems (AREA)
  • Computer Hardware Design (AREA)
  • Marketing (AREA)
  • Tourism & Hospitality (AREA)
  • Primary Health Care (AREA)
  • Public Health (AREA)
  • Human Resources & Organizations (AREA)
  • Development Economics (AREA)
  • Technology Law (AREA)
  • Computing Systems (AREA)
  • Water Supply & Treatment (AREA)
  • Data Mining & Analysis (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a block chain consensus method applied to a power resource sharing network, belongs to the technical field of block chain consensus, and aims to provide a lightweight block chain consensus method to realize the reliability and safety of the power resource sharing network. The method comprises the following steps: all the alliance committee nodes vote to select a leader of the current round; selecting the verifier nodes of the current round, forming a verifier node list, and broadcasting the verifier node list and the block chain height value after signature to each electric energy distribution node; each verifier node collects and verifies transactions from a public network, and broadcasts encrypted transaction messages to corresponding electric energy distribution nodes; each electric energy distribution node decrypts the corresponding encrypted transaction message and broadcasts the transaction message to the corresponding alliance committee node; all the alliance committee nodes vote to verify the transaction and broadcast voting messages to the alliance network; punishing the corresponding verifier nodes, and rewarding the corresponding leaders and verifier nodes.

Description

Block chain consensus method applied to power resource sharing network
Technical Field
The invention relates to the technical field of block chain consensus, in particular to a block chain consensus method applied to a power resource sharing network.
Background
With the development of society, the traditional power grid gradually develops towards the smart power grid, and the development of the smart power grid causes uncertain power demand, which causes unpredictable fluctuation of the power generation amount of the traditional power generator and the flow of the power grid system. In order to reduce the load fluctuation level of the power grid, progress optimization strategies for sharing electric energy by various power grid users are endless, and due to the fact that various problems such as trade orders, trade users and management accounts are involved in the electric power resource trading process, the time consumption and flexibility of the trading process between the users and the power grid are caused. Therefore, in order to encourage grid users to achieve demand responses in their own interest, blockchain techniques are combined with distributed energy trading networks.
Blockchain technology was originally used in cryptocurrency "bitcoins" without third parties as a ledger with distributed and immutable features, above which transactions were transparently traceable. The consensus protocol is a key part of the blockchain technology, and achieves that the non-falsifiable and non-repudiatable ledger records are completed without a third party. Due to the decentralization and high safety of the block chain, the block chain technology is applied to reliably and credibly manage data in the information sharing and resource transaction processes in the power grid scene. The consensus algorithm as a key technology of the block chain plays a crucial role in the efficiency and safety of the power grid system. With conventional consensus algorithms, for example, workloads prove difficult to compute when mining, so that trading speed is slow; the equity certificate utilizes the equity mastered by the participants to replace the ore digging operation, but easily causes the power to be mastered in the hands of a few fixed participants; most BFT type consensus algorithms have poor expandability and are difficult to increase users in large quantities. Therefore, the traditional consensus algorithm cannot meet the requirements of the power grid on efficiency and safety, and a new lightweight consensus mechanism suitable for the power grid system is needed.
For power resource sharing networks applying blockchain technology, efficiency and security are important issues that now need to be addressed. As trading users of the power resource sharing network have limited resources, a lightweight consensus algorithm is required to improve the efficiency of the power resource sharing network. Meanwhile, accurate implementation of transactions in the power resource sharing network and requirements of non-tampering require a consensus algorithm capable of preventing power concentration.
Based on the above, how to provide a lightweight block chain consensus processing method for a power resource sharing network to achieve reliability and security of the power resource sharing network is a technical problem to be solved.
Disclosure of Invention
The technical task of the present invention is to provide a block chain consensus method, a terminal and a medium applied to a power resource sharing network to solve the technical problem of how to provide a lightweight block chain consensus method to achieve reliability and security of the power resource sharing network.
In a first aspect, the present invention provides a block chain consensus method applied to a power resource sharing network, where a alliance network of the power resource sharing network is configured with a reward and punishment mechanism and is configured with a plurality of corresponding alliance committee nodes and power distribution nodes, a public network of the power resource sharing network is configured with user nodes, and each round of consensus includes the following steps:
according to the random trust values of the alliance committee nodes participating in the election, all the alliance committee nodes vote and select the leader of the current round;
according to the random trust value of the user node, the leader selects the verifier nodes of the current round and forms a verifier node list, and the verifier node list and the block chain height value are signed and then broadcast to each electric energy distribution node;
the electric energy distribution node encrypts the block chain height value according to the public key of the verifier node to obtain an encrypted verification message, the encrypted verification message is signed and then sent to each user node, and the user node confirms the identity of the verifier node through decrypting the signed verification message;
each verifier node collects and verifies transactions from a public network, divides the transactions and deposit into a plurality of shares and corresponds to the electric energy distribution nodes one by one for the verified transactions, and broadcasts the encrypted transaction messages to the corresponding electric energy distribution nodes after each share is used as a transaction message and encrypted by the public key of the corresponding electric energy distribution node;
each electric energy distribution node decrypts the corresponding encrypted transaction message and broadcasts the transaction message to the corresponding alliance committee node;
the federation committee nodes recover the transactions and the deposit corresponding to each verifier node, and for each transaction, all the federation committee nodes vote to verify the transactions and broadcast voting messages to the federation network based on the deposit and the trust value of the corresponding verifier node;
based on voting information, taking transactions which do not pass verification as malicious transactions, collecting verifier nodes corresponding to the malicious transactions by a leader and broadcasting the verifier nodes to a alliance network, triggering a reward and punishment mechanism to punish the corresponding verifier nodes, taking the transactions which pass verification as legal transactions, collecting the legal transactions by the leader and packaging the legal transactions as blocks to be broadcast to the alliance network, and triggering the reward and punishment mechanism to award the corresponding leader and verifier nodes.
Preferably, the random trust value of each federation committee node is derived based on the random trust value of the federation committee node of the previous round and the number of times the federation committee node was selected as the leader, and is calculated by:
Figure BDA0002813680190000031
Figure BDA0002813680190000032
wherein, Ti rRepresenting the random trust value of the node i of the alliance committee in the r-th round of consensus and the T corresponding to the first round of consensusi rIs an initial value;
r represents a random value corresponding to the R-th round consensus;
n represents the total number of federation-committee nodes in the federation network;
Nirepresenting the number of times a federation committee node i was selected as the leader.
Preferably, the league committee node selects the leader of the current round according to the random trust values of the league committee nodes participating in the election, and the method comprises the following steps:
the joint committee nodes participating in the election are used as the elections, and each election transmits a request voting message
Figure BDA0002813680190000033
For each contestant, each alliance committee node in the alliance network sends a voting response message to vote based on the random trust value of the contestant;
and selecting the election with the maximum random trust value as a leader.
Preferably, the random trust value of each user node is obtained based on the random trust value of the user node in the previous round and the number of times that the user node is selected as the verification node, and the calculation formula is as follows:
Figure BDA0002813680190000041
Figure BDA0002813680190000042
wherein,
Figure BDA0002813680190000043
representing the random trust value of the user v in the r-th round of consensus, corresponding to the first round of consensus
Figure BDA0002813680190000044
Is an initial value;
r represents a random value corresponding to the R-th round consensus;
n represents the total number of users in the public network;
Nvrepresenting the number of times the federation committee node v was selected as the verifier.
Preferably, according to the random trust value of the user node, the leader selects the verifier nodes of the current round and forms a verifier node list, and the verifier node list and the block chain height value are signed and then broadcasted to each electric energy distribution node, wherein the method comprises the following steps:
the leader selects the user nodes with the random trust values larger than or equal to the threshold value as verifier candidates according to the information of the user nodes, and forms a verifier candidate list validatedisted;
leader message verifier candidate
Figure BDA0002813680190000045
Sending the data to each alliance commission node;
voting on the verifier candidates by each alliance committee node according to the random trust value of the user node, voting on the trusted verifier candidate and the untrusted verifier candidate to be not, and voting information
Figure BDA0002813680190000046
Broadcasting into the alliance network;
the leader selects the first v members with votes being positive to form a verification group, if the number of verification group members reaches a preset value, a candidate of a verifier in the verification group is used as a verifier node to form a verifier node list, and if the number of verification group members does not meet the preset value, a threshold value is changed and the members are reselected to form the verification group;
the verifier node list and the height value of the current block chain
Figure BDA0002813680190000051
And after signature, broadcasting to the power distribution node.
Preferably, the electric energy distribution nodes cooperate with each other, the block chain height values are encrypted respectively according to the public keys of the verifier nodes to form verification arrays, the electric energy distribution node corresponding to the leader sends the verification arrays signed by the private key to each user node, and the user node confirms the identity of the verifier node by decrypting the verification arrays signed by the user node.
Preferably, each verifier node collects and verifies transactions from the public network, comprising the steps of:
the method comprises the steps that a verifier node collects transactions from a public network, and the transactions are sent to the public network after being subjected to hash calculation and signature by a corresponding user node;
verifying the signature of the transaction by the verifier node, and confirming that the transaction is from a real user node;
and verifying the hash of the transaction by the verifier node and confirming the correctness of the transaction.
Preferably, the encrypted transaction message is broadcast to the corresponding electric energy distribution node through an SSSS algorithm;
the federation committee nodes recover the transactions and deposit corresponding to each verifier node through the SSSS algorithm.
Preferably, the leader collects the legal transactions of the round and packages the legal transactions into blocks to be broadcast to the alliance network, and the corresponding leader and verifier nodes are rewarded by the reward punishment triggering mechanism, and the method comprises the following steps:
(1) the leader selects the deals meeting the preset voting number as legal deals according to the voting information, the legal deals are packaged into blocks, and the blocks are used as preselected blocks to be broadcast to the alliance network;
(2) the other nodes of the alliance committee except the leader verify the preselected block, if the verification is passed, the leader connects the preselected block as a final block into the block chain and performs the step (3), and if the verification is not passed, the leader broadcasts a verification failure message into the alliance network and performs the step (5);
(3) the electric energy distribution node receives the final block, broadcasts the final block to a public network, completes the consensus of the round and triggers a reward and punishment mechanism and a reward and punishment mechanism;
(4) based on a reward mechanism, fund rewards are conducted on verifier nodes, leaders and voting alliance committee nodes corresponding to the current round of legal transaction, and random trust values of the corresponding verifier nodes and the leaders are improved;
(5) and based on a reward mechanism, punishing the leader of the current round, sending out a change leader application by the alliance committee node, reducing the random trust value of the leader of the current round to an initial random trust value, and canceling the opportunity that the leader of the current round participates as a competitor in the leader of the next round.
Preferably, the leader collects verifier nodes corresponding to the current round of malicious transaction and broadcasts the verifier nodes to the alliance network, and the corresponding verifier nodes are punished by a reward punishment triggering mechanism, and the method comprises the following steps:
the leader selects the transaction which does not meet the preset voting number as a malicious transaction according to the voting information, and the verifier node corresponding to the malicious transaction is used as a malicious verifier node;
collecting the malicious verifier nodes of the round to form a malicious verifier node list, broadcasting the malicious verifier node list to the alliance network, and triggering a reward punishment mechanism;
punishment is carried out on the malicious verifier node based on a punishment mechanism in the reward punishment mechanism, verifier deposit contained in a deduction exchange is used as capital punishment, the deducted verifier deposit is stored in a reward amount wallet, the malicious verifier node is broadcasted in a alliance network, and the random trust value of the malicious verifier node is reduced to be an initial random trust value.
In a second aspect, the present invention provides a terminal comprising a processor, an input device, an output device and a memory, the processor, the input device, the output device and the memory being interconnected, the memory being configured to store a computer program comprising program instructions, the processor being configured to invoke the program instructions to perform the method according to any of the first aspects.
In a third aspect, the invention provides a medium, being a computer readable storage medium, having stored thereon a computer program comprising program instructions which, when executed by a processor, the processor performs the method according to any of the first aspect.
The block chain consensus method, the terminal and the medium applied to the power resource sharing network have the following advantages:
1. the alliance committee node elects the leader according to the random trust value of the contestant, and due to the superiority of the random trust value, the leader can be guaranteed not to be fixed in partial nodes, so that the power is dispersed, and the leader elects the verifier node according to the random trust value of the user node, so that the power is dispersed;
2. the verifier node list and the block chain height value are signed by the leader and then broadcast to each electric energy distribution node, the electric energy distribution nodes are matched with each other, the block chain height value is encrypted through a public key of the verifier node to form a verification array, the electric energy distribution node corresponding to the leader sends the verification array signed through a private key of the electric energy distribution node to each user node, and the user node confirms the identity of the verifier node through decrypting the verification array signed, so that encryption transmission is realized, and the accuracy and the safety of the verifier node are guaranteed;
3. the transaction verification and the block verification are separated, so that the efficiency of the consensus algorithm is improved;
4. the privacy of the transaction is ensured by the encrypted transmission of the transaction;
5. the second verification of the node on the transaction by the alliance committee prevents malicious transactions provided by an incorrect verifier and prevents Sybil attacks;
6. the application of an excitation mechanism improves the activity of the consensus algorithm.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed for the embodiments or the prior art descriptions will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
The invention is further described below with reference to the accompanying drawings.
Fig. 1 is a flowchart illustrating a block chain consensus method applied to a power resource sharing network according to an embodiment.
Detailed Description
The present invention is further described with reference to the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and can implement the present invention, but the embodiments are not to be construed as limiting the present invention and the embodiments and technical features of the embodiments can be combined with each other without conflict.
The embodiment of the invention provides a block chain consensus method applied to a power resource sharing network, which is used for solving the technical problem of how to provide a lightweight block chain consensus method to realize the reliability and safety of the power resource sharing network.
Example (b):
the block chain consensus method applied to the power resource sharing network is characterized in that a reward and punishment mechanism is configured in a alliance network of the power resource sharing network, a plurality of alliance committee nodes and power distribution nodes which correspond to each other one by one are configured in the alliance network, and user nodes are configured in a public network of the power resource sharing network.
The consensus of each round comprises the following steps:
s100, voting by all the alliance committee nodes to select a leader of the current round according to the random trust values of the alliance committee nodes participating in the election;
s200, according to the random trust value of the user node, a leader selects the verifier nodes in the current round and forms a verifier node list, and the verifier node list and the block chain height value are signed and then broadcast to each electric energy distribution node;
s300, the electric energy distribution node encrypts the block chain height value according to the public key of the verifier node to obtain an encrypted verification message, the encrypted verification message is signed and then sent to each user node, and the user node confirms the identity of the verifier node through decrypting the signed verification message;
s400, each verifier node collects and verifies transactions from a public network, divides the transactions and deposit into multiple shares and corresponds to the electric energy distribution nodes one by one for the verified transactions, and broadcasts encrypted transaction messages to the corresponding electric energy distribution nodes after each share is used as a transaction message and encrypted by a public key of the corresponding electric energy distribution node;
s500, each electric energy distribution node decrypts the corresponding encrypted transaction message and broadcasts the transaction message to the corresponding alliance committee node;
s600, recovering the transaction and deposit corresponding to each verifier node by the alliance committee nodes, and voting and verifying the transaction and broadcasting voting information to an alliance network by all the alliance committee nodes based on the deposit and the trust value of the corresponding verifier node for each transaction;
s700, based on voting messages, taking transactions which do not pass verification as malicious transactions, collecting verifier nodes corresponding to the malicious transactions of the current round by a leader and broadcasting the verifier nodes to a union network, triggering a reward and punishment mechanism to punish the corresponding verifier nodes, taking the transactions which pass verification as legal transactions, collecting the legal transactions of the current round by the leader and packaging the legal transactions as blocks to be broadcast to the union network, and triggering the reward and punishment mechanism to award the corresponding leader and verifier nodes.
In this embodiment, the random trust value of each alliance committee node is obtained based on the random trust value of the alliance committee node in the previous round and the number of times that the alliance committee node is selected as the leader, and the calculation formula is as follows:
Figure BDA0002813680190000091
Figure BDA0002813680190000092
wherein, Ti rRepresenting the random trust value of the node i of the alliance committee in the r-th round of consensus and the T corresponding to the first round of consensusi rIs an initial value;
r represents a random value corresponding to the R-th round consensus;
n represents the total number of federation-committee nodes in the federation network;
Nirepresenting the number of times a federation committee node i was selected as the leader.
The alliance committee nodes select the leader of the round according to the random trust values of the alliance committee nodes participating in the election, and the method comprises the following steps:
s110, the alliance committee nodes participating in the election serve as elections, and each election sends a voting request message
Figure BDA0002813680190000093
S120, for each contestant, each alliance committee node in the alliance network sends a voting response message to vote based on the random trust value of the contestant;
s130, selecting the election with the maximum random trust value as a leader.
The random trust value of each user node is obtained based on the random trust value of the user node in the previous round and the times of selecting the user node as a verification node, and the calculation formula is as follows:
Figure BDA0002813680190000094
Figure BDA0002813680190000095
wherein,
Figure BDA0002813680190000101
representing the random trust value of the user v in the r-th round of consensus, corresponding to the first round of consensus
Figure BDA0002813680190000102
Is an initial value;
r represents a random value corresponding to the R-th round consensus;
n represents the total number of users in the public network;
Nvrepresenting the number of times the federation committee node v was selected as the verifier.
According to the random trust value of the user node, the leader selects the verifier nodes of the current round and forms a verifier node list, and the verifier node list and the block chain height value are signed and then broadcast to each electric energy distribution node, and the method comprises the following steps:
s210, the leader selects user nodes with random trust values larger than or equal to a threshold value as verifier candidates according to the information of the user nodes, and forms a verifier candidate list validatedandiateList;
s220, the leader sends a verifier candidate message
Figure BDA0002813680190000103
Sending to each alliance committee node;
s230, voting on the verifier candidates by each alliance committee node according to the random trust value of the user node, voting yes on the trusted verifier candidates and voting no on the untrusted verifier candidates, and voting information
Figure BDA0002813680190000104
Broadcasting into the alliance network;
s240, the leader selects the first v members voted to be yes to form a verification group, if the number of verification group members reaches a preset value, a verifier candidate in the verification group serves as a verifier node to form a verifier node list, and if the number of verification group members does not meet the preset value, a threshold value is changed and the members are selected again to form the verification group;
s250, verifier node list and current block chain height value
Figure BDA0002813680190000105
And broadcasting to the electric energy distribution node after signature.
In step S300, the electric energy distribution nodes cooperate with each other, the block chain height values are encrypted to form a verification array according to the public key of each verifier node, the electric energy distribution node corresponding to the leader sends the verification array signed by the private key thereof to each user node, and the user node confirms the identity of the verifier node thereof by decrypting the verification array signed by the private key.
In concrete implementation, all the electric energy distribution nodes are coordinated, and the block chain height value h is encrypted to obtain hpk according to the round of encryption based on the public key of the verifier node in the verifier node listvHpk will bevCombined into an array EncryptedList [ v ]]Then, an array EncryptedList [ v ] is generated by the private key pair of the electric energy distribution node corresponding to the leader]Signing is carried out, and the signed verification message is obtained
Figure RE-GDA0002971466280000111
Verifying the message after signing
Figure RE-GDA0002971466280000112
To a user node of the public network.
The user node in the public network receives the verification message encrypted by the power distribution node
Figure BDA0002813680190000113
The user node capable of decrypting the block chain height value confirms that the user node becomes the verifier node.
And the verifier collects and verifies the transaction in the public network, and the transaction is subjected to Harvest calculation and signature by the corresponding user node and then is sent to the public network. Determining provenance by verifying transaction signaturesDetermining the correctness of the transaction by verifying the Hash of the transaction at a real user node, then dividing the verified transaction into m transaction messages by combining a certain amount of deposit, wherein m corresponds to the number of the electric energy distribution nodes, namely the m transaction messages correspond to the electric energy distribution nodes one by one, and respectively using a (k, m) SSSS scheme to enable the transaction messages of each share to respectively use a public key pk of the corresponding electric energy distribution nodegEncrypting, and then encrypting m encrypted transaction messages
Figure BDA0002813680190000114
Respectively broadcasting to the corresponding electric energy distribution nodes.
The electric energy distribution node receives the encrypted transaction message
Figure BDA0002813680190000115
Then decrypted and broadcast
Figure BDA0002813680190000116
Corresponding federation committee node.
Federation committee nodes recover the transaction and deposit transactionist for each verifier node using the SSSS algorithm&Deposit and broadcast to the federation network, and for each transaction, based on the Deposit and the trust value of the corresponding verifier node, all federation committee nodes vote to verify the transaction and broadcast a voting message to the federation network
Figure BDA0002813680190000117
The leader selects the transaction which does not meet the preset voting number as a malicious transaction according to the voting information, and the verifier node corresponding to the malicious transaction is used as a malicious verifier node; the leader collects the malicious verifier nodes of the current round to form a malicious verifier node list, broadcasts the malicious verifier node list to the alliance network, and triggers a reward and punishment mechanism; punishing the malicious verifier node based on a punishment mechanism in the reward punishment mechanism, deducting verifier deposit contained in the transaction as a capital punishment, and storing the deducted verifier deposit into a reward money purseAnd broadcasting the malicious verifier node in the alliance network, and reducing the random trust value of the malicious verifier node to an initial random trust value, namely
Figure BDA0002813680190000118
The leader selects the deals meeting the preset voting number as legal deals according to the voting information, the legal deals are packaged into blocks, and the blocks are used as preselected blocks to be broadcast to the alliance network; other alliance committee nodes except the leader verify the preselected block.
If the verification is passed, the leader connects the preselected block as a final block to the block chain, the electric energy distribution node receives the final block and broadcasts the final block to the public network, the consensus of the round is completed, and a reward and punishment mechanism is triggered to win the incentive mechanism; based on the reward mechanism, the verifier nodes, the leaders and the voting alliance committee nodes corresponding to the current round of legal transaction are rewarded, and specifically, the initial random trust values of the corresponding verifier nodes are improved, namely
Figure BDA0002813680190000121
For the leader to award a certain fund and increase its random trust value, Ti r=Ti r+Ti rX 10%, giving a certain monetary reward to the verifier node that votes positively.
If the verification fails, because the new block generated by the leader is not agreed by most of the joint committee nodes, the leader is punished, the joint committee members receive the agreement block message, send a change leader application and reduce the trust value of the current leader to be the initial trust value Ti r=Ti 0And simultaneously, the chance that the member of the alliance is used as a leader in the next election is cancelled.
While the invention has been shown and described in detail in the drawings and in the preferred embodiments, it is not intended to limit the invention to the disclosed embodiments, and it will be apparent to those skilled in the art that many more embodiments of the invention can be made by combining the various embodiments described above, and such embodiments are within the scope of the invention.

Claims (10)

1. The block chain consensus method applied to the power resource sharing network is characterized in that a reward and punishment mechanism is configured in a alliance network of the power resource sharing network, a plurality of alliance committee nodes and electric energy distribution nodes which correspond to each other one by one are configured in the alliance network, a user node is configured in a public network of the power resource sharing network, and each round of consensus comprises the following steps:
voting by all the alliance committee nodes to select a leader of the current round according to the random trust values of the alliance committee nodes participating in the election;
according to the random trust value of the user node, the leader selects the verifier nodes of the current round and forms a verifier node list, and the verifier node list and the block chain height value are signed and then broadcast to each electric energy distribution node;
the electric energy distribution node encrypts the block chain height value according to the public key of the verifier node to obtain an encrypted verification message, the encrypted verification message is signed and then sent to each user node, and the user node confirms the identity of the verifier node through decrypting the signed verification message;
each verifier node collects and verifies transactions from a public network, divides the transactions and deposit into a plurality of shares and corresponds to the electric energy distribution nodes one by one for the verified transactions, and broadcasts the encrypted transaction messages to the corresponding electric energy distribution nodes after each share is used as a transaction message and encrypted by the public key of the corresponding electric energy distribution node;
each electric energy distribution node decrypts the corresponding encrypted transaction message and broadcasts the transaction message to the corresponding alliance committee node;
the federation committee nodes recover the transactions and the deposit corresponding to each verifier node, and for each transaction, all the federation committee nodes vote to verify the transaction and broadcast voting messages to the federation network based on the deposit and the trust value of the corresponding verifier node;
based on voting information, taking the transaction which does not pass verification as a malicious transaction, collecting verifier nodes corresponding to the malicious transaction of the current round by a leader and broadcasting the verifier nodes to a alliance network, triggering a reward and punishment mechanism to punish the corresponding verifier nodes, taking the transaction which passes verification as a legal transaction, collecting the legal transaction of the current round by the leader and packaging the legal transaction as blocks to be broadcast to the alliance network, and triggering the reward and punishment mechanism to award the corresponding leader and verifier nodes.
2. The method of claim 1, wherein the random trust value of each alliance-committee node is derived based on the random trust value of the previous round of alliance-committee nodes and the number of times the alliance-committee node was selected as the leader, and the formula is as follows:
Figure FDA0002813680180000021
Figure FDA0002813680180000022
wherein, Ti rRepresenting the random trust value of the node i of the alliance committee in the r-th round of consensus and the T corresponding to the first round of consensusi rIs an initial value of initialization;
r represents a random value corresponding to the R-th round consensus;
n represents the total number of federation-committee nodes in the federation network;
Nirepresenting the number of times a federation committee node i was selected as the leader.
3. The blockchain consensus method for power resource sharing networks according to claim 1 or 2, wherein the alliance-committee node selects the leader of the current round according to the random trust values of the alliance-committee nodes participating in the election, comprising the steps of:
the joint committee nodes participating in the election are used as the elections, and each election transmits a voting request message
Figure FDA0002813680180000024
For each contestant, each alliance committee node in the alliance network sends a voting response message to vote based on the random trust value of the contestant;
and selecting the election with the maximum random trust value as a leader.
4. The blockchain consensus method applied to the power resource sharing network according to claim 1, wherein the random trust value of each user node is obtained based on the random trust value of the user node in the previous round and the number of times the user node is selected as the verification node, and the calculation formula is as follows:
Figure FDA0002813680180000023
Figure FDA0002813680180000031
wherein,
Figure FDA0002813680180000032
representing the random trust value of the user v in the r-th round of consensus, corresponding to the first round of consensus
Figure FDA0002813680180000033
Is an initial value;
r represents a random value corresponding to the R-th round consensus;
n represents the total number of users in the public network;
Nvrepresenting the number of times the federation committee node v was selected as the verifier.
5. The method for block chain consensus in power resource sharing network according to claim 1 or 4, wherein the leader selects the verifier nodes of the current round according to the random trust values of the user nodes, forms a verifier node list, and broadcasts the verifier node list and the block chain height value to each power distribution node after signing, comprising the following steps:
the leader selects the user nodes with the random trust values larger than or equal to the threshold value as verifier candidates according to the information of the user nodes, and forms a verifier candidate list validatedisted;
leader message verifier candidate
Figure FDA0002813680180000034
Sending to each alliance-committee node;
voting on the verifier candidates by each alliance committee node according to the random trust value of the user node, voting on the trusted verifier candidate and the untrusted verifier candidate to be not, and voting information
Figure FDA0002813680180000035
Broadcasting into the alliance network;
the leader selects the first v members with votes being positive to form a verification group, if the number of verification group members reaches a preset value, a candidate of a verifier in the verification group is used as a verifier node to form a verifier node list, and if the number of verification group members does not meet the preset value, a threshold value is changed and the members are selected again to form the verification group;
the verifier node list and the height value of the current block chain
Figure FDA0002813680180000036
And broadcasting to the electric energy distribution node after signing.
6. The method according to claim 1, wherein the power distribution nodes cooperate with each other to encrypt the height values of the blockchains according to the public keys of the verifier nodes to form a verification array, the power distribution node corresponding to the leader sends the verification array signed by its private key to each user node, and the user node confirms the identity of the verifier node by decrypting the verification array signed by its private key.
7. The blockchain consensus method applied to the power resource sharing network according to claim 1, wherein each verifier node collects and verifies transactions from the public network, comprising the steps of:
the method comprises the steps that a verifier node collects transactions from a public network, and the transactions are sent to the public network after being subjected to hash calculation and signature by a corresponding user node;
verifying the signature of the transaction by the verifier node, and confirming that the transaction is from a real user node;
and verifying the hash of the transaction by the verifier node and confirming the correctness of the transaction.
8. The blockchain consensus method applied to the power resource sharing network according to claim 1, wherein the encrypted transaction message is broadcasted to the corresponding power distribution node through an SSSS algorithm;
the federation committee nodes recover the transactions and deposit corresponding to each verifier node through the SSSS algorithm.
9. The block chain consensus method applied to the power resource sharing network of claim 1, wherein the leader collects the legal transactions of the current round and packages the legal transactions as blocks to be broadcast to the alliance network, and the trigger reward and punishment mechanism rewards the corresponding leader and verifier nodes, comprising the steps of:
(1) the leader selects the deals meeting the preset voting number as legal deals according to the voting information, the legal deals are packaged into blocks, and the blocks are used as preselected blocks to be broadcast to the alliance network;
(2) the other nodes of the alliance committee except the leader verify the preselected block, if the verification is passed, the leader connects the preselected block as a final block into the block chain and performs the step (3), and if the verification is not passed, the leader broadcasts a verification failure message into the alliance network and performs the step (5);
(3) the electric energy distribution node receives the final block, broadcasts the final block to a public network, completes the consensus of the round and triggers a reward and punishment mechanism and a reward and punishment mechanism;
(4) based on a reward mechanism, fund rewards are conducted on verifier nodes, leaders and voting alliance committee nodes corresponding to the current round of legal transaction, and random trust values of the corresponding verifier nodes and the leaders are improved;
(5) and punishing the leader of the current round based on a reward mechanism, sending out a leader replacement application by the joint committee node, reducing the random trust value of the leader of the current round to an initial random trust value, and canceling the opportunity that the leader of the current round participates in the next round as a competitor.
10. The block chain consensus method applied to the power resource sharing network of claim 1, wherein the leader collects verifier nodes corresponding to the current round of malicious transaction and broadcasts the verifier nodes to the alliance network, and the trigger reward and punishment mechanism punishs the corresponding verifier nodes, comprising the steps of:
the leader selects the transaction which does not meet the preset voting number as a malicious transaction according to the voting information, and the verifier node corresponding to the malicious transaction is used as a malicious verifier node;
collecting the malicious verifier nodes of the round to form a malicious verifier node list, broadcasting the malicious verifier node list to the alliance network, and triggering a reward punishment mechanism;
punishment is carried out on the malicious verifier node based on a punishment mechanism in the reward punishment mechanism, verifier deposit contained in the transaction is deducted to be used as capital punishment, the deducted verifier deposit is stored in a reward amount wallet, the malicious verifier node is broadcasted in the alliance network, and the random trust value of the malicious verifier node is reduced to be an initial random trust value.
CN202011393625.0A 2020-12-03 2020-12-03 Block chain consensus method applied to power resource sharing network Active CN112651830B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011393625.0A CN112651830B (en) 2020-12-03 2020-12-03 Block chain consensus method applied to power resource sharing network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011393625.0A CN112651830B (en) 2020-12-03 2020-12-03 Block chain consensus method applied to power resource sharing network

Publications (2)

Publication Number Publication Date
CN112651830A true CN112651830A (en) 2021-04-13
CN112651830B CN112651830B (en) 2023-01-24

Family

ID=75351088

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011393625.0A Active CN112651830B (en) 2020-12-03 2020-12-03 Block chain consensus method applied to power resource sharing network

Country Status (1)

Country Link
CN (1) CN112651830B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113297310A (en) * 2021-06-15 2021-08-24 广东工业大学 Method for selecting block chain fragmentation verifier in Internet of things
CN114463009A (en) * 2022-04-13 2022-05-10 成都理工大学 Method for improving transaction security of large-scale energy node
CN114499952A (en) * 2021-12-23 2022-05-13 中电科大数据研究院有限公司 Alliance chain consensus identity authentication method
CN115689760A (en) * 2022-12-30 2023-02-03 国网区块链科技(北京)有限公司 Block chain fragmentation consensus method, device and equipment for high concurrent power transaction
CN116996521A (en) * 2023-09-28 2023-11-03 江西农业大学 Relay committee cross-chain interaction system and method based on trust evaluation model

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105611600A (en) * 2016-02-02 2016-05-25 中国科学院上海微***与信息技术研究所 QoE (Quality of Experience) requirement oriented secure routing method for Internet of Things
CN107395403A (en) * 2017-07-07 2017-11-24 北京区块链云科技有限公司 A kind of fiduciary block chain common recognition method suitable for extensive ecommerce
CN109360100A (en) * 2018-11-13 2019-02-19 北京航空航天大学 Transaction rapid acknowledgment method and device based on block chain technology
CN109949034A (en) * 2019-03-06 2019-06-28 北京工业大学 Block chain common recognition method based on Credibility Assessment
CN109964242A (en) * 2018-05-25 2019-07-02 北京大学深圳研究生院 A kind of block chain common recognition method based on trusting relationship
CN110189128A (en) * 2019-06-06 2019-08-30 西安安盟智能科技股份有限公司 A kind of algorithm and device of the distributed common recognition quickly generated for block
AU2018347187A1 (en) * 2018-11-07 2020-05-21 Advanced New Technologies Co., Ltd. Facilitating practical byzantine fault tolerance blockchain consensus and node synchronization
CN111241114A (en) * 2020-01-07 2020-06-05 中国科学院信息工程研究所 Intelligent service transaction block chain credit management method and system combining transaction and consensus
CN112017051A (en) * 2020-10-29 2020-12-01 北京易真学思教育科技有限公司 Block chain system, related method, user node and storage medium

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105611600A (en) * 2016-02-02 2016-05-25 中国科学院上海微***与信息技术研究所 QoE (Quality of Experience) requirement oriented secure routing method for Internet of Things
CN107395403A (en) * 2017-07-07 2017-11-24 北京区块链云科技有限公司 A kind of fiduciary block chain common recognition method suitable for extensive ecommerce
CN109964242A (en) * 2018-05-25 2019-07-02 北京大学深圳研究生院 A kind of block chain common recognition method based on trusting relationship
AU2018347187A1 (en) * 2018-11-07 2020-05-21 Advanced New Technologies Co., Ltd. Facilitating practical byzantine fault tolerance blockchain consensus and node synchronization
CN109360100A (en) * 2018-11-13 2019-02-19 北京航空航天大学 Transaction rapid acknowledgment method and device based on block chain technology
CN109949034A (en) * 2019-03-06 2019-06-28 北京工业大学 Block chain common recognition method based on Credibility Assessment
CN110189128A (en) * 2019-06-06 2019-08-30 西安安盟智能科技股份有限公司 A kind of algorithm and device of the distributed common recognition quickly generated for block
CN111241114A (en) * 2020-01-07 2020-06-05 中国科学院信息工程研究所 Intelligent service transaction block chain credit management method and system combining transaction and consensus
CN112017051A (en) * 2020-10-29 2020-12-01 北京易真学思教育科技有限公司 Block chain system, related method, user node and storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
JUN ZOU ET AL.: "A Proof-of-Trust Consensus Protocol for Enhancing Accountability in Crowdsourcing Services", 《IEEE TRANSACTIONS ON SERVICES COMPUTING》 *
王冠,张文月: "基于可信性评估的区块链共识机制的研究", 《郑州大学学报(理学版)》 *

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113297310A (en) * 2021-06-15 2021-08-24 广东工业大学 Method for selecting block chain fragmentation verifier in Internet of things
CN114499952A (en) * 2021-12-23 2022-05-13 中电科大数据研究院有限公司 Alliance chain consensus identity authentication method
CN114499952B (en) * 2021-12-23 2024-04-09 中电科大数据研究院有限公司 Alliance chain consensus identity authentication method
CN114463009A (en) * 2022-04-13 2022-05-10 成都理工大学 Method for improving transaction security of large-scale energy node
CN115689760A (en) * 2022-12-30 2023-02-03 国网区块链科技(北京)有限公司 Block chain fragmentation consensus method, device and equipment for high concurrent power transaction
CN115689760B (en) * 2022-12-30 2023-03-03 国网区块链科技(北京)有限公司 Block chain fragmentation consensus method, device and equipment for high concurrent power transaction
CN116996521A (en) * 2023-09-28 2023-11-03 江西农业大学 Relay committee cross-chain interaction system and method based on trust evaluation model
CN116996521B (en) * 2023-09-28 2023-12-15 江西农业大学 Relay committee cross-chain interaction system and method based on trust evaluation model

Also Published As

Publication number Publication date
CN112651830B (en) 2023-01-24

Similar Documents

Publication Publication Date Title
CN112651830B (en) Block chain consensus method applied to power resource sharing network
Xiao et al. A survey of distributed consensus protocols for blockchain networks
Baza et al. B-ride: Ride sharing with privacy-preservation, trust and fair payment atop public blockchain
CN109360100B (en) Transaction rapid confirmation method and device based on block chain technology
Zaghloul et al. Bitcoin and blockchain: Security and privacy
CN110580653B (en) Block chain consensus mechanism based on transaction
CN109842606A (en) Block chain common recognition algorithm and system based on consistency hash algorithm
Bansal et al. SmartChain: a smart and scalable blockchain consortium for smart grid systems
CN111090892A (en) Block chain consensus method and device based on VRF and threshold signature
Guo et al. Reliable traffic monitoring mechanisms based on blockchain in vehicular networks
US11503036B2 (en) Methods of electing leader nodes in a blockchain network using a role-based consensus protocol
Ye et al. A trust-centric privacy-preserving blockchain for dynamic spectrum management in IoT networks
CN112073483A (en) Authority certification consensus method and system based on credit and committee endorsement mechanism
CN110855432A (en) Asynchronous BFT & DPOS consensus mechanism for assigning verifier rewards based on verifiable random functions
CN111767569A (en) Access authorization method and node of block chain
Wang et al. Blockchain-based dynamic energy management mode for distributed energy system with high penetration of renewable energy
Xue et al. STBC: A novel blockchain-based spectrum trading solution
Yin et al. Sidechains with fast cross-chain transfers
CN115270145A (en) User electricity stealing behavior detection method and system based on alliance chain and federal learning
Aluko et al. Proof-of-reputation: an alternative consensus mechanism for blockchain systems
CN110990790B (en) Data processing method and equipment
CN116595094A (en) Federal learning incentive method, device, equipment and storage medium based on block chain
Hu et al. Privacy-preserving combinatorial auction without an auctioneer
Wang et al. An efficient, secured, and infinitely scalable consensus mechanism for peer-to-peer energy trading blockchain
Wang et al. Enhancing power grid resilience with blockchain-enabled vehicle-to-vehicle energy trading in renewable energy integration

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant