Processing method and device based on blockchain system transactions

The account type of the transaction initiator is determined through the blockchain service gateway, and the hidden API service or token mechanism is called according to the account type to process the transaction request. This solves the problem of poor compatibility of privacy transaction protection in the blockchain system and realizes the compatibility and security of privacy transactions under multiple account models.

CN114581239BActive Publication Date: 2025-09-12INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210240767.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-10
Publication Date
2025-09-12
Estimated Expiration
2042-03-10

AI Technical Summary

Technical Problem

Privacy transaction protection in blockchain systems only supports a single account model, resulting in poor compatibility in cross-chain transactions.

Method used

The account type of the transaction initiator is determined through the blockchain service gateway, and the corresponding hidden API service or token mechanism is called according to the account type to process the transaction request, including transaction identity concealment service, transaction amount concealment service and privacy transaction compliance verification service, to achieve compatibility protection for different account models.

Benefits of technology

It improves the compatibility of privacy transaction protection in the blockchain system and ensures the security and legitimacy of transactions under multiple account models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114581239B_ABST
    Figure CN114581239B_ABST
Patent Text Reader

Abstract

This application discloses a method and device for processing transactions based on a blockchain system, relating to the field of blockchain technology. The method comprises: obtaining a transaction request through the transaction initiator's client; determining the transaction initiator's account type through a blockchain service gateway; if the transaction initiator's account type is an Account model, processing the transaction request through a hidden API service invoked by a smart contract on a blockchain node to obtain a target transaction request; if the transaction initiator's account type is a UTXO model, processing the transaction request through a hidden API service invoked by a token mechanism on the transaction initiator's client to obtain a target transaction request; and processing the target transaction request through a blockchain node based on the transaction initiator's account type to execute the target transaction request. This application addresses the problem of poor compatibility of privacy-preserving transaction protection in related technologies.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of blockchain technology, and more specifically, to a method and device for processing transactions based on a blockchain system. Background Art

[0002] With the formal passage of the Personal Information Protection Act, the protection of user privacy and the legal use of user information have become urgent. Currently, blockchain systems primarily focus on hashing data when it is uploaded to the blockchain. However, the account addresses and transaction amounts of both parties involved in a transaction have yet to be truly anonymized, which poses a potential risk of leaking the privacy of both parties. While blockchain systems currently have privacy protection schemes for transaction account addresses and transaction amounts, these schemes only support a single account model. Cross-chain transactions typically involve multiple account models (UTXO, Account, and other account models), resulting in poor compatibility in privacy protection.

[0003] Regarding the problem that privacy transaction protection on blockchain systems in related technologies only supports a single account model, while transactions usually involve multiple account models, resulting in poor compatibility of privacy transaction protection, no effective solution has been proposed so far. Summary of the Invention

[0004] The main purpose of this application is to provide a method and apparatus for processing transactions based on a blockchain system, in order to address the problem in related technologies that privacy transaction protection on blockchain systems only supports a single account model, while transactions typically involve multiple account models, resulting in poor compatibility of privacy transaction protection.

[0005] In order to achieve the above objectives, according to one aspect of the present application, a method for processing transactions based on a blockchain system is provided. The method includes: obtaining a transaction request through a client of a transaction initiator, wherein the transaction request includes at least: a transaction type, a transaction amount, address information of the transaction initiator, an account type of the transaction initiator, address information of a transaction recipient, and an account type of the transaction recipient; determining the account type of the transaction initiator through a blockchain service gateway, wherein the account type is one of the following: an Account model and a UTXO account model; if the account type of the transaction initiator is the Account model, processing the transaction request through a smart contract on a blockchain node by calling a hidden API service to obtain a target transaction request, wherein the hidden API service includes at least a transaction identity concealment service, a transaction amount concealment service, and a privacy transaction compliance verification service; if the account type of the transaction initiator is the UTXO account model, processing the transaction request through a token mechanism on the client of the transaction initiator by calling the hidden API service to obtain the target transaction request; and processing the target transaction request through the blockchain node according to the account type of the transaction initiator to execute the target transaction request.

[0006] Furthermore, before obtaining the transaction request through the client of the transaction initiator, the method also includes: calling a preset module to initialize parameters and obtain public parameters; and calling a key generation module based on the public parameters to obtain a certification key and a verification public key.

[0007] Furthermore, if the account type of the transaction initiator is the Account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request, including: sending the transaction request to the endorsement node on the blockchain node, and the endorsement node verifies the transaction request; if the transaction request passes the verification, the transaction request is sent to the smart contract; and the transaction request is processed by calling the hidden API service through the smart contract to obtain the target transaction request.

[0008] Furthermore, before processing the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request, the method also includes: generating a transaction certificate for the transaction request through the certification key.

[0009] Furthermore, if the account type of the transaction initiator is the Account model, the target transaction request is processed by the blockchain node according to the account type of the transaction initiator to execute the target transaction request, including: endorsing the target transaction request by the endorsement node to obtain an endorsement response, and sending the endorsement response and the target transaction request to the client of the transaction initiator; encapsulating the endorsement response, the target transaction request, the transaction certificate and the verification public key by the client of the transaction initiator to obtain a target transaction message; calling the blockchain node by the client of the transaction initiator The target transaction message is sent to the ordering node through the broadcast interface of the ordering node; the ordering node orders the target transaction message to obtain target block 1, and broadcasts the target block 1 to all blockchain nodes in the blockchain system; the accounting node on the blockchain node processes the target block 1 to obtain the transaction result of the target transaction request; based on the transaction proof and the verification public key, the accounting node on the blockchain node verifies the target block 1 and the transaction result to obtain a verification result; if the verification result is passed, it indicates that the target transaction request is successfully executed.

