WO2020221292A1 - 基于多个节点的网络交易验证方法及其系统和存储介质 - Google Patents

基于多个节点的网络交易验证方法及其系统和存储介质 Download PDF

Info

Publication number
WO2020221292A1
WO2020221292A1 PCT/CN2020/087770 CN2020087770W WO2020221292A1 WO 2020221292 A1 WO2020221292 A1 WO 2020221292A1 CN 2020087770 W CN2020087770 W CN 2020087770W WO 2020221292 A1 WO2020221292 A1 WO 2020221292A1
Authority
WO
WIPO (PCT)
Prior art keywords
transaction
nodes
verification
linked list
node
Prior art date
Application number
PCT/CN2020/087770
Other languages
English (en)
French (fr)
Other versions
WO2020221292A9 (zh
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 SG11202110209WA priority Critical patent/SG11202110209WA/en
Priority to JP2021544762A priority patent/JP7192196B2/ja
Priority to CN202080011112.0A priority patent/CN113348656A/zh
Publication of WO2020221292A1 publication Critical patent/WO2020221292A1/zh
Publication of WO2020221292A9 publication Critical patent/WO2020221292A9/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 e-commerce, and in particular to a multi-node-based network transaction verification method, and a corresponding computer system and storage medium.
  • both parties to the transaction may directly reach transaction agreements and fund transfers through the Internet. Therefore, the two parties to the transaction cannot directly confirm the identity of the other party as in the traditional transaction method, and whether the goods/services and funds are delivered in the manner specified in the agreement during the transaction. At this time, both parties to the transaction often need to verify their identities through a third-party transaction platform and guarantee the transaction.
  • third-party trading platforms When merchants or users use third-party trading platforms to conduct transactions, they must first provide proof of identity. At the same time, the merchant may also need to provide additional guarantee money. Third-party trading platforms need to spend corresponding costs to verify the true identities of the parties involved in the transaction, and promptly handle disputes that may arise during the transaction. Especially for daily massive small-value transactions, the back-end server of the third-party trading platform needs to verify the identities of both parties in each transaction, confirm the content of the transaction, and ensure the safety of funds, so as to ensure that the transaction is a transaction with a corresponding account. The true meaning of both parties. This puts forward higher requirements on the operation and maintenance capabilities and costs of third-party platforms.
  • the present disclosure proposes a multi-node-based network transaction verification method, and its corresponding computer system and storage medium to alleviate the problems in the related technical solutions.
  • the above-mentioned technical solution of the present application can obtain the effect of efficiently verifying the validity of each transaction.
  • the present disclosure proposes a multi-node-based network transaction verification method, which includes the following steps: identifying actual identities corresponding to multiple nodes participating in network transactions; selecting some nodes from the multiple nodes as used to verify network transactions The verification node of the node; initialize the public P2P channel transmission data between the multiple nodes and the current public transaction record linked list used to record the network transaction; generate and add the content by the IBFT (Istanbul Byzantine Fault Tolerant) consensus algorithm The transaction information and the signed data block to the current public transaction record linked list.
  • the node can participate in the client of network transaction.
  • the client terminal stores the real identity information of the real identity.
  • the real identity information can be saved on the device where the client is installed.
  • the foregoing initialization of the public P2P channel transmission data between the multiple nodes and the current public transaction record linked list used to record network transactions The step also includes the following sub-steps: collecting verification results returned by at least 2F+1 verification nodes; counting the collected verification results, and when the number of data blocks passing verification nodes is greater than or equal to F+1, the data The block is recorded to the end of the current public transaction record linked list.
  • the data block is write-locked during the verification process, so that all nodes process the data block in a read-only manner.
  • the data block is generated at a constant frequency, and when there is no new transaction information currently, the transaction information in the data block is empty.
  • the following steps are also performed: when the verification of 2/3 of the total number of all nodes cannot be passed, the The verification node no longer acts as a verification node.
  • the following steps are also performed: when the newly added node passes the total number of all nodes 2/3 When verifying, the node is selected as the new verification node.
  • the above-mentioned update threshold is 30,000 (that is, the above-mentioned verification is performed every time 30,000 data blocks are added).
  • the following steps may also be performed between any two or more nodes: initialize a private transaction transmission channel and a private transaction data linked list based on the current public transaction record linked list, and pass the private transaction
  • the transaction transmission channel shares the private transaction data link to the two or more nodes; through the Raft consensus algorithm, the data block containing transaction information and signatures between the two or more nodes is added to the private transaction data linked list At the end; through the private transaction transmission channel, incrementally update the private transaction data linked list to the two or more nodes; wherein, the private transaction transmission channel is different from the public P2P channel.
  • the computer system includes a memory, a processor, and a computer program stored on the memory and running on the processor.
  • the processor executes the program, the following steps are performed: identifying the actual identities corresponding to multiple nodes participating in network transactions; selecting some nodes from the multiple nodes as verification nodes for verifying network transaction nodes; and initializing
  • the public P2P channel between the multiple nodes transmits data and the current public transaction record linked list used to record network transactions; the data block containing transaction information and signature is generated and added to the current public transaction record linked list through the IBFT consensus algorithm.
  • the steps of initializing the public P2P channel transmission data between the multiple nodes and the current public transaction record linked list used to record network transactions It also includes the following sub-steps: collecting the verification results returned by at least 2F+1 verification nodes; counting the collected verification results, and when the number of the data block passes the verification node is greater than or equal to F+1, the data block Recorded to the end of the current public transaction record linked list.
  • the data block is write-locked during the verification process, so that all nodes process the data block in a read-only manner.
  • the data block is generated at a constant frequency, and when there is no new transaction information currently, the transaction information in the data block is empty.
  • the following steps are also performed: When the verification of 2/3 of the total number of all verification nodes cannot be passed, so The verification node is no longer a verification node.
  • the following steps are also executed: when the newly added node passes the total number of verification nodes 2/ In the verification of 3, the node is selected as the new verification node.
  • the aforementioned update threshold is 30000.
  • the processor when the processor executes the program, the following steps may be performed between any two or more nodes: initializing a private transaction transmission channel and a link list based on the current public transaction record Private transaction data link list, and share the private transaction data link to the two or more nodes through the private transaction transmission channel; through the Raft consensus algorithm, add the transaction information and signature between the two or more nodes Data block to the end of the private transaction data linked list; through the private transaction transmission channel, incrementally update the private transaction data linked list to the two or more nodes; wherein, the private transaction transmission channel is different from The public P2P channel.
  • this application discloses a storage medium in which a computer program is stored.
  • the computer program is configured to execute the following steps when running: identify the actual identities corresponding to multiple nodes participating in network transactions; select some nodes from the multiple nodes as verification nodes for verifying network transaction nodes;
  • the public P2P channel between the multiple nodes transmits data and the current public transaction record linked list used to record network transactions; the IBFT consensus algorithm generates and adds data blocks containing transaction information and signatures to the current public transaction record linked list.
  • the steps of initializing the public P2P channel transmission data between the multiple nodes and the current public transaction record linked list used to record network transactions It also includes the following sub-steps: collecting the verification results returned by at least 2F+1 verification nodes; counting the collected verification results, and when the number of the data block passes the verification node is greater than or equal to F+1, the data block Recorded to the end of the current public transaction record linked list.
  • the data block is write-locked during the verification process, so that all nodes process the data block in a read-only manner.
  • the data block is generated at a constant frequency, and when there is no new transaction information currently, the transaction information in the data block is empty.
  • the following steps are also performed: when the verification of 2/3 of the total number of all nodes cannot be passed, the The verification node no longer acts as a verification node.
  • the following steps are also performed: when the newly added node passes the total number of all nodes 2/3 When verifying, the node is selected as the new verification node.
  • the aforementioned update threshold is 30000.
  • the following steps may also be performed between any two or more nodes: initializing the private transaction transmission channel and based on the current public transaction record linked list Private transaction data link list, and share the private transaction data link to the two or more nodes through the private transaction transmission channel; through the Raft consensus algorithm, add the transaction information and signature between the two or more nodes Data block to the end of the private transaction data linked list; through the private transaction transmission channel, incrementally update the private transaction data linked list to the two or more nodes; wherein, the private transaction transmission channel is different from The public P2P channel.
  • the beneficial effects of the present disclosure are: the same transaction is verified by multiple nodes selected at random to ensure that in the case of high concurrency of transaction records, even if some nodes are down, or some nodes are malicious transaction participants Control and arbitrarily verify transactions in real time, and the corresponding transactions can still be properly verified. Because the real identities of all transaction participants are identified, this technical solution can track the actual participants of each transaction, thereby ensuring the reliability of the transaction. Since different consensus algorithms (IBFT and Raft) are used in public and private transactions, the disclosed scheme can avoid transaction forks. On the contrary, public blockchain transaction schemes using Proof of Work (PoW) will often have forks (or even hard forks) and waste resources.
  • PoW Proof of Work
  • Fig. 1 shows a flow chart of a multi-node-based network transaction verification method according to an embodiment of the present disclosure
  • Figure 2 is a schematic diagram of the network formed by multiple nodes used for network transaction verification in Figure 1;
  • Figure 3 shows a schematic diagram of the data structure of the data block and the current public transaction record linked list
  • FIG. 4 is a flowchart of the sub-method of initializing the public P2P channel transmission data between the multiple nodes and the current public transaction record linked list for recording network transactions in FIG. 1;
  • Figure 5 shows a flowchart of verifying transactions between any two or more nodes according to an embodiment of the present disclosure
  • Fig. 6 shows a framework diagram of a multi-node-based network transaction verification system according to an embodiment of the present disclosure.
  • both parties to the transaction often need to pay considerable costs to verify the identity, qualifications, and historical transaction records of the other party to ensure the reliability of the transaction.
  • the reliability of the transaction object is generally based on the transaction object's past transaction records; and the commercial credit evaluation made by other participants in the transaction history of the transaction object. This information is the reference factor for both parties in the transaction to evaluate each other's commercial credit.
  • these factors are used and used as indicators for measuring transaction security, so as to provide an e-commerce transaction security test for both parties to the transaction.
  • the identities of the two or more parties participating in the transaction can be verified on various terminals (such as laptops, desktop computers, smart phones, and tablet computers, etc.) through common identity verification methods in the field and communicate with the terminal. Bind. At this time, the corresponding terminal will become one of multiple nodes used for network transaction verification.
  • FIG. 1 is a schematic flowchart of a multi-node-based network transaction verification method according to an embodiment of the present disclosure.
  • the method includes: identifying actual identities corresponding to multiple nodes participating in network transactions; Select some of the multiple nodes as verification nodes for verifying network transaction nodes; initialize the public P2P channel transmission data between the multiple nodes and the current public transaction record linked list used to record network transactions; generated by the IBFT consensus algorithm And add a data block containing transaction information and signature to the current public transaction record linked list.
  • the IBFT consensus algorithm uses the proof of rights (Proof of Authority, PoA) made by the selected and verified actual identity verification node as the commercial credit evaluation of each participant in the transaction. Proof of rights uses a group of verification nodes to verify new transactions. Through the consensus of most verification nodes, new network transactions generate corresponding data blocks and add them to transaction records. According to the IBFT consensus algorithm, each verification node can be randomly selected and dynamically changed during subsequent multiple transaction verification processes. Whenever a new network transaction needs to be verified, one of all verification nodes is randomly selected as the Proposer. The randomly selected proposal node generates a corresponding data block according to the new network transaction, and hands it to all verification nodes for verification. These verification nodes and other nodes are formed in the network structure shown in Figure 2.
  • each data block is verified by different groups of verification nodes, and after reaching a consensus, it is recorded as a digital signature on the data block.
  • the verification node verifies each transaction to determine whether the data block can be added to the current public transaction record linked list; while the ordinary node has a complete copy of the current public transaction record linked list, and the data block and the transaction information are transmitted between each node The verification result of the data block between each node, so that each node can quickly respond to the newly generated data block.
  • the data block can be realized in the data structure shown in Figure 3.
  • these data blocks can be linked by a linked list as shown in the figure to form the current public transaction record linked list, that is, the data header of each data block includes the digital signature of the previous data block (data block 1 Including the linked list header), which can easily verify each data block of the current public transaction record linked list, so that it can quickly determine whether the current public transaction record linked list has been maliciously damaged, and can delete illegal data blocks in a timely manner. Roll to the normal state.
  • Those skilled in the art may also choose other suitable data structures to record each data block and the current public transaction record linked list, so as to conveniently verify whether the current public transaction record linked list has been maliciously damaged and record the current public transaction record.
  • transaction verification methods can also be common verification methods in the field (such as verifying whether the digital signature in the data block is correct) and custom rules (such as whether the amount of each transaction exceeds the upper limit, and the past transactions of related parties Whether the method of recording and transaction is legal), this disclosure will not further limit this. Those skilled in the art can select an appropriate verification method according to the actual situation.
  • the current public transaction record linked list can be recorded in the data center, and each verified data block can be added to the current public transaction record linked list stored in the data center at any time by any node ( Including verification nodes and non-verified ordinary nodes) retrieved.
  • each node may also store a copy of the current public transaction record linked list locally, and after the data block is verified, update it incrementally to the local current public In the copy of the linked list of transaction records, the decentralized storage of the current linked list of public transaction records can be realized to improve the robustness and security of the system.
  • the IBFT consensus algorithm Since the purpose of the IBFT consensus algorithm is to enable trust between nodes in an untrusted network environment; therefore, the above network transaction verification method using the IBFT consensus algorithm allows some current users of the verification node to be malicious and will collude Get up and make wrong judgments on the verification of the transaction to maximize the destruction of normal transactions. Even in the worst scenario, the IBFT consensus algorithm still guarantees that every transaction recorded in the current public transaction record chain has passed the review of most of the "loyal" verification nodes in the network, and becomes a part of the permanent record. Track the verification results made by each verification node at any time, or further serve as a basis for dynamic adjustment of verification nodes during subsequent multiple transaction verification processes.
  • the verification method of the proof of rights and interests can verify the security of the transaction more quickly than the verification method of the workload proof adopted by the traditional blockchain technology to meet the actual use needs, on the other hand, the verification method of the proof of rights and interests retains the work
  • the verification method of proof of quantity can be applied to its advantages in the untrusted network environment.
  • the step of initializing the public P2P channel transmission data between the multiple nodes and the current public transaction record linked list used to record network transactions also includes the following sub-steps: collecting verification results returned by at least 2F+1 verification nodes; When the number of verification nodes passed by the data block is greater than or equal to F+1, record the data block to the end of the current public transaction record linked list.
  • F is the number of error/malicious nodes that a network can tolerate.
  • the IBFT consensus algorithm assumes that “loyal” verification nodes in the network will make the same verification results at any time, and the number of verification nodes that the current user harbors maliciousness does not exceed 1/3 of the total number of nodes; therefore When receiving verification results returned by more than 2F+1 verification nodes, it can be considered that even in the worst case (that is, receiving verification results made by all malicious verification nodes), enough " The "loyal" verification node makes the correct verification result for this transaction, so that it will not make a wrong transaction security judgment.
  • the The data block is write-locked during the verification process, so that all nodes process the data block in a read-only manner. At this time, during the transmission of the data block, even if the passing node is currently occupied by a malicious user, it will not cause the data block to be tampered with.
  • the data block is generated at a constant frequency. If there is no new transaction information currently, the transaction information in the data block is empty. In fact, since the length of the current public transaction record linked list is steadily increasing, and the private key used by each verification node for signing can be updated regularly according to the length of the current public transaction record linked list, any attempt to collect signatures in the data block The malicious user needs to synchronize with the verification node to update the private key. This makes the security of the system itself improved.
  • the current public transaction record linked list After the increase of the data block in is greater than the update threshold, the following steps are performed: the verification nodes verify each other. When a verification node fails to pass the verification of 2/3 of the total verification nodes, the verification node will be deleted, No longer as a verification node.
  • the following steps are also performed: When a new node is added When the verification of 2/3 of the total number of verification nodes is passed, the newly added node is selected as the new verification node. Specifically, in some embodiments of the present disclosure, whenever the current public transaction record linked list adds 30,000 data blocks (including data blocks with empty transaction information), the update of all the above nodes can be performed.
  • the verification of the verification node itself may also be based on the correct rate of the verification node's judgment on the data blocks in the current public transaction record linked list within the foregoing time period. Specifically, the verification node whose judgment correct rate is the reciprocal 1/3 will be eliminated. In one or more embodiments of the present invention, when a certain node does not verify the verified node, it means maintaining the verified node.
  • any two or more nodes with high mutual trust can also perform the following steps: initialize a private transaction transmission channel (for example, specify any two or The port of the private transaction transmission channel between multiple nodes) and the private transaction data linked list based on the current public transaction record linked list (for example, the link head of the private transaction data linked list created based on the current public transaction record linked list), and through the private transaction
  • the transmission channel shares the private transaction data link to the two or more nodes; through the Raft consensus algorithm, the data block containing transaction information and signatures between the two or more nodes is added to the end of the private transaction data linked list
  • the private transaction transmission channel incrementally update the private transaction data linked list to the two or more nodes; wherein, the private transaction transmission channel is different from the public P2P channel.
  • Data can only be transmitted between any two or more nodes through the private transaction transmission channel. Further, the current public transaction record linked list and the private transaction transmission channel are isolated from each other. There is no interoperability or crossover between them. Therefore, the benefits of sending transactions through a private transaction transmission channel include at least not broadcasting transaction information to the entire network. Each private transaction transmission channel can be considered as a discrete Raft network.
  • a private transaction transmission channel means that although network participants may not fully trust each other (they may even be competitors in the same industry), they can choose other participants to conduct private transactions with, and pass only private transactions.
  • the data block is transmitted on the transaction transmission channel, so that only the parties in the private transaction transmission channel can see the transaction data between them. This provides an option for higher transaction privacy.
  • these nodes since the parties involved in the transaction through the private transaction transmission channel have a high level of trust in each other, these nodes will use a different method from the current public transaction record chain to complete transaction verification, that is, use
  • the Raft consensus algorithm replaces the IBFT consensus algorithm to complete the verification. At this time, each node will have a countdown timer (Election Timeout) for the current Raft network.
  • the time of the countdown timer is randomly between 150 ms and 300 ms. In other embodiments of the present application, the time is 160ms, 180ms, 200ms, 220ms, 250ms, or 280ms.
  • each node will perform at least the following two activities: Leader Election and Log Replication.
  • Leader Election and Log Replication At the beginning of the election campaign, all nodes in the Raft network are initialized to follow (Follower) state. After a certain node counts down (Timeout), the state of this node becomes the candidate (Candidate) state and the election is initiated. It sends an election request (Request Vote) to several other nodes.
  • a heartbeat message (Heartbeat) will be sent to all nodes in the candidate state. Message) to maintain the current state of all nodes.
  • the candidate state node resets its own countdown timer after receiving the heartbeat information of the dominant state node.
  • the client sends a request to the dominant node
  • the relevant data is written in the local log by the dominant node.
  • the node in the dominant state sends a request to update its local log to other nodes that follow the state.
  • these data are written by other nodes that follow the state to the local log and return success information to the node that is the dominant state.
  • the relevant data is set to the confirmed state in the local log on the node in the dominant state.
  • the node in the dominant state sends confirmation messages to other nodes in the following state, so that the corresponding data settings in the local log of the node in the following state are also changed to the confirmed state, thereby completing the complete log replication process.
  • embodiments of the present invention can process at least 1400 transactions per second. In other embodiments, it can handle at least 1650 transactions per second.
  • the robustness of the Raft consensus algorithm itself also enables as long as more than half of the two or more nodes participating in the transaction can operate normally, the transaction between the parties can be verified as usual; and The linked list of private transaction data can be kept consistent on each node through operations such as rollback after the corresponding node is restored.
  • the Raft consensus algorithm is based on a trust network, and the corresponding Raft network can tolerate the number of error/malicious nodes less than 1/2.
  • the private transaction when most nodes fail, the private transaction will stop, and the corresponding private transaction data block will not be added to the private transaction data block linked list. For example, when two nodes conduct a private transaction and one of the nodes fails or goes offline, the transaction will be aborted.
  • the offline node can rejoin the original private transaction later, and update the data link list missed when offline to the rejoined node.
  • the high throughput, security and privacy features of the present invention can effectively manage or process the affairs between multiple business organizations.
  • the technical solution can be used to manage or process affairs between multiple business organizations, between multiple business organizations and consumers, and/or between multiple consumers.
  • the above technical solution can be applied to manage a consumption reward plan.
  • Commercial organizations and consumers are multiple nodes for network transactions. Consumption records, business organization-specific reward points, universal points, etc. are transaction information and signatures in the data block.
  • the disclosed device and method may be implemented in other ways.
  • the system embodiment described above is merely illustrative.
  • the division of the modules or units is only a logical function division.
  • there may be other division methods for example, multiple units or components may be Combined or can be integrated into another system, or some features can be ignored or not implemented.
  • the displayed or discussed mutual coupling or direct coupling or communication connection may be indirect coupling or communication connection through some interfaces, devices or units, and may be in electrical, mechanical or other forms.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units can be selected according to actual needs to achieve the objectives of the solutions of the embodiments.
  • the functional units in the various embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units may be integrated into one unit.
  • the above-mentioned integrated unit can be implemented in the form of hardware or software functional unit.
  • the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer readable storage medium.
  • the present invention implements all or part of the processes in the above-mentioned embodiments and methods, and can also be completed by instructing relevant hardware through a computer program.
  • the computer program can be stored in a computer-readable storage medium. When the program is executed by the processor, the steps of the foregoing method embodiments can be implemented.
  • the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file, or some intermediate forms.
  • the computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory) , Random Access Memory (RAM, Random Access Memory), electrical carrier signal, telecommunications signal, and software distribution media, etc.
  • ROM Read-Only Memory
  • RAM Random Access Memory
  • electrical carrier signal telecommunications signal
  • software distribution media etc.
  • the content contained in the computer-readable medium can be appropriately added or deleted in accordance with the requirements of the legislation and patent practice in the jurisdiction.
  • the computer-readable medium Does not include electrical carrier signals and telecommunication signals.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

