Cross-chain transaction verification system and method based on ECDSA signature algorithm

The cross-chain transaction verification system through the ECDSA signature algorithm uses the signatures of multiple verification nodes and the mechanism stored on the application chain to solve the risks of untrustworthy verification nodes and centralized verification in cross-chain transaction verification, achieving higher reliability. Trustworthiness and decentralization.

CN115051808BActive Publication Date: 2024-08-23SHANGHAI WANXIANG BLOCK CHAIN CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210654945.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-10
Publication Date
2024-08-23
Estimated Expiration
2042-06-10

AI Technical Summary

Technical Problem

In cross-chain transaction verification, traditional centralized verification solutions can easily lead to third parties doing evil, and it is difficult for existing solutions to ensure the reliability and decentralization of verification results when transactions are successfully executed on the application chain.

Method used

A cross-chain transaction verification system based on the ECDSA signature algorithm is used to generate public and private keys through each verification node, connect different full nodes to monitor cross-chain transactions, generate certificates and broadcast signatures, and finally the signature collection nodes combine signatures to generate the final certificate and Stored on the target chain, ECDSA threshold signatures are used to ensure partial decentralization of the verification process and data privacy.

Benefits of technology

It improves the credibility and decentralization of the verification results, avoids the problem of a single full node being untrustworthy, and provides reliable storage on the application chain by storing the verification results, simplifying the verification process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115051808B
    Figure CN115051808B
Patent Text Reader

Abstract

The present invention provides a cross-chain transaction verification system and method based on the ECDSA signature algorithm, including: each verification node generates its own public and private keys; each verification node connects to different full nodes on the application chain, monitors cross-chain transactions, and generates corresponding proofs; the verification node signs the generated proofs with its own private key; after the verification node completes the transaction verification and signs, the proof and signature are broadcast; a signature collection node is defined to collect signatures; after a preset number of signatures are collected, these signatures are combined to generate the final proof and send it to the smart contract of the target chain for signature verification. In the present invention, each verification node can use its own private key to sign the result of the transaction verification module verification, and finally only the public key of the group can be used to unlock the signature, which ensures partial decentralization of the verification process and certain data privacy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of cross-chain transaction verification, and in particular to a cross-chain transaction verification system and method based on an ECDSA signature algorithm. Background Art

[0002] The cross-chain technology of blockchain can connect relatively independent blockchain systems, realize cross-chain interoperability of assets and data, improve the efficiency of collaboration between enterprises on different chains but interrelated, avoid the generation of isolated blockchain data islands, and connect many blockchain "local area networks" into a real "value Internet". In the specific implementation of the cross-chain framework, how to verify the atomicity of the transaction, that is, how to verify whether the transaction is really executed successfully on the corresponding application chain is one of the most important issues in the cross-chain architecture.

[0003] Patent document CN113935016A (application number: CN202111295613.9) discloses a blockchain-based trusted access and cross-domain authentication method in a named data network. It authenticates the device based on the ECDSA signature algorithm, records the authentication parameters on the chain for safekeeping, and reaches consensus on the authentication results through the ePBFT algorithm, thereby realizing cross-domain authentication and efficient access of IoT devices in the named data network.

[0004] Traditional centralized verification schemes may lead to the problem of third-party malicious behavior. The cross-chain transaction verification scheme using threshold signatures based on ECDSA requires certain verification nodes to verify and sign the transactions. Different verification nodes are connected to different full nodes on the application chain. They have a certain Byzantine fault tolerance, which can prevent some nodes from doing evil and achieve partial decentralization. Summary of the invention

[0005] In view of the defects in the prior art, the purpose of the present invention is to provide a cross-chain transaction verification system and method based on the ECDSA signature algorithm.

[0006] The cross-chain transaction verification system based on the ECDSA signature algorithm provided by the present invention includes:

[0007] Key generation module: Each verification node generates its own public and private keys;

[0008] Transaction verification module: Each verification node connects to different full nodes on the application chain, monitors cross-chain transactions, and generates corresponding proofs;

[0009] Signature generation module: The verification node signs the generated proof with its own private key and transfers it to the signature broadcast module;

[0010] Signature broadcast module: After the verification node completes the transaction verification and signs, the proof and signature are broadcast;

[0011] Signature collection module: defines signature collection nodes and collects signatures;

[0012] Proof generation module: After collecting a preset number of signatures, these signatures are combined to generate the final proof Proof and send it to the smart contract of the target chain for signature verification.

