A method, terminal and system for splitting digital currency during a transaction

By generating and verifying the trust chain of digital currency, the security issues in offline digital currency transactions are solved, and safe and efficient offline transactions are achieved.

CN115222528BActive Publication Date: 2025-10-03THE PEOPLES BANK OF CHINA DIGITAL CURRENCY INST
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110414590.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-04-16
Publication Date
2025-10-03
Estimated Expiration
2041-04-16

AI Technical Summary

Technical Problem

In offline digital currency transactions, how to ensure the security and credibility of transactions, especially when both parties cannot stay online.

Method used

By splitting the digital currency to generate the first trust chain and the second trust chain, the terminal's private key and public key are used for signing, transaction information is generated and verified, and offline transactions are realized.

Benefits of technology

It realizes the safe and effective splitting and verification of digital currency in offline transactions, improving the security and credibility of transactions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115222528B_ABST
    Figure CN115222528B_ABST
Patent Text Reader

Abstract

The present invention discloses a method, terminal, and system for splitting digital currency during a transaction, relating to the field of computer technology. A specific implementation of the method includes: determining a first transaction request indicating digital currency and first transaction information, the first transaction information including a first transaction amount; generating second transaction information including a second transaction amount based on the first transaction information; signing the first transaction information and the second transaction information using a private key of a first terminal; generating a first trust chain based on the signed first transaction information and the digital currency, and generating a second trust chain based on the signed second transaction information and the digital currency; and transmitting the first trust chain to a second terminal, so that the second terminal and the first terminal can conduct an offline transaction corresponding to the first transaction amount based on the first trust chain. This implementation facilitates offline transactions using digital currency while improving the security of offline transactions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a method, terminal, and system for splitting digital currency during a transaction. Background Art

[0002] In the era of digital economy, digital currency has attracted increasing attention from banks and consumers in various countries due to its low cost and convenience.

[0003] When consumers use digital currency to conduct transactions, they may not be able to maintain real-time online connections. For example, if both parties are offline, they cannot maintain online connections. In this case, the transaction can only be conducted offline. During offline transactions, ensuring the credibility of the digital currency is crucial to transaction security. Summary of the Invention

[0004] In view of this, embodiments of the present invention provide a method, terminal, and system for splitting digital currency during a transaction, which can realize the safe and effective splitting of digital currency during an offline transaction and realize the security verification of digital currency, thereby facilitating the use of digital currency for offline transactions while improving the security of offline transactions.

[0005] To achieve the above objectives, according to one aspect of an embodiment of the present invention, a method for splitting digital currency during a transaction is provided.

[0006] A method for splitting digital currency during a transaction according to an embodiment of the present invention, when applied to a first terminal, includes: determining a first transaction request, the first transaction request indicating digital currency to be traded and first transaction information, the first transaction information including a first transaction amount;

[0007] Generating second transaction information including a second transaction amount based on the first transaction information; the second transaction amount being the difference between the available balance of the digital currency and the first transaction amount;

[0008] Signing the first transaction information and the second transaction information respectively using the private key of the first terminal;

[0009] generating a first trust chain based on the signed first transaction information and the digital currency, and generating a second trust chain based on the signed second transaction information and the digital currency;

[0010] The first trust chain is sent to a second terminal, so that the second terminal and the first terminal implement an offline transaction corresponding to the first transaction amount according to the first trust chain.

[0011] Optionally, the method further includes:

[0012] The second trust chain is sent to a third terminal, so that the third terminal and the first terminal implement an offline transaction corresponding to the second transaction amount according to the second trust chain.

[0013] Optionally, generating a first trust chain based on the signed first transaction information and the digital currency includes:

[0014] Using the private key of the first terminal, signing the first transaction information and the public key of the second terminal to generate a first transaction chain;

[0015] The first trust chain is generated according to the first transaction chain and the digital currency.

[0016] Optionally, generating a second trust chain based on the signed second transaction information and the digital currency includes:

[0017] Using the private key of the first terminal, signing the second transaction information and the public key of the first terminal to generate a second transaction chain;

[0018] The second trust chain is generated according to the second transaction chain and the digital currency.

[0019] To achieve the above objectives, according to another aspect of an embodiment of the present invention, a method for splitting digital currency during a transaction is provided.

[0020] A method for splitting digital currency during a transaction according to an embodiment of the present invention, when applied to a second terminal, includes: receiving a first trust chain sent by a first terminal, the first trust chain including: digital currency to be traded and first transaction information signed using a private key of the first terminal; the first transaction information including a first transaction amount;

[0021] Verifying the first transaction information using the public key of the first terminal;

[0022] When the first transaction information is verified, an offline transaction is performed with the first terminal based on the digital currency and the first transaction amount.

[0023] Optionally, the method further includes:

[0024] Determining a second transaction request, where the second transaction request indicates third transaction information and the digital currency, and the third transaction information includes a third transaction amount;

[0025] Using the private key of the second terminal, signing the third transaction information and the public key of the fourth terminal to form a third transaction chain;

[0026] The third transaction chain is written into the first trust chain, and the first trust chain with the third transaction chain written into it is sent to the fourth terminal, so that the fourth terminal implements an offline transaction corresponding to the third transaction amount according to the first trust chain with the third transaction chain written into it.

[0027] Optionally, when the first transaction information is verified and the first trust chain includes multiple transaction information, the method further includes:

[0028] The digital currency is derived according to the transaction amount included in the last transaction information among the multiple transaction information.

[0029] To achieve the above-mentioned objective, according to another aspect of an embodiment of the present invention, a first terminal for splitting digital currency during a transaction is provided.

[0030] A first terminal for splitting digital currency during a transaction in an embodiment of the present invention includes: a first determination module, a splitting module, and a first transaction module; wherein,

[0031] The first determining module is configured to determine a first transaction request, wherein the first transaction request indicates a digital currency to be traded and first transaction information, wherein the first transaction information includes a first transaction amount;

[0032] The splitting module is configured to generate, based on the first transaction information, second transaction information including a second transaction amount, where the second transaction amount is the difference between the available balance of the digital currency and the first transaction amount; sign the first transaction information and the second transaction information using the private key of the first terminal, generate a first trust chain based on the signed first transaction information and the digital currency, and generate a second trust chain based on the signed second transaction information and the digital currency;

