WO2020133326A1 - 区块链生成方法、系统、计算机存储介质和电子设备 - Google Patents

区块链生成方法、系统、计算机存储介质和电子设备 Download PDF

Info

Publication number
WO2020133326A1
WO2020133326A1 PCT/CN2018/125273 CN2018125273W WO2020133326A1 WO 2020133326 A1 WO2020133326 A1 WO 2020133326A1 CN 2018125273 W CN2018125273 W CN 2018125273W WO 2020133326 A1 WO2020133326 A1 WO 2020133326A1
Authority
WO
WIPO (PCT)
Prior art keywords
network node
type
block
round
network
Prior art date
Application number
PCT/CN2018/125273
Other languages
English (en)
French (fr)
Inventor
段夕华
钟林
Original Assignee
北京建极练科技有限公司
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 北京建极练科技有限公司 filed Critical 北京建极练科技有限公司
Priority to PCT/CN2018/125273 priority Critical patent/WO2020133326A1/zh
Publication of WO2020133326A1 publication Critical patent/WO2020133326A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/40Network security protocols

Definitions

  • the present disclosure relates to the field of blockchain technology, and in particular, to a blockchain generation method, system, computer storage medium, and electronic equipment.
  • the blockchain system can realize new applications such as smart contracts and fair agreements, and can replace trusted third parties in regular transactions. Double spending is a key issue facing cryptocurrencies. Cryptocurrencies use a consensus mechanism to solve double spending issues. Research on the consensus mechanism is very difficult, because in an open environment, an attacker can generate multiple pseudonyms to conduct "witch" attacks. In addition, because the network is not synchronized, it is very difficult to achieve consensus in an asynchronous environment. At present, commonly used consensus algorithms include workload proof mechanism, share proof mechanism, share authorization proof mechanism, and practical Byzantine fault tolerance algorithm.
  • Proof-of-work mechanism Distribute accounting rights fairly to nodes across the network.
  • the system incentives obtained by each node depend on the effective work contributed. That is, the better the computing equipment invested in the node, the stronger the computing power provided, and the more revenue will be obtained. Therefore, the consensus mechanism of the proof-of-work mechanism can be regarded as the principle of distribution according to work. This mechanism has high security. If you want to achieve double spending, you need to exceed 51% of the computing power of the entire network. It is almost impossible to achieve 51% of the computing power of the entire network. Secondly, if the agreement is not carried out honestly in the manner prescribed by the system, not only will it not be able to obtain system incentives, but it will also cost power and equipment.
  • Proof-of-stake mechanism The accounting right is determined according to the proportion and time of the tokens owned by the nodes of the entire network.
  • the difficulty of obtaining the accounting power of a node is inversely proportional to the equity held by the node.
  • the proof-of-stake mechanism reduces the resource consumption of computing to a certain extent, and the system performance has been improved accordingly. So the proof-of-stake mechanism can be viewed as a way of capital allocation.
  • Proof-of-stake mechanism improves the consensus speed of the system, reduces the consumption of power, equipment, etc., and has high security, because nodes with 51% equity are bound by capital, such nodes will not maliciously execute the protocol and make the system insecure , Instability, which causes the price of coins to fall and other problems.
  • the proof-of-stake mechanism brings a fixed-point attack problem, that is, at a certain moment, two nodes with similar shares attack each other, making the other party unable to issue blocks, and its own block becomes the only legal block, which can receive system rewards. .
  • the more nodes there are in the proof-of-stake mechanism the more and more wealthy it will become, and the wealth will continue to be concentrated, so that the system's right to issue blocks will continue to be concentrated, thus deviating from the decentralized nature.
  • the share authorization certification mechanism is similar to the equity certification mechanism.
  • the share authorization certification mechanism divides all nodes into leaders and followers, and the followers will be notified only after a consensus is reached between the leaders. This mechanism can effectively reduce network pressure without increasing computing resources. As the number of bookkeeping nodes is further reduced, the speed at which the system reaches consensus is greatly improved, but the system security is further reduced, and the system continues to develop in a centralized manner.
  • Byzantine fault-tolerant algorithm is a state machine copy replication algorithm.
  • the service is modeled as a state machine, and the state machine replicates copies at different nodes of the distributed system. Each copy of the state machine saves the state of the service and also implements the operation of the service.
  • the algorithm has (n-1)/3 fault tolerance, but if 1/3 or more bookkeepers stop working, the system will not be able to provide services.
  • the inventor of the present invention found that there is a problem in the above-mentioned prior art, and therefore proposed a new technical solution to at least one of the problems.
  • a blockchain generation method is provided, which is applied to a blockchain network.
  • the blockchain network includes a plurality of network nodes, including: randomly selecting network nodes of the first type to make the first A type of network node generates a block and broadcasts the block in the blockchain network; a second type of network node is randomly selected to enable the second type of network node to vote for the block of the first type of network node and Broadcast the voting results; determine the selected block based on the voting of the second type of network node, and generate a blockchain based on the selected block.
  • a method for generating a blockchain is provided, which is applied to a blockchain network.
  • the blockchain network includes a plurality of network nodes, including: the network node determines whether to be selected as a blockchain-based agreement The first type of network node; if the network node is selected as the first type of network node, the network node generates a block and broadcasts the block in the blockchain network; if the network node is not selected as the first Network node, the network node determines whether it is selected as the second type network node based on the blockchain agreement; if the network node is selected as the second type network node, the network node performs Voting and broadcasting the voting results; the second-type network node determines the selected block based on the received votes of each second-type network node, and generates a blockchain based on the selected block.
  • a computer-readable storage medium on which a computer program is stored, which when executed by a processor implements the above-mentioned blockchain generation method.
  • an electronic device including:
  • a memory for storing executable instructions of the processor
  • the processor is configured to execute the above-mentioned blockchain generation method by executing the executable instruction.
  • a first type of network node is randomly selected through a protocol to generate and broadcast a block
  • a second type of network node randomly selected through a protocol selects a broadcast block
  • Conduct voting to determine the selected blocks and network nodes, and ensure that each network node in the blockchain network has the opportunity to be selected. Broadcast blocks and voting are performed by randomly selected nodes, saving the blockchain network The resources have improved the efficiency of the blockchain system.
  • FIG. 1 shows a flowchart of an embodiment of a blockchain generation method according to the present disclosure
  • FIG. 2 shows a flowchart of another embodiment of a blockchain generation method according to the present disclosure
  • FIG. 3 shows a flowchart of still another embodiment of the blockchain generation method according to the present disclosure
  • FIG. 4 shows a schematic diagram of an embodiment of a blockchain system according to the present disclosure
  • FIG. 5 shows a flowchart of still another embodiment of the blockchain generation method according to the consensus algorithm of the present disclosure.
  • FIG. 6 shows a schematic diagram of an electronic device used in the blockchain generation method of the present disclosure.
  • FIG. 1 shows a flowchart of an embodiment of a blockchain generation method according to the present disclosure. The method is applied to a blockchain network including multiple network nodes.
  • a first type of network node is randomly selected from the blockchain network so that the first type of network node generates a block and broadcasts the block in the blockchain network.
  • the selected network node is eligible to generate and broadcast blocks.
  • a second type of network node is randomly selected from the blockchain network, and the second type of network node has the right to vote on the received block.
  • the network nodes that vote for the block can be randomly selected among all nodes based on random numbers or seeds combined with the blockchain network node's own attributes, such as the network node's private key and other information.
  • the second type of network node is different from the first type of network node.
  • Step 106 Determine the selected block based on the vote of the second type of network node, and generate a blockchain based on the selected block.
  • the first type of network node is randomly selected through the protocol to generate and broadcast the block, and the second type of network node randomly selected through the protocol vote on the broadcast block to determine the selected block And network nodes, to ensure that all network nodes in the blockchain network have the opportunity to be selected, avoiding the problems caused by the proof-of-work mechanism, the stock proof mechanism, etc.; and the broadcast block and voting are randomly selected parts
  • Node execution saves resources of the entire blockchain network and improves the efficiency of the entire system.
  • a consensus algorithm (referred to as eRoc algorithm for short) is proposed, based on a probability model, a certain number of user broadcast blocks are selected, and a certain number of other users vote on the blocks to achieve consensus . More specifically, in a certain round (within a specified time range), the system randomly selects a certain number of network nodes to broadcast the block, and randomly selects a certain number of other network nodes to grade the block and vote; if a certain If the number of votes in a block exceeds the threshold specified by the system, the block becomes the only consensus block in the entire network.
  • eRoc algorithm for short
  • the eRoc algorithm guarantees the distributed characteristics in a randomly selected manner, and has good properties in terms of consensus speed, security, and efficiency.
  • FIG. 2 shows a flowchart of another embodiment of a blockchain generation method according to the present disclosure.
  • a first predetermined number of network nodes of the first type are determined from the blockchain network based on the seeds broadcast in the blockchain network and the private keys of the network nodes.
  • the first predetermined number may be 10, 20, 50, 80, 100, 200, or the like.
  • Step 204 The first type of network node generates blocks and broadcasts the generated blocks in the blockchain network.
  • Step 206 Determine a second predetermined number of network nodes of the second type from the blockchain network based on the seeds broadcast in the blockchain network and the private keys of the network nodes.
  • the second predetermined number may be 200, 300, 500, 1000, 2000, 3000, 5000, or the like.
  • Step 208 The second network node votes on the received block, and broadcasts the voted block in the blockchain network to achieve consensus.
  • step 210 the block whose number of votes exceeds the system threshold is determined as the selected block.
  • Step 212 Perform the next round of blockchain generation based on the selected block and the next round of seeds generated by the selected node, and continue to perform steps 202-210.
  • the first type of network node and the second type of network node are randomly selected based on the broadcast seed in the network and the private key of the network node, which ensures the randomness of the selection, and also ensures that each node has the opportunity to participate and Fairness; broadcast blocks and voting are executed by randomly selected nodes, saving resources of the entire blockchain network and improving the efficiency of the entire system.
  • FIG. 3 shows a flowchart of yet another embodiment of the blockchain generation method according to the present disclosure.
  • step S302 the network node calculates a seed value according to the network node's own private key and the received seed.
  • step S304 the network node judges whether the seed value is less than the first threshold, and if so, proceeds to step S306, otherwise, proceeds to step S308.
  • the first threshold is determined based on the total number of nodes in the blockchain network and the first predetermined number.
  • Step S306 the network node is selected as the first type of network node, and the first type of network node is qualified to generate blocks; the network node generates blocks and broadcasts the generated blocks in the blockchain network.
  • step S308 the network node determines whether the seed value is less than the second threshold, and if so, proceeds to step S310, otherwise, proceeds to step 328.
  • the second threshold is determined based on the total number of nodes in the blockchain network and the second predetermined number.
  • step S310 the network node is selected as the second type of network node, and the second type of network node is eligible to vote; the network node first verifies the received block.
  • Step S312 After the verification is passed, the second type of network node votes on the received block and broadcasts the voting result.
  • Step S314 After receiving the voting results of other network nodes, the second type of network node relays the voting results.
  • step S316 the second type of network node judges whether the number of votes received for the block is greater than the system threshold, and if so, proceeds to step S318, otherwise, proceeds to step S322.
  • step S318 the block whose number of votes of the block is greater than the system threshold is determined as the selected block.
  • Step S320 Use the next round of seeds in the selected block as the next round of seeds in the blockchain network. If the number of votes of all blocks does not exceed the system threshold within the specified time range, the empty block is selected as the selected block.
  • Step S322 Use the blank block as the selected block.
  • step S324 the next round of seeds is generated according to the previous round of seeds.
  • Step S326 Broadcast the selected block in the blockchain network.
  • Step S328 the nodes in the blockchain network receive the broadcast selected block, and generate a blockchain after verification.
  • the first threshold and the second threshold are calculated according to the following formula:
  • the first predetermined number N1 may be 10, 20, 50, 80, 100, 150, 200, etc.
  • the second predetermined number N2 may be 200, 300, 500, 1000, 2000, 3000, 5000, etc.
  • the total number of nodes in the blockchain network is also dynamically or periodically updated, and the first threshold and the second threshold are updated correspondingly.
  • the network nodes in the blockchain network obtain the seed value based on the received seed and their own attribute information based on the blockchain protocol. Different network nodes have different seed values. Based on their own seed values, they judge that they belong to the first One type of network node, the second type of network node or other nodes. For the first type network node 41, it has the qualification to generate blocks and broadcast the block; for the second type network node 42, it has the qualification to vote for the block, and broadcasts the voting result. The network node determines the selected block according to the voting result, and generates a blockchain accordingly.
  • the following broadcast strategy is adopted:
  • Block broadcast All blocks are broadcast to the whole network, then the network node can collect all blocks.
  • Voting broadcast The network node with voting rights broadcasts only the votes corresponding to the highest level block and the hash value of the block, while other votes refuse to broadcast.
  • the consensus algorithm parameter settings in the blockchain generation method include:
  • W is the bit width of the lottery function output.
  • N 1 refers to the number of blocks expected to be broadcast in each round of the system.
  • N 2 refers to the number of votes expected by the system.
  • N 3 If the number of votes in a block exceeds the threshold set by the system, the block is the only consensus block in the round.
  • x ⁇ refers to the number of blocks actually sent in round ⁇ .
  • Sum refers to the estimated value of the total number of nodes in the whole network in the round. For example: if the system broadcasts a block greater than N 1 in a certain round, increase the value of Sum; if the block broadcast in a certain round is less than N 1 , then decrease the value of Sum; assuming the first ⁇ - The total number of nodes in round 1 is Sum ⁇ -1 , then the total number of nodes in round ⁇ Sum ⁇ is calculated as follows:
  • the threshold T 1 ensures that N 1 blocks are broadcast to the entire network as much as possible in each round of the system. For example: The system sets the entire network in round ⁇ to send out about N 1 blocks, calculated as follows:
  • the seed value calculated by the user is within the range of [0, T 1 ], then it is eligible to send blocks, otherwise it is not eligible.
  • T 2 The threshold T 2 ensures that the system can cast a certain number of votes. For example: the system sets up to N 2 votes in round ⁇ , calculated as follows:
  • the seed value calculated by the user is within the range of (T 1 ⁇ , T 2 ⁇ ], then it is eligible to vote, otherwise it is not eligible to vote.
  • the above threshold can be determined as needed.
  • the present invention is not limited to the above specific value.
  • FIG. 5 shows a flowchart of still another embodiment of the blockchain generation method according to the consensus algorithm of the present disclosure.
  • step S502 the parameters are updated. Update the seed, total node count, block sending threshold, and voting threshold.
  • step S504 block broadcasting.
  • the nodes of the whole network calculate whether they are qualified to generate and send blocks based on the seeds in the previous round of consensus blocks. If there is, then send a block, otherwise refuse.
  • the network-wide nodes verify two aspects: whether the total number of nodes is similar, and whether the block sending qualification is valid.
  • step S506 the block vote.
  • the nodes of the entire network calculate whether they are eligible to vote based on the seeds in the previous round of consensus blocks. If yes, vote, otherwise refuse. Verification of nodes across the entire network: whether the total number of nodes is similar, whether the block sending qualification is valid, whether the voting qualification is valid, and whether the voting is valid.
  • step S508 voting is relayed.
  • the nodes of the entire network calculate whether they are eligible to vote for relay based on the seeds in the consensus block of the previous round.
  • Network-wide node verification whether the total number of nodes is similar, whether the block sending qualification is valid, the voting qualification is valid, the voting is valid, the voting relay is eligible, and the voting relay is valid.
  • step S510 the block becomes effective.
  • the network-wide node counts whether the block vote exceeds the threshold. If it exceeds, the block takes effect, otherwise the empty block is the only legal block.
  • the voting network node and the relay network node may be determined using different conditions, that is, the voting network node and the relay network node are different.
  • VRF verifiable random function
  • digital signature digital signature
  • trapdoor hash function the general structure of the eRoc consensus algorithm is given according to the definition.
  • the multi-signature algorithm the aggregate signature algorithm
  • the trapdoor hash function algorithm based on the discrete logarithm difficult problem
  • the trapdoor hash function algorithm based on the factorized difficult problem
  • the specific eRoc is constructed according to these four algorithms Consensus algorithm.
  • G function generation algorithm probability algorithm
  • input unary character string security parameter is k
  • output two binary character strings public key PK, private key SK
  • V function verification algorithm
  • VRF verifiable random function
  • T (T E, T J ) is a random algorithm, and T E ( ⁇ , ⁇ ), and T J ( ⁇ , ⁇ , ⁇ ) input 1 k, the run up to s (k) Step . Then the probability of success in the following experiment is at most 1/2+1/s(k).
  • Step 1 Parameter update
  • the parameter update includes four aspects of update: seed, total number of nodes, block sending threshold, and voting threshold.
  • Parameter update method The whole network node calculates the seed, the total number of nodes, the block sending threshold, and the voting threshold of round ⁇ based on the seed and the total number of nodes in the valid block of round ⁇ -1.
  • the network-wide nodes perform the following calculations:
  • T 1 ⁇ (N 1 /Sum ⁇ ) ⁇ 2 W
  • Step 2 Block broadcasting
  • Block broadcasting consists of 2 steps:
  • the whole network node calculates whether it is qualified to broadcast the block. If there is, then send a block, otherwise refuse.
  • the network-wide nodes verify two aspects: whether the total number of nodes is similar, and whether the qualification for sending blocks is valid.
  • the algorithm is as follows: The nodes of the entire network perform the following calculations:
  • Block qualification in case Then broadcast the block, otherwise reject.
  • Update of the total number of nodes Since the number of blockchains received by each node is not exactly the same, the total number of nodes in the next round of update by each node can be approximated.
  • Block sending qualification Since the block sending threshold and voting threshold in the ⁇ -1 round are unified across the entire network, the determination of the block sending qualification is done by comparing with the parameters valid in the round ⁇ -1.
  • Step 3 Block voting
  • Block voting consists of 2 steps:
  • the nodes of the entire network calculate whether they are eligible to vote based on the highest-level block. If yes, vote, otherwise refuse.
  • the algorithm is as follows: The nodes of the entire network perform the following calculations:
  • the seed of the latest block is used for lottery, and the seed value is compared with the voting threshold of the previous consensus block.
  • the lottery can prevent eclipse attacks and target denial of service attacks.
  • the voting method can prevent selfish mining attacks.
  • the voting relay consists of 2 steps:
  • the nodes of the entire network calculate whether they are eligible to vote for relay based on the highest-level block.
  • the algorithm is as follows: The nodes of the entire network perform the following calculations:
  • Step 5 The block takes effect
  • the network-wide node counts whether the block vote exceeds the threshold. If it exceeds, the block takes effect, otherwise the empty block is the only legal block.
  • the algorithm is as follows: The nodes of the entire network perform the following calculations:
  • the digital signature algorithm consists of three algorithms: KGen, Sig, and Ver, which are used for key generation, signing, and verification, respectively. For a fixed security parameter, these three algorithms operate as follows:
  • Sig input the private key SK, the message M in a certain set M, and output a signature ⁇ ;
  • Ver Input public key PK and message signature pair (M, ⁇ ), and output validity judgment valid/invalid.
  • the digital signature algorithm is correct, if the following properties are met:
  • the digital signature algorithm is safe, if attacker A:
  • a S(sk, ⁇ ) indicates that attacker A accesses oracle S(SK, ⁇ )
  • Q indicates the number of queries A of attacker A to oracle S
  • attacker A knows the public key PK and the security parameter ⁇ . Note that the attacker cannot directly query the oracle S x.
  • Step 1 Parameter update
  • T 1 ⁇ (N 1 /Sum ⁇ ) ⁇ 2 W
  • Step 2 Block broadcasting
  • Block qualification in case Then broadcast the block, otherwise reject.
  • Step 3 Block voting
  • Step 5 The block takes effect
  • . Let H be a random member ⁇ 0, 1 ⁇ * ⁇ G * of the hash function family. Let P ⁇ P 1 ,..., P n ⁇ be a group member.
  • MulSig the private key of any group member P j ⁇ P is SK j , the message M needs to be signed, then calculated and broadcast make It is a group member who signs the message.
  • J ⁇ i 1 ,..., i l ⁇ be the index set of members of this group.
  • Step 1 Parameter update
  • T 1 ⁇ (N 1 /Sum ⁇ ) ⁇ 2 W
  • Step 2 Block broadcasting
  • Block qualification in case Then broadcast the block, otherwise reject.
  • Step 3 Block voting
  • Step 5 The block takes effect
  • the given message is M ⁇ ⁇ 0, 1 ⁇ * , calculate h ⁇ h(M), where h ⁇ G 2 and ⁇ h x , the signature is ⁇ G 2 .
  • Ver. Given the user's public key is v, the message is M, the signature is ⁇ , calculate h ⁇ h(M); if e(g 1 , ⁇ ) e(v,h) holds, then accept, otherwise reject.
  • each user u i ⁇ U provides a signature ⁇ i ⁇ G 2 . Note that all messages M i must be different from each other. Calculation Then the aggregate signature is ⁇ G 2 .
  • the messages M i are different from each other, otherwise they are rejected;
  • the trapdoor hash family contains a pair (I; H), which meets the following conditions:
  • I is a probabilistic polynomial time secret key generation algorithm.
  • Input 1 k and output a pair of secret keys (PK, SK), so that the length of the public key and private key PK, SK is a polynomial of k.
  • H is a family of random functions. Each hash function in H corresponds to a hashed public key PK, and the application and message, from a space M to a random element in a limited space R, the output of the hash function h PK does not depend on the trapdoor Secret key SK.
  • the trapdoor hash family (I; H) has the following properties:
  • Trap door collision there is a probabilistic polynomial time algorithm, input a pair of hash public and private keys (PK, SK) ⁇ I(1 k ), a pair (m 1 , r 1 ) ⁇ M ⁇ R, and a Message m 2 ⁇ M, output a value r 2 ⁇ R, and satisfy:
  • h PK (m 1 ; r 1 ) h PK (m 2 ; r 2 )
  • Step 1 Parameter update
  • T 1 ⁇ (N 1 /Sum ⁇ ) ⁇ 2 W
  • Step 2 Block broadcasting
  • Block qualification in case Then broadcast the block, otherwise reject.
  • Step 3 Block voting
  • Step 5 The block takes effect
  • Step 1 Parameter update
  • T 1 ⁇ (N 1 /Sum ⁇ ) ⁇ 2 W
  • Step 2 Block broadcasting
  • Block qualification in case Then broadcast the block, otherwise reject.
  • Step 3 Block voting
  • Step 5 The block takes effect
  • the electronic device 600 according to this embodiment of the present invention will be described below with reference to FIG. 6.
  • the electronic device 600 shown in FIG. 6 is only an example, and should not bring any limitation to the functions and use scope of the embodiments of the present invention.
  • the electronic device 600 is represented in the form of a general-purpose computing device.
  • the components of the electronic device 600 may include, but are not limited to: the at least one processing unit 610, the at least one storage unit 620, and a bus 630 connecting different system components (including the storage unit 620 and the processing unit 610).
  • the storage unit stores a program code
  • the program code may be executed by the processing unit 610, so that the processing unit 610 executes various exemplary according to the present invention described in the "exemplary method" section of the above specification Implementation steps.
  • the processing unit 610 may perform S102 as shown in FIG. 1 to randomly select the first type network node to cause the first type network node to generate blocks and broadcast the blocks in the blockchain network; S104, Randomly select the second type network node to make the second type network node vote on the block of the first type network node and broadcast the voting result; S106, determine the selected block based on the vote of the second type network node To generate a blockchain based on the selected block.
  • the storage unit 620 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 6201 and/or a cache storage unit 6202, and may further include a read-only storage unit (ROM) 6203.
  • RAM random access storage unit
  • ROM read-only storage unit
  • the storage unit 620 may further include a program/utility tool 6204 having a set of (at least one) program modules 6205.
  • program modules 6205 include but are not limited to: an operating system, one or more application programs, other program modules, and program data. Each of these examples or some combination may include an implementation of the network environment.
  • the bus 630 may be one or more of several types of bus structures, including a storage unit bus or a storage unit controller, a peripheral bus, a graphics acceleration port, a processing unit, or a local area using any of a variety of bus structures bus.
  • the electronic device 600 may also communicate with one or more external devices (eg, keyboard, pointing device, Bluetooth device, etc.), and may also communicate with one or more devices that enable a user to interact with the electronic device 600, and/or with The electronic device 600 can communicate with any device (eg, router, modem, etc.) that communicates with one or more other computing devices. Such communication may be performed through an input/output (I/O) interface 650.
  • the electronic device 600 can also communicate with one or more networks (such as a local area network (LAN), a wide area network (WAN), and/or a public network, such as the Internet) through a network adapter 660. As shown, the network adapter 660 communicates with other modules of the electronic device 600 through the bus 630.
  • LAN local area network
  • WAN wide area network
  • the Internet such as the Internet
  • the network adapter 660 communicates with other modules of the electronic device 600 through the bus 630.
  • other hardware and/or software modules may be used in conjunction with the electronic device 600, including
  • the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, U disk, mobile hard disk, etc.) or on a network , Including several instructions to cause a computing device (which may be a personal computer, server, terminal device, or network device, etc.) to perform the method according to an embodiment of the present disclosure.
  • a non-volatile storage medium which may be a CD-ROM, U disk, mobile hard disk, etc.
  • a computing device which may be a personal computer, server, terminal device, or network device, etc.
  • a computer-readable storage medium on which a program product capable of implementing the above method of this specification is stored.
  • various aspects of the present invention may also be implemented in the form of a program product, which includes program code, and when the program product runs on a terminal device, the program code is used to enable the The terminal device executes the steps according to various exemplary embodiments of the present invention described in the "Exemplary Method" section of this specification.
  • the program product for implementing the above method according to an embodiment of the present invention may use a portable compact disk read-only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer.
  • CD-ROM portable compact disk read-only memory
  • the program product of the present invention is not limited to this.
  • the readable storage medium may be any tangible medium containing or storing a program, and the program may be used by or in combination with an instruction execution system, apparatus, or device.
  • the program product may use any combination of one or more readable media.
  • the readable medium may be a readable signal medium or a readable storage medium.
  • the readable storage medium may be, for example but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or device, or any combination of the above. More specific examples of readable storage media (non-exhaustive list) include: electrical connections with one or more wires, portable disks, hard disks, random access memory (RAM), read only memory (ROM), erasable Programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the foregoing.
  • the computer-readable signal medium may include a data signal that is transmitted in baseband or as part of a carrier wave, in which readable program code is carried. This propagated data signal can take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing.
  • the readable signal medium may also be any readable medium other than a readable storage medium, and the readable medium may send, propagate, or transmit a program for use by or in combination with an instruction execution system, apparatus, or device.
  • the program code contained on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
  • the program code for performing the operations of the present invention can be written in any combination of one or more programming languages including object-oriented programming languages such as Java, C++, etc., as well as conventional procedural formulas Programming language-such as "C" language or similar programming language.
  • the program code may be executed entirely on the user's computing device, partly on the user's device, as an independent software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server To execute.
  • the remote computing device may be connected to the user computing device through any kind of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (eg, using Internet service provision Business to connect via the Internet).
  • LAN local area network
  • WAN wide area network
  • Internet service provision Business to connect via the Internet
  • the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, U disk, mobile hard disk, etc.) or on a network , Including several instructions to cause a computing device (which may be a personal computer, server, mobile terminal, or network device, etc.) to perform the method according to an embodiment of the present disclosure.
  • a non-volatile storage medium which may be a CD-ROM, U disk, mobile hard disk, etc.
  • a computing device which may be a personal computer, server, mobile terminal, or network device, etc.