[0013] Preferably, the key generation module includes: interacting all verification nodes to form a public key, and using the public key to verify the correctness of the signature after the ECDSA threshold multi-signature.

[0014] Preferably, the transaction verification module includes: after monitoring a cross-chain message, requesting the block header and block information of the cross-chain transaction from the full node to which it is connected, querying whether the transaction comes from the application chain it monitors and is successfully executed on the application chain, if the verification is successful, generating a corresponding proof, if the verification fails, no corresponding proof is generated.

[0015] Preferably, the signature collection module includes: defining the signature collection node through the application chain when registering the transaction verification module, defining a list of verification nodes, and collecting the signatures by the verification node ranked first in the list. If the node cannot operate normally, the signatures are collected in order by the verification node ranked second, and so on.

[0016] Preferably, it also includes a proof storage module: after collecting the final proof Proof, the proof Proof is sent to the application chain and stored, and the correctness of the proof Proof is verified on the chain according to requirements.

[0017] The cross-chain transaction verification method based on the ECDSA signature algorithm provided by the present invention includes:

[0018] Key generation step: Each verification node generates its own public and private keys;

[0019] Transaction verification steps: Each verification node connects to different full nodes on the application chain, monitors cross-chain transactions, and generates corresponding proofs;

[0020] Signature generation step: The verification node signs the generated proof using its own private key;

[0021] Signature broadcasting step: After the verification node completes the transaction verification and signs it, the proof and signature are broadcasted;

[0022] Signature collection step: define signature collection nodes and collect signatures;

[0023] Proof generation step: After collecting a preset number of signatures, these signatures are combined to generate the final proof Proof and sent to the smart contract of the target chain for signature verification.

[0024] Preferably, the key generation step includes: interacting all verification nodes to form a public key, and using the public key to verify the correctness of the signature after the ECDSA threshold multi-signature.

[0025] Preferably, the transaction verification step includes: after monitoring a cross-chain message, requesting the block header and block information of the cross-chain transaction from the full node to which it is connected, querying whether the transaction comes from the application chain it monitors and is successfully executed on the application chain, if the verification is successful, generating a corresponding proof, if the verification fails, no corresponding proof is generated.

[0026] Preferably, the signature collection step includes: defining the signature collection node through the application chain, defining a list of verification nodes, and collecting the signatures by the verification node ranked first in the list. If the node cannot operate normally, the signatures are collected in order by the verification node ranked second, and so on.

[0027] Preferably, a proof storage step is also included: after collecting the final proof Proof, the proof Proof is sent to the application chain and stored, and the correctness of the proof Proof is verified on the chain as required.

[0028] Compared with the prior art, the present invention has the following beneficial effects:

[0029] 1) The present invention enables the verification node to connect to different full nodes through the transaction verification module, which can avoid the problem that the full node is unreliable when obtaining data from a single full node, thereby improving the credibility of the verification result;

[0030] 2) The present invention uses the ECDSA threshold signature solution through the signature generation module. Each verification node can use its own private key to sign the result of the transaction verification module. Finally, only the group's public key can be used to decrypt the signature, ensuring partial decentralization of the verification process and a certain degree of data privacy;

[0031] 3) The present invention stores data on the other party's application chain through the proof storage module, which can reliably store the verification results of the verification node. Compared with the traditional relay chain solution, it is a simpler and more effective solution. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Other features, objects and advantages of the present invention will become more apparent from the detailed description of non-limiting embodiments made with reference to the following drawings:

[0033] Figure 1 It is the system framework flow chart;

[0034] Figure 2 Flowchart of the cross-chain transaction verification process. DETAILED DESCRIPTION

[0035] The present invention is described in detail below in conjunction with specific embodiments. The following embodiments will help those skilled in the art to further understand the present invention, but are not intended to limit the present invention in any form. It should be noted that, for those of ordinary skill in the art, several changes and improvements can also be made without departing from the concept of the present invention. These all belong to the protection scope of the present invention.

[0036] Example:

[0037] The present invention provides a cross-chain transaction verification system based on threshold signature of ECDSA, including a key generation module, a transaction verification module, a signature generation module, a signature broadcast module, a signature collection module, a proof generation module and a proof storage module. The system uses the threshold signature scheme of ECDSA to enable the verification node to verify whether the cross-chain transaction is successfully uploaded to the chain, which can achieve partial centralization of the verification process, and finally store the verification result in the cross-chain double-send chain, so as to achieve credible and reliable storage of data. The overall system framework flow chart is as follows: Figure 1 shown.