[0010] Furthermore, if the account type of the transaction initiator is a UTXO account model, the target transaction request is processed by the blockchain node according to the account type of the transaction initiator to execute the target transaction request, including: sending the target transaction request to the certification node on the blockchain node; querying the account information of the transaction initiator and the account information of the transaction recipient through the certification node to obtain input information; executing the target transaction request through the certification node to obtain output information; using the target transaction request, the input information, the output information, the transaction certificate and the verification public key as target data information ; Feedback the target data information to the client of the transaction initiator; Call the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator, and send the target data information to the sorting node through the broadcast interface; The sorting node sorts the target data information to obtain target block two, and broadcasts the target block two to all blockchain nodes of the blockchain system; Based on the transaction proof and the verification public key, the target block two is verified by the accounting node on the blockchain node to obtain a verification result; If the verification result is passed, it indicates that the target transaction request is successfully executed.

[0011] Furthermore, executing the target transaction request through the certification node to obtain output information includes: performing privacy computing work of the target transaction request through the hidden API service to obtain the output information.

[0012] Furthermore, obtaining a transaction request through the client of the transaction initiator includes: calling a preset function through the client of the transaction initiator to obtain the address information of the transaction initiator and the address information of the transaction recipient; and using the address information of the transaction initiator and the address information of the transaction recipient as content in the transaction request.

[0013] In order to achieve the above-mentioned purpose, according to another aspect of the present application, a processing device for blockchain system transactions is provided. The device includes: an acquisition unit, used to obtain a transaction request through the client of the transaction initiator, wherein the transaction request at least includes: transaction type, transaction amount, address information of the transaction initiator, account type of the transaction initiator, address information of the transaction recipient and account type of the transaction recipient; a determination unit, used to determine the account type of the transaction initiator through the blockchain service gateway, wherein the account type is one of the following: Account account model and UTXO account model; a first calling unit, used to, if the account type of the transaction initiator is the Account account model, then through the smart contract on the blockchain node Calling a hidden API service to process the transaction request to obtain a target transaction request, wherein the hidden API service includes at least: a transaction identity concealment service, a transaction amount concealment service, and a privacy transaction compliance verifiable service; a second calling unit is used to call the hidden API service through the Token mechanism on the client of the transaction initiator to process the transaction request if the account type of the transaction initiator is a UTXO account model to obtain the target transaction request; a processing unit is used to process the target transaction request through the blockchain node according to the account type of the transaction initiator to execute the target transaction request.

[0014] Furthermore, the device also includes: a third calling unit, which is used to call a preset module to initialize parameters and obtain public parameters before obtaining a transaction request through the client of the transaction initiator; and a fourth calling unit, which is used to call a key generation module based on the public parameters to obtain a certification key and a verification public key.

[0015] Furthermore, the first calling unit includes: a first verification module, used to send the transaction request to an endorsement node on the blockchain node, and the endorsement node verifies the transaction request; a first sending module, used to send the transaction request to the smart contract if the transaction request passes the verification; and a processing module, used to process the transaction request by calling the hidden API service through the smart contract to obtain the target transaction request.

[0016] Furthermore, the device also includes: a construction unit, configured to generate a transaction proof of the transaction request using the proof key before processing the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request.

[0017] Furthermore, if the account type of the transaction initiator is the Account model, the processing unit includes: an endorsement module, which is used to endorse the target transaction request through the endorsement node, obtain an endorsement response, and send the endorsement response and the target transaction request to the client of the transaction initiator; a first processing module, which is used to encapsulate the endorsement response, the target transaction request, the transaction certificate and the verification public key through the client of the transaction initiator to obtain a target transaction message; a calling module, which is used to call the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator, and send the target transaction message through the broadcast interface. The first broadcast module is used to sort the target transaction message through the sorting node to obtain the target block one, and broadcast the target block one to all blockchain nodes in the blockchain system; the second processing module is used to process the target block one through the accounting node on the blockchain node to obtain the transaction result of the target transaction request; the second verification module is used to verify the target block one and the transaction result through the accounting node on the blockchain node based on the transaction proof and the verification public key to obtain a verification result; the first judgment module is used to indicate that the target transaction request is successfully executed if the verification result is passed.

[0018] Furthermore, if the account type of the transaction initiator is a UTXO account model, the processing unit further includes: a second sending module for sending the target transaction request to the certification node on the blockchain node; a query module for querying the account information of the transaction initiator and the account information of the transaction recipient through the certification node to obtain input information; an execution module for executing the target transaction request through the certification node to obtain output information; a third processing module for using the target transaction request, the input information, the output information, the transaction certificate and the verification public key as target data information; and a feedback module for feeding back the target data information to the transaction initiator. a client; a third sending module, configured to call the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator, and send the target data information to the sorting node through the broadcast interface; a second broadcast module, configured to enable the sorting node to sort the target data information to obtain target block 2, and broadcast the target block 2 to all blockchain nodes of the blockchain system; a third verification module, configured to verify the target block 2 through the accounting node on the blockchain node based on the transaction proof and the verification public key to obtain a verification result; a second judgment module, configured to indicate that the target transaction request is successfully executed if the verification result is passed.

[0019] Furthermore, the execution module includes: a calculation submodule, which is used to perform privacy calculation work on the target transaction request through the hidden API service to obtain the output information.

[0020] Furthermore, the acquisition unit includes: an acquisition module, used to call a preset function through the client of the transaction initiator to obtain the address information of the transaction initiator and the address information of the transaction recipient; a fourth processing module, used to use the address information of the transaction initiator and the address information of the transaction recipient as content in the transaction request.

[0021] In order to achieve the above-mentioned purpose, according to one aspect of the present application, a processor is provided, which is used to run a program, wherein the program executes any one of the above-mentioned methods for processing transactions based on a blockchain system when running.

[0022] In order to achieve the above-mentioned objectives, according to one aspect of the present application, an electronic device is provided, which includes one or more processors and a memory, and the memory is used to store the one or more processors to implement any of the above-mentioned methods for processing transactions based on a blockchain system.

