Cross-chain transaction method, computer equipment and storage medium
By setting up multiple cross-chain information transmission channels between blockchains and selecting transmission strategies according to user needs, the problem of the diversification of transaction credentials and time in cross-chain transactions is solved, thereby improving the efficiency of cross-chain data interaction and user experience.
Patent Information
- Application Number
- CN202410897075.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-04
- Publication Date
- 2024-11-29
- Estimated Expiration
- 2044-07-04
AI Technical Summary
Existing cross-chain transaction methods require users to pay fixed user transaction credentials, which cannot meet users' diverse needs for transaction credentials and transaction time, and the efficiency of cross-chain data interaction is low.
Set up a transaction credential priority channel, a speed priority channel, a balanced channel, and a custom channel between the business acquisition blockchain and the destination blockchain. Select the target information transmission channel according to user needs, determine the user's transaction credentials and cross-chain transmission data, send the cross-chain transmission data through the target information transmission channel, and perform permission verification on the destination blockchain.
It meets users' diverse needs for transaction time and transaction credentials during cross-chain transactions, improves the efficiency of cross-chain data interaction, and enhances users' cross-chain transaction experience.
Smart Images

Figure CN119048230A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of blockchain technology, and in particular to a cross-chain transaction method, computer equipment, and storage medium. Background Art
[0002] Blockchain is a decentralized distributed ledger that is tamper-proof, secure and reliable. Users can deploy transaction vouchers on the blockchain to obtain the information or data they want through the blockchain. Currently, a single blockchain may not be able to meet the diverse transaction needs of users, so cross-chain transactions have emerged. If the business acquisition blockchain that obtains user transaction information cannot provide the user with the data required by the user, the business acquisition blockchain can send the user transaction information to the destination blockchain that can perform cross-chain transactions based on the pre-set cross-chain transaction contract, so that the user can obtain the data required by the user from the destination blockchain on the basis of paying the user transaction voucher. However, the current cross-chain transaction method requires users to pay fixed user transaction vouchers, which cannot meet the diverse needs of users for the user transaction vouchers and transaction time they need to provide, and the cross-chain data interaction efficiency between blockchains is low. Therefore, how to meet the diverse needs of users for transaction time and the user transaction vouchers required to be provided when conducting cross-chain transactions and improve the cross-chain data interaction efficiency of blockchains is a problem that needs to be solved. Summary of the invention
[0003] Based on this, it is necessary to provide a cross-chain transaction method, computer equipment and storage medium that can meet the diverse needs of users for transaction time and user transaction credentials required when conducting cross-chain transactions in response to the above technical problems.
[0004] In a first aspect, the present application provides a cross-chain transaction method, the method comprising:
[0005] The business acquisition blockchain obtains the cross-chain transaction information sent by the user end, and analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis result; the cross-chain information transmission channel includes a transaction voucher priority channel, a speed priority channel, a balance channel and a custom channel;
[0006] The business acquisition blockchain determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information through the target information transmission channel, and sends the cross-chain transmission data to the target blockchain;
[0007] The destination blockchain obtains the cross-chain transmission data, and verifies the user's transaction authority based on the cross-chain transmission data. If the destination blockchain verifies the user's transaction authority, it obtains the user transaction voucher sent by the target information transmission channel, and sends the target transaction data to the business acquisition blockchain through the target information transmission channel;
[0008] The business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user terminal.
[0009] In one embodiment, the business obtains the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, including:
[0010] If the target information transmission channel is a custom channel, the business obtains the blockchain through the custom channel and determines the user transaction voucher, user identity information, transaction voucher slippage and transaction time slippage according to the cross-chain transaction information;
[0011] The business obtains the blockchain to verify the transaction time slippage through the custom channel;
[0012] If the business obtains the blockchain and verifies the transaction time slippage, the cross-chain transmission data is determined through the custom channel according to the user identity information and the transaction voucher slippage, and the cross-chain transmission data is sent to the destination blockchain.
[0013] In one embodiment, after the business obtains the blockchain to verify the transaction time slippage through the custom channel, it also includes:
[0014] If the business obtains the blockchain and fails to pass the transaction time slippage verification, the user transaction certificate is returned to the user terminal.
[0015] In one embodiment, the business acquires the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, further comprising:
[0016] If the target information transmission channel is a transaction voucher priority channel, the business acquisition blockchain determines the user transaction voucher and user identity information according to the cross-chain transaction information through the transaction voucher priority channel, and uses the user identity information as cross-chain transmission data;
[0017] The business obtains the blockchain and stores the cross-chain transmission data in the first transmission data queue through the transaction voucher priority channel;
[0018] The business acquisition blockchain determines whether the queue length of the first transmission data queue meets a preset queue length threshold. If so, all the cross-chain transmission data in the first transmission data queue are sent to the destination blockchain through the transaction voucher priority channel.
[0019] In one embodiment, the business acquires the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, further comprising:
[0020] If the target information transmission channel is a balance channel, the business acquires the blockchain through the balance channel, determines the user transaction credentials and user identity information according to the cross-chain transaction information, and uses the user identity information as cross-chain transmission data;
[0021] The business obtains the blockchain through the balance channel and stores the cross-chain transaction information in the second transmission data queue;
[0022] The business acquisition blockchain sends all the cross-chain transmission data in the second transmission data queue to the destination blockchain through the balance channel based on the transaction information sending cycle.
[0023] In one embodiment, the business acquires the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, further comprising:
[0024] If the target information transmission channel is a speed priority channel, the business acquires the blockchain through the speed priority channel, determines the user transaction credentials and user identity information according to the cross-chain transaction information, and uses the user identity information as the cross-chain transmission data;
[0025] The business acquisition blockchain sends the cross-chain transmission data to the destination blockchain in real time through the speed priority channel.
[0026] In one embodiment, after the destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data, it also includes:
[0027] If the target blockchain fails to verify the user's transaction authority, feedback verification failure information to the business acquisition blockchain through the target information transmission channel;
[0028] After the business acquisition blockchain obtains the verification failure information, it obtains the user transaction certificate from the target information transmission channel, and sends the verification failure information and the user transaction certificate to the user terminal.
[0029] In one embodiment, after the business acquisition blockchain obtains the verification failure information, obtains the user transaction voucher from the target information transmission channel, and sends the verification failure information and the user transaction voucher to the user terminal, it also includes:
[0030] The business obtains the transaction complaint information sent by the user end through the blockchain; the transaction complaint information includes the Merkel proof, the complaint transaction serial number and the transaction voucher information of the user transaction voucher;
[0031] The business acquisition blockchain calls the cross-chain contract to verify the transaction complaint information. If the transaction complaint information is verified, the transaction complaint information is stored in the transaction complaint channel;
[0032] The business acquisition blockchain reviews the transaction complaint information through the off-chain relay corresponding to the transaction complaint channel. If the review is passed, a user compensation voucher is generated through the cross-chain contract;
[0033] The business acquisition blockchain sends the user compensation voucher and the user transaction voucher to the user terminal.
[0034] In a second aspect, the present application further provides a computer device, the computer device comprising a memory and a processor, the memory storing a computer program, and the processor implementing the following steps when executing the computer program:
[0035] The business acquisition blockchain obtains the cross-chain transaction information sent by the user end, and analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis result; the cross-chain information transmission channel includes a transaction voucher priority channel, a speed priority channel, a balance channel and a custom channel;
[0036] The business acquisition blockchain determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information through the target information transmission channel, and sends the cross-chain transmission data to the target blockchain;
[0037] The destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data;
[0038] If the target blockchain verifies the user's transaction authority, the target blockchain obtains the user's transaction voucher sent by the target information transmission channel, and sends the target transaction data to the business acquisition blockchain through the target information transmission channel;
[0039] The business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user terminal.
[0040] In a third aspect, the present application further provides a computer-readable storage medium, wherein a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the following steps are implemented:
[0041] The business acquisition blockchain obtains the cross-chain transaction information sent by the user end, and analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis result; the cross-chain information transmission channel includes a transaction voucher priority channel, a speed priority channel, a balance channel and a custom channel;
[0042] The business acquisition blockchain determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information through the target information transmission channel, and sends the cross-chain transmission data to the target blockchain;
[0043] The destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data;
[0044] If the target blockchain verifies the user's transaction authority, the target blockchain obtains the user's transaction voucher sent by the target information transmission channel, and sends the target transaction data to the business acquisition blockchain through the target information transmission channel;
[0045] The business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user terminal.
[0046] In the above-mentioned cross-chain transaction method, computer device and storage medium, the business acquisition blockchain obtains the cross-chain transaction information sent by the user terminal, and analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis results; the business acquisition blockchain determines the user transaction voucher and cross-chain transmission data according to the cross-chain transaction information through the target information transmission channel, and sends the cross-chain transmission data to the destination blockchain; the destination blockchain obtains the cross-chain transmission data, and verifies the user transaction authority based on the cross-chain transmission data; if the destination blockchain verifies the user transaction authority, it obtains the user transaction voucher sent by the target information transmission channel, and sends the target transaction data to the business acquisition blockchain through the target information transmission channel; the business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user terminal. The above scheme solves the problem that the current cross-chain transaction method requires users to pay fixed user transaction credentials and cannot meet the user's diverse needs for the user transaction credentials and transaction time they need to provide. By setting a cross-chain information transmission channel with different cross-chain transmission strategies under the business acquisition blockchain, the target information transmission channel is determined from the cross-chain information transmission channel according to the needs of the transaction requester. The business acquisition blockchain sends the cross-chain transmission data to the destination blockchain through the target information transmission channel. The destination blockchain determines whether to provide the target transaction data requested by the transaction requester to the user end according to the cross-chain transmission data. If so, the target transaction data is sent to the business acquisition blockchain through the target information transmission channel. The business acquisition blockchain sends the target transaction data to the user end, and constructs multiple cross-chain data transmission channels between the business blockchain and the destination blockchain, which meets the user's diverse needs for transaction time and the user transaction credentials required to be provided when conducting cross-chain transactions, improves the user's cross-chain transaction experience, and improves the cross-chain data interaction efficiency of the blockchain. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] Figure 1 A schematic diagram of a cross-chain transaction method in one embodiment;
[0048] Figure 2 A schematic diagram of a cross-chain transaction method in another embodiment;
[0049] Figure 3 A schematic diagram of a cross-chain transaction method in another embodiment;
[0050] Figure 4 A schematic diagram of a cross-chain transaction method in another embodiment;
[0051] Figure 5 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0052] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0053] In one embodiment, Figure 1 As shown, a cross-chain transaction method is provided, which is executed by a cross-chain transaction system and includes the following steps:
[0054] S110, the business obtains the cross-chain transaction information sent by the user end through the blockchain, analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis results.
[0055] Cross-chain information transmission channels include transaction voucher priority channel, speed priority channel, balance channel and custom channel.
[0056] It should be noted that the business acquisition blockchain refers to the blockchain used to obtain the cross-chain transaction information issued by the transaction requester, and the destination blockchain refers to the blockchain used to provide the transaction requester with the transaction data requested by the transaction requester. The cross-chain transmission of transaction data can be realized between the business acquisition blockchain and the destination blockchain based on the cross-chain transaction contract. The cross-chain information transmission channel refers to the data transmission channel used to transmit information between the business acquisition blockchain and the destination blockchain. For each cross-chain information transmission channel, a corresponding downlink relay needs to be set as the information transmission component of the cross-chain information transmission channel. The information transmission components between each cross-chain information transmission channel are independent of each other. The information transmission component corresponding to each cross-chain information transmission channel will monitor the cross-chain transaction information thrown by the cross-chain contract on the business acquisition blockchain in real time, and determine whether the monitored cross-chain information should be transmitted by its corresponding cross-chain information transmission channel. Different cross-chain information transmission channels correspond to different information transmission strategies.
[0057] Exemplarily, the information transmission strategy of the transaction voucher priority channel may be: when the transaction requester needs to conduct a cross-chain transaction, fewer user transaction vouchers are collected, but the cross-chain transmission data corresponding to the transaction requester needs to be temporarily stored in the transaction queue in the transaction voucher priority channel, until the queue length of the transaction queue in the transaction voucher priority channel is greater than or equal to the preset queue length threshold, all the cross-chain transmission data in the transaction queue in the transaction voucher priority channel are sent to the destination blockchain to achieve batch transmission of cross-chain transmission data. The information transmission strategy of the speed priority channel may be: when the transaction requester needs to conduct a cross-chain transaction, more user transaction vouchers are collected, and after determining the cross-chain transmission data corresponding to the transaction requester, the cross-chain transmission data is immediately sent to the destination blockchain. The information transmission strategy of the balancing channel may be: a certain amount of user transaction vouchers is collected, the number of user transaction vouchers collected is more than the number of user transaction vouchers collected by the transaction voucher priority channel, and less than the number of user transaction vouchers collected by the speed priority channel, the cross-chain transmission data corresponding to the transaction requester is temporarily stored in the transaction queue in the balancing channel, and when the specified data transmission time is reached, all the cross-chain transmission data in the transaction queue in the balancing channel are sent to the destination blockchain. The information transmission strategy of the custom channel can be: the transaction requester can customize the transaction voucher slippage and transaction time slippage. The custom channel can determine the maximum user transaction voucher that the transaction requester can pay, as well as the transaction requester's expected transaction time based on the user-defined transaction voucher slippage and transaction time slippage, and determine whether cross-chain transaction services can be provided to the transaction requester based on the maximum user transaction voucher and the expected transaction time. If so, the cross-chain transmission data corresponding to the transaction requester is sent to the destination blockchain based on the expected transaction time corresponding to the transaction time slippage.
[0058] It can be understood that among the transaction voucher priority channel, speed priority channel and balance channel, the user transaction vouchers collected when conducting cross-chain transactions based on the transaction voucher priority channel are the least, the user transaction vouchers collected when conducting cross-chain transactions based on the speed priority channel are the most, and the number of user transaction vouchers collected when conducting cross-chain transactions based on the balance channel is between the number of user transaction vouchers corresponding to the transaction voucher priority channel and the number of user transaction vouchers corresponding to the speed priority channel.
[0059] Specifically, the business acquisition blockchain obtains the cross-chain transaction information sent by the transaction requester through the user terminal. The cross-chain transaction information may include the user identity information of the transaction requester, the user transaction voucher, and the expected transaction strategy of the transaction requester. The user identity information refers to the information that can characterize the identity of the transaction requester, and the user transaction voucher refers to the voucher information that the transaction requester needs to pay when conducting a cross-chain transaction. The business acquisition blockchain analyzes the cross-chain transaction information through the information transmission component corresponding to the cross-chain information transmission channel, determines the expected transaction strategy of the transaction requester, and determines the target information transmission channel that can perform cross-chain transmission of the user transaction information from the cross-chain information transmission channel according to the expected transaction strategy.
[0060] S120: The business obtains the blockchain through the target information transmission channel, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain.
[0061] Among them, cross-chain transmission data refers to the data required by the destination blockchain to verify the user transaction authority of the transaction requester.
[0062] Specifically, the business obtains the information transmission component corresponding to the blockchain through the target information transmission channel, determines the user transaction certificate issued by the transaction requester and the cross-chain transmission data that can verify the user transaction authority of the user requester based on the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain through the target information transmission channel.
[0063] S130. The destination blockchain obtains cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data. If the destination blockchain verifies the user's transaction authority, it obtains the user transaction credential sent by the target information transmission channel and sends the target transaction data to the business acquisition blockchain through the target information transmission channel.
[0064] The target transaction data refers to the transaction data that the transaction requester expects to obtain.
[0065] Specifically, after the destination blockchain obtains the cross-chain transmission data, it determines the user identity information of the transaction requester based on the cross-chain transmission data, and verifies the user transaction authority of the transaction requester based on the user identity information to determine whether the transaction requester has the authority to conduct cross-chain transactions. If the destination blockchain verifies the user transaction authority, it determines that the transaction requester has the authority to obtain the target transaction data, and sends a notification message of the user transaction authority verification to the business acquisition blockchain through the target information transmission channel. After the business acquisition blockchain obtains the notification message of the household transaction authority verification, it sends the user transaction voucher to the destination blockchain through the target information transmission channel. After the destination blockchain obtains the user transaction voucher, it sends the target transaction data to the business acquisition blockchain through the target transaction channel.
[0066] S140, the business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user terminal.
[0067] In the above cross-chain transaction method, the business acquisition blockchain obtains the cross-chain transaction information sent by the user end, and analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis results; the business acquisition blockchain determines the user transaction voucher and cross-chain transmission data according to the cross-chain transaction information through the target information transmission channel, and sends the cross-chain transmission data to the destination blockchain; the destination blockchain obtains the cross-chain transmission data, and verifies the user transaction authority based on the cross-chain transmission data; if the destination blockchain verifies the user transaction authority, it obtains the user transaction voucher sent by the target information transmission channel, and sends the target transaction data to the business acquisition blockchain through the target information transmission channel; the business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user end. The above scheme solves the problem that the current cross-chain transaction method requires users to pay fixed user transaction credentials and cannot meet the user's diverse needs for the user transaction credentials and transaction time they need to provide. By setting a cross-chain information transmission channel with different cross-chain transmission strategies under the business acquisition blockchain, the target information transmission channel is determined from the cross-chain information transmission channel according to the needs of the transaction requester. The business acquisition blockchain sends the cross-chain transmission data to the destination blockchain through the target information transmission channel. The destination blockchain determines whether to provide the target transaction data requested by the transaction requester to the user end according to the cross-chain transmission data. If so, the target transaction data is sent to the business acquisition blockchain through the target information transmission channel. The business acquisition blockchain sends the target transaction data to the user end, and constructs multiple cross-chain data transmission channels between the business blockchain and the destination blockchain, which meets the user's diverse needs for transaction time and the user transaction credentials required to be provided when conducting cross-chain transactions, improves the user's cross-chain transaction experience, and improves the cross-chain data interaction efficiency of the blockchain.
[0068] In one embodiment, Figure 2 As shown, the business obtains the target information transmission channel through the blockchain, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the target blockchain, including:
[0069] S210. If the target information transmission channel is a custom channel, the business obtains the blockchain through the custom channel and determines the user transaction voucher, user identity information, transaction voucher slippage and transaction time slippage according to the cross-chain transaction information.
[0070] Among them, the transaction voucher slippage refers to the maximum user transaction voucher that can be paid in the cross-chain transaction set by the transaction requester, and the transaction time slippage refers to the transmission time of the cross-chain transmission data expected by the transaction requester in the cross-chain transaction.
[0071] Specifically, if the target information transmission channel is a custom channel, the business acquisition blockchain can analyze the cross-chain transaction information through the information transmission component corresponding to the custom channel to determine the user transaction credentials, user identity information, transaction credential slippage and transaction time slippage corresponding to the cross-chain transaction information.
[0072] S220, the business obtains the blockchain to verify the transaction time slippage through a custom channel.
[0073] It should be noted that the earlier the transmission time of the cross-chain data, the more user transaction vouchers the transaction requester needs to pay. Therefore, it is necessary to verify whether the transmission time of the cross-chain data and the user transaction vouchers that the transaction requester can pay match.
[0074] Specifically, the earlier the cross-chain transmission data transmission time is, the larger the user transaction voucher that needs to be collected is. Therefore, the business needs to obtain the blockchain through the information transmission component corresponding to the custom channel to determine whether the user transaction voucher corresponding to the transaction voucher slippage and the transmission time of the cross-chain transmission data corresponding to the transaction time slippage match, and whether the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is a valid transmission time. If the transmission time of the user transaction voucher corresponding to the transaction voucher slippage and the cross-chain transmission data corresponding to the transaction time slippage match, and the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is a valid transmission time, then it is determined that the verification of the transaction time slippage and the transaction voucher slippage has passed; if the user transaction voucher corresponding to the transaction voucher slippage and the transmission time of the cross-chain transmission data corresponding to the transaction time slippage do not match, or the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is not a valid transmission time, then it is determined that the verification of the transaction time slippage and the transaction voucher slippage has failed. Exemplarily, if the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is ten o'clock, but the determined time of the cross-chain transmission data is fourteen o'clock, then the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is an invalid transmission time.
[0075] S230. If the transaction time slippage verification of the business acquisition blockchain is passed, the cross-chain transmission data is determined through a custom channel according to the user identity information and the transaction credential slippage, and the cross-chain transmission data is sent to the destination blockchain.
[0076] Specifically, if the business obtains the blockchain and passes the transaction time slippage verification, the maximum credential information of the user transaction credential that the transaction requester can pay is determined through the custom channel according to the transaction credential slippage, and the cross-chain transmission data is determined according to the user identity information and the maximum credential information, and then the cross-chain transmission data is sent to the destination blockchain through the custom channel.
[0077] Exemplarily, the method for determining cross-chain transmission data based on user identity information and maximum credential information may be to hash the maximum credential information, and sign the hashed maximum credential information based on the user identity information to determine the cross-chain transmission data. When the destination blockchain verifies the user's transaction authority based on the cross-chain transmission data, it needs to verify whether the transaction requester has the transaction authority for the target transaction data based on the user identity information, and determine whether the user transaction voucher paid by the transaction requester can trade the target transaction data based on the maximum credential information. If so, it is determined that the user transaction authority verification has passed.
[0078] It can be understood that the custom channel allows the transaction requester to customize the transaction time slippage and transaction voucher slippage according to actual needs, thereby meeting the transaction requester's diverse needs for cross-chain transaction time and transaction vouchers to be paid, and improving the transaction requester's cross-chain transaction experience.
[0079] In one embodiment, after the business obtains the blockchain to verify the transaction time slippage through the custom channel, it also includes:
[0080] If the business fails to pass the blockchain slippage verification for transaction time or transaction voucher slippage, the user transaction voucher will be returned to the user end.
[0081] Specifically, if the business obtains the blockchain and fails to pass the transaction time slippage verification through the target information transmission channel, the cross-chain transaction task will be canceled, and the user transaction certificate will be returned to the user end, and the reason for the failure of the verification will be fed back to the user end.
[0082] The above scheme can return the user transaction certificate to the user end when the transaction time slippage set by the transaction requester cannot be met, thereby ensuring the security of the transaction certificate of the transaction requester.
[0083] In one embodiment, Figure 3 As shown, the business obtains the blockchain through the target information transmission channel, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the target blockchain, and also includes:
[0084] S310. If the target information transmission channel is a transaction credential priority channel, the business obtains the blockchain through the transaction credential priority channel, determines the user transaction credential and user identity information according to the cross-chain transaction information, and uses the user identity information as cross-chain transmission data.
[0085] Specifically, if the target information transmission channel is the transaction voucher priority channel, the business obtains the blockchain through the transaction voucher priority channel, and determines the user transaction voucher and user identity information based on the cross-chain transaction information. At this time, the user transaction voucher is locked in the cross-chain contract and will not be uploaded to the destination blockchain along with the cross-chain transmission data.
[0086] S320, the business obtains the blockchain through the transaction voucher priority channel and stores the cross-chain transmission data in the first transmission data queue.
[0087] Among them, the first transmission data queue refers to the transmission data queue in the transaction voucher priority channel. The transaction voucher priority channel will collect fewer user transaction vouchers and store the cross-chain transmission data of the transaction requester in the first transmission data queue.
[0088] S330, the business acquisition blockchain determines whether the queue length of the first transmission data queue meets the preset queue length threshold. If so, all cross-chain transmission data in the first transmission data queue are sent to the destination blockchain through the transaction voucher priority channel.
[0089] The queue length threshold can be set according to actual needs.
[0090] It is understandable that when the business acquisition blockchain sends cross-chain transmission data to the destination blockchain through the transaction voucher priority channel, the transaction requester can obtain the target transaction data fed back by the destination blockchain by paying fewer user transaction vouchers. However, the transmission efficiency of cross-chain transmission data is low, which can meet the needs of transaction requesters who do not have high requirements for the transmission efficiency of cross-chain transmission data and hope to conduct cross-chain transactions by paying fewer user transaction vouchers.
[0091] In one embodiment, the business obtains the blockchain through the target information transmission channel, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the target blockchain, and also includes:
[0092] If the target information transmission channel is a balancing channel, the business acquires the blockchain through the balancing channel, determines the user transaction credentials and user identity information based on the cross-chain transaction information, and uses the user identity information as the cross-chain transmission data; the business acquires the blockchain through the balancing channel, and stores the cross-chain transaction information in the second transmission data queue; the business acquires the blockchain through the balancing channel, and sends all cross-chain transmission data in the second transmission data queue to the destination blockchain based on the transaction information sending cycle.
[0093] Among them, the second transmission data queue is a transmission data queue composed of cross-chain transmission data received at different times and stored in the balancing channel.
[0094] It should be noted that when executing the transmission task of cross-chain transmission data through the balancing channel, the transaction information sending cycle can be set in advance, and all cross-chain transmission data in the second transmission data queue can be sent to the destination blockchain on a regular basis according to the transaction information sending cycle.
[0095] The above scheme, by executing the transmission task of cross-chain transmission data through the balancing channel, can balance the relationship between the user transaction voucher that the transaction requester needs to pay and the transmission efficiency of cross-chain transmission data, and meet the transaction requester's demand for a balance between the user transaction voucher and the transmission efficiency of cross-chain transmission data.
[0096] In one embodiment, the business obtains the blockchain through the target information transmission channel, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the target blockchain, and also includes:
[0097] If the target information transmission channel is a speed priority channel, the business acquisition blockchain uses the speed priority channel to determine the user transaction credentials and user identity information based on the cross-chain transaction information, and uses the user identity information as the cross-chain transmission data; the business acquisition blockchain sends the cross-chain transmission data to the destination blockchain in real time through the speed priority channel.
[0098] Specifically, if the target information transmission channel is a speed priority channel, a higher user transaction certificate is required to provide cross-chain transaction services to the transaction requester. The business acquisition blockchain determines the user transaction certificate and user identity information based on the cross-chain transaction information through the speed priority channel, and uses the user identity information as the cross-chain transmission data. After the business acquisition blockchain determines that the cross-chain transmission data is successful, it immediately sends the cross-chain transmission data to the destination blockchain through the speed priority channel.
[0099] The above solution can send the cross-chain transmission data to the destination blockchain immediately after the cross-chain transmission data is generated, meeting the transaction requester's demand for the transmission rate of the cross-chain transmission data.
[0100] In one embodiment, after the destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data, it also includes:
[0101] If the destination blockchain fails to verify the user's transaction authority, the verification failure information will be fed back to the business acquisition blockchain through the target information transmission channel; after the business acquisition blockchain obtains the verification failure information, it obtains the user's transaction certificate from the target information transmission channel, and sends the verification failure information and the user's transaction certificate to the user end.
[0102] The above scheme can return the user transaction certificate to the transaction requester when the destination blockchain fails to verify the user's transaction authority, thereby preventing the transaction requester from losing the user transaction certificate.
[0103] In one embodiment, Figure 4 As shown, after the business obtains the verification failure information from the blockchain, it obtains the user transaction certificate from the target information transmission channel, and sends the verification failure information and the user transaction certificate to the user end, it also includes:
[0104] S410: The business obtains the transaction complaint information sent by the user end in the blockchain.
[0105] The transaction appeal information includes the Merkle proof, the appeal transaction sequence number and the transaction voucher information of the user's transaction voucher.
[0106] Among them, Merkle proof refers to a light node sending a proof request to a full node, asking the full node whether there is a specified node in the complete Merkle tree. The full node returns a Merkle proof path to the light node, which is calculated by the light node to verify the existence. The appeal transaction sequence number refers to the sequence number of the cross-chain transaction information that the transaction requester needs to appeal, and the transaction voucher information includes the number of user transaction vouchers paid by the transaction requester.
[0107] It should be noted that when the destination blockchain fails to verify the user's transaction authority, the business acquisition blockchain needs to return the user's transaction certificate to the user end. If the user end does not receive the returned user transaction certificate, the transaction requester can issue a transaction complaint information through the user end. When submitting the transaction complaint information, the user also needs to upload certain guarantee certificates on the business acquisition blockchain. If the transaction complaint information submitted by the transaction requester does not meet the complaint conditions, the guarantee certificate can be withheld to avoid malicious complaints.
[0108] S420: The business obtains the blockchain and calls the cross-chain contract to verify the transaction complaint information. If the transaction complaint information is verified, the transaction complaint information is stored in the transaction complaint channel.
[0109] Specifically, the business obtains the blockchain and calls the cross-chain contract to verify the transaction complaint information. While verifying the Merkel proof, it extracts the maximum transaction sequence number in the transmission queue during batch cross-chain transactions and compares it with the complaint transaction sequence number. If the Merkel proof is verified, and the maximum transaction sequence number is greater than the complaint transaction sequence number, it is determined that the transaction complaint information is verified, and the transaction complaint information is stored in the transaction complaint channel.
[0110] S430, the business acquisition blockchain reviews the transaction appeal information through the off-chain relay corresponding to the transaction appeal channel. If the review is passed, a user compensation certificate is generated through the cross-chain contract.
[0111] Specifically, after the transaction complaint information is stored in the transaction complaint channel, there will be a waiting period. During the waiting period, the business acquisition blockchain reviews the transaction complaint information through the off-chain relay corresponding to the transaction complaint channel to determine whether the cross-chain transaction process corresponding to the transaction complaint information is legal and compliant. If the off-chain relay corresponding to the transaction complaint channel finds that the cross-chain transaction process corresponding to the transaction complaint information is legal and compliant, the transaction complaint information is determined to be invalid, and the guarantee certificate uploaded by the transaction requester is deducted; if the waiting period ends, the off-chain relay corresponding to the transaction complaint channel cannot prove that the cross-chain transaction process corresponding to the transaction complaint information is legal and compliant, then the transaction complaint information is determined to be approved, and a user compensation certificate is generated through the cross-chain contract.
[0112] S440, the business acquisition blockchain sends the user compensation voucher and the user transaction voucher to the user end.
[0113] The above solution can ensure the security of the transaction requester's user transaction credentials and the reliability of cross-chain transactions.
[0114] Exemplarily, based on the above embodiment, the cross-chain transaction method includes:
[0115] The business acquisition blockchain obtains the cross-chain transaction information sent by the transaction requester through the user end. The cross-chain transaction information may include the user identity information of the transaction requester, the user transaction voucher, and the expected transaction strategy of the transaction requester. The user identity information refers to the information that can characterize the identity of the transaction requester, and the user transaction voucher refers to the voucher information that the transaction requester needs to pay when conducting a cross-chain transaction. The business acquisition blockchain analyzes the cross-chain transaction information through the information transmission component corresponding to the cross-chain information transmission channel, determines the expected transaction strategy of the transaction requester, and determines the target information transmission channel that can perform cross-chain transmission of the user transaction information from the cross-chain information transmission channel according to the expected transaction strategy. The cross-chain information transmission channel includes a transaction voucher priority channel, a speed priority channel, a balance channel, and a custom channel.
[0116] If the target information transmission channel is a custom channel, the business acquisition blockchain can analyze the cross-chain transaction information through the information transmission component corresponding to the custom channel to determine the user transaction voucher, user identity information, transaction voucher slippage, and transaction time slippage corresponding to the cross-chain transaction information. The faster the cross-chain transmission data transmission speed, the larger the user transaction voucher that needs to be collected. Therefore, the business acquisition blockchain needs to determine whether the user transaction voucher corresponding to the transaction voucher slippage and the cross-chain transmission data corresponding to the transaction time slippage match the transmission time through the information transmission component corresponding to the custom channel, and whether the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is a valid transmission time. If the user transaction voucher corresponding to the transaction voucher slippage meets the transaction conditions of the cross-chain transaction, the user transaction voucher corresponding to the transaction voucher slippage and the transmission time of the cross-chain transmission data corresponding to the transaction time slippage match, and the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is a valid transmission time, then it is determined that the verification of the transaction time slippage and the transaction voucher slippage has passed; if the user transaction voucher corresponding to the transaction voucher slippage and the transmission time of the cross-chain transmission data corresponding to the transaction time slippage do not match, or the transmission time of the cross-chain transmission data corresponding to the transaction time slippage is not a valid transmission time, then it is determined that the verification of the transaction time slippage and the transaction voucher slippage has failed. If the business obtains the blockchain to verify the transaction time slippage, the maximum voucher information of the user transaction voucher that the transaction requester can pay is determined through the custom channel according to the transaction voucher slippage, the cross-chain transmission data is determined according to the user identity information and the maximum voucher information, and then the cross-chain transmission data is sent to the destination blockchain through the custom channel. If the business obtains the blockchain to verify the transaction time slippage through the target information transmission channel, the cross-chain transaction task is canceled, and the user transaction voucher is returned to the user end, and the reason for the verification failure is fed back to the user end.
[0117] If the target information transmission channel is the transaction voucher priority channel, the business acquisition blockchain determines the user transaction voucher and user identity information according to the cross-chain transaction information through the transaction voucher priority channel. At this time, the user transaction voucher is locked in the cross-chain contract and will not be uploaded to the target blockchain along with the cross-chain transmission data. The business acquisition blockchain stores the cross-chain transmission data in the first transmission data queue through the transaction voucher priority channel. The business acquisition blockchain determines whether the queue length of the first transmission data queue meets the preset queue length threshold. If so, all cross-chain transmission data in the first transmission data queue are sent to the target blockchain through the transaction voucher priority channel.
[0118] If the target information transmission channel is a balancing channel, the business acquisition blockchain determines the user transaction credentials and user identity information based on the cross-chain transaction information through the balancing channel, and uses the user identity information as the cross-chain transmission data; the business acquisition blockchain stores the cross-chain transaction information in the second transmission data queue through the balancing channel, and sends all cross-chain transmission data in the second transmission data queue to the destination blockchain through the balancing channel.
[0119] If the target information transmission channel is a speed priority channel, a higher user transaction certificate is required to provide cross-chain transaction services to the transaction requester. The business acquisition blockchain determines the user transaction certificate and user identity information based on the cross-chain transaction information through the speed priority channel, and uses the user identity information as the cross-chain transmission data. After the business acquisition blockchain determines that the cross-chain transmission data is successfully determined based on the determination information of the cross-chain transmission data, it immediately sends the cross-chain transmission data to the destination blockchain through the speed priority channel.
[0120] After the destination blockchain obtains the cross-chain transmission data, it determines the user identity information of the transaction requester based on the cross-chain transmission data, and verifies the user transaction authority of the transaction requester based on the user identity information to determine whether the transaction requester has the authority to conduct cross-chain transactions.
[0121] If the destination blockchain verifies the user's transaction authority, it determines that the transaction requester has the authority to obtain the target transaction data, and sends a notification message of the user's transaction authority verification to the business acquisition blockchain through the target information transmission channel. After the business acquisition blockchain obtains the notification message of the user's transaction authority verification, it sends the user's transaction voucher to the destination blockchain through the target information transmission channel. After the destination blockchain obtains the user's transaction voucher, it sends the target transaction data to the business acquisition blockchain through the target transaction channel.
[0122] If the destination blockchain fails to verify the user's transaction authority, the verification failure information will be fed back to the business acquisition blockchain through the target information transmission channel; after the business acquisition blockchain obtains the verification failure information, it obtains the user's transaction certificate from the target information transmission channel, and sends the verification failure information and the user's transaction certificate to the user end.
[0123] When the destination blockchain fails to verify the user's transaction authority, the business acquisition blockchain needs to return the user's transaction voucher to the user end. If the user end does not receive the returned user transaction voucher, the transaction requester can issue a transaction complaint information through the user end. When submitting the transaction complaint information, the user also needs to upload certain guarantee certificates on the business acquisition blockchain. The business acquisition blockchain calls the cross-chain contract to verify the transaction complaint information. If the transaction complaint information is verified, the transaction complaint information is stored in the complaint information queue in the transaction complaint channel. After the transaction complaint information is stored in the transaction complaint channel, there will be a waiting period. During the waiting period, the business acquisition blockchain reviews the transaction complaint information through the off-chain relay corresponding to the transaction complaint channel to determine whether the cross-chain transaction process corresponding to the transaction complaint information is legal and compliant. If the off-chain relay corresponding to the transaction complaint channel finds that the cross-chain transaction process corresponding to the transaction complaint information is legal and compliant, the transaction complaint information is determined to be invalid, and the guarantee certificate uploaded by the transaction requester is deducted; if the waiting period ends, the off-chain relay corresponding to the transaction complaint channel cannot prove that the cross-chain transaction process corresponding to the transaction complaint information is legal and compliant, then the transaction complaint information is determined to be approved, and a user compensation certificate is generated through the cross-chain contract. The business acquisition blockchain sends the user compensation voucher and user transaction voucher to the user end.
[0124] In the above cross-chain transaction method, the business acquisition blockchain obtains the cross-chain transaction information sent by the user end, and analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis results; the business acquisition blockchain determines the user transaction voucher and cross-chain transmission data according to the cross-chain transaction information through the target information transmission channel, and sends the cross-chain transmission data to the destination blockchain; the destination blockchain obtains the cross-chain transmission data, and verifies the user transaction authority based on the cross-chain transmission data; if the destination blockchain verifies the user transaction authority, it obtains the user transaction voucher sent by the target information transmission channel, and sends the target transaction data to the business acquisition blockchain through the target information transmission channel; the business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user end. The above scheme solves the problem that the current cross-chain transaction method requires users to pay fixed user transaction credentials and cannot meet the user's diverse needs for the user transaction credentials and transaction time they need to provide. By setting a cross-chain information transmission channel with different cross-chain transmission strategies under the business acquisition blockchain, the target information transmission channel is determined from the cross-chain information transmission channel according to the needs of the transaction requester. The business acquisition blockchain sends the cross-chain transmission data to the destination blockchain through the target information transmission channel. The destination blockchain determines whether to provide the target transaction data requested by the transaction requester to the user end based on the cross-chain transmission data. If so, the target transaction data is sent to the business acquisition blockchain through the target information transmission channel. The business acquisition blockchain sends the target transaction data to the user end, which meets the user's diverse needs for transaction time and the user transaction credentials required to be provided when conducting cross-chain transactions, and improves the user's cross-chain transaction experience.
[0125] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0126] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 5As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. Among them, the processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be implemented through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a cross-chain transaction method is implemented. The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device shell, or an external keyboard, touchpad or mouse.
[0127] Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0128] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:
[0129] Step 1: The business obtains the cross-chain transaction information sent by the user end through the blockchain, and analyzes the cross-chain transaction information through the cross-chain information transmission channel. According to the analysis results, the target information transmission channel is determined from the cross-chain information transmission channel; the cross-chain information transmission channel includes the transaction voucher priority channel, the speed priority channel, the balance channel and the custom channel;
[0130] Step 2: The business obtains the target information transmission channel through the blockchain, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the target blockchain;
[0131] Step 3: The destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data. If the destination blockchain verifies the user's transaction authority, it obtains the user transaction certificate sent by the target information transmission channel and sends the target transaction data to the business acquisition blockchain through the target information transmission channel;
[0132] Step 4: The business obtains the target transaction data of the target information transmission channel through the blockchain and sends the target transaction data to the user end.
[0133] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0134] Step 1: The business obtains the cross-chain transaction information sent by the user end through the blockchain, and analyzes the cross-chain transaction information through the cross-chain information transmission channel. According to the analysis results, the target information transmission channel is determined from the cross-chain information transmission channel; the cross-chain information transmission channel includes the transaction voucher priority channel, the speed priority channel, the balance channel and the custom channel;
[0135] Step 2: The business obtains the target information transmission channel through the blockchain, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the target blockchain;
[0136] Step 3: The destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data. If the destination blockchain verifies the user's transaction authority, it obtains the user transaction certificate sent by the target information transmission channel and sends the target transaction data to the business acquisition blockchain through the target information transmission channel;
[0137] Step 4: The business obtains the target transaction data of the target information transmission channel through the blockchain and sends the target transaction data to the user end.
[0138] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:
[0139] Step 1: The business obtains the cross-chain transaction information sent by the user end through the blockchain, and analyzes the cross-chain transaction information through the cross-chain information transmission channel. According to the analysis results, the target information transmission channel is determined from the cross-chain information transmission channel; the cross-chain information transmission channel includes the transaction voucher priority channel, the speed priority channel, the balance channel and the custom channel;
[0140] Step 2: The business obtains the target information transmission channel through the blockchain, determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the target blockchain;
[0141] Step 3: The destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data. If the destination blockchain verifies the user's transaction authority, it obtains the user transaction certificate sent by the target information transmission channel and sends the target transaction data to the business acquisition blockchain through the target information transmission channel;
[0142] Step 4: The business obtains the target transaction data of the target information transmission channel through the blockchain and sends the target transaction data to the user end.
[0143] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.
[0144] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0145] The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0146] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A cross-chain transaction method, characterized in that: The cross-chain transaction method is executed by a cross-chain transaction system, the cross-chain transaction system includes a business acquisition blockchain and a target blockchain, and the cross-chain transaction method includes: The business acquisition blockchain obtains the cross-chain transaction information sent by the user end, and analyzes the cross-chain transaction information through the cross-chain information transmission channel, and determines the target information transmission channel from the cross-chain information transmission channel according to the analysis result; the cross-chain information transmission channel includes a transaction voucher priority channel, a speed priority channel, a balance channel and a custom channel; The business acquisition blockchain determines the user transaction credentials and cross-chain transmission data according to the cross-chain transaction information through the target information transmission channel, and sends the cross-chain transmission data to the target blockchain; The destination blockchain obtains the cross-chain transmission data, and verifies the user's transaction authority based on the cross-chain transmission data. If the destination blockchain verifies the user's transaction authority, it obtains the user transaction voucher sent by the target information transmission channel, and sends the target transaction data to the business acquisition blockchain through the target information transmission channel; The business acquisition blockchain obtains the target transaction data sent by the target information transmission channel, and sends the target transaction data to the user terminal.
2. The method according to claim 1, characterized in that The business obtains the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, including: If the target information transmission channel is a custom channel, the business obtains the blockchain through the custom channel and determines the user transaction voucher, user identity information, transaction voucher slippage and transaction time slippage according to the cross-chain transaction information; The business obtains the blockchain to verify the transaction time slippage through the custom channel; If the business obtains the blockchain and verifies the transaction time slippage, the cross-chain transmission data is determined through the custom channel according to the user identity information and the transaction voucher slippage, and the cross-chain transmission data is sent to the destination blockchain.
3. The method according to claim 2, characterized in that After the business obtains the blockchain to verify the transaction time slippage through the custom channel, it also includes: If the business obtains the blockchain and fails to pass the transaction time slippage verification, the user transaction certificate is returned to the user terminal.
4. The method according to claim 1, characterized in that: The business acquires the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, and also includes: If the target information transmission channel is a transaction voucher priority channel, the business acquisition blockchain determines the user transaction voucher and user identity information according to the cross-chain transaction information through the transaction voucher priority channel, and uses the user identity information as cross-chain transmission data; The business obtains the blockchain and stores the cross-chain transmission data in the first transmission data queue through the transaction voucher priority channel; The business acquisition blockchain determines whether the queue length of the first transmission data queue meets a preset queue length threshold. If so, all the cross-chain transmission data in the first transmission data queue are sent to the destination blockchain through the transaction voucher priority channel.
5. The method according to claim 1, characterized in that The business acquires the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, and also includes: If the target information transmission channel is a balance channel, the business acquires the blockchain through the balance channel, determines the user transaction credentials and user identity information according to the cross-chain transaction information, and uses the user identity information as cross-chain transmission data; The business obtains the blockchain through the balance channel and stores the cross-chain transaction information in the second transmission data queue; The business acquisition blockchain sends all the cross-chain transmission data in the second transmission data queue to the destination blockchain through the balance channel based on the transaction information sending cycle.
6. The method according to claim 1, characterized in that The business acquires the blockchain through the target information transmission channel, determines the user transaction credentials and the cross-chain transmission data according to the cross-chain transaction information, and sends the cross-chain transmission data to the destination blockchain, and also includes: If the target information transmission channel is a speed priority channel, the business acquires the blockchain through the speed priority channel, determines the user transaction credentials and user identity information according to the cross-chain transaction information, and uses the user identity information as the cross-chain transmission data; The business acquisition blockchain sends the cross-chain transmission data to the destination blockchain in real time through the speed priority channel.
7. The method according to claim 1, characterized in that After the destination blockchain obtains the cross-chain transmission data and verifies the user's transaction authority based on the cross-chain transmission data, it also includes: If the target blockchain fails to verify the user's transaction authority, feedback verification failure information to the business acquisition blockchain through the target information transmission channel; After the business acquisition blockchain obtains the verification failure information, it obtains the user transaction certificate from the target information transmission channel, and sends the verification failure information and the user transaction certificate to the user terminal.
8. The method according to claim 7, characterized in that After the business acquisition blockchain obtains the verification failure information, obtains the user transaction certificate from the target information transmission channel, and sends the verification failure information and the user transaction certificate to the user terminal, it also includes: The business obtains the transaction complaint information sent by the user end through the blockchain; the transaction complaint information includes the Merkel proof, the complaint transaction serial number and the transaction voucher information of the user transaction voucher; The business acquisition blockchain calls the cross-chain contract to verify the transaction complaint information. If the transaction complaint information is verified, the transaction complaint information is stored in the transaction complaint channel; The business acquisition blockchain reviews the transaction complaint information through the off-chain relay corresponding to the transaction complaint channel. If the review is passed, a user compensation voucher is generated through the cross-chain contract; The business acquisition blockchain sends the user compensation voucher and the user transaction voucher to the user terminal.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 8 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.
Citation Information
Patent Citations
System architecture for cross-block-chain open data sharing under heterogeneous multi-chain architecture
CN108876370A
Multichannel implementation method based on alliance chain
CN110555682A
Block chain all-in-one machine, cross-chain method and device for multiple nodes in block chain all-in-one machine and storage medium
CN112995344A
Cross-chain data access transmission method, system and device adopting multi-channel access
CN114095253A
Cross-chain validation
US20200252202A1