一种基于多节点的网络交易验证方法、网络交易验证系统和存储介质,所述方法包括以下步骤:识别参与网络交易的多个节点所对应的实际身份(S100);从所述多个节点中选择部分节点作为用于验证网络交易节点的验证节点(S200);初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表(S300);通过IBFT共识算法生成并添加含有交易信息和签名的数据块到所述当前公共交易记录链表(S400)。

Description

基于多个节点的网络交易验证方法及其系统和存储介质 技术领域
本公开涉及电子商务领域,尤其涉及一种基于多节点的网络交易验证方法,及其相应的计算机系统和存储介质。
背景技术
虽然电子商务借助互联网技术和基础通信设备而为商家和用户之间的交易提供了不少方便,但是交易的双方可能是通过网络直接达成交易协议和资金转账。因此,交易的双方无法类似于传统交易方法那样确认可以直接确认对方身份,以及在交易期间货物/服务和资金是否按照协议所指定的方式交付。此时,交易双方往往需要通过第三方交易平台验证双方身份,并对交易进行担保。
商家或用户在使用第三方交易平台进行交易时,需要先提供身份识别证明。同时,商家或者还需要提供额外的担保金。第三方交易平台需要花费相应的成本验证参与交易各方的真实身份,并及时处理交易过程中可能出现的纠纷。尤其是对于日常的海量小额交易,第三方交易平台的后台服务器需要高并发核实每笔交易中双方的身份、确认交易的内容以及确保资金的安全,从而保证该笔交易是拥有相应账号的交易双方真实意思的表示。这对第三方平台的运维能力和成本提出了较高的要求。
对于大宗商品交易,尤其双方的初次交易,目前交易双方一般还是采用传统的线下交易方式进行,以保证交易双方的公平。
此外,因为相关公共区块链技术(例如:比特币、以太坊(Ethereum)以及其他加密货币)并没有任何验证机制,亦未能提供数据保密;所以这些非验证技术需大量额外资源防止恶意行为,从而影响交易处理能力。目前,比特币网络的交易处理能力为大概每秒3.3至7个交易,以太坊大约为每秒25个交易。
因此,有需要提供一种具高处理效率及数据保密的交易方法以应付海量交易。
发明内容
针对上述技术方案中出现的缺陷,本公开提出一种基于多节点的网络交易验证方法,及其相应的计算机系统和存储介质,以缓解相关技术方案中的问题。本申请的上述技术方案能够获得高效验证每笔交易的有效性的效果。
为了实现上述目的,本公开采用以下的技术方案。
首先,本公开提出一种基于多节点的网络交易验证方法,包括以下步骤:识别参与网络交易的多个节点所对应的实际身份;从所述多个节点中选择部分节点作为用于验证网络交易节点的验证节点;初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表;通过IBFT(Istanbul Byzantine Fault Tolerant,伊斯坦布尔拜占庭容错)共识算法生成并添加含有交易信息和签名的数据块到所述当前公共交易记录链表。其中,所述节点可以参与网络交易的客户端。所述客户端保存有被实际身份的真实身份信息。该真实身份信息可以保存在安装有该客户端的设备上。
在本公开的上述实施例中,当所述验证节点的个数是3F+1时,上述初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表步骤还包括以下子步骤:收集至少2F+1个验证节点返回的验证结果;统计所收集的验证结果,并当所述数据块通过验证节点的数量大于或等于F+1时,将所述数据块记录到所述当前公共交易记录链表的末尾。
在本公开的一个或多个实施例中,所述数据块在被验证的过程中被写锁定,使得所有节点以只读方式处理所述数据块。
在本公开的一个或多个实施例中,所述数据块是以恒定的频率生成,其中当前没有新的交易信息时,所述数据块内的交易信息为空。
在本公开的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:当不能通过所有节点的总数2/3的验证时,所述验证节点不再作为验证节点。
类似地,在本公开的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:当新增的节点通过所有节点的总数2/3的验证时,所述节点被选择为新的验证节点。
在本公开的一个或多个实施例中,上述更新阈值是30000(即每新增30000个数据块时,执行上述验证)。
在本公开的一个或多个实施例中,任意两个或多个节点之间还可以执行以下步骤:初始化私密交易传输信道和基于当前公共交易记录链表的私密交易数据链表,并通过所述私密交易传输信道共享私密交易数据链至所述两个或多个节点;通过Raft共识算法,添加所述两个或多个节点之间含有交易信息和签名的数据块到所述私密交易数据链表的末尾;通过所述私密交易传输信道,增量更新所述私密交易数据链表到所述两个或多个节点;其中,所述私密交易传输信道是不同于所述公共P2P信道。
其次,本公开还提出一种计算机系统。所述计算机系统包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序。所述处理器执行所述程序时,执行以下步骤:识别参与网络交易的多个节点所对应的实际身份;从所述多个节点中选择部分节点作为用于验证网络交易节点的验证节点;初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表;通过IBFT共识算法生成并添加含有交易信息和签名的数据块到所述当前公共交易记录链表。
在本公开的实施例中,当所述验证节点的个数是3F+1时,上述初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表步骤还包括以下子步骤:收集至少2F+1个验证节点返回的验证结果;统计所收集的验证结果,并当所述数据块通过验证节点的数量大于或等于F+1时,将所述数据块记录到所述当前公共交易记录链表的末尾。
在本公开的一个或多个实施例中,所述数据块在被验证的过程中被写锁定,使得所有节点以只读方式处理所述数据块。
在本公开的一个或多个实施例中,所述数据块是以恒定的频率生成,其中当前没有新的交易信息时,所述数据块内的交易信息为空。
在本公开的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:当不能通过所有验证节点的总数2/3的验证时,所述验证节点不再作为验证节点。
类似地,在本公开的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:当新增的节点通过所有验证节点的总数2/3的验证时,所述节点被选择为新的验证节点。
在本公开的一个或多个实施例中,上述更新阈值是30000。
在本公开的一个或多个实施例中,所述处理器执行所述程序时,任意两个或多个节点之间还可以执行以下步骤:初始化私密交易传输信道和基于当前公共交易记录链表的私密交易数据链表,并通过所述私密交易传输信道共享私密交易数据链至所述两个或多个节点;通过Raft共识算法,添加所述两个或多个节点之间含有交易信息和签名的数据块到所述私密交易数据链表的末尾;通过所述私密交易传输信道,增量更新所述私密交易数据链表到所述两个或多个节点;其中,所述私密交易传输信道是不同于所述公共P2P信道。
最后,本申请公开了一种存储介质,其中所述存储介质中存储有计算机程序。所述计算机程序被设置为运行时执行以下步骤:识别参与网络交易的多个节点所 对应的实际身份;从所述多个节点中选择部分节点作为用于验证网络交易节点的验证节点;初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表;通过IBFT共识算法生成并添加含有交易信息和签名的数据块到所述当前公共交易记录链表。
在本公开的实施例中,当所述验证节点的个数是3F+1时,上述初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表步骤还包括以下子步骤:收集至少2F+1个验证节点返回的验证结果;统计所收集的验证结果,并当所述数据块通过验证节点的数量大于或等于F+1时,将所述数据块记录到所述当前公共交易记录链表的末尾。
在本公开的一个或多个实施例中,所述数据块在被验证的过程中被写锁定,使得所有节点以只读方式处理所述数据块。
在本公开的一个或多个实施例中,所述数据块是以恒定的频率生成,其中当前没有新的交易信息时,所述数据块内的交易信息为空。
在本公开的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:当不能通过所有节点的总数2/3的验证时,所述验证节点不再作为验证节点。
类似地,在本公开的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:当新增的节点通过所有节点的总数2/3的验证时,所述节点被选择为新的验证节点。
在本公开的一个或多个实施例中,上述更新阈值是30000。
在本公开的一个或多个实施例中,所述计算机程序被设置为运行时,任意两个或多个节点之间还可以执行以下步骤:初始化私密交易传输信道和基于当前公共交易记录链表的私密交易数据链表,并通过所述私密交易传输信道共享私密交易数据链至所述两个或多个节点;通过Raft共识算法,添加所述两个或多个节点之间含有交易信息和签名的数据块到所述私密交易数据链表的末尾;通过所述私密交易传输信道,增量更新所述私密交易数据链表到所述两个或多个节点;其中,所述私密交易传输信道是不同于所述公共P2P信道。
本公开的有益效果为:通过随机选择的多个节点对同一交易进行验证,确保在交易记录数量高并发的情况下,即使有部分节点出现宕机时,又或者部分节点被恶意的交易参与者控制而任意对交易进行核实时,相应交易依然能够被恰当地核实。因为所有交易参与者的真实身份都被识别,所以本技术方案能够追踪每项交易的实际参与者,从而确保交易的可靠性。由于在公共及私密交易中分别使用 不同的共识算法(IBFT与Raft),因此所公开方案能避免交易分叉的情况。相反,使用工作量证明(Proof of Work,简称PoW)的公共区块链交易方案会经常会出现分叉(甚至是硬分叉)而浪费资源。
附图说明
图1所示为根据本公开实施例的基于多节点的网络交易验证方法的流程图;
图2所示为图1中用于网络交易验证的多个节点所构成网络的示意图;
图3所示为数据块和当前公共交易记录链表的数据结构示意图;
图4所示为图1中初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表步骤的子方法的流程图;
图5所示为根据本公开实施例的任意两个或多个节点之间验证交易的流程图;
图6所示为根据本公开实施例的基于多节点的网络交易验证系统的框架图。
具体实施方式
以下将结合实施例和附图对本发明的构思、具体结构及产生的技术效果进行清楚、完整的描述,以充分地理解本发明的目的、方案和效果。需要说明的是,在不冲突的情况下,本申请中的实施例及实施例中的特征可以相互组合。附图中各处使用的相同的附图标记指示相同或相似的部分。
目前涉及大宗商品的交易中,交易双方往往需要付出相当的成本来验证对方的身份、资质和历史交易记录等信息以确保交易的可靠性。然而,交易对象的可靠性一般是基于交易对象的过往交易记录;以及该交易对象的交易历史中,其他参与方为其作出的商业信用评价。这些信息都是交易双方对彼此进行商业信用评价的参考因素。
在本公开的实施例利用这些因素,并将其用作衡量交易安全性的指标,从而为交易双方提供一个电子商务的交易安全性检验。在本公开的应用场合中,参与交易的双方或多方身份可以通过本领域的常用身份验证方式在各种终端(例如笔记本电脑、台式电脑、智能手机和平板电脑等)上被核验并与该终端绑定。此时,相应的终端将成为用于网络交易验证的多个节点中的一个。具体地,参考图1所示为根据本公开实施例的基于多节点的网络交易验证方法的示意性流程图,该方法包括:识别参与网络交易的多个节点所对应的实际身份;从所述多个节点中选择部分节点作为用于验证网络交易节点的验证节点;初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表;通过 IBFT共识算法生成并添加含有交易信息和签名的数据块到所述当前公共交易记录链表。
IBFT共识算法利用由被选中且经过核实实际身份的验证节点所作出的权益证明(Proof of Authority,简称PoA)作为交易中各参与方的商业信用评价。权益证明是利用一组验证节点来验证新的交易,通过多数验证节点的共识,新的网络交易生成相应的数据块,添加到交易记录。根据IBFT共识算法,每个验证节点可以是随机选择,并在随后的多次交易验证过程中动态变化。每当有新的网络交易需要被验证时,全体验证节点中的一个被随机选取为提议节点(the Proposer)。该随机选择的提议节点根据新的网络交易生成相应的数据块,并交给全体验证节点进行验证。这些验证节点和其他节点以图2所示网络结构形成。根据本发明的一个或多个实施例,每一个数据块经过不同组的验证节点进行验证,得出共识后,并在数据块上记录为数字签名。其中,验证节点为每次交易进行验证,确定数据块能否添加到当前公共交易记录链表;而普通节点具有当前公共交易记录链表的完整副本,则在各个节点间传播含有交易信息的数据块和该数据块在各个节点间的验证结果,从而使得各个节点能够快速地响应新生成的数据块。在数据块通过验证而被添加到所述当前公共交易记录链表,或者不能通过验证而被丢弃后,可继续从全体验证节点中随机选取一个或继续使用同一提议节点,重复上述流程以对下一个网络交易进行验证。当数据块不能通过验证时,该轮验证的提议节点会被更换,随机选取新的提议节点。数据块可以如图3所示的数据结构实现。在本申请的某些实施例中,这些数据块可以通过如图所示的链表方式链接起来形成当前公共交易记录链表,即每一个数据块的数据头包括前一个数据块的数字签名(数据块1包括链表头),从而可以方便地验证当前公共交易记录链表的各个数据块,从而能够快速地判断当前公共交易记录链表是否遭到恶意破坏,并能够通过删除不合法的数据块而及时地回滚到正常状态。本领域技术人员也可能选用其他合适的数据结构记录每一个数据块和当前公共交易记录链表,从而能够方便地验证所述当前公共交易记录链表是否遭到恶意破坏,并在所述当前公共交易记录链表遭到恶意破坏的情况下能够及时回滚到正常状态。本公开对此不作进一步限定。类似地,交易的验证方式也可以是本领域中的常用验证方式(例如验证数据块中的数字签名是否正确)和自定义的规则(例如每笔交易的金额是否超出上限、相关交易方过往交易记录和交易的方式是否合法),本公开对此也不作进一步限定。本领域技术人员可以根据实际的情况选用合适的验证方式。在本申请的一个或多个实施例中,当前公共交易记录链表可以记录在数据中心中,每个通过验证数据块在添加到存储在数据中心当前公共交易记录链表后,可以随时被任意节点 (包括验证节点和非验证的普通节点)检索到。相应地,可替代地,在本申请的其他实施例中,每个节点也可以在本地存储当前公共交易记录链表的副本,并在数据块通过验证后,将其增量更新到本地的当前公共交易记录链表的副本中,从而实现当前公共交易记录链表的去中心化存储,以提高该系统的鲁棒性和安全性。根据本发明的一个或多个实施例,为确保每次只有一个数据块添加到记录链表,当数据块得到多数验证节点共识时,但该数据块还未添加到记录链表,中止选取新的数据块。
由于IBFT共识算法的目的是在不信任网络环境下,使得其中的节点之间能够建立信任;因此上述利用IBFT共识算法的网络交易验证方法允许部分验证节点的当前用户是怀有恶意的,会串通起来对交易的验证作出错误的判断以最大限度地破坏正常的交易。即使在最坏的情景下,IBFT共识算法依然保证当前公共交易记录链表中所记录的每项交易都通过了网络中大部分“忠诚”的验证节点的审核,并成为永久记录的一部分,以及可随时跟踪每一个验证节点所作出的验证结果,或者进一步地作为后继多次交易验证过程中动态调整验证节点的依据。因此,一方面由于权益证明的验证方式比传统区块链技术所采用工作量证明的验证方式能够更快地验证交易的安全性以满足实际使用需要,另一方面权益证明的验证方式保留了工作量证明的验证方式可以应用于不信任网络环境中的优点。
为了进一步应对特定时间段内爆发式增长的交易量,参照图4所示的子流程图,在本申请的一个或多个实施例中,当所述验证节点的个数是3F+1时,上述初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表步骤还包括以下子步骤:收集至少2F+1个验证节点返回的验证结果;统计所收集的验证结果,并当所述数据块通过验证节点的数量大于或等于F+1时,将所述数据块记录到所述当前公共交易记录链表的末尾。其中,F为一网络可容许错误/恶意节点的个数。
事实上,由于IBFT共识算法假设了在任何时候网络中“忠诚”的验证节点都会作出同样的验证结果,且当前用户怀有恶意的验证节点个数不超过总节点个数的1/3;因此当接收到超过2F+1个验证节点返回的验证结果时,可以认为即使在最坏的情况下(即收到所有怀有恶意的验证节点所作出的验证结果)也已经收到足够多的“忠诚”的验证节点就此次交易作出正确的验证结果,从而不会作出错误的交易安全性判断。进一步地,为了保证每个“忠诚”的验证节点都会作出同样的验证结果,而不会出现传统的拜占庭将军问题(Byzantine Generals Problem)中“叛变”的中间节点修改传送信息的潜在隐患,所述数据块在被验 证的过程中被写锁定,使得所有节点以只读方式处理所述数据块。此时,所述数据块在传输的过程中,即使所经过的节点当前被怀有恶意的用户所占用,也不会导致所述数据块被其篡改。
在本申请的一个或多个实施例中,为保证系统的安全性,所述数据块是以恒定的频率生成。如果当前没有新的交易信息时,所述数据块内的交易信息为空。事实上,由于当前公共交易记录链表的长度是稳定增长的,且各个验证节点用于签名的私钥可以相应地根据当前公共交易记录链表的长度而定期更新,因此任何企图通过收集数据块内签名的怀有恶意的用户需要与验证节点到需要同步更新私钥。这使得系统本身的安全性得到提高。
为了及时发现并剔除IBFT共识算法所假设的、占总节点个数的1/3的、当前用户为怀有恶意的验证节点,在本申请的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:验证节点对彼此进行验证,当一验证节点不能通过全体验证节点的总数2/3的验证时,所述验证节点将被删除,不再作为验证节点。相应地,为补充被删除的验证节点,在本申请的一个或多个实施例中,当前公共交易记录链表中的数据块的增加量大于更新阈值后,还执行以下步骤:当新增的节点通过全体验证节点的总数2/3的验证时,所述增新的节点被选择为新的验证节点。具体地,在本公开的一些实施例中,每当所述当前公共交易记录链表增加30000个数据块(包括交易信息为空的数据块)时,可以执行上述所有节点的更新。在本申请的一个或多个实施例中,上述对验证节点本身的验证也可以是基于该验证节点在上述时间段内就所述当前公共交易记录链表中数据块的判断的正确率。具体地,判断正确率是倒数1/3的验证节点将被剔除。本发明的一个或多个实施例中,当某个节点对被验证节点并未作出验证,其表示维持该被验证节点。
因为在当前公共交易记录链表上的数据块能够被所有的节点查看,所以对于某些互相信任交易方之间创建专用的私密交易传输信道验证交易的安全性。具体地,参照图5所示的子流程图,这些相互之间高度信任的任意两个或多个节点之间还可以执行以下步骤:初始化私密交易传输信道(例如,指定所述任意两个或多个节点之间的私密交易传输信道的端口)和基于当前公共交易记录链表的私密交易数据链表(例如,基于当前公共交易记录链表创建私密交易数据链表的链头),并通过所述私密交易传输信道共享私密交易数据链至所述两个或多个节点;通过Raft共识算法,添加所述两个或多个节点之间含有交易信息和签名的数据块到所述私密交易数据链表的末尾;通过所述私密交易传输信道,增量更新所述私密交 易数据链表到所述两个或多个节点;其中,所述私密交易传输信道是不同于所述公共P2P信道。所述任意两个或多个节点之间只能通过所述私密交易传输信道传输数据。进一步地,当前公共交易记录链表和私密交易传输信道被相互隔离。它们之间不存在互操作性或交叉。因此,通过私密交易传输信道发送交易的好处至少包括不向整个网络广播交易信息。每个私密交易传输信道都可以被认为是离散的Raft网络。
运行私密交易传输信道意味着,尽管网络参与者可能不会完全相互信任(他们甚至可能是同一行业的竞争者),但是他们可以选择要与之进行私密交易的其他参与者,并通过仅在私密交易传输信道上传输数据块,使得只有使用私密交易传输信道中的各方才能看到他们之间的交易数据。这为更高的交易隐私性提供了一种选择。根据前面的讨论可知,由于通过私密交易传输信道进行交易的各方对彼此都有较高的信任,因此这些节点之间将采用与当前公共交易记录链表不同的方式完成交易的验证,即采用使用Raft共识算法代替IBFT共识算法完成验证。此时,每个节点上都会有针对当前Raft网络的倒计时器(Election Timeout)。在本申请的实施例中,所述倒计时器的时间随机在150ms到300ms之间。在本申请的其他实施例中,所述时间为160ms、180ms、200ms、220ms、250ms或280ms。在Raft网络运行过程中各个节点将至少执行以下两个活动:选主(Leader Election)和复制日志(Log Replication)。在选主活动开始时,Raft网络中的所有节点都初始化为追随(Follower)状态。在某一个节点倒计时结束(Timeout)后,这个节点的状态变成候选(Candidate)状态并提起选举。它给其他几个节点发送选举请求(Request Vote)。若至少一半以上的其它节点都返回成功,这个节点的状态就会由候选变成了主导(Leader),并在每个一小段时间后,就给所有的候选状态的节点发送一个心跳信息(Heartbeat Message)以保持所有节点的当前状态。候选状态的节点在收到主导状态节点的心跳信息后重设其自身的倒计时器。当客户端发送请求给主导状态的节点时,相关数据被主导状态的节点写在本地日志。然后,主导状态的节点向其它追随状态的节点发送请求更新其本地日志。当这些数据被其它追随状态的节点写到本地日志并向主导状态的节点返回成功信息。只要主导状态的节点收到过半数节点返回成功信息,相关数据在主导状态的节点上的本地日志中设置为确认状态。此时,主导状态的节点再向其它追随状态的节点发送确认信息,使得追随状态的节点在本地日志内的相应数据设置也改为已确认状态,从而完成完整的复制日志过程。
同时,这使得事务处理速度可以提高到每秒数千个事务处理,以满足日常交 易需要。例如,本发明的实施例能处理每秒至少1400个交易。在其他的实施例中,其能处理每秒至少1650个交易。此外,Raft共识算法自身的鲁棒性也使得只要参与交易的所述两个或多个节点中还有超过半数的节点能够正常运行,各方之间的交易就可以如常地进行验证;并且所述私密交易数据链表能够在相应节点恢复后通过回滚等操作而在各个节点上的保持一致。换言之,Raft共识算法是基于信任网络,相应的Raft网络可容许错误/恶意节点的个数为小于1/2。在本发明的一个或多个实施例中,当大多数节点失效时,私密交易将停止,相应的私密交易的数据块亦不会添加到私密交易数据块链表。例如,当两个节点进行私密交易而其中一个节点失效或离线,交易将中止。在本发明一个或多个实施例中,离线的节点可以在稍后再次加入到原有的私密交易,并更新在离线时所错过的数据链表到所述重新加入的节点。
本发明的高吞吐量、安全性和私密性的特点,可有效地管理或处理多个业务组织之间的事务。本技术方案可用于管理或处理多个商业组织之间、多个商业组织与消费者之间和/或多个消费者之间的事务。在本发明的实施例中,上述技术方案可应用于管理消费奖励计划。商业组织及消费者为网络交易的多个节点。消费记录、商业组织特定的奖励积分、通用性积分等为数据块中的交易信息和签名。
参照图6所示的基于多节点的网络交易验证系统的框架图,本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。
在本发明所提供的实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的系统实施例仅仅是示意性的,例如,所述模块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通讯连接可以是通过一些接口,装置或单元的间接耦合或通讯连接,可以是电性,机械或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来 实现本实施例方案的目的。
另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。所述计算机可读介质可以包括:能够携带所述计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、电载波信号、电信信号以及软件分发介质等。需要说明的是,所述计算机可读介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如在某些司法管辖区,根据立法和专利实践,计算机可读介质不包括是电载波信号和电信信号。
以上所述实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围,均应包含在本发明的保护范围之内。