[0033] The first transaction module is configured to send the first trust chain to a second terminal, so that the second terminal and the first terminal implement an offline transaction corresponding to the first transaction amount based on the first trust chain.

[0034] Optionally, the first transaction module is further configured to send the second trust chain to a third terminal, so that the third terminal and the first terminal implement an offline transaction corresponding to the second transaction amount based on the second trust chain.

[0035] Optionally, the splitting module is configured to use the private key of the first terminal to sign the first transaction information and the public key of the second terminal to generate a first transaction chain; and generate the first trust chain based on the first transaction chain and the digital currency.

[0036] Optionally, the splitting module is configured to use the private key of the first terminal to sign the second transaction information and the public key of the first terminal to form a second transaction chain; and generate the second trust chain based on the second transaction chain and the digital currency.

[0037] To achieve the above-mentioned purpose, according to another aspect of an embodiment of the present invention, a second terminal for splitting digital currency during a transaction is provided.

[0038] A second terminal for splitting digital currency during a transaction in an embodiment of the present invention includes: a receiving module, a verification module, and a second transaction module; wherein,

[0039] The receiving module is configured to receive a first trust chain sent by a first terminal, wherein the first trust chain includes: digital currency to be traded and first transaction information signed using a private key of the first terminal, wherein the first transaction information includes a first transaction amount;

[0040] The verification module is configured to verify the first transaction information using the public key of the first terminal;

[0041] The second transaction module is configured to perform an offline transaction with the first terminal based on the digital currency and the first transaction amount when the first transaction information is verified.

[0042] Optionally, the receiving module is further configured to receive a second transaction request, where the second transaction request indicates third transaction information and the digital currency, and the third transaction information includes a third transaction amount;

[0043] The second transaction module is further configured to use the private key of the second terminal to sign the third transaction information and the public key of the fourth terminal to form a third transaction chain; write the third transaction chain into the first trust chain, and send the first trust chain with the third transaction chain written therein to the fourth terminal, so that the fourth terminal implements an offline transaction corresponding to the third transaction amount based on the first trust chain with the third transaction chain written therein.

[0044] Optionally, the second transaction module is further used to derive the digital currency based on the transaction amount included in the last transaction information among the multiple transaction information when the first transaction information is verified and the first trust chain includes multiple transaction information.

[0045] To achieve the above objectives, according to another aspect of an embodiment of the present invention, a system for splitting digital currency during a transaction is provided.

[0046] A system for splitting digital currency during a transaction according to an embodiment of the present invention includes: at least two terminals; wherein:

[0047] Each of the at least two terminals stores a trust chain, wherein the trust chain includes: digital currency and one or more transaction information, wherein the transaction information includes a transaction amount; and the sum of the transaction amounts included in the last transaction information in each of the trust chains is equal to the face value of the digital currency.

[0048] To achieve the above-mentioned purpose, according to another aspect of an embodiment of the present invention, an electronic device for splitting digital currency during a transaction is provided.

[0049] An electronic device for splitting digital currency during a transaction process according to an embodiment of the present invention includes: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement a method for splitting digital currency during a transaction process according to an embodiment of the present invention.

[0050] To achieve the above objective, according to another aspect of an embodiment of the present invention, a computer-readable storage medium is provided.

[0051] A computer-readable storage medium according to an embodiment of the present invention stores a computer program, which, when executed by a processor, implements a method for splitting digital currency during a transaction according to an embodiment of the present invention.

[0052] One embodiment of the above invention has the following advantages or beneficial effects: when determining a first transaction request, the first terminal (payer) generates second transaction information including a second transaction amount based on the first transaction amount indicated by the first transaction request. The second transaction amount is the difference between the available balance of the digital currency indicated by the first transaction request and the first transaction amount. The first terminal can then use its own private key to sign the first transaction information and the second transaction information indicated by the first transaction request. Then, based on the signed first and second transaction information and the digital currency, a first trust chain and a second trust chain are generated, respectively. This achieves the splitting of the digital currency in the offline transaction, thereby facilitating the offline transaction. Furthermore, the first terminal sends the first trust chain to the second terminal (payee), so that the second terminal can use the first terminal's public key to verify the first transaction information in the first trust chain to verify whether the digital currency is credible. If the digital currency is credible, the second terminal can conduct an offline transaction with the first terminal corresponding to the first transaction amount. Thus, by securely and effectively verifying the digital currency during the transaction, the second terminal and the first terminal can conduct an offline transaction based on the first trust chain in an offline state, thereby ensuring the security of the offline transaction.

[0053] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with specific embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0054] The accompanying drawings are provided for a better understanding of the present invention and are not intended to limit the present invention.

[0055] Figure 1 is a schematic diagram of the main steps of a method for splitting digital currency during a transaction according to an embodiment of the present invention;

[0056] Figure 2 This is a schematic diagram of the structure of a first transaction chain according to an embodiment of the present invention;

[0057] Figure 3 is a schematic structural diagram of another first transaction chain according to an embodiment of the present invention;

[0058] Figure 4 This is a structural diagram of another first transaction chain according to an embodiment of the present invention;

[0059] Figure 5 This is a schematic diagram of the structure of a first trust chain according to an embodiment of the present invention;

[0060] Figure 6 is a schematic diagram of the main steps of applying another method for verifying digital currency in a transaction process to a first terminal according to an embodiment of the present invention;

[0061] Figure 7 is a schematic diagram of the main steps of a method for verifying digital currency during a transaction according to an embodiment of the present invention applied to a second terminal;

[0062] Figure 8 is a schematic diagram of the main steps of applying another method for verifying digital currency in a transaction process to a second terminal according to an embodiment of the present invention;

[0063] Figure 9 is a schematic structural diagram of another first trust chain according to an embodiment of the present invention;

[0064] Figure 10 is a schematic diagram of main modules of a first terminal for splitting digital currency during a transaction according to an embodiment of the present invention;

[0065] Figure 11 is a schematic diagram of main modules of a second terminal for splitting digital currency during a transaction according to an embodiment of the present invention;

[0066] Figure 12 is an exemplary system architecture diagram in which embodiments of the present invention may be applied;

[0067] Figure 13It is a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION

[0068] The following description of exemplary embodiments of the present invention is made in conjunction with the accompanying drawings, in which various details of the embodiments of the present invention are included to facilitate understanding. These details should be considered as merely exemplary. Therefore, it should be appreciated by those skilled in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for the sake of clarity and conciseness, descriptions of well-known functions and structures are omitted in the following description.