[0023] Through this application, the following steps are adopted: obtaining a transaction request through the client of the transaction initiator; determining the account type of the transaction initiator through the blockchain service gateway; if the account type of the transaction initiator is the Account account model, calling the hidden API service through the smart contract on the blockchain node to process the transaction request and obtain a target transaction request, wherein the hidden API service at least includes: transaction identity concealment service, transaction amount concealment service and privacy transaction compliance verification service; if the account type of the transaction initiator is the UTXO account model, calling the hidden API service through the Token mechanism on the client of the transaction initiator to process the transaction request and obtain a target transaction request; based on the account type of the transaction initiator, processing the target transaction request through the blockchain node to execute the target transaction request, which solves the problem in the related technology that the privacy transaction protection on the blockchain system only supports a single account model, while multiple types of account models are usually involved in transactions, resulting in poor compatibility of privacy transaction protection. By introducing the Token mechanism, the protection of transaction information under different account models is achieved. When the account type of the transaction initiator is the Account account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request; when the account type of the transaction initiator is the UTXO account model, the transaction request is processed by calling the hidden API service through the Token mechanism to obtain the target transaction request, thereby achieving the effect of improving the compatibility of privacy transaction protection. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] The accompanying drawings, which constitute part of this application, are intended to provide a further understanding of this application. The exemplary embodiments and descriptions of this application are intended to explain this application and do not constitute an improper limitation on this application. In the accompanying drawings:

[0025] Figure 1 This is a flowchart of a method for processing transactions based on a blockchain system according to an embodiment of the present application;

[0026] Figure 2 is a schematic diagram of an Account model provided according to an embodiment of the present application;

[0027] Figure 3 This is a schematic diagram of the UTXO account model provided according to an embodiment of the present application;

[0028] Figure 4 This is a flowchart of a method for processing transactions based on a blockchain system when the account type of the transaction initiator is an Account model, as provided in an embodiment of the present application;

[0029] Figure 5This is a flowchart of a method for processing transactions based on a blockchain system when the account type of the transaction initiator is a UTXO account model according to an optional embodiment of the present application;

[0030] Figure 6 This is a flowchart of an optional blockchain system transaction processing method provided in accordance with an embodiment of the present application;

[0031] Figure 7 1 is a schematic diagram of a blockchain system transaction processing device provided according to an embodiment of the present application;

[0032] Figure 8 is a schematic diagram of an electronic device provided according to an embodiment of the present application. DETAILED DESCRIPTION

[0033] It should be noted that, in the absence of conflict, the embodiments and features of the embodiments in this application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0034] In order to enable those skilled in the art to better understand the present invention, the following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of this application.

[0035] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present application described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0036] 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 display, data for analysis, etc.) involved in this disclosure are all information and data authorized by the user or fully authorized by all parties.

[0037] The present invention will be described below in conjunction with preferred implementation steps. Figure 1This is a flowchart of a method for processing transactions based on a blockchain system according to an embodiment of the present application. Figure 1 As shown, the method includes the following steps:

[0038] Step S101: Obtain a transaction request through the client of the transaction initiator, wherein the transaction request includes at least: transaction type, transaction amount, address information of the transaction initiator, account type of the transaction initiator, address information of the transaction recipient, and account type of the transaction recipient.

[0039] Specifically, a transaction request is initiated through the client of the transaction initiator, and the transaction request needs to include information such as the transaction type, transaction amount, address information of the transaction initiator, account type of the transaction initiator, address information of the transaction recipient, and account type of the transaction recipient.

[0040] Step S102: Determine the account type of the transaction initiator through the blockchain service gateway, where the account type is one of the following: Account model and UTXO account model.

[0041] Specifically, the blockchain service gateway will identify the account type of the transaction initiator when forwarding the transaction request. There are two types of account types: Account model and UTXO account model. Figure 2 As shown in the figure, this model usually has better programmability. The UTXO (Unspent Transaction Output) account model is as follows Figure 3 As shown in Figure 2, Bitcoin, one of the earliest blockchain systems, uses this account type. This account model does not aggregate and store balances but instead records individual transaction results. A user's account balance is calculated by scanning the collection of all transaction results and performing an aggregate calculation.

[0042] In step S103, if the account type of the transaction initiator is the Account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request. The hidden API service includes at least: transaction identity concealment service, transaction amount concealment service and privacy transaction compliance verification service.

[0043] Specifically, because the Account model offers greater compatibility with smart contracts, smart contracts can directly invoke hidden API services to process transaction requests and obtain the target transaction request. These hidden API services include transaction identity concealment, transaction amount concealment, and privacy transaction compliance verification. This service can be implemented through a ring signature interface, a Pedersen commitment interface, and a bulletproof proof interface. Users can flexibly schedule different services to process transaction requests based on specific scenario requirements.

[0044] In step S104, if the account type of the transaction initiator is the UTXO account model, the hidden API service is called through the Token mechanism on the client of the transaction initiator to process the transaction request and obtain the target transaction request.

[0045] Specifically, the account type of the transaction initiator is the UTXO account model. A Token mechanism is deployed on the client of the transaction initiator, and the hidden API service is called through the Token mechanism to process the transaction request to obtain the target transaction request.

[0046] Step S105: Process the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request.

[0047] In summary, by introducing the Token mechanism, we can protect transaction information under different account models. When the account type of the transaction initiator is the Account account model, the smart contract on the blockchain node calls the hidden API service to process the transaction request and obtain the target transaction request. When the account type of the transaction initiator is the UTXO account model, the Token mechanism calls the hidden API service to process the transaction request and obtain the target transaction request, thereby improving the compatibility of privacy transaction protection.

[0048] Optionally, in the blockchain system transaction processing method provided in an embodiment of the present application, before obtaining the transaction request through the client of the transaction initiator, the method further includes: calling a preset module to initialize parameters to obtain public parameters; and calling a key generation module based on the public parameters to obtain a proof key and a verification public key.

[0049] Specifically, before a transaction request is made, parameters are initialized using a pre-set module to generate public parameters. Based on these public parameters, the key generation module is then called to generate a proof key and a verification public key. These proof key and verification public key verify the legitimacy of the transaction request, ensuring successful execution.

[0050] Optionally, in the blockchain system transaction processing method provided in the embodiment of the present application, if the account type of the transaction initiator is the Account account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request, including: sending the transaction request to the endorsement node on the blockchain node, and the endorsement node verifies the transaction request; if the transaction request passes the verification, the transaction request is sent to the smart contract; and the transaction request is processed by calling the hidden API service through the smart contract to obtain the target transaction request.