[0038] The key generation module uses the key generation interaction process of the ECDSA threshold signature scheme to generate public and private keys for each verification node. All verification nodes can be called a group. After the group interaction, a public key will be formed. This public key can be used to verify the correctness of the ECDSA threshold multi-signature signature. In addition, during the implementation of the scheme, no one can obtain the group's parent private key or the child private key representing any group. This is also a feature of the ECDSA threshold signature.

[0039] Each verification node in the transaction verification module connects to different full nodes on the application chain and monitors cross-chain transactions. If a cross-chain message is monitored, it will request the block header and block information of the cross-chain transaction from the full node it is connected to, and check whether the transaction really comes from the application chain it monitors and is really executed successfully on the application chain. If the verification is successful, the corresponding proof will be generated. If the verification fails, no corresponding proof will be generated.

[0040] The signature generation module is based on the transaction verification module. The verification node signs the generated proof with its own private key and transfers it to the signature broadcast module.

[0041] In the signature broadcast module, once a verification node completes the transaction verification and signs it, it needs to broadcast the Proof and signature.

[0042] The signature collection module defines a signature collection node, which is defined by the application chain when registering the verification module. When registering the application chain, a list of verification nodes will be defined, indicating that the signature will be collected by the node ranked first in the list. If the node is down or the network is not accessible due to other unknown reasons, the second-ranked verification node will collect signatures in order, and so on.

[0043] After the signature collector collects n threshold signatures, the Proof generation module will combine these n signatures to generate the final Proof and send it to the smart contract of the target chain for signature verification.

[0044] The proof storage module is executed by the signature collector. After collecting the final Proof, the signature collector will send the Proof to the application chain and store the Proof. Later, everyone can go to the chain to verify the correctness of the Proof.

[0045] A detailed analysis of the overall verification process of cross-chain transactions is conducted, and a 2-3 threshold signature solution is selected, that is, there are 3 verification nodes, and at least 2 verification nodes are required to verify the transaction and sign the transaction to generate a valid proof. Each verification node will connect to different full nodes to verify whether the transaction is successfully uploaded to the chain, sign and generate proof. There will be a master node responsible for collecting signatures and sending proofs and related transactions to the corresponding application chain. The flow chart of the cross-chain transaction verification process is as follows: Figure 2 shown.

[0046] First, each verification node will send a heartbeat packet to indicate the current survival status. As shown in the figure, there are three verification nodes P1, P2, and P3, and each verification node is connected to a different full node on the application chain. In the key generation module, these three verification nodes form a group, which can be understood as a SK and PK in this group, but SK is actually useless. The signatures of each verification node on the transaction are collected together and the signatures can be verified with PK. Each verification node generates its own public and private keys Pk and SK through a specific algorithm for a specific threshold signature.

[0047] When the SDK registers the cross-chain service with the verification node, it will generate a node list based on the status of the verification node. This node list is stored in each verification node and the SDK. The SDK will select the verification node to forward the transaction based on this list.

[0048] For example, there are currently 3 verification nodes, with serial numbers 1-3. The SDK will generate two transactions TxA and TxB. The corresponding verification node list in the SDK is 1, 2, and 3. The corresponding verification node list of chainB is 3, 2, and 1. Then when the SDK sends TxA, it will first send it to verification node 1. Similarly, it will first send TxB to verification node 3. After receiving the transaction sent by the SDK, verification node 1 needs to broadcast the message that txA has been received. After receiving the transaction sent by the SDK, verification node 3 needs to broadcast the message that txB has been received, indicating that verification node 3 will collect signatures. And reply to the SDK that it has received the transaction (handshake). If the SDK has not received the message of successful transaction reception after a timeout period, the SDK will continue to send it to the next verification node in the order list.

[0049] At this time, the order here is to broadcast first and then reply to the SDK to receive txA. In this way, if the verification node 1 hangs up after receiving TxA, the remaining verification nodes will listen to the verification node 1 sending TxA, but will not listen to the TxA event on chainA. Then the remaining verification nodes will request the hash of TxA from the SDK and check whether TxA is sent successfully on chainA. If it is not sent successfully, the next verification node 2 in the order list will send TxA to chainA.