Claims (10)

  1. 一种基于多个节点的网络交易验证方法,包括以下步骤:
    识别参与网络交易的多个节点所对应的实际身份;
    从所述多个节点中选择部分节点作为用于验证网络交易节点的验证节点;
    初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表;
    通过IBFT共识算法生成并添加含有交易信息和签名的数据块到所述当前公共交易记录链表;及
    当前公共交易记录链表中的数据块的增加量大于更新阈值后,更新所述验证节点,所述更新步骤包括所述多个节点对于所述验证节点进行验证。
  2. 根据权利要求1所述网络交易验证方法,其特征在于,当所述验证节点的个数是3F+1时,上述初始化所述多个节点之间的公共P2P信道传输数据和用于记录网络交易的当前公共交易记录链表步骤还包括以下子步骤:
    收集至少2F+1个验证节点返回的验证结果;
    统计所收集的验证结果,并当所述数据块通过验证节点的数量大于或等于F+1时,将所述数据块记录到所述当前公共交易记录链表的末尾。
  3. 根据权利要求1所述网络交易验证方法,其特征在于,所述数据块是以恒定的频率生成,其中当前没有新的交易信息时,所述数据块内的交易信息为空。
  4. 根据权利要求1所述网络交易验证方法,其特征在于,所述更新步骤还包括:
    当被验证的验证节点不能通过全体验证节点的总数2/3的验证时,所述被验证的验证节点不再作为验证节点。
  5. 根据权利要求1所述网络交易验证方法,其特征在于,所述更新步骤还包括:
    当新增的验证节点通过全体验证节点的总数2/3的验证时,所述新增的节点被选择为新的验证节点。
  6. 根据权利要求1所述网络交易验证方法,其特征在于,所述更新阈值是30000。
  7. 根据权利要求1所述网络交易验证方法,其特征在于,任意两个或多个节点之间还可以执行以下步骤:
    初始化私密交易传输信道和基于当前公共交易记录链表的私密交易数据链表,并通过所述私密交易传输信道共享私密交易数据链至所述两个或多个节点;
    通过Raft共识算法,添加所述两个或多个节点之间含有交易信息和签名的数据块到所述私密交易数据链表的末尾;
    通过所述私密交易传输信道,增量更新所述私密交易数据链表到所述两个或多个节点;
    其中,所述私密交易传输信道是不同于所述公共P2P信道。
  8. 根据权利要求1所述网络交易验证方法,其特征在于,所述数据块在被验证的过程中被写锁定,使得所有节点以只读方式处理所述数据块。
  9. 一种计算机系统,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,其特征在于,所述处理器执行所述计算机程序时,实现上述权利要求1-8中任一项所述的方法。
  10. 一种存储介质,其中所述存储介质中存储有计算机程序,所述计算机程序被设置为运行时执行所述权利要求1-8中任一项所述的方法。