[0051] Specifically, when the account type of the transaction initiator is the Account model, the transaction processing flow chart is as follows: Figure 4 As shown, the transaction initiator's client first sends a transaction request to an endorsing node on the blockchain. The endorsing node verifies the transaction request and, if it passes verification, sends it to the smart contract. The smart contract then calls the hidden API service based on actual needs to process the transaction request and obtain the target transaction request. Verification of the transaction request by the endorsing node ensures the legitimacy of the transaction.

[0052] Optionally, in the blockchain system transaction processing method provided in an embodiment of the present application, before processing the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request, the method also includes: generating a transaction certificate for the transaction request through a certification key.

[0053] Specifically, a proof key is used to generate a transaction proof for the transaction request so that the accounting node on the subsequent blockchain node can perform verification.

[0054] Optionally, in the blockchain system transaction processing method provided in an embodiment of the present application, if the account type of the transaction initiator is the Account account model, the target transaction request is processed by the blockchain node according to the account type of the transaction initiator to execute the target transaction request, including: endorsing the target transaction request by the endorsement node to obtain an endorsement response, and sending the endorsement response and the target transaction request to the client of the transaction initiator; encapsulating the endorsement response, the target transaction request, the transaction proof and the verification public key by the client of the transaction initiator to obtain a target transaction message; calling the broadcast interface of the sorting node on the blockchain node by the client of the transaction initiator, and sending the target transaction message to the sorting node through the broadcast interface; sorting the target transaction message by the sorting node to obtain a target block one, and broadcasting the target block one to all blockchain nodes of the blockchain system; processing the target block one by the accounting node on the blockchain node to obtain a transaction result of the target transaction request; verifying the target block one and the transaction result by the accounting node on the blockchain node based on the transaction proof and the verification public key to obtain a verification result; if the verification result is passed, it indicates that the target transaction request is successfully executed.

[0055] Specifically, if Figure 4 As shown, the transaction initiator's account type is the Account model. After receiving the target transaction request, the endorsing node endorses the target transaction request and returns the endorsement response to the transaction initiator's client. Upon receiving the endorsement response, the client encapsulates the endorsement response, the target transaction request, the transaction proof, and the verification public key to obtain the target transaction message. The transaction initiator's client then calls the broadcast interface of the ordering node on the blockchain node and sends the target transaction message to the ordering node. The ordering node sorts the target transaction message, obtains target block 1, and broadcasts target block 1 to all blockchain nodes in the blockchain system to achieve consensus. The accounting node then processes target block 1 to obtain the transaction result for this transaction request. The accounting node verifies target block 1 and the transaction result to obtain a verification result. If the verification result passes, the target transaction request is successfully executed. If the verification result fails, the target transaction request fails. This process ensures the security and legitimacy of transactions on the blockchain system.

[0056] Optionally, in the blockchain system transaction processing method provided in an embodiment of the present application, if the account type of the transaction initiator is a UTXO account model, the target transaction request is processed by the blockchain node according to the account type of the transaction initiator to execute the target transaction request, including: sending the target transaction request to the proof node on the blockchain node; querying the account information of the transaction initiator and the account information of the transaction recipient through the proof node to obtain input information; executing the target transaction request through the proof node to obtain output information; using the target transaction request, input information, output information, transaction proof and verification public key as target data information; feeding back the target data information to the client of the transaction initiator; calling the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator, and sending the target data information to the sorting node through the broadcast interface; the sorting node sorts the target data information to obtain target block two, and broadcasts the target block two to all blockchain nodes of the blockchain system; based on the transaction proof and verification public key, the target block two is verified by the accounting node on the blockchain node to obtain a verification result; if the verification result is passed, it indicates that the target transaction request is successfully executed.

[0057] Specifically, if Figure 5 As shown, when the transaction initiator's account type is a UTXO account model, after the transaction initiator's client initiates a transaction request, it uses the token mechanism to call the hidden API service on demand to process the transaction request, obtaining the target transaction request. The target transaction request is then sent to the proving node on the blockchain node. The proving node first queries the transaction initiator's account information (i.e., balance information, represented in ciphertext) and the transaction recipient's account information to obtain the input information. The proving node then executes the target transaction request and performs a private transaction calculation to obtain the output information. For example, if account A transfers xx yuan to account B, the proving node first queries the balance information of accounts A and B (i.e., the input information mentioned above), then performs a private calculation to calculate the balance information of accounts A and B after the transfer (i.e., the output information mentioned above). The target transaction request, input information, output information, transaction proof, and verification public key are then used as the target data information and fed back to the transaction initiator's client. This is to enable the initiator's client to call the broadcast interface of the ordering node on the blockchain node to broadcast the target data information. The target data is sent to the sorting node via the broadcast interface. The sorting node sorts the target data to obtain target block 2, which is then broadcast to all blockchain nodes in the blockchain system to achieve consensus. Finally, based on the transaction proof and the verification public key, the accounting node on the blockchain node verifies target block 2 and obtains a verification result. If the verification result is passed, the transaction request is successfully executed. This process ensures the security and legitimacy of transactions on the blockchain system.

[0058] Optionally, in the blockchain system transaction processing method provided in an embodiment of the present application, the target transaction request is executed by the certification node to obtain output information, including: performing privacy calculation work of the target transaction request through the hidden API service to obtain output information.

[0059] Specifically, the proving node executes the target transaction request and performs privacy-preserving computations through the hidden API service to obtain output information. This privacy-preserving computation ensures data privacy and security.

[0060] Optionally, in the blockchain system transaction processing method provided in an embodiment of the present application, obtaining a transaction request through the client of the transaction initiator includes: calling a preset function through the client of the transaction initiator to obtain the address information of the transaction initiator and the address information of the transaction recipient; and using the address information of the transaction initiator and the address information of the transaction recipient as content in the transaction request.

[0061] Specifically, the address information of the transaction initiator and the address information of the transaction recipient are generated through a preset function.