Abstract

一种区块链生成方法、系统、计算机存储介质和电子设备,涉及区块链技术领域。该方法包括:随机选择第一类网络节点以生成区块并在区块链网络中广播区块(S102);随机选择第二类网络节点以对区块进行投票并广播投票结果(S104);基于第二类网络节点的投票确定选中区块,并根据选中区块生成区块链(S106)。这样,通过随机选择的网络节点生成并广播区块以及对广播的区块进行投票,保证了区块链网络中各个网络节点都有被选中的机会,避免了工作量证明机制,权益证明机制等共识机制带来的中心化与资源浪费等问题;广播区块和投票都是随机选择部分节点执行的,节约了整个区块链网络资源,并提升了整个系统的效率。

Description

区块链生成方法、系统、计算机存储介质和电子设备 技术领域
本公开涉及区块链技术领域,特别涉及一种区块链生成方法、系统、计算机存储介质和电子设备。
背景技术
区块链系统能够实现智能合约、公平协议等新应用,并且能够在常规交易中代替可信第三方。双重花费是密码货币面临的关键问题,密码货币通过共识机制以解决双重花费问题。共识机制的研究是非常困难的,因为在开放环境下,攻击者可以产生多个假名进行“女巫”攻击。此外,由于网络不同步,在异步环境下实现共识是非常困难的。当前,常用的共识算法有工作量证明机制、股份证明机制、股份授权证明机制、实用拜占庭容错算法等。
然而,这类算法在分布式特性、共识速度、安全性、效率等方面均存在一定问题。
工作量证明机制:将记账权公平的分派到全网节点,各节点所获得的系统激励取决于贡献的有效工作。即节点投入的计算设备越好,提供的算力越强,则获得的收益越多。所以工作量证明机制共识机制可以看作是按劳分配原则。该机制具有较高的安全性,如果想要实现双重花费,则需要超过全网51%的算力才能够实现,而达到全网51%的算力几乎是不可能的。其次,如果不按照系统规定的方式诚实执行协议,不但不能获得系统激励,而且还会损失电力、设备等成本。因此,非诚实执行协议会带来较大的损失,从而进一步保证系统安全性。但是,目前工作量证明机制造成了大量的资源浪费,并且矿机的使用使得普通用户挖矿变得不可能。工作量证明机制达成的共识速度较慢,比特币共识需要约10分钟,而以太坊共需要约20秒,远远不能满足商业化的交易需求。挖矿联盟的出现使得算力不断集中,使得工作量证明机制偏离了原有的去中心化性质,安全性也随之降低。
权益证明机制:根据全网节点所拥有的代币的比例和时间决定记账权。节点记账权的获得难度与节点持有的权益成反比。相对于工作量证明机制,权益证明机制在一定程度减少了运算带来的资源消耗,系统性能得到了相应的提升。所以权益证明机制可以看作是按资本分配方式。权益证明机制提高了系统的共识速度、降低了电力、设备等消耗,而且具有较高的安全性,因为具有51%股权的节点被资本绑定,该类节点不会恶意执行协议使得系统不安全、不稳定,而导致币的价格下跌等问题。但是权益证明机制带来了定点攻击问题,即在某一时刻,两个股权相近的节点攻击对方,使得对方无法发出区块,而自己的发块则成为唯一合法区块,从而可以获得系统奖励。其次,权益证明机制中拥有币越多的节点,则会变得越来越富有,财富不断集中,从而使得系统的发块权不断集中,因此偏离了去中心化特性。
股份授权证明机制:股份授权证明机制,与权益证明机制相近。股份授权证明机制将所有节点分为领导者与跟随者,只有领导者之间达成共识后才会通知跟随者。该机制能够在不增加计算资源的前提下有效减少网络压力。由于记账节点数量进一步减少,系统达到共识的 速度得到了巨大的提升,但是系统安全性进一步降低,且系统不断向中心化发展。
实用拜占庭容错算法:拜占庭容错算法是一种状态机副本复制算法,服务作为状态机进行建模,状态机在分布式系统的不同节点进行副本复制。每个状态机的副本都保存了服务的状态,同时也实现了服务的操作。拜占庭容错算法中链上所有人参与投票,少于(N-1)/3个节点反对时就获得公示信息的权利。该算法具有(n-1)/3容错性,但是如果有1/3或以上记账人停止工作后,系统将无法提供服务。
由于现有的工作量证明机制、股份证明机制等不断向中心化发展,且在共识速度、安全性、效率等方面存在一定问题,因此,达成共识的去中心化、共识速度快、高安全性和高效率等关键特征是区块链技术的关键研究方向。
发明内容
本发明的发明人发现上述现有技术中存在问题,并因此针对所述问题中的至少一个问题提出了一种新的技术方案。
根据本公开的一个方面,提供一种区块链生成方法,应用于一区块链网络,所述区块链网络包括多个网络节点,包括:随机选择第一类网络节点以使所述第一类网络节点生成区块并在所述区块链网络中广播区块;随机选择第二类网络节点以使所述第二类网络节点对所述第一类网络节点的区块进行投票并广播投票结果;基于所述第二类网络节点的投票确定选中区块,根据所述选中区块生成区块链。
根据本公开的另一方面,提供一种区块链生成方法,应用于区块链网络,所述区块链网络包括多个网络节点,包括:网络节点基于区块链协定判断是否被选为第一类网络节点;如果所述网络节点被选为第一类网络节点,则所述网络节点生成区块并在所述区块链网络中广播区块;如果网络节点未被选为第一类网络节点,则所述网络节点基于区块链协定判断是否被选为第二类网络节点;如果所述网络节点被选为第二类网络节点,则所述网络节点对接收的区块进行投票并广播投票结果;所述第二类网络节点基于接收的各个第二类网络节点的投票确定选中区块,根据所述选中区块生成区块链。
根据本公开的又一方面,提供一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现上述的区块链生成方法。
根据本公开的又一方面,提供一种电子设备,包括:
处理器;以及
存储器,用于存储所述处理器的可执行指令;
其中,所述处理器配置为经由执行所述可执行指令来执行上述区块链生成方法。
本公开的区块链生成方法、系统和计算设备,在区块链网络中通过协议随机选择第一类网络节点生成并广播区块,通过协议随机选择的第二类网络节点对广播的区块进行投票,从而确定选中的区块和网络节点,保证区块链网络中各个网络节点都有被选中的机会,广播区块和投票都是由随机选择的部分节点执行,节省了区块链网络的资源,提升了区块链系统的效率。
通过以下参照附图对本发明的示例性实施例的详细描述,本发明的其它特征及其优点将会变得清楚。
附图说明
构成说明书的一部分的附图描述了本发明的实施例,并且连同说明书一起用于解释本发明的原理。
参照附图,根据下面的详细描述,可以更加清楚地理解本发明,其中:
图1示出根据本公开区块链生成方法的一个实施例的流程图;
图2示出根据本公开区块链生成方法的另一个实施例的流程图;
图3示出根据本公开区块链生成方法的又一个实施例的流程图;
图4示出根据本公开的区块链系统的一个实施例的示意图;
图5示出根据本公开的共识算法的区块链生成方法的再一个实施例的流程图;和
图6示出用于本公开的区块链生成方法的电子设备的示意图。
具体实施方式
现在将参照附图来详细描述本发明的各种示例性实施例。应注意到:除非另外具体说明,否则在这些实施例中阐述的部件和步骤的相对布置、数字表达式和数值不限制本发明的范围。
同时,应当明白,为了便于描述,附图中所示出的各个部分的尺寸并不是按照实际的比例关系绘制的。
以下对至少一个示例性实施例的描述实际上仅仅是说明性的,决不作为对本发明及其应用或使用的任何限制。
对于相关领域普通技术人员已知的技术、方法和设备可能不作详细讨论,但在适当情况下,所述技术、方法和设备应当被视为授权说明书的一部分。
在这里示出和讨论的所有示例中,任何具体值应被解释为仅仅是示例性的,而不是作为限制。因此,示例性实施例的其它示例可以具有不同的值。
应注意到:相似的标号和字母在下面的附图中表示类似项,因此,一旦某一项在一个附图中被定义,则在随后的附图中不需要对其进行进一步讨论。
图1示出根据本公开区块链生成方法的一个实施例的流程图,该方法应用于一区块链网络,该区块链网络中包括多个网络节点。
如图1所示,步骤102,从区块链网络中随机选择第一类网络节点以使所述第一类网络节点生成区块并在区块链网络中广播区块。可以根据随机数或者种子结合区块链网络节点自身属性,如网络节点的私钥等信息在区块链网络中随机选择网络节点,被选中网络节点具有生成并广播区块的资格。
步骤104,从区块链网络中随机选择第二类网络节点,该第二类网络节点具有对接收区块的投票权。可以根据随机数或者种子结合区块链网络节点自身属性,如网络节点的私钥等信息在所有节点中随机选择对区块进行投票的网络节点。在一个实施例中,第二类网络节点不同于第一类网络节点。
步骤106,基于第二类网络节点的投票确定选中区块,根据该选中区块生成区块链。
上述实施例中,在区块链网络中通过协议随机选择第一类网络节点生成并广播区块,通过协议随机选择的第二类网络节点对广播的区块进行投票,从而确定选中的区块和网络节点,保证区块链网络中各个网络节点都有被选中的机会,避免了工作量证明机制,股份证明 机制等方式带来的问题;而且广播区块和投票都是由随机选择的部分节点执行,节省了整个区块链网络的资源,提升了整个系统的效率。
在本公开的一个实施例中,提出一种共识算法(简称为eRoc算法),以概率模型为基础,选择一定数量的用户广播区块,并选择一定数量的其他用户对区块投票以实现共识。更具体来说,在某一轮次(规定时间范围内),系统随机选择一定数量的网络节点广播区块,并且,随机选择一定数量的其他网络节点对区块进行分级并投票;如果某个区块的投票数量超过系统规定的阈值,则该区块成为全网唯一共识区块。如果在规定时间范围内全网区块的投票数量没有超过系统规定的阈值,则全网用户以空区块当作该轮次的唯一合法区块。因此,eRoc算法以随机选择的方式保障分布式特性,而且在共识速度、安全性、效率等方面均有较好的性质。
图2示出根据本公开区块链生成方法的另一个实施例的流程图。
如图2所示,步骤202,基于在区块链网络中广播的种子和网络节点的私钥从区块链网络中确定第一预定数量的第一类网络节点。该第一预定数量可以是10、20、50、80、100、200等。
步骤204,第一类网络节点生成区块并在区块链网络中广播生成的区块。
步骤206,基于在区块链网络中广播的种子和网络节点的私钥从区块链网络中确定第二预定数量的第二类网络节点。该第二预定数量可以是200、300、500、1000、2000、3000、5000等。
步骤208,第二网络节点对接收的区块进行投票,并将投票的区块在区块链网络中进行广播以实现共识。
步骤210,将投票数超过系统阈值的区块确定选中区块。
步骤212,基于选中区块以及选中节点生成的下一轮的种子进行下一轮区块链生成,继续执行步骤202-210。
上述实施例中,基于网络中广播的种子以及网络节点的私钥以随机选择第一类网络节点和第二类网络节点,即保证了选择的随机性,又保证了各个节点的拥有参与机会和公平性;广播区块和投票都是由随机选择的部分节点执行,节省了整个区块链网络的资源,提升了整个系统的效率。
图3示出根据本公开区块链生成方法的又一个实施例的流程图。
如图3所示,步骤S302,网络节点根据网络节点自身的私钥和接收的种子计算种子值。
步骤S304,网络节点判断种子值是否小于第一阈值,如果是,则继续步骤S306,否则,继续步骤S308。在一个实施例中,第一阈值根据区块链网络中的总节点数和第一预定数量确定。
步骤S306,该网络节点被选为第一类网络节点,第一类网络节点具有生成区块的资格;该网络节点生成区块并在区块链网络中广播生成的区块。
步骤S308,网络节点判断种子值是否小于第二阈值,如果是,则继续步骤S310,否则,继续步骤328。在一个实施例中,第二阈值根据区块链网络中的总节点数和第二预定数量确定。
步骤S310,该网络节点被选为第二类网络节点,第二类网络节点具有投票资格;该网络节点首先对接收的区块进行验证。
步骤S312,验证通过后,第二类网络节点对接收的区块进行投票,并对投票结果进行广播。
步骤S314,第二类网络节点接收到其他网络节点的投票结果后,对投票结果进行中继广播。
步骤S316,第二类网络节点判断接收的对于区块的投票数是否大于系统阈值,如果是,则继续步骤S318,否则,继续步骤S322。
步骤S318,将区块的投票数大于系统阈值的区块确定选中区块。
步骤S320,将选中区块中的下一轮种子作为区块链网络中下一轮的种子。如果在规定时间范围内所有区块的投票数没有超过所述系统阈值,则以空区块作为选中区块。
步骤S322,将空白区块作为选中区块。
步骤S324,根据上一轮种子生成下一轮种子。
步骤S326,在区块链网络中广播选中区块。
步骤S328,区块链网络中的节点接收广播的选中区块,验证后生成区块链。
进入下一轮的区块链生成。
在一个实施例中,根据如下公式计算第一阈值和第二阈值:
T 1 ξ=(N 1/Sum ξ)·2 W  (1)
T 2 ξ=(N 2/Sum ξ)·2 W  (2)
其中,第一预定数量N1可以是10、20、50、80、100、150,200等,第二预定数量N2可以是200、300、500、1000、2000、3000、5000等。
在一个实施例中,还动态或者周期性更新区块链网络中的总节点数,并对应更新第一阈值和第二阈值。
图4示出根据本公开的区块链系统的一个实施例的示意图。如图4所示,区块链网络中的网络节点基于区块链协议根据接收的种子和自身属性信息获得种子值,不同的网络节点的种子值不同,基于自身的种子值判断自己是属于第一类网络节点、第二类网络节点还是其他节点。对于第一类网络节点41,其具有生成区块并广播区块的资格;对于第二类网络节点42,其具有对区块进行投票的资格,并将投票结果进行广播。网络节点根据投票结果确定选中区块,并对应生成区块链。
在本公开的一个实施例中,采用如下广播策略:
区块广播:所有区块广播到全网,则网络节点能够收集到所有区块。
选票广播:具有投票权的网络节点仅广播最高级别区块对应的选票及区块的哈希值,而其他选票则拒绝广播。
在本公开的一些实施例中,区块链生成方法中的共识算法参数设置包括:
W:是抽签函数输出的位宽。
N 1:是指系统中每轮期望广播的区块数量。
N 2:是指系统期望的投票数量。
N 3:系统中如果一个区块的投票数量超过系统设定的阈值,则该区块为该轮的唯一共识区块。
x ξ:是指第ξ轮实际发出的区块数量。
Sum:是指该轮全网节点总数的估计值。例如:如果系统在某一轮广播的区块大于N 1个,则增大Sum的取值;如果某一轮广播的区块小于N 1个,则减小Sum的取值;假设第ξ-1轮的节点总数为Sum ξ-1,则第ξ轮的节点总数Sum ξ计算如下:
Sum ξ=Sum ξ-1·x ξ/N 1
T 1:阈值T 1确保系统每一轮尽可能有N 1个区块广播到全网。例如:系统设置第ξ轮全网发出约N 1个区块,如下计算:
T 1 ξ=(N 1/Sum ξ)·2 W
用户计算出的种子值在[0,T 1]区间范围内,则有资格发块,否则没有资格。
T 2:阈值T 2确保系统能够投出有一定数量的选票。例如:系统设置第ξ轮最多有N 2个选票,如下计算:
T 2 ξ=(N 2/Sum ξ)·2 W
用户计算出的种子值在(T 1 ξ,T 2 ξ]区间范围内,则有资格投票,否则没有资格投票。
本领域的技术人员可以理解,可以根据需要确定上述阈值,如,本发明并不限定为上述特定值。
图5示出根据本公开的共识算法的区块链生成方法的再一个实施例的流程图。
如图5所示,在步骤S502,参数更新。对种子、总节点数、发块阈值、投票阈值进行更新。
在步骤S504,区块广播。全网节点根据上一轮共识区块中的种子计算是否有资格生成并发送区块。如果有,则发块,否则拒绝。全网节点验证两方面:总节点数是否相近,发块资格是否有效。
在步骤S506,区块投票。全网节点根据上一轮共识区块中的种子计算是否有资格投票。如果有,则投票,否则拒绝。全网节点验证:总节点数是否相近,发块资格是否有效,投票资格是否有效,投票是否有效。
在步骤S508,投票中继。全网节点根据上一轮共识区块中的种子计算是否有资格投票中继。全网节点验证:总节点数是否相近,发块资格是否有效,投票资格是否有效,投票是否有效,投票中继是否有资格,投票中继是否有效。
在步骤S510,区块生效。全网节点统计区块的投票是否超过阈值。如果超过,则区块生效,否则以空块为唯一合法区块。
在一个实施例中,投票网络节点和中继网络节点可以采用不同的条件确定,即投票网络节点和中继网络节点不同。
以下结合具体的实施例给出可验证随机函数VRF,数字签名,陷门哈希函数的定义,并根据定义给出eRoc共识算法的一般构造。其次,给出多重签名算法、聚合签名算法、基于离散对数困难问题的陷门哈希函数算法、基于因子分解困难问题的陷门哈希函数算法,并根据这四个算法构造出具体的eRoc共识算法。
【实施例一】
1.基于VRF(Verifiable Random Functions,可验证随机函数)的eRoc共识算法
1.1定义
令G,F和V为多项式时间算法,其中
G(函数生成算法)概率算法;输入一元字符串(安全参数为k);输出两个二进制字符串(公钥PK,私钥SK);
F=(F 1,F 2)(函数求值算法)确定性算法;输入两个二进制字符串(私钥SK,字符串x);输出两个二进制字符串(VRF的函数值F 1(SK,x)和对应的proof=F 2(SK,x));
V(函数验证算法)概率算法;输入四个二进制字符串(PK,x,v,proof);输出Yes或No。
Figure PCTCN2018125273-appb-000001
Figure PCTCN2018125273-appb-000002
为三个任意函数,使得a(k),b(k),c(k)在多项式时间ploy(k)内是可计算的,且a(k),b(k)在k的多项式内有界的(除去输入为*的情况)。
(G,F,V)是可验证随机函数(VRF),其输入长度为a(k),输出长度为b(k),安全性为s(k),如果满足如下性质:
对于
Figure PCTCN2018125273-appb-000003
以下两个条件成功的概率为1-2 -Ω(k)
(a)域范围正确性:对于任意x∈{0,1} a(k),则F 1(SK,x)∈{0,1} b(k)
(b)完整性:对于任意x∈{0,1} a(k),如果(v,proof)=F(SK,x)
PROB[V(PK,x,v,proof)=YES]>1-2 -Ω(k)
唯一性:对于任意PK,x,v 1,v 2,proof 1,proof 2,且v 1≠v 2,无论i=1或i=2,以下均成立:
PROB[V(PK,x,v i,proof i)=YES]<2 -Ω(k)
伪随机性:令T=(T E,T J)为任意一对算法,且T E(·,·)和T J(·,·,·)输入1 k,则最多运行s(k)步。则在以下实验中成功的概率最多为1/2+1/s(k)。
(a)运行G(1 k)生成(PK,SK)。
(b)运行
Figure PCTCN2018125273-appb-000004
生成(x,state)。
(c)选择
Figure PCTCN2018125273-appb-000005
如果r=0,令v=F 1(SK,x);如果r=1,选择
Figure PCTCN2018125273-appb-000006
(d)运行
Figure PCTCN2018125273-appb-000007
生成guess。
(e)T=(T E,T J)成功,如果x∈{0,1} a(k),guess=r,且x没有被提交到F(SK,·)进行查询,包括T E和T J
如果
Figure PCTCN2018125273-appb-000008
我们认为f(·)=F 1(SK,·)是一个独立的VRF。如果a(k)=*对于所有k,则VRF具有任意输入长度。
1.2基于VRF的eRoc共识算法
步骤1:参数更新
参数更新包括4方面的更新:种子、总节点数、发块阈值、投票阈值的更新。
参数更新方法:全网节点根据第ξ-1轮的有效区块中的种子和总节点数,计算第ξ轮的种子、总节点数、发块阈值、投票阈值。
算法如下:
全网节点进行如下计算:
种子更新:
Figure PCTCN2018125273-appb-000009
总节点数更新:Sum ξ=Sum ξ-1·x ξ/N 1
发块阈值更新:T 1 ξ=(N 1/Sum ξ)·2 W
投票阈值更新:T 2 ξ=(N 2/Sum ξ)·2 W
步骤2:区块广播
区块广播包含2个步骤:
全网节点计算自己是否有资格广播区块。如果有,则发块,否则拒绝。
全网节点验证两方面:总节点数是否相近,发块资格是否有效。
算法如下:全网节点进行如下计算:
发块资格:
Figure PCTCN2018125273-appb-000010
如果
Figure PCTCN2018125273-appb-000011
则广播区块,否则拒绝。
区块内容:
Figure PCTCN2018125273-appb-000012
验证:
Figure PCTCN2018125273-appb-000013
注释:1.总节点数更新:由于每个节点接收到的区块链数量不是完全相同的,因此各节点更新的下一轮总节点数是近似范围即可。2.发块资格:由于ξ-1轮中的发块阈值与投票阈值是全网统一的,因此发块资格的确定是通过与第ξ-1轮中生效的参数进行对比完成的。
步骤3:区块投票
区块投票包含2步:
1全网节点根据最高级的区块计算是否有资格投票。如果有,则投票,否则拒绝。
2全网节点验证:1.总节点数是否相近,2.发块资格是否有效,3.投票资格是否有效,4投票是否有效。
算法如下:全网节点进行如下计算:
分级:
Figure PCTCN2018125273-appb-000014
投票资格:
Figure PCTCN2018125273-appb-000015
如果
Figure PCTCN2018125273-appb-000016
则进行投票
Figure PCTCN2018125273-appb-000017
选票广播:
Figure PCTCN2018125273-appb-000018
选票验证:
Figure PCTCN2018125273-appb-000019
注释:使用最新区块的种子进行抽签,而种子值与上一轮共识区块的投票阈值进行比较。
抽签方式能够防止日食攻击、目标拒绝服务攻击。
投票方式能够防止自私挖矿攻击。
步骤4:投票中继
投票中继包含2步:
1全网节点根据最高级的区块计算是否有资格投票中继。
2全网节点验证:1.总节点数是否相近,2.发块资格是否有效,3.投票资格是否有效,4投票是否有效,5投票中继是否有资格,6投票中继是否有效。
算法如下:全网节点进行如下计算:
中继资格:
Figure PCTCN2018125273-appb-000020
如果
Figure PCTCN2018125273-appb-000021
则进行投票
Figure PCTCN2018125273-appb-000022
否则拒绝。
中继:
Figure PCTCN2018125273-appb-000023
中继验证:
Figure PCTCN2018125273-appb-000024
步骤5:区块生效
全网节点统计区块的投票是否超过阈值。如果超过,则区块生效,否则空块为唯一合法区块。
算法如下:全网节点进行如下计算:
如果
Figure PCTCN2018125273-appb-000025
Figure PCTCN2018125273-appb-000026
否则ValidBlock ξ←BlankBlock.
【实施例二】
2.基于数字签名(digital signature)的eRoc共识算法
2.1定义
数字签名算法由三个算法组成KGen,Sig,和Ver,分别用于秘钥生成,签名和验证。对于一个固定的安全参数,这三个算法如下运行:
KGen:输入安全参数λ,输出一对随机秘钥(PK,SK);
Sig:输入私钥SK、某个集合M中的消息M,输出一个签名σ;
Ver:输入公钥PK和消息签名对(M,σ),输出有效性判断valid/invalid。
数字签名算法具有正确性,如果满足以下性质:
Figure PCTCN2018125273-appb-000027
数字签名算法是安全的,如果对任意非均匀概率多项式时间攻击者A:
Figure PCTCN2018125273-appb-000028
其中A S(sk,·)表明攻击者A访问预言机S(SK,·),且Q表明攻击者A对预言机S的查询次数A,攻击者A知道公钥PK和安全参数λ。注意攻击者不能直接对预言机S查询x。
2.2基于数字签名的eRoc共识算法
步骤1:参数更新
种子更新:
Figure PCTCN2018125273-appb-000029
总节点数更新:Sum ξ=Sum ξ-1·x ξ/N 1
发块阈值更新:T 1 ξ=(N 1/Sum ξ)·2 W
投票阈值更新:T 2 ξ=(N 2/Sum ξ)·2 W
步骤2:区块广播
发块资格:
Figure PCTCN2018125273-appb-000030
如果
Figure PCTCN2018125273-appb-000031
则广播区块,否则拒绝。
区块广播:
Figure PCTCN2018125273-appb-000032
验证:
Figure PCTCN2018125273-appb-000033
步骤3:区块投票
分级:
Figure PCTCN2018125273-appb-000034
投票资格:
Figure PCTCN2018125273-appb-000035
如果
Figure PCTCN2018125273-appb-000036
则进行投票
Figure PCTCN2018125273-appb-000037
选票广播:
Figure PCTCN2018125273-appb-000038
选票验证:
Figure PCTCN2018125273-appb-000039
Figure PCTCN2018125273-appb-000040
步骤4:投票中继
中继资格:
Figure PCTCN2018125273-appb-000041
如果
Figure PCTCN2018125273-appb-000042
则进行投票
Figure PCTCN2018125273-appb-000043
否则拒绝。
中继:
Figure PCTCN2018125273-appb-000044
中继验证:
Figure PCTCN2018125273-appb-000045
步骤5:区块生效
如果
Figure PCTCN2018125273-appb-000046
Figure PCTCN2018125273-appb-000047
否则ValidBlock ξ←BlankBlock.
【实施例三】
2.3多重签名(Multisignature)
MulKeyGen:令G为GDH群,令I为全局信息,包含一个群G的生成元g,群G的阶p=|G|。令H为哈希函数族随机成员{0,1} *→G *。令P={P 1,...,P n}为群成员。
MulSig:任意群成员P j∈P其私钥为SK j,需要对消息M签名,则计算并广播
Figure PCTCN2018125273-appb-000048
Figure PCTCN2018125273-appb-000049
为对消息进行签名的群成员。令J={i 1,...,i l}为这类群成员的的指数集合。指定的任意签名群成员D,假设其知道每个签名,则计算σ=∏ j∈Jj)且输出T=(M,L,σ)。
MulVer:验证者输入T=(M,L,σ)和对应签名群成员
Figure PCTCN2018125273-appb-000050
的公钥列表,其中
Figure PCTCN2018125273-appb-000051
对于i j∈J。验证者计算
Figure PCTCN2018125273-appb-000052
输出V DDH(g,PK L,H(M),σ).
2.4基于多重签名的eRoc共识算法
步骤1:参数更新
种子更新:
Figure PCTCN2018125273-appb-000053
总节点数更新:Sum ξ=Sum ξ-1·x ξ/N 1
发块阈值更新:T 1 ξ=(N 1/Sum ξ)·2 W
投票阈值更新:T 2 ξ=(N 2/Sum ξ)·2 W
步骤2:区块广播
发块资格:
Figure PCTCN2018125273-appb-000054
如果
Figure PCTCN2018125273-appb-000055
则广播区块,否则拒绝。
区块广播:
Figure PCTCN2018125273-appb-000056
验证:
Figure PCTCN2018125273-appb-000057
步骤3:区块投票
分级:
Figure PCTCN2018125273-appb-000058
投票资格:
Figure PCTCN2018125273-appb-000059
如果
Figure PCTCN2018125273-appb-000060
则进行投票
Figure PCTCN2018125273-appb-000061
选票广播:
Figure PCTCN2018125273-appb-000062
选票验证:
Figure PCTCN2018125273-appb-000063
Figure PCTCN2018125273-appb-000064
步骤4:投票中继
中继资格:
Figure PCTCN2018125273-appb-000065
如果
Figure PCTCN2018125273-appb-000066
则进行投票
Figure PCTCN2018125273-appb-000067
否则拒绝。
中继:
Figure PCTCN2018125273-appb-000068
中继验证:
Figure PCTCN2018125273-appb-000069
步骤5:区块生效
如果
Figure PCTCN2018125273-appb-000070
Figure PCTCN2018125273-appb-000071
否则ValidBlock ξ←BlankBlock.
【实施例四】
2.5聚合签名(Aggregate Signature)
KGen.对于任意用户,选择随机数
Figure PCTCN2018125273-appb-000072
计算
Figure PCTCN2018125273-appb-000073
则该用户的公钥为v∈G 1,用户的私钥为x∈Z p
Sig.对于一个用户,其私钥为x,给定消息为M∈{0,1} *,计算h←h(M),其中h∈G 2,且σ←h x,则签名为σ←G 2.
Ver.给定用户公钥为v,消息为M,签名为σ,计算h←h(M);如果e(g 1,σ)=e(v,h)成立,则接收,否则拒绝。
Aggregation.对于用户集合的聚合
Figure PCTCN2018125273-appb-000074
每个用户分配一个索引i,从1至k=|U|。对于消息M i∈{0,1} *,每个用户u i∈U提供一个签名σ i∈G 2。注意所有的消息M i必须是互不相同的。计算
Figure PCTCN2018125273-appb-000075
则聚合签名为σ∈G 2.
Aggregate Verification.对于用户集合U的聚合,给定一个聚合签名σ∈G 2,其索引不变,给定原签名消息M i∈{0,1} *和对应用户u i∈U的公钥v i∈G 1.验证聚合签名σ:
各消息M i互不相同,否则拒绝;
对于用户索引1≤i≤k=|U|,计算h i←h(M i),如果
Figure PCTCN2018125273-appb-000076
成立,则接收,否则拒绝。
在投票过程中,如果每个投票用户对区块及其公钥计算摘要值后,再进行聚合签名
Figure PCTCN2018125273-appb-000077
则该签名过程满足签名消息互不相同条件。因此,与上述多重签名方案类似,聚合签名也可以用于eRoc共识算法。
【实施例五】
3.基于陷门哈希族(Trapdoor Hash Family)的eRoc共识算法
3.1定义
陷门哈希族包含一对(I;H),满足如下条件:
I是一个概率多项式时间秘钥生成算法,输入1 k,输出一对秘钥(PK,SK),使得公钥和私钥PK,SK的长度是k的多项式。
H是随机函数族。在H中的每个哈希函数对应于一个哈希公钥PK,且应用与消息,从一个空间M到一个有限空间R中的随机元素,哈希函数h PK的输出并不取决于陷门秘钥SK。
陷门哈希族(I;H)具有如下性质:
高效性:给定哈希公钥PK和一对(m,r)∈M×R,能够在多项式时间内计算函数值h PK(m;r)。
抗碰撞性:不存在概率多项式时间算法A,输入哈希公钥PK,以不可忽略的概率输出两对(m 1,r 1),(m 2,r 2)∈M×R,且m 1≠m 2,h PK(m 1;r 1)=h PK(m 2;r 2)。随机生成哈希公钥PK,其中(PK,SK)←I(1 k),且算法A随机投币。
陷门碰撞性:存在一个概率多项式时间算法,输入一对哈希公钥和私钥(PK,SK)←I(1 k),一对(m 1,r 1)∈M×R,和一个消息m 2∈M,输出一个值r 2∈R,且满足:
h PK(m 1;r 1)=h PK(m 2;r 2)
如果r 1在R上是均匀分布的,则r 2在R上与均匀分布计算不可区分。
3.2基于陷门哈希族的eRoc共识算法
步骤1:参数更新
种子更新:
Figure PCTCN2018125273-appb-000078
总节点数更新:Sum ξ=Sum ξ-1·x ξ/N 1
发块阈值更新:T 1 ξ=(N 1/Sum ξ)·2 W
投票阈值更新:T 2 ξ=(N 2/Sum ξ)·2 W
步骤2:区块广播
发块资格:
Figure PCTCN2018125273-appb-000079
如果
Figure PCTCN2018125273-appb-000080
则广播区块,否则拒绝。
区块广播:
Figure PCTCN2018125273-appb-000081
验证:
Figure PCTCN2018125273-appb-000082
步骤3:区块投票
分级:
Figure PCTCN2018125273-appb-000083
投票资格:
Figure PCTCN2018125273-appb-000084
如果
Figure PCTCN2018125273-appb-000085
则进行投票
Figure PCTCN2018125273-appb-000086
选票广播:
Figure PCTCN2018125273-appb-000087
选票验证:
Figure PCTCN2018125273-appb-000088
Figure PCTCN2018125273-appb-000089
步骤4:投票中继
中继资格:
Figure PCTCN2018125273-appb-000090
如果
Figure PCTCN2018125273-appb-000091
则进行投票
Figure PCTCN2018125273-appb-000092
否则拒绝。
中继:
Figure PCTCN2018125273-appb-000093
中继验证:
Figure PCTCN2018125273-appb-000094
步骤5:区块生效
如果
Figure PCTCN2018125273-appb-000095
Figure PCTCN2018125273-appb-000096
否则ValidBlock ξ←Blankblock.
【实施例六】
3.3基于离散对数困难问题的陷门哈希函数
秘钥生成算法I:选择一个随机安全素数p∈{0,1} k(即,一个素数p使得另外一个素数
Figure PCTCN2018125273-appb-000097
以及一个元素
Figure PCTCN2018125273-appb-000098
的阶为q。选择一个随机元素
Figure PCTCN2018125273-appb-000099
计算y=g αmod p。则公钥PK=y,私钥SK=α.
陷门哈希函数H:对于公钥PK=y,陷门哈希函数
Figure PCTCN2018125273-appb-000100
定义为
Figure PCTCN2018125273-appb-000101
3.4基于离散对数陷门哈希函数的eRoc共识算法
步骤1:参数更新
种子更新:
Figure PCTCN2018125273-appb-000102
总节点数更新:Sum ξ=Sum ξ-1·x ξ/N 1
发块阈值更新:T 1 ξ=(N 1/Sum ξ)·2 W
投票阈值更新:T 2 ξ=(N 2/Sum ξ)·2 W
步骤2:区块广播
发块资格:
Figure PCTCN2018125273-appb-000103
如果
Figure PCTCN2018125273-appb-000104
则广播区 块,否则拒绝。
区块广播:
Figure PCTCN2018125273-appb-000105
验证:
Figure PCTCN2018125273-appb-000106
步骤3:区块投票
分级:
Figure PCTCN2018125273-appb-000107
选票资格:
Figure PCTCN2018125273-appb-000108
如果
Figure PCTCN2018125273-appb-000109
则进行投票
Figure PCTCN2018125273-appb-000110
选票广播:
Figure PCTCN2018125273-appb-000111
选票验证:
Figure PCTCN2018125273-appb-000112
Figure PCTCN2018125273-appb-000113
步骤4:投票中继
中继资格:
Figure PCTCN2018125273-appb-000114
如果
Figure PCTCN2018125273-appb-000115
则进行投票
Figure PCTCN2018125273-appb-000116
否则拒绝。
中继:
Figure PCTCN2018125273-appb-000117
中继验证:
Figure PCTCN2018125273-appb-000118
步骤5:区块生效
如果
Figure PCTCN2018125273-appb-000119
Figure PCTCN2018125273-appb-000120
否则ValidBlock ξ←BlankBlock.
【实施例七】
3.5基于因子分解困难问题的陷门哈希函数
秘钥生成算法I 2:随机选择两个素数p,q∈{0,1} k/2,满足p≡3 mod 8和q=7 mod 8,计算n=pq,则哈希公钥为n对应的陷门秘钥为(p,q).
哈希函数H 2:对于一个哈希公钥n,h PK是消息空间M×QR n的函数,其中M是{0,1} *的 任意自由下标子集,且
Figure PCTCN2018125273-appb-000121
给定一个消息m=m[1]m[2]...m[|m|]和一个随机数r∈ RQR n
Figure PCTCN2018125273-appb-000122
其中
Figure PCTCN2018125273-appb-000123
Figure PCTCN2018125273-appb-000124
Figure PCTCN2018125273-appb-000125
为基于因子分解困难问题的陷门哈希函数。
给定一个陷门私钥SK=(p,q),函数
Figure PCTCN2018125273-appb-000126
在多项式时间内可计算,因此r 2的值在多项式内也是可计算的
Figure PCTCN2018125273-appb-000127
因此在因子分解困难假设下,(I 2,H 2)也是陷门哈希族。与上述基于离散对数困难问题的陷门哈希函数类似,可以根据因子分解困难问题的陷门哈希函数构造eRoc共识算法。
所属技术领域的技术人员能够理解,本发明的各个方面可以实现为系统、方法或程序产品。因此,本发明的各个方面可以具体实现为以下形式,即:完全的硬件实施方式、完全的软件实施方式(包括固件、微代码等),或硬件和软件方面结合的实施方式,这里可以统称为“电路”、“模块”或“系统”。
下面参照图6来描述根据本发明的这种实施方式的电子设备600。图6显示的电子设备600仅仅是一个示例,不应对本发明实施例的功能和使用范围带来任何限制。
如图6所示,电子设备600以通用计算设备的形式表现。电子设备600的组件可以包括但不限于:上述至少一个处理单元610、上述至少一个存储单元620、连接不同系统组件(包括存储单元620和处理单元610)的总线630。
其中,所述存储单元存储有程序代码,所述程序代码可以被所述处理单元610执行,使得所述处理单元610执行本说明书上述“示例性方法”部分中描述的根据本发明各种示例性实施方式的步骤。例如,所述处理单元610可以执行如图1中所示的S102,随机选择第一类网络节点以使所述第一类网络节点生成区块并在区块链网络中广播区块;S104,随机选择第二类网络节点以使所述第二类网络节点对所述第一类网络节点的区块进行投票并广播投票结果;S106,基于所述第二类网络节点的投票确定选中区块,根据所述选中区块生成区块链。
存储单元620可以包括易失性存储单元形式的可读介质,例如随机存取存储单元(RAM)6201和/或高速缓存存储单元6202,还可以进一步包括只读存储单元(ROM)6203。
存储单元620还可以包括具有一组(至少一个)程序模块6205的程序/实用工具6204,这样的程序模块6205包括但不限于:操作系统、一个或者多个应用程序、其它程序模块以及程序数据,这些示例中的每一个或某种组合中可能包括网络环境的实现。
总线630可以为表示几类总线结构中的一种或多种,包括存储单元总线或者存储单元控制器、外围总线、图形加速端口、处理单元或者使用多种总线结构中的任意总线结构的局域总线。
电子设备600也可以与一个或多个外部设备(例如键盘、指向设备、蓝牙设备等)通信,还可与一个或者多个使得用户能与该电子设备600交互的设备通信,和/或与使得该电子设备600能与一个或多个其它计算设备进行通信的任何设备(例如路由器、调制解调器等等)通信。这种通信可以通过输入/输出(I/O)接口650进行。并且,电子设备600还可以通过网络适配器660与一个或者多个网络(例如局域网(LAN),广域网(WAN)和/或公共网络,例如因特网)通信。如图所示,网络适配器660通过总线630与电子设备600的其它模块通信。应当明白,尽管图中未示出,可以结合电子设备600使用其它硬件和/或软件模块,包括但不限于:微代码、设备驱动器、冗余处理单元、外部磁盘驱动阵列、RAID系统、磁带驱动器以及数据备份存储系统等。
通过以上的实施方式的描述,本领域的技术人员易于理解,这里描述的示例实施方式可以通过软件实现,也可以通过软件结合必要的硬件的方式来实现。因此,根据本公开实施方式的技术方案可以以软件产品的形式体现出来,该软件产品可以存储在一个非易失性存储介质(可以是CD-ROM,U盘,移动硬盘等)中或网络上,包括若干指令以使得一台计算设备 (可以是个人计算机、服务器、终端装置、或者网络设备等)执行根据本公开实施方式的方法。
在本公开的示例性实施例中,还提供了一种计算机可读存储介质,其上存储有能够实现本说明书上述方法的程序产品。在一些可能的实施方式中,本发明的各个方面还可以实现为一种程序产品的形式,其包括程序代码,当所述程序产品在终端设备上运行时,所述程序代码用于使所述终端设备执行本说明书上述“示例性方法”部分中描述的根据本发明各种示例性实施方式的步骤。
根据本发明的实施方式的用于实现上述方法的程序产品,其可以采用便携式紧凑盘只读存储器(CD-ROM)并包括程序代码,并可以在终端设备,例如个人电脑上运行。然而,本发明的程序产品不限于此,在本文件中,可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。
所述程序产品可以采用一个或多个可读介质的任意组合。可读介质可以是可读信号介质或者可读存储介质。可读存储介质例如可以为但不限于电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。可读存储介质的更具体的例子(非穷举的列表)包括:具有一个或多个导线的电连接、便携式盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。
计算机可读信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了可读程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。可读信号介质还可以是可读存储介质以外的任何可读介质,该可读介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。
可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于无线、有线、光缆、RF等等,或者上述的任意合适的组合。
可以以一种或多种程序设计语言的任意组合来编写用于执行本发明操作的程序代码,所述程序设计语言包括面向对象的程序设计语言-诸如Java、C++等,还包括常规的过程式程序设计语言-诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算设备上执行、部分地在用户设备上执行、作为一个独立的软件包执行、部分在用户计算设备上部分在远程计算设备上执行、或者完全在远程计算设备或服务器上执行。在涉及远程计算设备的情形中,远程计算设备可以通过任意种类的网络,包括局域网(LAN)或广域网(WAN),连接到用户计算设备,或者,可以连接到外部计算设备(例如利用因特网服务提供商来通过因特网连接)。
此外,尽管在附图中以特定顺序描述了本公开中方法的各个步骤,但是,这并非要求或者暗示必须按照该特定顺序来执行这些步骤,或是必须执行全部所示的步骤才能实现期望的结果。附加的或备选的,可以省略某些步骤,将多个步骤合并为一个步骤执行,以及/或者将一个步骤分解为多个步骤执行等。
通过以上的实施方式的描述,本领域的技术人员易于理解,这里描述的示例实施方式可以通过软件实现,也可以通过软件结合必要的硬件的方式来实现。因此,根据本公开实施方式的技术方案可以以软件产品的形式体现出来,该软件产品可以存储在一个非易失性存储介质(可以是CD-ROM,U盘,移动硬盘等)中或网络上,包括若干指令以使得一台计算设备(可以是个人计算机、服务器、移动终端、或者网络设备等)执行根据本公开实施方式的方法。
本领域技术人员在考虑说明书及实践这里公开的发明后,将容易想到本公开的其它实施方案。本申请旨在涵盖本公开的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本公开的一般性原理并包括本公开未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本公开的真正范围和精神由所附的权利要求指 出。

Claims (36)

  1. 一种区块链生成方法,应用于区块链网络,所述区块链网络包括多个网络节点,其特征在于,包括:
    随机选择第一类网络节点以使所述第一类网络节点生成区块并在所述区块链网络中广播区块;
    随机选择第二类网络节点以使所述第二类网络节点对所述第一类网络节点的区块进行投票并广播投票结果;
    基于所述第二类网络节点的投票结果确定选中区块,根据所述选中区块生成区块链。
  2. 根据权利要求1所述的方法,其特征在于,所述随机选择第一类网络节点包括:
    基于在所述区块链网络中广播的种子、所述网络节点的私钥和第一阈值选择所述第一类网络节点;
    所述随机选择第二类网络节点包括:
    基于在所述区块链网络中广播的种子、所述网络节点的私钥和第二阈值选择所述第二类网络节点。
  3. 根据权利要求2所述的方法,其特征在于,基于在所述区块链网络中广播的种子、所述网络节点的私钥和第一阈值选择所述第一类网络节点,基于在所述区块链网络中广播的种子、所述网络节点的私钥和第二阈值选择所述第二类网络节点包括:
    网络节点根据自身的私钥和所述种子计算种子值;
    网络节点判断所述种子值是否小于所述第一阈值;
    如果所述种子值小于所述第一阈值,则网络节点被选为所述第一类网络节点;
    如果所述种子值大于等于所述第一阈值,则判断所述种子值是否小于所述第二阈值;
    如果所述种子值小于所述第二阈值,则所述网络节点被选为第二类网络节点。
  4. 根据权利要求3所述的方法,其特征在于,所述第一类网络节点生成的区块包括:上一轮选中区块的哈希值,所述第一类网络节点的种子值,所述第一类网络节点的公钥、所述第一类网络节点生成的下一轮的种子,所述第一类网络节点收集的所有交易单;
    所述第二类网络节点广播的投票结果包括:投票的区块,投票区块的哈希值,所述第二类网络节点的种子值,所述第二类网络节点的公钥。
  5. 根据权利要求4所述的方法,其特征在于,所述第二类网络节点对所述第一类网络节点的区块进行投票包括:
    所述第二类网络节点对所述第一类网络节点的区块按照所述种子值对区块进行投票,并广播所述投票结果。
  6. 根据权利要求5所述的方法,其特征在于,所述第二类网络节点在对接收的区块投票之前,还包括:
    所述第二类网络节点对所述第一类网络节点的区块进行验证。
  7. 根据权利要求5或6所述的方法,其特征在于,所述基于所述第二类网络节点的投票确定选中区块包括:
    所述第二类网络节点接收其他第二类网络节点的投票结果,并对投票结果进行中继;
    所述第二类网络节点将投票数超过系统阈值的网络节点和区块确定所述选中区块。
  8. 根据权利要求7所述的方法,其特征在于,还包括:
    所述第二类网络节点对于其他第二类网络节点的投票结果进行验证。
  9. 根据权利要求8所述的方法,其特征在于,所述第一类网络节点生成的区块还包括总节点数;
    所述第一阈值根据所述区块链网络中的总节点数和第一预定数量确定,所述第二阈值根据所述区块链网络中的总节点数和第二预定数量确定。
  10. 根据权利要求9所述的方法,其特征在于,所述第一阈值根据所述区块链网络中的总节点数和第一预定数量确定包括:
    T 1 ξ=(N 1/Sum ξ)·2 W
    所述第二阈值根据所述区块链网络中的总节点数和第二预定数量确定包括;
    Figure PCTCN2018125273-appb-100001
    其中,ξ表示轮次数,T 1 ξ表示第一阈值,
    Figure PCTCN2018125273-appb-100002
    表示第二阈值,N 1表示第一预定数量,N 2表示第二预定数量,Sum ξ表示第ξ轮系统的总节点数,W表示抽签函数输出的位宽。
  11. 根据权利要求7所述的方法,其特征在于,还包括:
    如果在规定时间范围内所有区块的投票数没有超过所述系统阈值,则以空区块作为选中区块。
  12. 根据权利要求11所述的方法,其特征在于,所述第二类网络节点确定选中区块后,在区块链网络中广播选中结果。
  13. 根据权利要求11所述的方法,其特征在于,基于如下公式生成下一轮种子:
    Figure PCTCN2018125273-appb-100003
    其中,Seed ξ表示第ξ轮的种子,Seed ξ-1表示第ξ-1轮的种子,
    Figure PCTCN2018125273-appb-100004
    表示网络节点α i的私钥,VRF()表示可验证随机函数,ValidBlock ξ-1表示第ξ-1轮的共识区块,
    Figure PCTCN2018125273-appb-100005
    表示第ξ-1轮选中区块为网络节点Node i的区块,BlankBlock为空白区块。
  14. 根据权利要求10所述的方法,其特征在于,根据如下公式更新总节点数:
    Sum ξ=Sum ξ-1·x ξ/N 1
    其中,Sum ξ表示第ξ轮的总节点数,Sum ξ-1表示第ξ-1轮的总节点数,N 1表示第一预定数量,x ξ表示第ξ轮实际发出的区块数量。
  15. 根据权利要求9所述的方法,其特征在于,所述网络节点根据自身的私钥和所述种子计算种子值包括:
    Figure PCTCN2018125273-appb-100006
    所述第一类网络节点生成区块包括:
    Figure PCTCN2018125273-appb-100007
    所述第二类网络节点广播投票结果包括:
    Figure PCTCN2018125273-appb-100008
    所述第二类网络节点对接收的所述第一类网络节点的区块进行验证包括:
    Figure PCTCN2018125273-appb-100009
    所述第二类网络节点对接收的投票结果进行验证包括:
    Figure PCTCN2018125273-appb-100010
    所述第二类网络节点对对投票结果进行中继发送包括:
    Figure PCTCN2018125273-appb-100011
    其中,α i、β 1、β i分别表示网络节点,ξ、ξ-1表示轮次数,
    Figure PCTCN2018125273-appb-100012
    分别表示网络节点α i、β 1、β i第ξ轮的种子值,
    Figure PCTCN2018125273-appb-100013
    表示网络节点α i的私钥,
    Figure PCTCN2018125273-appb-100014
    Figure PCTCN2018125273-appb-100015
    表示网络节点α i、β 1、β i的公钥,Sum ξ表示第ξ轮的总节点数,Sum ξ-1表示第ξ-1轮的总节点数,T 1 ξ表示第ξ轮的第一阈值,
    Figure PCTCN2018125273-appb-100016
    表示第ξ轮的第二阈值,N 1表示第一预定数量,N 2表示第二预定数量,x ξ表示第ξ轮实际发出的区块数量,Block ξ-1表示第ξ-1轮选中区块,
    Figure PCTCN2018125273-appb-100017
    表示第ξ轮网络节点α i区块,
    Figure PCTCN2018125273-appb-100018
    表示第ξ投票的种子值最小的区块,T 1 ξ-1表示第ξ-1轮的第一阈值,
    Figure PCTCN2018125273-appb-100019
    表示第ξ-1轮的第二阈值,VRF()表示可验证随机函数,Hash()表示哈希函数,Tx 1,...,n表示n个交易单。
  16. 根据权利要求9所述的方法,其特征在于,所述网络节点根据自身的私钥和所述种子计算种子值包括:
    Figure PCTCN2018125273-appb-100020
    所述第一类网络节点生成区块包括:
    Figure PCTCN2018125273-appb-100021
    所述第二类网络节点广播投票结果包括:
    Figure PCTCN2018125273-appb-100022
    所述第二类网络节点对接收的所述第一类网络节点的区块进行验证包括:
    Figure PCTCN2018125273-appb-100023
    所述第二类网络节点对接收的投票结果进行验证包括:
    Figure PCTCN2018125273-appb-100024
    所述第二类网络节点对对投票结果进行中继发送包括:
    Figure PCTCN2018125273-appb-100025
    其中,α i、β 1、β i分别表示网络节点,ξ、ξ-1表示轮次数,
    Figure PCTCN2018125273-appb-100026
    分别表示网络节点α i、β 1、β i第ξ轮的种子值,
    Figure PCTCN2018125273-appb-100027
    表示网络节点α i的私钥,
    Figure PCTCN2018125273-appb-100028
    Figure PCTCN2018125273-appb-100029
    表示网络节点α i、β 1、β i的公钥,Sum ξ表示第ξ轮的总节点数,Sum ξ-1表示第ξ-1的总节点数,T 1 ξ表示第ξ轮的第一阈值,
    Figure PCTCN2018125273-appb-100030
    表示第ξ轮的第二阈值,N 1表示第一预定数量,N 2表示第二预定数量,x ξ表示第ξ轮实际发出的区块数量,Block ξ-1表示第ξ-1轮选中区块,
    Figure PCTCN2018125273-appb-100031
    表示第ξ轮网络节点α i区块,
    Figure PCTCN2018125273-appb-100032
    表示第ξ投票的种子值最小的区块,T 1 ξ-1表示第ξ-1轮的第一阈值,
    Figure PCTCN2018125273-appb-100033
    表示第ξ-1轮的第二阈值,Sig()表示数字签名,Ver()表示签名验证函数,Hash()表示哈希函数,Tx 1,...,n表示n个交易单。
  17. 根据权利要求9所述的方法,其特征在于,所述网络节点根据自身的私钥和所述种子计算种子值包括:
    Figure PCTCN2018125273-appb-100034
    所述第一类网络节点生成区块包括:
    Figure PCTCN2018125273-appb-100035
    所述第二类网络节点广播投票结果包括:
    Figure PCTCN2018125273-appb-100036
    所述第二类网络节点对接收的所述第一类网络节点的区块进行验证包括:
    Figure PCTCN2018125273-appb-100037
    所述第二类网络节点对接收的投票结果进行验证包括:
    Figure PCTCN2018125273-appb-100038
    所述第二类网络节点对对投票结果进行中继发送包括:
    Figure PCTCN2018125273-appb-100039
    其中,α i、β 1、β i分别表示网络节点,ξ、ξ-1表示轮次数,
    Figure PCTCN2018125273-appb-100040
    分别表示网络节点α i、β 1、β i第ξ轮的种子值,表示网络节点α i的私钥,
    Figure PCTCN2018125273-appb-100041
    表示网络节点α i、β 1、β i的公钥,Sum ξ表示第ξ轮的总节点数,Sum ξ-1表示第ξ-1的总节点数,T 1 ξ表示第ξ轮的第一阈值,
    Figure PCTCN2018125273-appb-100042
    表示第ξ轮的第二阈值,N 1表示第一预定数量,N 2表示第二预定数量,x ξ表示第ξ轮实际发出的区块数量,Block ξ-1表示第ξ-1轮选中区块,
    Figure PCTCN2018125273-appb-100043
    表示第ξ轮网络节点α i区块,
    Figure PCTCN2018125273-appb-100044
    表示第ξ投票的种子值最小的区块,T 1 ξ-1表示第ξ-1轮的第一阈值,
    Figure PCTCN2018125273-appb-100045
    表示第ξ-1轮的第二阈值,
    Figure PCTCN2018125273-appb-100046
    表示通过私钥SK i的多重签名,e()表示双线性映射函数,Hash()表示哈希函数,Tx 1,...,n表示n个交易单。
  18. 根据权利要求9所述的方法,其特征在于,所述网络节点根据自身的私钥和所述种子计算种子值包括:
    Figure PCTCN2018125273-appb-100047
    所述第一类网络节点生成区块包括:
    Figure PCTCN2018125273-appb-100048
    所述第二类网络节点广播投票结果包括:
    Figure PCTCN2018125273-appb-100049
    所述第二类网络节点对接收的所述第一类网络节点的区块进行验证包括:
    Figure PCTCN2018125273-appb-100050
    所述第二类网络节点对接收的投票结果进行验证包括:
    Figure PCTCN2018125273-appb-100051
    所述第二类网络节点对对投票结果进行中继发送包括:
    Figure PCTCN2018125273-appb-100052
    其中,α i、β 1、β i分别表示网络节点,ξ、ξ-1表示轮次数,
    Figure PCTCN2018125273-appb-100053
    分别表示网络节点α i、β 1、β i第ξ轮的种子值,
    Figure PCTCN2018125273-appb-100054
    表示网络节点α i的私钥,
    Figure PCTCN2018125273-appb-100055
    Figure PCTCN2018125273-appb-100056
    表示网络节点α i、β 1、β i的公钥,Sum ξ表示第ξ轮的总节点数,Sum ξ-1表示第ξ-1的总节点数,T 1 ξ表示第ξ轮的第一阈值,
    Figure PCTCN2018125273-appb-100057
    表示第ξ轮的第二阈值,N 1表示第一预定数量,N 2表示第二预定数量,x ξ表示第ξ轮实际发出的区块数量,Block ξ-1表示第ξ-1轮选中区块,
    Figure PCTCN2018125273-appb-100058
    表示第ξ轮网络节点α i区块,
    Figure PCTCN2018125273-appb-100059
    表示第ξ投票的种子值最小的区块,T 1 ξ-1表示第ξ-1轮的第一阈值,
    Figure PCTCN2018125273-appb-100060
    表示第ξ-1轮的第二阈值,
    Figure PCTCN2018125273-appb-100061
    表示通过私钥
    Figure PCTCN2018125273-appb-100062
    的陷门哈希族函数,
    Figure PCTCN2018125273-appb-100063
    表示通过公钥
    Figure PCTCN2018125273-appb-100064
    的陷门哈希族函数,Hash()表示哈希函数,Tx 1,...,n表示n个交易单。
  19. 根据权利要求9所述的方法,其特征在于,所述网络节点根据自身的私钥和所述种子计算种子值包括:
    Figure PCTCN2018125273-appb-100065
    所述第一类网络节点生成区块包括:
    Figure PCTCN2018125273-appb-100066
    所述第二类网络节点广播投票结果包括:
    Figure PCTCN2018125273-appb-100067
    所述第二类网络节点对接收的所述第一类网络节点的区块进行验证包括:
    Figure PCTCN2018125273-appb-100068
    所述第二类网络节点对接收的投票结果进行验证包括:
    Figure PCTCN2018125273-appb-100069
    所述第二类网络节点对对投票结果进行中继发送包括:
    Figure PCTCN2018125273-appb-100070
    其中,α i、β 1、β i分别表示网络节点,ξ、ξ-1表示轮次数,
    Figure PCTCN2018125273-appb-100071
    分别表示网络节点α i、β 1、β i第ξ轮的种子值,
    Figure PCTCN2018125273-appb-100072
    表示网络节点α i的私钥,
    Figure PCTCN2018125273-appb-100073
    Figure PCTCN2018125273-appb-100074
    表示网络节点α i、β 1、β i的公钥,Sum ξ表示第ξ轮的总节点数,Sum ξ-1表示第ξ-1的总节点数,T 1 ξ表示第ξ轮的第一阈值,
    Figure PCTCN2018125273-appb-100075
    表示第ξ轮的第二阈值,N 1表示第一预定数量,N 2表示第二预定数量,x ξ表示第ξ轮实际发出的区块数量,Block ξ-1表示第ξ-1轮选中区块,
    Figure PCTCN2018125273-appb-100076
    表示第ξ轮网络节点α i区块,
    Figure PCTCN2018125273-appb-100077
    表示第ξ投票的种子值最小的区块,T 1 ξ-1表示第ξ-1轮的第一阈值,
    Figure PCTCN2018125273-appb-100078
    表示第ξ-1轮的第二阈值,所述种子值的生成和验证基于离散对数陷门哈希函数,Hash()表示哈希函数,Tx 1,...,n表示n个交易单。
  20. 一种区块链生成方法,应用于区块链网络,所述区块链网络包括多个网络节点,其特征在于,包括:
    网络节点基于区块链协定判断是否被选为第一类网络节点;
    如果所述网络节点被选为第一类网络节点,则所述网络节点生成区块并在所述区块链网络中广播区块;
    如果网络节点未被选为第一类网络节点,则所述网络节点基于区块链协定判断是否被选为第二类网络节点;
    如果所述网络节点被选为第二类网络节点,则所述网络节点对接收的区块进行投票并广播投票结果;
    所述第二类网络节点基于接收的各个第二类网络节点的投票确定选中区块,根据所述选中区块生成区块链。
  21. 根据权利要求20所述的方法,其特征在于,所述网络节点基于区块链协定判断是否被选为第一类网络节点包括:
    所述网络节点基于在所述区块链网络中广播的种子、所述网络节点的私钥和第一阈值判断是否被选为所述第一类网络节点;
    所述网络节点基于区块链协定判断是否被选为第二类网络节点包括:
    所述网络节点基于在所述区块链网络中广播的种子、所述网络节点的私钥和第二阈值判断是否被选为所述第二类网络节点。
  22. 根据权利要求21所述的方法,其特征在于,所述网络节点基于在所述区块链网络中广播的种子、所述网络节点的私钥和第一阈值判断是否被选为所述第一类网络节点,基于在所述区块链网络中广播的种子、所述网络节点的私钥和第二阈值判断是否被选为所述第二类网络节点包括:
    所述网络节点根据自身的私钥和所述种子计算种子值;
    所述网络节点判断所述种子值是否小于所述第一阈值;
    如果所述种子值小于所述第一阈值,则所述网络节点被选为所述第一类网络节点;
    如果所述种子值大于等于所述第一阈值,则所述网络节点判断所述种子值是否小于所述第二阈值;
    如果所述种子值小于所述第二阈值,则所述网络节点被选为第二类网络节点。
  23. 根据权利要求22所述的方法,其特征在于,所述第一类网络节点生成的区块包括:上一轮选中区块的哈希值,所述第一类网络节点的种子值,所述第一类网络节点的公钥、所述第一类网络节点生成的下一轮的种子,所述第一类网络节点收集的所有交易单;
    所述第二类网络节点广播的投票结果包括:投票的区块,投票区块的哈希值,所述第二类网络节点的种子值,所述第二类网络节点的公钥。
  24. 根据权利要求23所述的方法,其特征在于,所述第二类网络节点对所述第一类网络节点的区块进行投票包括:
    所述第二类网络节点对所述第一类网络节点的区块按照所述种子值对区块进行投票,并广播所述投票结果。
  25. 根据权利要求24所述的方法,其特征在于,所述第二类网络节点在对接收的区块投票之前,还包括:
    所述第二类网络节点对所述第一类网络节点的区块进行验证。
  26. 根据权利要求24或25所述的方法,其特征在于,所述基于所述第二类网络节点的投票确定选中区块包括:
    所述第二类网络节点接收其他第二类网络节点的投票结果,并对投票结果进行中继;
    所述第二类网络节点将投票数超过系统阈值的区块确定所述选中区块。
  27. 根据权利要求26所述的方法,其特征在于,还包括:
    所述第二类网络节点对于其他第二类网络节点的投票结果进行验证。
  28. 根据权利要求27所述的方法,其特征在于,所述第一类网络节点生成的区块还包括总节点数;
    所述第一阈值根据所述区块链网络中的总节点数和第一预定数量确定,所述第二阈值根据所述区块链网络中的总节点数和第二预定数量确定。
  29. 根据权利要求28所述的方法,其特征在于,所述第一阈值根据所述区块链网络中的总节点数和第一预定数量确定包括:
    T 1 ξ=(N 1/Sum ξ)·2 W
    所述第二阈值根据所述区块链网络中的总节点数和第二预定数量确定包括;
    Figure PCTCN2018125273-appb-100079
    其中,ξ表示轮次,T 1 ξ表示第一阈值,
    Figure PCTCN2018125273-appb-100080
    表示第二阈值,N 1表示第一预定数量,N 2表示第二预定数量,Sum ξ表示第ξ轮系统的总节点数,W表示抽签函数输出的位宽。
  30. 根据权利要求26所述的方法,其特征在于,还包括:
    如果在规定时间范围内所有区块的投票数没有超过所述系统阈值,则所述第二类节点以空区块作为选中区块。
  31. 根据权利要求30所述的方法,其特征在于,所述第二类网络节点确定选中区块后,在区块链网络中广播选中结果。
  32. 根据权利要求30所述的方法,其特征在于,基于如下公式生成下一轮种子:
    Figure PCTCN2018125273-appb-100081
    其中,Seed ξ表示第ξ轮的种子,Seed ξ-1表示第ξ-1轮的种子,
    Figure PCTCN2018125273-appb-100082
    表示网络节点α i的私钥,VRF()表示可验证随机函数,ValidBlock ξ-1表示第ξ-1轮的共识区块,
    Figure PCTCN2018125273-appb-100083
    表示第ξ-1轮选中区块为网络节点Node i的区块,BlankBlock为空白区块。
  33. 根据权利要求29所述的方法,其特征在于,根据如下公式更新总节点数:
    Sum ξ=Sum ξ-1·x ξ/N 1
    其中,Sum ξ表示第ξ轮的总节点数,Sum ξ-1表示第ξ-1轮的总节点数,N 1表示第一预定数量,x ξ表示第ξ轮实际发出的区块数量。
  34. 一种区块链生成系统,其特征在于,包括:多个位于区块链网络中的网络节点;
    网络节点基于区块链协定判断是否被选为第一类网络节点;
    如果网络节点被选为第一类网络节点,则生成区块并在所述区块链网络中广播区块;
    如果网络节点未被选为第一类网络节点,则基于区块链协定判断是否被选为第二类网络节点;
    如果网络节点被选为第二类网络节点,则对接收的区块进行投票并广播投票结果;
    如果网络节点未被选为第二类网络节点,则基于接收的第二类网络节点的投票确定选中区块,根据所述选中区块生成区块链。
  35. 一种计算机可读存储介质,其上存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现权利要求1~33中任意一项所述的区块链生成方法。
  36. 一种电子设备,其特征在于,包括:
    处理器;以及
    存储器,用于存储所述处理器的可执行指令;
    其中,所述处理器配置为经由执行所述可执行指令来执行权利要求1~33中任意一项所述区块链生成方法。
PCT/CN2018/125273 2018-12-29 2018-12-29 区块链生成方法、系统、计算机存储介质和电子设备 WO2020133326A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/125273 WO2020133326A1 (zh) 2018-12-29 2018-12-29 区块链生成方法、系统、计算机存储介质和电子设备

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/125273 WO2020133326A1 (zh) 2018-12-29 2018-12-29 区块链生成方法、系统、计算机存储介质和电子设备

Publications (1)

Publication Number Publication Date
WO2020133326A1 true WO2020133326A1 (zh) 2020-07-02

Family

ID=71127344

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/125273 WO2020133326A1 (zh) 2018-12-29 2018-12-29 区块链生成方法、系统、计算机存储介质和电子设备

Country Status (1)

Country Link
WO (1) WO2020133326A1 (zh)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112101940A (zh) * 2020-09-16 2020-12-18 上海万向区块链股份公司 用区块链实施的随机可验证样本选取系统
CN112541791A (zh) * 2020-12-16 2021-03-23 中国联合网络通信集团有限公司 资源兑换方法和服务器
CN112887078A (zh) * 2021-02-02 2021-06-01 中国银联股份有限公司 一种编辑区块链中区块的方法及装置
CN113096299A (zh) * 2021-04-28 2021-07-09 浙江数秦科技有限公司 一种基于联盟链的不记名电子投票方法
CN113489671A (zh) * 2021-05-11 2021-10-08 深圳前海移联科技有限公司 一种跨联盟链通讯方法、装置、计算机设备及存储介质
CN113722137A (zh) * 2021-08-26 2021-11-30 杭州优海信息系统有限公司 用于共享工业智能设备故障修复方案的方法及设备
CN114077637A (zh) * 2020-08-12 2022-02-22 北京航空航天大学 分片区块链实现方法
CN114615286A (zh) * 2022-03-15 2022-06-10 上海万向区块链股份公司 基于跨链技术的碳普惠业务数据流转方法和系统
CN114978524A (zh) * 2022-04-21 2022-08-30 浪潮云信息技术股份公司 一种基于离散对数的多重变色龙哈希方法及系统
CN115314352A (zh) * 2022-07-27 2022-11-08 北京航空航天大学 隐私增强的公平区块链领导者选举方法及装置
CN115396504A (zh) * 2022-08-23 2022-11-25 浪潮工业互联网股份有限公司 一种区块链投票数据缓存方法、设备及介质
CN115396432A (zh) * 2022-07-29 2022-11-25 北京理工大学 二元协商方法及装置、电子设备和存储介质
CN115514608A (zh) * 2021-06-22 2022-12-23 腾讯科技(深圳)有限公司 一种区块共识方法、装置、设备及存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106445711A (zh) * 2016-08-28 2017-02-22 杭州云象网络技术有限公司 一种应用于区块链的拜占庭容错共识方法
CN107124403A (zh) * 2017-04-14 2017-09-01 朱清明 区块链中共识区块的生成方法与计算设备
US20170352219A1 (en) * 2015-08-06 2017-12-07 Blockchain Technologies Corporation System and method for securely receiving and counting votes in an election
CN108614748A (zh) * 2018-04-19 2018-10-02 上海分布信息科技有限公司 一种拜占庭容错的方法及其通证经济的治理系统
CN109039646A (zh) * 2018-07-12 2018-12-18 北京链享未来科技有限公司 一种基于节点能力的区块链区块打包和验证方法及系统

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170352219A1 (en) * 2015-08-06 2017-12-07 Blockchain Technologies Corporation System and method for securely receiving and counting votes in an election
CN106445711A (zh) * 2016-08-28 2017-02-22 杭州云象网络技术有限公司 一种应用于区块链的拜占庭容错共识方法
CN107124403A (zh) * 2017-04-14 2017-09-01 朱清明 区块链中共识区块的生成方法与计算设备
CN108614748A (zh) * 2018-04-19 2018-10-02 上海分布信息科技有限公司 一种拜占庭容错的方法及其通证经济的治理系统
CN109039646A (zh) * 2018-07-12 2018-12-18 北京链享未来科技有限公司 一种基于节点能力的区块链区块打包和验证方法及系统

Cited By (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114077637A (zh) * 2020-08-12 2022-02-22 北京航空航天大学 分片区块链实现方法
CN114077637B (zh) * 2020-08-12 2022-12-27 北京航空航天大学 分片区块链实现方法
CN112101940A (zh) * 2020-09-16 2020-12-18 上海万向区块链股份公司 用区块链实施的随机可验证样本选取系统
CN112541791A (zh) * 2020-12-16 2021-03-23 中国联合网络通信集团有限公司 资源兑换方法和服务器
CN112541791B (zh) * 2020-12-16 2023-06-30 中国联合网络通信集团有限公司 资源兑换方法和服务器
CN112887078B (zh) * 2021-02-02 2022-10-14 中国银联股份有限公司 一种编辑区块链中区块的方法及装置
CN112887078A (zh) * 2021-02-02 2021-06-01 中国银联股份有限公司 一种编辑区块链中区块的方法及装置
CN113096299B (zh) * 2021-04-28 2022-05-24 浙江数秦科技有限公司 一种基于联盟链的不记名电子投票方法
CN113096299A (zh) * 2021-04-28 2021-07-09 浙江数秦科技有限公司 一种基于联盟链的不记名电子投票方法
CN113489671A (zh) * 2021-05-11 2021-10-08 深圳前海移联科技有限公司 一种跨联盟链通讯方法、装置、计算机设备及存储介质
CN115514608A (zh) * 2021-06-22 2022-12-23 腾讯科技(深圳)有限公司 一种区块共识方法、装置、设备及存储介质
CN113722137A (zh) * 2021-08-26 2021-11-30 杭州优海信息系统有限公司 用于共享工业智能设备故障修复方案的方法及设备
CN114615286A (zh) * 2022-03-15 2022-06-10 上海万向区块链股份公司 基于跨链技术的碳普惠业务数据流转方法和系统
CN114615286B (zh) * 2022-03-15 2024-01-02 上海万向区块链股份公司 基于跨链技术的碳普惠业务数据流转方法和系统
CN114978524A (zh) * 2022-04-21 2022-08-30 浪潮云信息技术股份公司 一种基于离散对数的多重变色龙哈希方法及系统
CN114978524B (zh) * 2022-04-21 2024-04-12 浪潮云信息技术股份公司 一种基于离散对数的多重变色龙哈希方法及系统
CN115314352B (zh) * 2022-07-27 2023-12-12 北京航空航天大学 隐私增强的公平区块链领导者选举方法及装置
CN115314352A (zh) * 2022-07-27 2022-11-08 北京航空航天大学 隐私增强的公平区块链领导者选举方法及装置
CN115396432A (zh) * 2022-07-29 2022-11-25 北京理工大学 二元协商方法及装置、电子设备和存储介质
CN115396504A (zh) * 2022-08-23 2022-11-25 浪潮工业互联网股份有限公司 一种区块链投票数据缓存方法、设备及介质
CN115396504B (zh) * 2022-08-23 2024-01-16 浪潮工业互联网股份有限公司 一种区块链投票数据缓存方法、设备及介质

Similar Documents

Publication Publication Date Title
WO2020133326A1 (zh) 区块链生成方法、系统、计算机存储介质和电子设备
US11232478B2 (en) Methods and system for collecting statistics against distributed private data
CN107113179B (zh) 用于通信验证的方法、系统及非瞬时计算机可读存储介质
CN110198213B (zh) 一种基于秘密共享随机数共识算法的系统
CN111108732A (zh) 用于确定数字资产交易所的偿付能力的方法、系统和计算机程序产品
US9641340B2 (en) Certificateless multi-proxy signature method and apparatus
CN108769230B (zh) 交易数据存储方法、装置、服务器及存储介质
Mazumdar et al. Design of anonymous endorsement system in hyperledger fabric
CN110892674A (zh) 区块链的交易生成方法和区块链的块验证方法
Ma et al. Practical lattice-based multisignature schemes for blockchains
CN117112196A (zh) 用于区块链网络中一致分布式内存池的方法和系统
CN113783697B (zh) 一种基于委托的数据广播服务证明共识协议应用方法
WO2019166916A1 (en) Computer implemented voting process and system
US20220374544A1 (en) Secure aggregation of information using federated learning
CN110445795B (zh) 一种区块链认证唯一性确认方法
Campanelli et al. Succinct zero-knowledge batch proofs for set accumulators
CN110149379A (zh) 一种基于层逻辑的多原链吞吐量扩展方法
CN110990790B (zh) 一种数据处理方法及设备
CN112613601A (zh) 神经网络模型更新方法、设备及计算机存储介质
Lin et al. Blockchain-based complete self-tallying E-voting protocol
CN113939821A (zh) 用于在工作量证明区块链网络上进行非并行挖掘的系统和方法
ElSheikh et al. Dispute-free scalable open vote network using zk-SNARKs
Zhu et al. New instant confirmation mechanism based on interactive incontestable signature in consortium blockchain
Baniata et al. Prifob: a privacy-aware fog-enhanced blockchain-based system for global accreditation and credential verification
Blum et al. Superlight–A permissionless, light-client only blockchain with self-contained proofs and BLS signatures

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18944141

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18944141

Country of ref document: EP

Kind code of ref document: A1