[0069] It should be pointed out that, in the absence of conflict, the embodiments of the present invention and the technical features therein may be combined with each other.

[0070] Figure 1 This is a schematic diagram of the main steps of applying a method for splitting digital currency during a transaction according to an embodiment of the present invention to a first terminal.

[0071] like Figure 1 As shown, a method for splitting digital currency during a transaction according to an embodiment of the present invention, when applied to a first terminal, mainly includes the following steps:

[0072] Step S101: Determine a first transaction request, where the first transaction request indicates a digital currency to be traded and first transaction information, where the first transaction information includes a first transaction amount.

[0073] Among them, the first transaction request can be automatically generated by the first user (payer) during the transaction. For example, when the first user wants to use digital currency to transfer money to the second user (payee), a first transaction request corresponding to the transfer transaction can be generated.

[0074] The first transaction request not only indicates the digital currency to be traded, but also indicates first transaction information. The first transaction information includes not only the first transaction amount, but also at least one of a transaction identifier, a transaction count, and a transaction time. For example, when the first transaction request corresponds to a transfer transaction, the first transaction amount is the amount to be transferred, the transaction identifier can be the order number of the transfer, the transaction time can be the time when the first transaction information is generated, that is, the time when the transfer request is submitted, and the transaction count can be the number of transactions that have occurred with the digital currency to be traded.

[0075] Step S102: Generate second transaction information including a second transaction amount based on the first transaction information; the second transaction amount is the difference between the available balance of the digital currency and the first transaction amount.

[0076] It is understood that the available balance of digital currency is the difference between the initial denomination of the digital currency and its transaction amount. For example, if the initial denomination of the digital currency exported by the first terminal from the currency management device is 100, and before this transaction, the digital currency has been traded twice, each time for a transaction amount of 10, then the available balance of the digital currency is 80. The second transaction amount is the difference between the available balance of the digital currency and the first transaction amount. If the first transaction amount is 20, the second transaction amount is 60. It is understood that the first transaction amount must not exceed the available balance of the digital currency. If the first terminal verifies that the first transaction amount is greater than the available balance of the digital currency, it can directly reject the transaction.

[0077] Step S103: using the private key of the first terminal to sign the first transaction information and the second transaction information respectively.

[0078] Step S104: Generate a first trust chain based on the signed first transaction information and the digital currency, and generate a second trust chain based on the signed second transaction information and the digital currency.

[0079] It can be understood that the generation operations of the first transaction chain and the second trust chain are the same, and the difference between the two is the components of the trust chain. That is, the first transaction chain is composed of the first transaction information and digital currency, and the second transaction chain is composed of the second transaction information and digital currency, but the composition actions of the two are consistent.

[0080] For ease of description, the following describes the trust chain generation process in detail, taking the generation process of the first trust chain as an example. When generating the first trust chain, the private key of the first terminal can be used to sign the first trust chain. Then, based on the signature of the first terminal and the first transaction information, a first transaction chain is generated. Finally, the first transaction chain and the digital currency are combined to generate the first trust chain.

[0081] Specifically, when generating the first transaction chain, the first transaction information and the public key of the second terminal can be signed using the private key of the first terminal to generate the first transaction chain, and then the first trust chain is generated based on the first transaction chain and the digital currency.

[0082] It is understandable that the user of the first terminal is the payee and the user of the second terminal is the payee. The public key of the second terminal can indicate the payee's information. The first transaction information and the public key of the second terminal are signed using the private key of the first terminal to generate a first transaction chain. The generated first transaction chain can be as follows: Figure 2 As shown, the first transaction chain can indicate not only the payer's information but also the payee's information. That is, the first transaction chain can represent the transaction corresponding to the first transaction request between the first terminal and the second terminal.

[0083] In addition, the public key of the second terminal (payee) can also be used to encrypt the first transaction information signed by the private key of the first terminal to generate a first transaction chain. The schematic diagram of the first transaction chain generated in this way can be shown as follows: Figure 3 As shown. This also allows the first transaction chain to indicate not only the payer's information but also the payee's information. In other words, the first transaction chain generated in this way can also represent the transaction corresponding to the first transaction request between the first terminal and the second terminal.

[0084] It is understandable that the difference between the above two methods of generating the first transaction chain is only the different signing methods. In other words, Figure 4 As shown, transaction chains generated using different signature methods all include the private key of the first terminal, the public key of the second terminal, and the first transaction information. Accordingly, the second terminal's verification methods for the first and second transaction chains will differ, but both can represent the transaction corresponding to the first transaction request between the first and second terminals. Furthermore, as described above, the generation process of the second transaction chain is identical to that of the first transaction chain, with only the first transaction information being replaced by the second transaction information. This generation process will not be further described here.

[0085] After the first transaction chain is generated, the first transaction chain can be combined with the digital currency to generate a first trust chain for offline transactions between the first terminal and the second terminal. The generated first trust chain can be as follows: Figure 5 In addition, the second transaction chain and the digital currency can be combined in the same manner to generate a second trust chain.

[0086] Step S105: sending the first trust chain to the second terminal, so that the second terminal and the first terminal implement an offline transaction corresponding to the first transaction amount according to the first trust chain.

[0087] After the first terminal sends the first trust chain to the second terminal, the second terminal can use the public key of the first terminal to verify the first transaction information. When the verification is successful, it means that the second terminal has successfully authenticated the signature of the first terminal, indicating that the first transaction chain in the first trust chain is credible. Therefore, it is verified that the digital currency in the first trust chain is credible, so that the offline transaction corresponding to the first transaction amount can be realized between the second terminal and the first terminal based on the first trust chain.

[0088] Depending on how the first transaction chain is generated, the second terminal's verification process for the first transaction information also varies. When the first transaction chain is generated by signing the first transaction information and the second terminal's public key using the first terminal's private key, the second terminal can first decrypt the first transaction chain using the first terminal's public key to obtain the first transaction information and the second terminal's public key. The second terminal can then use the second terminal's private key to verify the second terminal's public key. Successful verification of the second terminal's public key indicates that the first transaction information is authentic. This process demonstrates that to verify the authenticity of the first transaction information, the second terminal must use the first terminal's public key and the second terminal's private key to verify the first terminal's private key signature and the second terminal's public key, respectively. In other words, successful verification of the second terminal's public key and the first terminal's private key confirms that the first transaction information has been verified, thereby confirming the authenticity of the digital currency.