PCT/CN2020/087770 2019-04-29 2020-04-29 基于多个节点的网络交易验证方法及其系统和存储介质 WO2020221292A1 (zh)

Priority Applications (3)

Application Number Priority Date Filing Date Title
SG11202110209WA SG11202110209WA (en) 2019-04-29 2020-04-29 Network transaction verification method based on plurality of nodes, and system therefor and storage medium
JP2021544762A JP7192196B2 (ja) 2019-04-29 2020-04-29 複数のノードに基づくネットワークトランザクション検証方法及びそのシステム並びに記憶媒体
CN202080011112.0A CN113348656A (zh) 2019-04-29 2020-04-29 基于多个节点的网络交易验证方法及其系统和存储介质

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
HK19123085 2019-04-29
HK19123085.3 2019-04-29
HK19133728.6 2019-12-17
HK19133728 2019-12-17

Publications (2)

Publication Number Publication Date
WO2020221292A1 true WO2020221292A1 (zh) 2020-11-05
WO2020221292A9 WO2020221292A9 (zh) 2021-01-21

Family

ID=73028603

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/087770 WO2020221292A1 (zh) 2019-04-29 2020-04-29 基于多个节点的网络交易验证方法及其系统和存储介质

Country Status (4)

Country Link
JP (1) JP7192196B2 (zh)
CN (1) CN113348656A (zh)
SG (1) SG11202110209WA (zh)
WO (1) WO2020221292A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112600874A (zh) * 2020-11-24 2021-04-02 成都质数斯达克科技有限公司 节点加入方法、装置、电子设备及可读存储介质
CN117978547A (zh) * 2024-03-29 2024-05-03 华东交通大学 Trp-pbft共识方法、系统、存储介质及设备

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024004485A1 (ja) * 2022-06-30 2024-01-04 株式会社CountUp ブロックチェーンネットワークの構成方法及びその方法を実施するためのコンピュータソフトウエアプログラム
WO2024009650A1 (ja) * 2022-07-04 2024-01-11 株式会社CountUp ブロックチェーンネットワークの構成方法及びその方法を実施するためのコンピュータソフトウエアプログラム

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107124403A (zh) * 2017-04-14 2017-09-01 朱清明 区块链中共识区块的生成方法与计算设备
US20180123779A1 (en) * 2016-11-01 2018-05-03 Jiangang Zhang Flexible Blockchain Smart-Contract Deployment
CN108320155A (zh) * 2017-12-21 2018-07-24 中国科学院信息工程研究所 一种实现区块链共识机制的方法
CN108881287A (zh) * 2018-07-18 2018-11-23 电子科技大学 一种基于区块链的物联网节点身份认证方法

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018069566A1 (en) * 2016-10-14 2018-04-19 Nokia Technologies Oy Method, device and system for validating sensitive user data transactions within trusted circle
CN111614655A (zh) * 2017-03-24 2020-09-01 创新先进技术有限公司 一种共识校验的方法及装置
US11030331B2 (en) * 2017-06-01 2021-06-08 Schvey, Inc. Distributed privately subspaced blockchain data structures with secure access restriction management
CN107231299A (zh) * 2017-06-07 2017-10-03 众安信息技术服务有限公司 一种链路由及实现区块链跨链通信的系统
CN107909369A (zh) * 2017-10-13 2018-04-13 布比(北京)网络技术有限公司 基于跨链交易的共识方法、装置和存储介质
CN107766540A (zh) * 2017-10-31 2018-03-06 上海分布信息科技有限公司 一种分区的区块链网络及其实现分区存储的方法
CN109002349B (zh) * 2018-06-25 2021-01-05 百度在线网络技术(北京)有限公司 应用程序交互方法、实现方法、装置、设备和介质
CN109327459B (zh) * 2018-11-12 2020-12-01 崔晓晖 一种联盟区块链网络的共识方法

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180123779A1 (en) * 2016-11-01 2018-05-03 Jiangang Zhang Flexible Blockchain Smart-Contract Deployment
CN107124403A (zh) * 2017-04-14 2017-09-01 朱清明 区块链中共识区块的生成方法与计算设备
CN108320155A (zh) * 2017-12-21 2018-07-24 中国科学院信息工程研究所 一种实现区块链共识机制的方法
CN108881287A (zh) * 2018-07-18 2018-11-23 电子科技大学 一种基于区块链的物联网节点身份认证方法

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112600874A (zh) * 2020-11-24 2021-04-02 成都质数斯达克科技有限公司 节点加入方法、装置、电子设备及可读存储介质
CN117978547A (zh) * 2024-03-29 2024-05-03 华东交通大学 Trp-pbft共识方法、系统、存储介质及设备
CN117978547B (zh) * 2024-03-29 2024-06-07 华东交通大学 Trp-pbft共识方法、系统、存储介质及设备