[0050] Next, after verification node 1 sends TxA to chainA and executes successfully, in the transaction verification module, all verification nodes will listen to the cross-chain event from chainA. When the three verification nodes all listen to the cross-chain transaction event, they obtain txhash and header from the chain respectively, call the signature generation module to verify the transaction and sign the transaction respectively, and obtain sig1, sig2 and sig3. The verification node then calls the signature broadcast module to broadcast the generated proof containing sig. When the verification node 3 that collects the signature calls the proof2 sig received by the signature collection module, it calls the Proof proof generation module to generate the final Sig and proofA, and sends them together with TxB to the proxy contract of chainB.

[0051] At this time, the group's PK will be put into the proxy contract, and the proxy contract of chainB will use the group's PK to verify the proof. If chainB passes the verification, it will call contract B. Each verification node will maintain a proof verification status table and monitor the verification results of chainB. If the verification fails, it will start to trade with each other to see if the signature is correct. If the verification succeeds, it will record that the proof has passed the verification.

[0052] Note that you can consider only checking the result of proof failure, and temporarily ignore the inconsistency of proof verification success, that is, only one node receives the message of successful verification, and not all nodes need to receive the message that the proof is true. When a node receives the message of proof failure, it can issue a request for signature verification.

[0053] Finally, the signature collector will call the proof storage module to store the generated Proof on the application chain.

[0054] When the signature collector is determined based on the node list in the signature collection module, the signature collector can also be dynamically determined by heartbeat packets such as Raft consensus.

[0055] In order to take into account the problem that the distributed verification node may crash at any time in the signature broadcast module, you can consider adding relevant functions to reject the same transaction in the smart contract of the application chain to prevent the processing of duplicate transactions.

[0056] This solution solves the problem of untrustworthy verification nodes in the verification process of traditional cross-chain solutions. In order to ensure the atomicity of cross-chain transactions in existing cross-chain solutions, a mechanism is needed to verify whether the transaction is successfully uploaded to the chain. Traditional verification solutions are generally third-party verification mechanisms, and the reliability of the verification results can only rely on this third party. However, centralized verification solutions will have the problem of single-point verification maliciousness. In order to solve the problem of single-point verification maliciousness, some existing solutions in recent years use the relay chain as a transaction verification platform (such as BitXHub of FunChain), and the verification process of the Proof generated by the node verifying the transaction is handed over to the contract on the relay chain for verification. However, in this verification method, the correctness of the proof generated by the verification node cannot be guaranteed, that is, there is still a risk of malicious verification nodes. At this time, even if the relay chain verifies the Proof, it cannot guarantee that the transaction transmitted is indeed uploaded to the chain, and can only trust the verification node. At this time, the relay chain is more of a decentralized storage service, storing the Proof transmitted by the verification node on the relay chain.

[0057] Compared with the relay chain cross-chain solution that uses a complete chain as proof storage and verification, the ECDSA threshold signature solution is used to solve the reliability problem of the verification node, and the multi-verification node threshold signature solution is used in the process of generating proof. The use of the ECDSA threshold signature solution can achieve partial decentralization in the process of verifying whether the transaction is really on the chain, and to a certain extent ensure the reliability of the verification result. At the same time, the verification result is stored on the other party's chain, so that the proof can be stored reliably, and there is no need to build a relay chain specifically for storing proof. It is a simpler solution.

[0058] The cross-chain transaction verification method based on the ECDSA signature algorithm provided by the present invention includes: a key generation step: each verification node generates its own public and private keys; a transaction verification step: each verification node connects to different full nodes on the application chain, listens to cross-chain transactions, and generates corresponding proofs; a signature generation step: the verification node signs the generated proof using its own private key; a signature broadcasting step: after the verification node completes the transaction verification and signs, the proof and signature are broadcast; a signature collection step: a signature collection node is defined to collect signatures; a Proof generation step: after a preset number of signatures are collected, these signatures are combined to generate the final proof and send it to the smart contract of the target chain for signature verification.

[0059] The key generation step includes: interacting all verification nodes to form a public key, and using the public key to verify the correctness of the signature after the ECDSA threshold multi-signature. The transaction verification step includes: after listening to a cross-chain message, requesting the block header and block information of the cross-chain transaction from the full node to which it is connected, querying whether the transaction comes from the application chain it listens to and is successfully executed on the application chain. If the verification is successful, the corresponding proof is generated. If the verification fails, the corresponding proof is not generated. The signature collection step includes: defining the signature collection node through the application chain, defining a list of verification nodes, and collecting signatures by the verification node ranked first in the list during signature collection. If the node cannot operate normally, the second-ranked verification node collects signatures in order, and so on. It also includes a proof storage step: after collecting the final proof, send the proof to the application chain and store it, and verify the correctness of the proof on the chain according to demand.