[0089] In addition, when the transaction chain in the first trust chain is the first transaction chain obtained by encrypting the first transaction information signed by the public key of the second terminal, the second terminal can first use the private key of the second terminal to decrypt the first transaction chain to obtain the first transaction information signed by the private key of the first terminal, and then further use the public key of the first terminal to decrypt the first transaction information to obtain the first transaction information. Through this process, it can be seen that to verify the credibility of the first transaction information, the second terminal needs to use the private key of the second terminal and the public key of the first terminal to verify the signature of the second terminal's public key and the private key of the first terminal in turn. In other words, when the public key of the second terminal and the private key of the first terminal are successfully verified, it can be determined that the first transaction information has been verified, and thus the digital currency can be determined to be credible.

[0090] In addition, the second terminal can further verify each signature in the digital currency. For example, when the digital currency records the signature of its issuing agency, the central management agency described by its issuing agency and / or the owner of the digital currency, the second terminal can verify the signature of the issuing agency, the signature of the central management agency described by its issuing agency and the signature of its owner respectively to further ensure the credibility of the digital currency, thereby further improving the security of offline transactions.

[0091] In addition, for the second trust chain, the first terminal can directly store the second trust chain, that is, the first terminal can keep the second trust chain for itself. At this time, the first terminal can use the private key of the first terminal to sign the second transaction and the public key of the first terminal to generate a second transaction chain, and then generate a second trust chain based on the second transaction chain and digital currency.

[0092] Of course, the first terminal can also conduct new transactions with other terminals (third terminals) based on the second trust chain. That is, the first terminal can send the second trust chain to the third terminal so that the third terminal and the first terminal can realize an offline transaction corresponding to the second transaction amount based on the second trust chain.

[0093] As described above, the process for generating the second trust chain is identical to that for the first trust chain. Simply by converting the first transaction information in the first trust chain into the second transaction information, the second trust chain can be generated using the same method as the first trust chain. Accordingly, the process for the third terminal to conduct a transaction with the first terminal based on the second trust chain is identical to the process for the second terminal to conduct a transaction with the first terminal based on the first trust chain.

[0094] According to the above embodiment, Figure 6 As shown, the method for splitting digital currency during a transaction provided by the present invention, when applied to a first terminal, may include the following steps:

[0095] Step S601: Determine a first transaction request, where the first transaction request indicates a digital currency to be traded and first transaction information, where the first transaction information includes a first transaction amount.

[0096] Step S602: Generate second transaction information including a second transaction amount based on the first transaction information; the second transaction amount is the difference between the available balance of the digital currency and the first transaction amount.

[0097] Step S603: Use the private key of the first terminal to sign the first transaction information and the second transaction information respectively.

[0098] Step S604: Generate a first trust chain based on the signed first transaction information and the digital currency, and generate a second trust chain based on the signed second transaction information and the digital currency.

[0099] Step S605: Send the first trust chain to the second terminal.

[0100] Step S606: the second terminal verifies the first trust chain, and when the verification passes, implements an offline transaction corresponding to the first transaction amount according to the first trust chain.

[0101] It's worth noting that after the second terminal conducts a transaction with the first terminal based on the first trust chain, it can also continue to conduct transactions with the fourth terminal based on the first trust chain. Specifically, the second terminal can generate a third transaction chain based on the transaction information between it and the fourth terminal, then write the third transaction chain into the first trust chain. The first trust chain with the third transaction chain written into it is then sent to the fourth terminal. After the fourth terminal verifies the first trust chain, it can then conduct transactions with the second terminal based on the first trust chain.

[0102] Step S607: Send the second trust chain to the third terminal.

[0103] Step S608: the third terminal verifies the second trust chain, and when the verification passes, implements an offline transaction corresponding to the second transaction amount according to the second trust chain.

[0104] According to a method for splitting digital currency during a transaction according to an embodiment of the present invention, it can be seen that when the first terminal (payer) determines the first transaction request, it generates second transaction information including a second transaction amount based on the first transaction amount indicated by the first transaction request. The second transaction amount is the difference between the available balance of the digital currency indicated by the first transaction request and the first transaction amount. Then, the first terminal can use its own private key to sign the first transaction information and the second transaction information indicated by the first transaction request respectively. Then, based on the signed first and second transaction information and the digital currency, a first trust chain and a second trust chain are generated respectively. This realizes the splitting of digital currency in offline transactions, thereby facilitating the offline transaction. Further, the first terminal sends the first trust chain to the second terminal (payee), so that the second terminal can use the public key of the first terminal to verify the first transaction information in the first trust chain to verify whether the digital currency is credible. If the digital currency is credible, the second terminal can conduct an offline transaction corresponding to the first transaction amount with the first terminal. Thus, by securely and effectively verifying the digital currency during the transaction, the second terminal and the first terminal can conduct offline transactions based on the first trust chain in an offline state, thereby ensuring the security of offline transactions.

[0105] Figure 7 2 is a schematic diagram of the main steps of a method for splitting digital currency during a transaction according to an embodiment of the present invention.

[0106] like Figure 7 As shown, a method for splitting digital currency during a transaction according to an embodiment of the present invention, when applied to a second terminal, mainly includes the following steps:

[0107] Step S701: Receive a first trust chain sent by a first terminal, where the first trust chain includes: digital currency to be traded and first transaction information signed using a private key of the first terminal, where the first transaction information includes a first transaction amount.

[0108] Step S702: Use the public key of the first terminal to verify the first transaction information.

[0109] Step S703: When the first transaction information is verified, an offline transaction is performed with the first terminal based on the digital currency and the first transaction amount.

[0110] After the first terminal sends the first trust chain to the second terminal, the second terminal can use the public key of the first terminal to verify the first transaction information. When the verification is successful, it means that the second terminal has successfully authenticated the signature of the first terminal, indicating that the transaction chain in the first trust chain is credible. Therefore, the digital currency in the first trust chain is verified to be credible, so that the second terminal and the first terminal can realize offline transactions based on the first trust chain.

[0111] The second terminal's verification process for the first transaction information varies depending on how the first transaction chain is generated. If the first transaction chain is generated by signing the first transaction information and the second terminal's public key using the first terminal's private key, the second terminal can first decrypt the first transaction chain using the first terminal's public key to obtain the first transaction information and the second terminal's public key. The second terminal can then verify the second terminal's public key using its private key. Successful verification of the second terminal's public key indicates that the first transaction information is authentic.