Also Published As

Publication number Publication date
SG11202110209WA (en) 2021-11-29
JP7192196B2 (ja) 2022-12-20
WO2020221292A9 (zh) 2021-01-21
CN113348656A (zh) 2021-09-03
JP2022518960A (ja) 2022-03-17

Similar Documents

Publication Publication Date Title
WO2020221292A1 (zh) 基于多个节点的网络交易验证方法及其系统和存储介质
US11811910B2 (en) Blockchain maintenance method and apparatus, server, and computer-readable storage medium
WO2020147568A1 (zh) 基于区块链的存证方法和装置
US11962681B2 (en) Symmetric encryption for private smart contracts among multiple parties in a private peer-to-peer network
CN111488393B (zh) 虚拟区块链
JP7228322B2 (ja) ブロックチェーン・ネットワークにおける自動コミット・トランザクション管理
TW202016818A (zh) 區塊鏈的交易方法和裝置
CN110275891B (zh) 人工智能软件市场
US11580240B2 (en) Protecting sensitive data
US20210150558A1 (en) Method, apparatus, and electronic device for resource allocation based on blockchain
CN110674128B (zh) 区块链的链上治理
WO2020125234A1 (zh) 一种基于区块链的数据处理方法和装置
CN114365116A (zh) 来自私有区块链的更新的链外通知
US11354669B2 (en) Collaborative analytics for fraud detection through a shared public ledger
US11227287B2 (en) Collaborative analytics for fraud detection through a shared public ledger
KR20220149702A (ko) 블록체인을 위한 더 빠른 뷰 변경
CN111666332A (zh) 自动演进的数据库背书策略
CN111881109B (zh) 数据库可合并分类账
US20220276996A1 (en) Assessment node and token assessment container
CN111507839A (zh) 基于区块链的数据处理方法、装置、存储介质及设备
CN114363327A (zh) 区块链网络中的合规机制
CN111797426B (zh) 一种用于去信任通知服务的方法和系统
CN111698198B (zh) 秘密生成和份额分发
CN110807209A (zh) 一种数据处理方法、设备及存储介质
KR20220149556A (ko) 컨텍스트 무결성 보존

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: 20798727

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2021544762

Country of ref document: JP

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20798727

Country of ref document: EP

Kind code of ref document: A1