[0060] The difficulties of the present invention are: 1) how to ensure that the verification node in the transaction verification module is actually successfully executed on the original chain; 2) how to synchronize the verification results in a distributed network in the signature broadcast module; 3) how to determine a signature collector in the distributed network in the signature collection module, and finally generate Proof by this signature collector.

[0061] This technical solution can solve the problem of a single verification node doing evil in a cross-chain system. The use of the ECDSA threshold signature scheme ensures partial decentralization of the verification process, which is a distributed verification solution.

[0062] Those skilled in the art know that, in addition to implementing the system, device and its various modules provided by the present invention in a purely computer-readable program code, it is entirely possible to implement the same program in the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers and embedded microcontrollers by logically programming the method steps. Therefore, the system, device and its various modules provided by the present invention can be considered as a hardware component, and the modules included therein for implementing various programs can also be considered as structures within the hardware component; the modules for implementing various functions can also be considered as both software programs for implementing the method and structures within the hardware component.

[0063] The above describes the specific embodiments of the present invention. It should be understood that the present invention is not limited to the above specific embodiments, and those skilled in the art can make various changes or modifications within the scope of the claims, which does not affect the essence of the present invention. In the absence of conflict, the embodiments of the present application and the features in the embodiments can be combined with each other arbitrarily.

Claims

1. A cross-chain transaction verification system based on the ECDSA signature algorithm, characterized in that: include: Key generation module: Each verification node generates its own public and private keys; Transaction verification module: Each verification node connects to different full nodes on the application chain, monitors cross-chain transactions, and generates corresponding proofs; Signature generation module: The verification node signs the generated proof with its own private key and transfers it to the signature broadcast module; Signature broadcast module: After the verification node completes the transaction verification and signs, the proof and signature are broadcast; Signature collection module: defines signature collection nodes and collects signatures; Proof generation module: After collecting a preset number of signatures, these signatures are combined to generate the final proof and send it to the smart contract of the target chain for signature verification; The key generation module includes: interacting all verification nodes to form a public key, and using the public key to verify the correctness of the ECDSA threshold multi-signature signature; The transaction verification module includes: after listening to a cross-chain message, requesting the block header and block information of the cross-chain transaction from the full node to which it is connected, querying whether the transaction comes from the application chain it listens to and is successfully executed on the application chain, if the verification is successful, generating a corresponding proof, if the verification fails, no corresponding proof is generated; The signature collection module includes: defining a signature collection node through an application chain when registering a transaction verification module, defining a list of verification nodes, and collecting signatures by the verification node ranked first in the list during signature collection. If the node cannot operate normally, the second-ranked verification node collects signatures in order, and so on; It also includes a proof storage module: after collecting the final proof Proof, the proof Proof is sent to the application chain and stored, and the correctness of the proof Proof is verified on the chain as needed.

2. A cross-chain transaction verification method based on the ECDSA signature algorithm, characterized in that: include: Key generation step: Each verification node generates its own public and private keys; Transaction verification steps: Each verification node connects to different full nodes on the application chain, monitors cross-chain transactions, and generates corresponding proofs; Signature generation step: The verification node signs the generated proof using its own private key; Signature broadcasting step: After the verification node completes the transaction verification and signs it, the proof and signature are broadcasted; Signature collection step: define signature collection nodes and collect signatures; Proof generation step: After collecting a preset number of signatures, these signatures are combined to generate the final proof and sent to the smart contract of the target chain for signature verification; The key generation step includes: interacting all verification nodes to form a public key, and using the public key to verify the correctness of the ECDSA threshold multi-signature signature; The transaction verification step includes: after monitoring a cross-chain message, requesting the block header and block information of the cross-chain transaction from the full node to which it is connected, querying whether the transaction comes from the application chain it monitors and is successfully executed on the application chain, if the verification is successful, generating a corresponding proof, if the verification fails, no corresponding proof is generated; The signature collection step includes: defining a signature collection node through an application chain, defining a list of verification nodes, and collecting signatures by the verification node ranked first in the list. If the node cannot operate normally, the second verification node in the list collects signatures in order, and so on; It also includes the proof storage step: after collecting the final proof Proof, send the proof Proof to the application chain and store it, and verify the correctness of the proof Proof on the chain as needed.