[0112] In addition, when the transaction chain in the first trust chain is the first transaction chain obtained by encrypting the first transaction information signed by the public key of the second terminal, the second terminal can first use the private key of the second terminal to decrypt the first transaction chain to obtain the first transaction information signed by the private key of the first terminal, and then further use the public key of the first terminal to decrypt the first transaction information to obtain the first transaction information.

[0113] The same digital currency can be traded multiple times based on its denomination and the transaction amount indicated in each transaction. For example, if the denomination of a digital currency is greater than the transaction amount of a single transaction, and after completing a transaction, there is an available balance of the digital currency (the difference between the initial denomination of the digital currency and the transaction amount of the single transaction), the digital currency can be used for further transactions based on the available balance.

[0114] In an embodiment of the present invention, after the second terminal conducts an offline transaction with the first terminal based on the first trust chain sent by the first terminal, it can also continue to trade again with other terminals (such as the fourth terminal) based on the first trust chain, so that multiple terminals can conduct multiple transactions based on the first trust chain. For the sake of convenience of description, the offline transaction between the second terminal and the first terminal is referred to as a primary transaction, and the offline transaction between the second terminal and the fourth terminal is referred to as a secondary transaction. The fourth terminal may be the same as or different from the first terminal. When the fourth terminal is the same as the first terminal, it means that in the secondary transaction process, the positions of the payee and the payer are interchanged, that is, in the primary transaction process, the first terminal is the payer and the second terminal is the payee; in the secondary transaction process, the second terminal is the payer and the first terminal is the payee.

[0115] In one embodiment of the present invention, Figure 8 As shown, the process of the second terminal performing a secondary transaction according to the first trust chain may include the following steps:

[0116] Step S801: Determine a second transaction request, where the second transaction request indicates third transaction information and the digital currency, and the third transaction information includes a third transaction amount.

[0117] The second transaction request may be automatically generated by the user of the second terminal (the payer of the secondary transaction) during the transaction. If the digital currency indicated by the second transaction request is the digital currency in the first trust chain, it means that the first trust chain can be used for this transaction.

[0118] Step S802: Use the private key of the second terminal to sign the third transaction information and the public key of the fourth terminal to form a third transaction chain.

[0119] It will be appreciated that the process for generating the third transaction chain is the same as that for generating the first or second transaction chain. That is, the third transaction information and the third terminal's public key can be signed using the second terminal's private key to form the third transaction chain. Specifically, the third transaction information and the third terminal's public key can be signed using the second terminal's private key to generate the third transaction chain. Alternatively, the third transaction information can be first signed using the second terminal's private key, and then the third terminal's public key can be used to encrypt the third transaction information signed with the second terminal's private key to generate the third transaction chain.

[0120] Step S803: writing the third transaction chain into the first trust chain, and sending the first trust chain with the third transaction chain written therein to the fourth terminal, so that the fourth terminal implements an offline transaction corresponding to the third transaction amount according to the first trust chain with the third transaction chain written therein.

[0121] After the third transaction chain is generated, the third transaction chain is written into the first trust chain to form a new first trust chain. The new first trust chain structure can be as follows: Figure 9 As shown. Because the third transaction chain represents the transaction between the second terminal and the fourth terminal corresponding to the second transaction request, the fourth terminal can verify the third transaction information and digital currency based on the new first trust chain. When the digital currency verification passes, the offline transaction between the fourth terminal and the second terminal can be carried out based on the new first trust chain. The verification process of the new first trust chain is the same as the verification process of the second terminal for the first trust chain described above, and will not be repeated here.

[0122] When the receiving terminal (payee) of the trust chain receives the trust chain, it can further verify it based on the available balance of the digital currency and the transaction amount corresponding to the transaction information. Only when the available balance of the digital currency is not less than the transaction amount corresponding to the transaction information, will the offline transaction be carried out based on the digital currency and the sending terminal (payer) of the trust chain to further improve the security of offline transactions.

[0123] It can be seen from the above embodiments that Figure 9 As shown, a trust chain may include multiple transaction chains corresponding to multiple transaction information. The multiple transaction information may be the first transaction information and the third transaction information, and the corresponding transaction chains are the first transaction chain and the third transaction chain, respectively. Multiple transaction chains indicate that the digital currency in the trust chain has been traded multiple times, and the objects of each transaction are different.

[0124] Based on the above-mentioned trust chain generation process, it can be understood that only the transaction corresponding to the last transaction information in the trust chain is the transaction corresponding to the trust chain receiving terminal. For example, when the trust chain includes a first transaction chain and a third transaction chain, the transaction corresponding to the first transaction chain (primary transaction) is an offline transaction between the first terminal and the second terminal, and the transaction corresponding to the third transaction chain (secondary transaction) is an offline transaction between the second terminal and the fourth terminal. Only the transaction corresponding to the last generated third transaction chain is the transaction corresponding to the trust chain receiving terminal (the fourth terminal). Therefore, when the fourth terminal redeems digital currency, it can only export digital currency based on the transaction amount corresponding to the transaction (secondary transaction) to which it is related. For another example, when the first trust chain received by the second terminal includes multiple transaction information, and the first transaction information is the last transaction information among them, the digital currency in the first trust chain can be exported based on the first transaction amount included in the last transaction information in the first trust chain.

[0125] It is worth mentioning that each transaction chain in the trust chain can include a timestamp, and the last transaction information in the trust chain can be determined based on the timestamps of multiple transaction chains, that is, the transaction information corresponding to the transaction chain closest to the current moment is the last transaction information in the trust chain.

[0126] It is understandable that when the fourth transaction amount between the first terminal and the third terminal is less than the available balance of the digital currency in the second trust chain, after the third terminal conducts an offline transaction with the first terminal based on the second trust chain, the third terminal may also conduct offline transactions with other terminals again based on the second trust chain. This process is the same as the offline transaction process between the second terminal and the fourth terminal and will not be repeated here. At the same time, when the transaction amount between the first terminal and the third terminal is less than the available balance of the digital currency in the second trust chain, the first terminal may also generate a fourth trust chain. The available balance of the digital currency in the fourth trust chain is the difference between the available balance of the digital currency in the second trust chain and the fourth transaction amount. This enables secure and efficient offline transactions between multiple terminals based on the trust chain.