[0062] The embodiment of the present application provides a method for processing transactions based on a blockchain system, which obtains a transaction request through the client of the transaction initiator; determines the account type of the transaction initiator through a blockchain service gateway; if the account type of the transaction initiator is the Account account model, the transaction request is processed by calling a hidden API service through the smart contract on the blockchain node to obtain a target transaction request, wherein the hidden API service at least includes: a transaction identity concealment service, a transaction amount concealment service, and a privacy transaction compliance verification service; if the account type of the transaction initiator is the UTXO account model, the transaction request is processed by calling a hidden API service through the Token mechanism on the client of the transaction initiator to obtain a target transaction request; based on the account type of the transaction initiator, the target transaction request is processed through the blockchain node to execute the target transaction request, thereby solving the problem in the related art that privacy transaction protection on the blockchain system only supports a single account model, while multiple types of account models are usually involved in transactions, resulting in poor compatibility of privacy transaction protection. By introducing the Token mechanism, the protection of transaction information under different account models is achieved. When the account type of the transaction initiator is the Account account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request; when the account type of the transaction initiator is the UTXO account model, the transaction request is processed by calling the hidden API service through the Token mechanism to obtain the target transaction request, thereby achieving the effect of improving the compatibility of privacy transaction protection.

[0063] like Figure 6 As shown, a flowchart of an optional blockchain system transaction processing method provided in an embodiment of the present application is provided. Public parameters are obtained through a preset module, and a proof key and a verification public key are obtained through the public parameters. The client of the transaction initiator sends a transaction request, and the blockchain service gateway determines the account type of the transaction initiator. If the account type is the Account account model, the smart contract deployed on the blockchain node calls the hidden API service to process the transaction request to obtain the target transaction request; if the account type is the UTXO account model, the client of the transaction initiator calls the hidden API service through the Token mechanism to process the transaction request to obtain the target transaction request. A transaction proof of the transaction request is generated by the proof key. Then, transaction endorsement, transaction broadcast and transaction verification are performed on the blockchain node to execute the transaction request.

[0064] It should be noted that the steps shown in the flowcharts of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and that, although a logical order is shown in the flowcharts, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0065] The present application also provides a blockchain-based transaction processing device. It should be noted that the blockchain-based transaction processing device provided in the present application can be used to execute the blockchain-based transaction processing method provided in the present application. The following describes the blockchain-based transaction processing device provided in the present application.

[0066] Figure 7 Schematic diagram of a processing device based on blockchain system transactions according to an embodiment of the present application. Figure 7 As shown, the device includes: an acquisition unit 701, a determination unit 702, a first calling unit 703, a second calling unit 704 and a processing unit 705.

[0067] An acquisition unit 701 is configured to acquire a transaction request from a client of a transaction initiator, wherein the transaction request includes at least: a transaction type, a transaction amount, an address of the transaction initiator, an account type of the transaction initiator, an address of the transaction recipient, and an account type of the transaction recipient;

[0068] A determining unit 702 is configured to determine the account type of the transaction initiator through the blockchain service gateway, where the account type is one of the following: an Account model and a UTXO account model;

[0069] The first calling unit 703 is configured to, if the account type of the transaction initiator is the Account model, process the transaction request through a smart contract on the blockchain node by calling a hidden API service to obtain a target transaction request, wherein the hidden API service includes at least: a transaction identity concealment service, a transaction amount concealment service, and a privacy transaction compliance verification service;

[0070] The second calling unit 704 is configured to, if the account type of the transaction initiator is a UTXO account model, call the hidden API service through the token mechanism on the client of the transaction initiator to process the transaction request and obtain a target transaction request;

[0071] The processing unit 705 is configured to process the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request.

[0072] The processing device based on blockchain system transactions provided by the embodiment of the present application obtains a transaction request through the client of the transaction initiator through the acquisition unit 701, wherein the transaction request includes at least: transaction type, transaction amount, address information of the transaction initiator, account type of the transaction initiator, address information of the transaction recipient and account type of the transaction recipient; the determination unit 702 determines the account type of the transaction initiator through the blockchain service gateway, wherein the account type is one of the following: Account account model and UTXO account model; the first calling unit 703 processes the transaction request by calling the hidden API service through the smart contract on the blockchain node if the account type of the transaction initiator is the Account account model, and obtains The target transaction request, wherein the hidden API service includes at least: a transaction identity concealment service, a transaction amount concealment service, and a private transaction compliance and verifiable service; if the transaction initiator's account type is a UTXO account model, the second calling unit 704 calls the hidden API service through the token mechanism on the transaction initiator's client to process the transaction request and obtain the target transaction request; the processing unit 705 processes the target transaction request through the blockchain node based on the transaction initiator's account type to execute the target transaction request, thereby solving the problem that private transaction protection on blockchain systems in related technologies only supports a single account model, while transactions often involve multiple account models, resulting in poor compatibility of private transaction protection. By introducing a token mechanism to protect transaction information under different account models, when the transaction initiator's account type is an Account account model, the hidden API service is called by the smart contract on the blockchain node to process the transaction request and obtain the target transaction request; when the transaction initiator's account type is a UTXO account model, the hidden API service is called through the token mechanism to process the transaction request and obtain the target transaction request, thereby achieving the effect of improving the compatibility of private transaction protection.

[0073] Optionally, in the blockchain system transaction processing device provided in an embodiment of the present application, the device further includes: a third calling unit, used to call a preset module to initialize parameters and obtain public parameters before obtaining a transaction request through the client of the transaction initiator; and a fourth calling unit, used to call a key generation module based on the public parameters to obtain a proof key and a verification public key.

[0074] Optionally, in the blockchain system transaction processing device provided in an embodiment of the present application, the first calling unit 703 includes: a first verification module, used to send the transaction request to the endorsement node on the blockchain node, and the endorsement node verifies the transaction request; a first sending module, used to send the transaction request to the smart contract if the transaction request passes the verification; and a processing module, used to process the transaction request by calling the hidden API service through the smart contract to obtain the target transaction request.