[0127] When multiple terminals conduct offline transactions based on a trust chain, each terminal will have a trust chain corresponding to its transaction. Each trust chain includes digital currency and one or more transaction information, and the transaction information includes a corresponding transaction amount. It is understood that the transaction amount included in each transaction information corresponds to the transaction to which it corresponds. During the transmission of the trust chain across multiple terminals, the transaction amount included in the transaction information in each trust chain is the difference between the available balance of the digital currency and the corresponding transaction amount, and each trust chain corresponds to the same digital currency. Furthermore, according to the trust chain generation process described above, it can be seen that only the transaction corresponding to the last transaction information in the trust chain corresponds to the transaction corresponding to the terminal receiving the trust chain. In other words, the transaction corresponding to the last transaction information in the trust chain corresponds to the transaction corresponding to the terminal in which the trust chain exists. Therefore, the sum of the transaction amounts included in the last transaction information in each trust chain stored in each terminal is equal to the denomination of the digital currency corresponding to each trust chain. The denomination of the digital currency is the initial denomination of the digital currency when it is exported from the currency management device, i.e., the denomination of the digital currency before any transaction.

[0128] For example, a digital currency is exported from a currency management device by a first terminal. The denomination of the digital currency at the time of export is 100. After the first terminal and the second terminal conduct a transaction for 10 through a first trust chain, the second terminal continues to conduct a transaction for 5 with a fourth terminal through the first trust chain. Simultaneously, the first terminal and the third terminal conduct a second transaction for 20 through a second trust chain. The available balance of the digital currency indicated by the trust chains stored by the fourth terminal and the second terminal is both 5. The available balance of the digital currency indicated by the third trust chain remaining at the first terminal is 70, and the available balance of the digital currency indicated by the second trust chain stored at the third terminal is 20. Therefore, the sum of the transaction amounts included in the last transaction at each terminal is equal to the denomination of the digital currency. In this example, the sum of the transaction amounts included in the last transaction in the trust chains stored by the first, second, third, and fourth terminals is 100.

[0129] According to the above embodiment, the present invention also provides a system for splitting digital currency during a transaction, characterized in that it includes: at least two terminals; wherein each of the at least two terminals stores a trust chain, and the trust chain includes: digital currency and one or more transaction information, and the transaction information includes a transaction amount; the sum of the transaction amounts included in the last transaction information in each of the trust chains is equal to the face value of the digital currency.

[0130] Figure 10 2 is a schematic diagram of main modules of a first terminal for splitting digital currency during a transaction according to an embodiment of the present invention.

[0131] like Figure 10 As shown, a first terminal 1000 for splitting digital currency during a transaction according to an embodiment of the present invention includes: a first determination module 1001, a splitting module 1002 and a first transaction module 1003; wherein,

[0132] The first determining module 1001 is configured to determine a first transaction request, where the first transaction request indicates a digital currency to be traded and first transaction information, where the first transaction information includes a first transaction amount;

[0133] The splitting module 1002 is configured to generate, based on the first transaction information, second transaction information including a second transaction amount, where the second transaction amount is the difference between the available balance of the digital currency and the first transaction amount; sign the first transaction information and the second transaction information using the private key of the first terminal, generate a first trust chain based on the signed first transaction information and the digital currency, and generate a second trust chain based on the signed second transaction information and the digital currency;

[0134] The first transaction module 1003 is configured to send the first trust chain to the second terminal 1100 , so that the second terminal 1100 and the first terminal 1000 implement an offline transaction corresponding to the first transaction amount based on the first trust chain.

[0135] In one embodiment of the present invention, the first transaction module 1003 is further configured to send the second trust chain to a third terminal 1004, so that the third terminal and the first terminal implement an offline transaction corresponding to the second transaction amount based on the second trust chain.

[0136] In one embodiment of the present invention, the splitting module 1002 is used to use the private key of the first terminal to sign the first transaction information and the public key of the second terminal to generate a first transaction chain; and generate the first trust chain based on the first transaction chain and the digital currency.

[0137] In one embodiment of the present invention, the splitting module 1002 is used to use the private key of the first terminal to sign the second transaction information and the public key of the first terminal to form a second transaction chain; and generate the second trust chain based on the second transaction chain and the digital currency.

[0138] Figure 11 2 is a schematic diagram of main modules of a second terminal for splitting digital currency during a transaction according to an embodiment of the present invention.

[0139] like Figure 11 As shown, the second terminal 1100 for splitting digital currency in a transaction process according to an embodiment of the present invention includes: a receiving module 1101, a verification module 1102 and a second transaction module 1103; wherein,

[0140] The receiving module 1101 is configured to receive a first trust chain sent by the first terminal 1000, wherein the first trust chain includes: digital currency to be traded and first transaction information signed using a private key of the first terminal, wherein the first transaction information includes a first transaction amount;

[0141] The verification module 1102 is configured to verify the first transaction information using the public key of the first terminal;

[0142] The second transaction module 1103 is configured to perform an offline transaction with the first terminal 1000 based on the digital currency and the first transaction amount when the first transaction information is verified.

[0143] In one embodiment of the present invention, the receiving module 1101 is further configured to receive a second transaction request, where the second transaction request indicates third transaction information and the digital currency, and the third transaction information includes a third transaction amount;

[0144] The second transaction module 1103 is further configured to use the private key of the second terminal to sign the third transaction information and the public key of the fourth terminal to form a third transaction chain; write the third transaction chain into the first trust chain, and send the first trust chain with the third transaction chain written therein to the fourth terminal 1104, so that the fourth terminal 1104 implements an offline transaction corresponding to the third transaction amount based on the first trust chain with the third transaction chain written therein.

[0145] In one embodiment of the present invention, the second transaction module 1103 is further configured to derive the digital currency based on the transaction amount included in the last transaction information among the multiple transaction information when the first transaction information is verified and the first trust chain includes multiple transaction information.

[0146] According to an embodiment of the present invention, a first terminal and a second terminal for splitting digital currency during a transaction process can be seen. When the first terminal (payer) determines the first transaction request, it generates second transaction information including a second transaction amount based on the first transaction amount indicated by the first transaction request. The second transaction amount is the difference between the available balance of the digital currency indicated by the first transaction request and the first transaction amount. Then, the first terminal can use its own private key to sign the first transaction information and the second transaction information indicated by the first transaction request respectively. Then, based on the signed first and second transaction information and the digital currency, a first trust chain and a second trust chain are generated respectively. This realizes the splitting of digital currency in offline transactions, thereby facilitating the offline transaction. Further, the first terminal sends the first trust chain to the second terminal (payee), so that the second terminal can use the public key of the first terminal to verify the first transaction information in the first trust chain to verify whether the digital currency is credible. If the digital currency is credible, the second terminal can conduct an offline transaction corresponding to the first transaction amount with the first terminal. Thus, by securely and effectively verifying the digital currency during the transaction process, the second terminal and the first terminal can conduct offline transactions based on the first trust chain in an offline state, thereby ensuring the security of offline transactions.

[0147] Figure 12 An exemplary system architecture 1200 is shown in which a method for splitting digital currency during a transaction or an apparatus for splitting digital currency during a transaction according to an embodiment of the present invention can be applied.

[0148] like Figure 12As shown, system architecture 1200 may include terminal devices 1201, 1202, and 1203, a network 1204, and a server 1205. Network 1204 is used to provide a medium for communication links between terminal devices 1201, 1202, and 1203 and server 1205. Network 1204 may include various connection types, such as wired or wireless communication links or fiber optic cables.

[0149] Users can use terminal devices 1201, 1202, and 1203 to interact with server 1205 via network 1204 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 1201, 1202, and 1203, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc.

[0150] The terminal devices 1201 , 1202 , and 1203 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers.

[0151] Server 1205 may be a server that provides various services, such as a backend management server that supports shopping websites browsed by users using terminal devices 1201, 1202, and 1203. The backend management server may analyze and process received data such as product information query requests, and feed back the processing results (e.g., target push information, product information) to the terminal device.

[0152] It should be noted that the method for splitting digital currency during a transaction provided by the embodiment of the present invention is generally executed by terminal devices 1201, 1202, and 1203.

[0153] It should be understood that Figure 12 The number of terminal devices, networks and servers in the embodiment is merely illustrative. Any number of terminal devices, networks and servers may be provided as required.

[0154] Reference below Figure 13 , which shows a schematic structural diagram of a computer system 1300 of a terminal device suitable for implementing an embodiment of the present invention. Figure 13 The terminal device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.

[0155] like Figure 13As shown, the computer system 1300 includes a central processing unit (CPU) 1301, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 1302 or a program loaded from a storage unit 1308 into a random access memory (RAM) 1303. Various programs and data required for the operation of the system 1300 are also stored in the RAM 1303. The CPU 1301, the ROM 1302, and the RAM 1303 are connected to each other via a bus 1304. An input / output (I / O) interface 1305 is also connected to the bus 1304.

[0156] The following components are connected to the I / O interface 1305: an input section 1306 including a keyboard, a mouse, and the like; an output section 1307 including devices such as a cathode ray tube (CRT), a liquid crystal display (LCD), and speakers; a storage section 1308 including a hard disk; and a communication section 1309 including a network interface card such as a LAN card or a modem. The communication section 1309 performs communication processing via a network such as the Internet. A drive 1310 is also connected to the I / O interface 1305 as needed. Removable media 1311, such as a magnetic disk, an optical disk, a magneto-optical disk, or a semiconductor memory, is installed in the drive 1310 as needed, so that computer programs read therefrom can be installed into the storage section 1308 as needed.

[0157] In particular, according to the embodiments disclosed in the present invention, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, the embodiments disclosed in the present invention include a computer program product comprising a computer program carried on a computer-readable medium, the computer program comprising program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network via the communication section 1309, and / or installed from a removable medium 1311. When the computer program is executed by the central processing unit (CPU) 1301, the above-mentioned functions defined in the system of the present invention are performed.

[0158] It should be noted that the computer-readable medium described in the present invention can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media can include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present invention, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In the present invention, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. This propagated data signal can take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device. Program code embodied on a computer-readable medium may be transmitted using any suitable medium, including but not limited to wireless, wireline, optical fiber cable, RF, or any suitable combination thereof.

[0159] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present invention. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the above-mentioned module, program segment, or a part of code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flowchart, and the combination of boxes in the block diagram or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

[0160] The modules described in the embodiments of the present invention may be implemented in software or hardware. The modules described may also be located within a processor. For example, a processor may be described as comprising a first determination module, a splitting module, and a first transaction module. The names of these modules do not, in some cases, limit the modules themselves. For example, the first determination module may also be described as a "module for determining a first transaction request."

[0161] As another aspect, the present invention further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently and not be incorporated into the device. The computer-readable medium carries one or more programs, and when the one or more programs are executed by a device, the device is caused to: determine a first transaction request, the first transaction request indicating a digital currency to be traded and first transaction information, the first transaction information including a first transaction amount; generate second transaction information including a second transaction amount based on the first transaction information; the second transaction amount is the difference between the available balance of the digital currency and the first transaction amount; use the private key of the first terminal to sign the first transaction information and the second transaction information, respectively; generate a first trust chain based on the signed first transaction information and the digital currency, and generate a second trust chain based on the signed second transaction information and the digital currency; and send the first trust chain to a second terminal, so that the second terminal and the first terminal implement an offline transaction corresponding to the first transaction amount based on the first trust chain.

[0162] According to the technical solution of an embodiment of the present invention, when determining a first transaction request, the first terminal (payer) generates second transaction information including a second transaction amount based on the first transaction amount indicated in the first transaction request. The second transaction amount is the difference between the available balance of the digital currency indicated in the first transaction request and the first transaction amount. The first terminal can then use its own private key to sign the first transaction information and the second transaction information indicated in the first transaction request. Then, based on the signed first and second transaction information and the digital currency, a first trust chain and a second trust chain are generated, respectively. This achieves the splitting of digital currency in offline transactions, thereby facilitating offline transactions. Furthermore, the first terminal sends the first trust chain to the second terminal (payee), allowing the second terminal to verify the first transaction information in the first trust chain using the first terminal's public key to verify whether the digital currency is credible. If the digital currency is credible, the second terminal can conduct an offline transaction with the first terminal corresponding to the first transaction amount. Thus, by securely and effectively verifying the digital currency during the transaction, the second terminal and the first terminal can conduct offline transactions based on the first trust chain, thereby ensuring the security of offline transactions.