[0075] Optionally, in the blockchain system transaction processing device provided in an embodiment of the present application, the device also includes: a construction unit, which is used to generate a transaction certificate for the transaction request through a certification key before processing the target transaction request through a blockchain node based on the account type of the transaction initiator to execute the target transaction request.

[0076] Optionally, in the processing device based on blockchain system transactions provided in the embodiment of the present application, if the account type of the transaction initiator is the Account account model, the processing unit 705 includes: an endorsement module for endorsing the target transaction request through the endorsement node, obtaining an endorsement response, and sending the endorsement response and the target transaction request to the client of the transaction initiator; a first processing module for encapsulating the endorsement response, the target transaction request, the transaction certificate and the verification public key through the client of the transaction initiator to obtain a target transaction message; a calling module for calling the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator , sending the target transaction message to the sorting node through the broadcast interface; the first broadcast module is used to sort the target transaction message through the sorting node to obtain the target block one, and broadcast the target block one to all blockchain nodes in the blockchain system; the second processing module is used to process the target block one through the accounting node on the blockchain node to obtain the transaction result of the target transaction request; the second verification module is used to verify the target block one and the transaction result through the accounting node on the blockchain node based on the transaction proof and the verification public key to obtain the verification result; the first judgment module is used to indicate that the target transaction request is successfully executed if the verification result is passed.

[0077] Optionally, in the processing device based on blockchain system transactions provided in the embodiment of the present application, if the account type of the transaction initiator is the UTXO account model, the processing unit 705 further includes: a second sending module for sending the target transaction request to the certification node on the blockchain node; a query module for querying the account information of the transaction initiator and the account information of the transaction recipient through the certification node to obtain input information; an execution module for executing the target transaction request through the certification node to obtain output information; a third processing module for using the target transaction request, input information, output information, transaction proof and verification public key as target data information; a feedback module for The target data information is fed back to the client of the transaction initiator; the third sending module is used to call the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator, and send the target data information to the sorting node through the broadcast interface; the second broadcast module is used for the sorting node to sort the target data information to obtain target block 2, and broadcast target block 2 to all blockchain nodes in the blockchain system; the third verification module is used to verify the target block 2 through the accounting node on the blockchain node based on the transaction proof and verification public key to obtain a verification result; the second judgment module is used to indicate that the target transaction request is successfully executed if the verification result is passed.

[0078] Optionally, in the blockchain system transaction processing device provided in an embodiment of the present application, the execution module includes: a calculation submodule, which is used to perform privacy calculation of the target transaction request through a hidden API service to obtain output information.

[0079] Optionally, in the blockchain system transaction processing device provided in an embodiment of the present application, the acquisition module is used to call a preset function through the client of the transaction initiator to obtain the address information of the transaction initiator and the address information of the transaction recipient; the fourth processing module is used to use the address information of the transaction initiator and the address information of the transaction recipient as content in the transaction request.

[0080] The processing device based on blockchain system transactions includes a processor and a memory. The above-mentioned acquisition unit 701, determination unit 702, first calling unit 703, second calling unit 704 and processing unit 705 are all stored in the memory as program units, and the processor executes the above-mentioned program units stored in the memory to implement corresponding functions.

[0081] The processor contains a kernel, which retrieves the corresponding program unit from the memory. There can be one or more kernels, and the kernel parameters can be adjusted to process transactions in the blockchain system.

[0082] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.

[0083] An embodiment of the present invention provides a processor, which is used to run a program, wherein the processing method based on blockchain system transactions is executed when the program is running.

[0084] like Figure 8 As shown, an embodiment of the present invention provides an electronic device, which includes a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, the following steps are implemented: obtaining a transaction request through a client of the transaction initiator, wherein the transaction request includes at least: transaction type, transaction amount, address information of the transaction initiator, account type of the transaction initiator, address information of the transaction recipient, and account type of the transaction recipient; determining the account type of the transaction initiator through a blockchain service gateway, wherein the account type is one of the following: Account account model and UTXO account model; if the account type of the transaction initiator is the Account account model, processing the transaction request through a smart contract on a blockchain node using a hidden API service to obtain a target transaction request, wherein the hidden API service includes at least: transaction identity concealment service, transaction amount concealment service, and privacy transaction compliance verification service; if the account type of the transaction initiator is the UTXO account model, processing the transaction request through a token mechanism on the client of the transaction initiator using a hidden API service to obtain a target transaction request; processing the target transaction request through a blockchain node based on the account type of the transaction initiator to execute the target transaction request.

[0085] Optionally, before obtaining the transaction request through the client of the transaction initiator, the method further includes: calling a preset module to initialize parameters and obtain public parameters; and calling a key generation module based on the public parameters to obtain a certification key and a verification public key.

[0086] Optionally, if the account type of the transaction initiator is the Account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request, including: sending the transaction request to the endorsement node on the blockchain node, and the endorsement node verifying the transaction request; if the transaction request passes the verification, the transaction request is sent to the smart contract; the transaction request is processed by calling the hidden API service through the smart contract to obtain the target transaction request.

[0087] Optionally, before processing the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request, the method also includes: generating a transaction proof of the transaction request through a proof key.

[0088] Optionally, if the account type of the transaction initiator is the Account model, the target transaction request is processed by the blockchain node based on the account type of the transaction initiator to execute the target transaction request, including: endorsing the target transaction request by the endorsement node to obtain an endorsement response, and sending the endorsement response and the target transaction request to the client of the transaction initiator; encapsulating the endorsement response, the target transaction request, the transaction proof and the verification public key by the client of the transaction initiator to obtain a target transaction message; calling the broadcast interface of the sorting node on the blockchain node by the client of the transaction initiator, and sending the target transaction message to the sorting node through the broadcast interface; sorting the target transaction message by the sorting node to obtain target block one, and broadcasting the target block one to all blockchain nodes of the blockchain system; processing the target block one by the accounting node on the blockchain node to obtain the transaction result of the target transaction request; verifying the target block one and the transaction result by the accounting node on the blockchain node based on the transaction proof and the verification public key to obtain a verification result; if the verification result is passed, it indicates that the target transaction request is successfully executed.

[0089] Optionally, if the account type of the transaction initiator is a UTXO account model, the target transaction request is processed through the blockchain node based on the account type of the transaction initiator to execute the target transaction request, including: sending the target transaction request to the proof node on the blockchain node; querying the account information of the transaction initiator and the account information of the transaction recipient through the proof node to obtain input information; executing the target transaction request through the proof node to obtain output information; using the target transaction request, input information, output information, transaction proof and verification public key as target data information; feeding back the target data information to the client of the transaction initiator; calling the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator, and sending the target data information to the sorting node through the broadcast interface; the sorting node sorts the target data information to obtain target block two, and broadcasts the target block two to all blockchain nodes of the blockchain system; based on the transaction proof and verification public key, the target block two is verified by the accounting node on the blockchain node to obtain a verification result; if the verification result is passed, it means that the target transaction request is successfully executed.

[0090] Optionally, the target transaction request is executed by the certification node to obtain output information, including: performing privacy computing work on the target transaction request through the hidden API service to obtain output information.

[0091] Optionally, obtaining the transaction request through the client of the transaction initiator includes: invoking a preset function through the client of the transaction initiator to obtain the address information of the transaction initiator and the address information of the transaction recipient; and using the address information of the transaction initiator and the address information of the transaction recipient as content in the transaction request. The device in this context may be a server, a PC, a PAD, a mobile phone, etc.

[0092] The present application also provides a computer program product, which, when executed on a data processing device, is suitable for executing a program that initializes the following method steps: obtaining a transaction request through the client of the transaction initiator, wherein the transaction request includes at least: transaction type, transaction amount, address information of the transaction initiator, account type of the transaction initiator, address information of the transaction recipient, and account type of the transaction recipient; determining the account type of the transaction initiator through the blockchain service gateway, wherein the account type is one of the following: Account account model and UTXO account model; if the account type of the transaction initiator is the Account account model, then calling the hidden API service through the smart contract on the blockchain node to process the transaction request to obtain a target transaction request, wherein the hidden API service includes at least: transaction identity concealment service, transaction amount concealment service and privacy transaction compliance verification service; if the account type of the transaction initiator is the UTXO account model, then calling the hidden API service through the Token mechanism on the client of the transaction initiator to process the transaction request to obtain a target transaction request; based on the account type of the transaction initiator, processing the target transaction request through the blockchain node to execute the target transaction request.

[0093] Optionally, before obtaining the transaction request through the client of the transaction initiator, the method further includes: calling a preset module to initialize parameters and obtain public parameters; and calling a key generation module based on the public parameters to obtain a certification key and a verification public key.

[0094] Optionally, if the account type of the transaction initiator is the Account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request, including: sending the transaction request to the endorsement node on the blockchain node, and the endorsement node verifying the transaction request; if the transaction request passes the verification, the transaction request is sent to the smart contract; the transaction request is processed by calling the hidden API service through the smart contract to obtain the target transaction request.

[0095] Optionally, before processing the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request, the method also includes: generating a transaction proof of the transaction request through a proof key.

[0096] Optionally, if the account type of the transaction initiator is the Account model, the target transaction request is processed by the blockchain node based on the account type of the transaction initiator to execute the target transaction request, including: endorsing the target transaction request by the endorsement node to obtain an endorsement response, and sending the endorsement response and the target transaction request to the client of the transaction initiator; encapsulating the endorsement response, the target transaction request, the transaction proof and the verification public key by the client of the transaction initiator to obtain a target transaction message; calling the broadcast interface of the sorting node on the blockchain node by the client of the transaction initiator, and sending the target transaction message to the sorting node through the broadcast interface; sorting the target transaction message by the sorting node to obtain target block one, and broadcasting the target block one to all blockchain nodes of the blockchain system; processing the target block one by the accounting node on the blockchain node to obtain the transaction result of the target transaction request; verifying the target block one and the transaction result by the accounting node on the blockchain node based on the transaction proof and the verification public key to obtain a verification result; if the verification result is passed, it indicates that the target transaction request is successfully executed.

[0097] Optionally, if the account type of the transaction initiator is a UTXO account model, the target transaction request is processed through the blockchain node based on the account type of the transaction initiator to execute the target transaction request, including: sending the target transaction request to the proof node on the blockchain node; querying the account information of the transaction initiator and the account information of the transaction recipient through the proof node to obtain input information; executing the target transaction request through the proof node to obtain output information; using the target transaction request, input information, output information, transaction proof and verification public key as target data information; feeding back the target data information to the client of the transaction initiator; calling the broadcast interface of the sorting node on the blockchain node through the client of the transaction initiator, and sending the target data information to the sorting node through the broadcast interface; the sorting node sorts the target data information to obtain target block two, and broadcasts the target block two to all blockchain nodes of the blockchain system; based on the transaction proof and verification public key, the target block two is verified by the accounting node on the blockchain node to obtain a verification result; if the verification result is passed, it means that the target transaction request is successfully executed.

[0098] Optionally, the target transaction request is executed by the certification node to obtain output information, including: performing privacy computing work on the target transaction request through the hidden API service to obtain output information.

[0099] Optionally, obtaining the transaction request through the client of the transaction initiator includes: calling a preset function through the client of the transaction initiator to obtain the address information of the transaction initiator and the address information of the transaction recipient; and using the address information of the transaction initiator and the address information of the transaction recipient as content in the transaction request.

[0100] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

[0101] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0102] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.

[0103] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0104] In a typical configuration, a computing device includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.

[0105] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.

[0106] Computer-readable media includes permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media (transitory media), such as modulated data signals and carrier waves.

[0107] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a ..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.

[0108] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present application may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0109] The above are merely embodiments of the present application and are not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present application should all be included within the scope of the claims of the present application.

Claims