[0163] The above specific embodiments do not limit the scope of protection of the present invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions may occur depending on design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention are intended to be included within the scope of protection of the present invention.

Claims

1. A method for splitting digital currency during a transaction, characterized in that: Applied to the first terminal, including: Determining a first transaction request, where the first transaction request indicates a digital currency to be traded and first transaction information, where the first transaction information includes a first transaction amount; Generating second transaction information including a second transaction amount based on the first transaction information; the second transaction amount being the difference between the available balance of the digital currency and the first transaction amount; Signing the first transaction information and the second transaction information respectively using the private key of the first terminal; Using the private key of the first terminal, the first transaction information and the public key of the second terminal are signed to generate a first transaction chain, generating a first trust chain based on the first transaction chain and the digital currency, and generating a second trust chain based on the signed second transaction information and the digital currency; The first trust chain is sent to a second terminal, so that the second terminal and the first terminal implement an offline transaction corresponding to the first transaction amount according to the first trust chain.

2. The method according to claim 1, characterized in that Also includes: The second trust chain is sent to a third terminal, so that the third terminal and the first terminal implement an offline transaction corresponding to the second transaction amount according to the second trust chain.

3. The method according to claim 1, characterized in that Generating a second trust chain based on the signed second transaction information and the digital currency includes: Using the private key of the first terminal, signing the second transaction information and the public key of the first terminal to generate a second transaction chain; The second trust chain is generated according to the second transaction chain and the digital currency.

4. A method for splitting digital currency during a transaction, characterized in that: Applied to the second terminal, including: Receiving a first trust chain sent by a first terminal, the first trust chain comprising: digital currency to be traded and first transaction information signed using a private key of the first terminal; the first transaction information comprising a first transaction amount; the first trust chain being generated by signing the first transaction information and a public key of a second terminal using the private key of the first terminal to generate a first transaction chain; and generating the first trust chain based on the first transaction chain and the digital currency; Verifying the first transaction information using the public key of the first terminal; When the first transaction information is verified, an offline transaction is performed with the first terminal based on the digital currency and the first transaction amount.

5. The method according to claim 4, characterized in that Also includes: Determining a second transaction request, where the second transaction request indicates third transaction information and the digital currency, and the third transaction information includes a third transaction amount; Using the private key of the second terminal, signing the third transaction information and the public key of the fourth terminal to form a third transaction chain; The third transaction chain is written into the first trust chain, and the first trust chain with the third transaction chain written into it is sent to the fourth terminal, so that the fourth terminal implements an offline transaction corresponding to the third transaction amount according to the first trust chain with the third transaction chain written into it.

6. The method according to claim 4, characterized in that When the first transaction information is verified and the first trust chain includes multiple transaction information, the method further includes: The digital currency is derived according to the transaction amount included in the last transaction information among the multiple transaction information.

7. A first terminal for splitting digital currency during a transaction, characterized in that: include: A first determination module, a splitting module and a first transaction module; wherein, The first determining module is configured to determine a first transaction request, wherein the first transaction request indicates a digital currency to be traded and first transaction information, wherein the first transaction information includes a first transaction amount; The splitting module is configured to generate, based on the first transaction information, second transaction information including a second transaction amount, where the second transaction amount is the difference between the available balance of the digital currency and the first transaction amount; sign the first transaction information and the second transaction information using the private key of the first terminal, respectively; sign the first transaction information and the public key of the second terminal using the private key of the first terminal to generate a first transaction chain; generate a first trust chain based on the first transaction chain and the digital currency; and generate a second trust chain based on the signed second transaction information and the digital currency; The first transaction module is configured to send the first trust chain to a second terminal, so that the second terminal and the first terminal implement an offline transaction corresponding to the first transaction amount based on the first trust chain.

8. The first terminal according to claim 7, characterized in that The first transaction module is further configured to send the second trust chain to a third terminal, so that the third terminal and the first terminal implement an offline transaction corresponding to the second transaction amount based on the second trust chain.

9. The first terminal according to claim 7, characterized in that The splitting module is configured to use the private key of the first terminal to sign the first transaction information and the public key of the second terminal to generate a first transaction chain; and generate the first trust chain based on the first transaction chain and the digital currency.

10. The first terminal according to claim 7, characterized in that The splitting module is configured to use the private key of the first terminal to sign the second transaction information and the public key of the first terminal to form a second transaction chain; and generate the second trust chain based on the second transaction chain and the digital currency.

11. A second terminal for splitting digital currency during a transaction, characterized in that: include: Receiving module, verification module and second transaction module; wherein, The receiving module is configured to receive a first trust chain sent by a first terminal, the first trust chain comprising: digital currency to be traded and first transaction information signed using a private key of the first terminal, the first transaction information comprising a first transaction amount; the first trust chain is generated by signing the first transaction information and a public key of a second terminal using the private key of the first terminal to generate a first transaction chain, and the first trust chain is generated based on the first transaction chain and the digital currency; The verification module is configured to verify the first transaction information using the public key of the first terminal; The second transaction module is configured to perform an offline transaction with the first terminal based on the digital currency and the first transaction amount when the first transaction information is verified.

12. The second terminal according to claim 11, characterized in that The receiving module is further configured to receive a second transaction request, wherein the second transaction request indicates third transaction information and the digital currency, and the third transaction information includes a third transaction amount; The second transaction module is further configured to use the private key of the second terminal to sign the third transaction information and the public key of the fourth terminal to form a third transaction chain; write the third transaction chain into the first trust chain, and send the first trust chain with the third transaction chain written therein to the fourth terminal, so that the fourth terminal implements an offline transaction corresponding to the third transaction amount based on the first trust chain with the third transaction chain written therein.

13. The second terminal according to claim 11, characterized in that The second transaction module is further configured to derive the digital currency based on the transaction amount included in the last transaction information among the multiple transaction information when the first transaction information is verified and the first trust chain includes multiple transaction information.

14. A system for splitting digital currency during a transaction, characterized in that: include: The first terminal according to any one of claims 7 to 10 and the second terminal according to any one of claims 11 to 13.

15. An electronic device for splitting digital currency during a transaction, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 3 or 4 to 6.

16. A computer-readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 3 or 4 to 6 is implemented.

Citation Information

Patent Citations

  • Transaction data processing method and device, equipment and computer readable storage medium

    CN110175919A

  • Digital currency transaction method, device and system

    CN112150281A