1. A method for processing transactions based on a blockchain system, characterized in that: include: Obtaining a transaction request through the client of the transaction initiator, wherein the transaction request includes at least: transaction type, transaction amount, address information of the transaction initiator, account type of the transaction initiator, address information of the transaction recipient, and account type of the transaction recipient; Determining the account type of the transaction initiator through a blockchain service gateway, wherein the account type is one of the following: an Account model and a UTXO account model; If the account type of the transaction initiator is the Account model, the smart contract on the blockchain node calls the hidden API service to process the transaction request and obtain the target transaction request, wherein the hidden API service at least includes: transaction identity concealment service, transaction amount concealment service and privacy transaction compliance verification service. The transaction identity concealment service is implemented through the ring signature interface, the transaction amount concealment service is implemented through the Pedersen commitment interface, and the privacy transaction compliance verification service is implemented through the bulletproof proof interface; If the account type of the transaction initiator is a UTXO account model, the hidden API service is called through the Token mechanism on the client of the transaction initiator to process the transaction request and obtain the target transaction request; The target transaction request is processed by the blockchain node based on the account type of the transaction initiator to execute the target transaction request.

2. The method according to claim 1, characterized in that Before obtaining the transaction request through the client of the transaction initiator, the method further includes: Call the preset module to initialize parameters and obtain common parameters; Based on the public parameters, a key generation module is called to obtain a certification key and a verification public key.

3. The method according to claim 2, characterized in that If the account type of the transaction initiator is the Account model, the transaction request is processed by calling the hidden API service through the smart contract on the blockchain node to obtain the target transaction request, including: Sending the transaction request to an endorsing node on the blockchain node, where the endorsing node verifies the transaction request; If the transaction request passes the verification, the transaction request is sent to the smart contract; The smart contract calls the hidden API service to process the transaction request to obtain the target transaction request.

4. The method according to claim 3, characterized in that Before processing the target transaction request by the blockchain node based on the account type of the transaction initiator to execute the target transaction request, the method further includes: A transaction certificate for the transaction request is generated using the certificate key.

5. The method according to claim 4, characterized in that If the account type of the transaction initiator is the Account model, processing the target transaction request through the blockchain node according to the account type of the transaction initiator to execute the target transaction request includes: Endorsing the target transaction request through the endorsing node to obtain an endorsement response, and sending the endorsement response and the target transaction request to the client of the transaction initiator; The transaction initiator's client encapsulates the endorsement response, the target transaction request, the transaction proof, and the verification public key to obtain a target transaction message; The client of the transaction initiator calls the broadcast interface of the sorting node on the blockchain node, and sends the target transaction message to the sorting node through the broadcast interface; The target transaction message is sorted by the sorting node to obtain target block 1, and the target block 1 is broadcast to all blockchain nodes in the blockchain system; Processing the target block 1 through the accounting node on the blockchain node to obtain a transaction result of the target transaction request; Based on the transaction proof and the verification public key, the target block 1 and the transaction result are verified by the accounting node on the blockchain node to obtain a verification result; If the verification result is passed, it means that the target transaction request is executed successfully.

6. The method according to claim 4, characterized in that If the account type of the transaction initiator is a UTXO account model, the target transaction request is processed by the blockchain node according to the account type of the transaction initiator to execute the target transaction request, including: Sending the target transaction request to a certification node on the blockchain node; querying the account information of the transaction initiator and the account information of the transaction recipient through the certification node to obtain input information; Executing the target transaction request through the certification node to obtain output information; The target transaction request, the input information, the output information, the transaction certificate and the verification public key are used as target data information; Feedback the target data information to the client of the transaction initiator; The transaction initiator's client calls the broadcast interface of the sorting node on the blockchain node, and sends the target data information to the sorting node through the broadcast interface; The sorting node sorts the target data information to obtain target block 2, and broadcasts the target block 2 to all blockchain nodes in the blockchain system; Verifying the target block 2 through the accounting node on the blockchain node based on the transaction proof and the verification public key to obtain a verification result; If the verification result is passed, it means that the target transaction request is executed successfully.

7. The method according to claim 6, characterized in that The target transaction request is executed by the certification node to obtain output information including: The privacy computing work of the target transaction request is performed through the hidden API service to obtain the output information.

8. The method according to claim 1, characterized in that Obtain the transaction request through the transaction initiator's client, including: The client of the transaction initiator calls a preset function to obtain the address information of the transaction initiator and the address information of the transaction recipient; The address information of the transaction initiator and the address information of the transaction recipient are used as the content of the transaction request.

9. A processing device based on blockchain system transactions, characterized in that: include: an acquiring unit, configured to acquire a transaction request through a client of a transaction initiator, wherein the transaction request includes at least: a transaction type, a transaction amount, address information of the transaction initiator, an account type of the transaction initiator, and address information and an account type of the transaction recipient; A determining unit, configured to determine the account type of the transaction initiator through a blockchain service gateway, wherein the account type is one of the following: an Account model and a UTXO account model; A first calling unit is configured to, if the account type of the transaction initiator is the Account model, call a hidden API service through a smart contract on a blockchain node to process the transaction request and obtain a target transaction request, wherein the hidden API service includes at least: a transaction identity hiding service, a transaction amount hiding service, and a privacy transaction compliance verifiable service, wherein the transaction identity hiding service is implemented through a ring signature interface, the transaction amount hiding service is implemented through a Pedersen commitment interface, and the privacy transaction compliance verifiable service is implemented through a bulletproof proof interface; A second calling unit is configured to, if the account type of the transaction initiator is a UTXO account model, call the hidden API service through a token mechanism on the client of the transaction initiator to process the transaction request and obtain the target transaction request; A processing unit is configured to process the target transaction request through the blockchain node based on the account type of the transaction initiator to execute the target transaction request.

10. A processor, characterized in that: The processor is used to run a program, wherein when the program is run, the processing method based on blockchain system transactions described in any one of claims 1 to 8 is executed.

11. An electronic device, characterized in that: The system comprises one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the processing method based on blockchain system transactions as described in any one of claims 1 to 8.

Citation Information

Patent Citations

  • Blockchain key management method, system and key management device, storage medium

    CN108600182A

  • Block chain transaction method and device, electronic equipment and storage medium

    CN113128989A