Methods and devices for risk control in offline digital currency transactions
By generating and matching the payer's account balance and device fingerprint information verification code, the security of offline transactions of digital currency is ensured, and the risk of transaction information being tampered with in the existing technology is solved, and the economic losses of users are reduced.
Patent Information
- Application Number
- CN201911164579.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2019-11-25
- Publication Date
- 2024-12-17
- Estimated Expiration
- 2039-11-25
AI Technical Summary
Offline payment of digital currency has the risk of intercepting and tampering in the middle of the transaction information, resulting in economic losses for users. The existing methods are prone to the risk of balance being tampered with or account being copied.
By obtaining the account balance data and device fingerprint information after the payer completes the transaction, the first verification code and the second verification code are generated. If it matches, offline transactions are allowed. If it doesn’t match, the account will be locked to ensure the security of the transaction process.
Effectively prevent balances from being tampered with or device fingerprints tampered with, improve the security of offline transactions of digital currency and reduce the risk of economic losses for users.
Smart Images

Figure CN112837065B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of network and information security, and in particular to a method and device for controlling risks in offline digital currency transactions. Background Art
[0002] As a new force in future payment methods, digital currency needs to support both online payments based on the Internet and offline payments when both the payer and the payee are offline and not connected to the Internet.
[0003] Digital currency offline payment mainly exchanges transaction information through Near Field Communication (NFC) and other methods. The information is verified and reported when the payee and payee are online. It is impossible to verify the identity of the other party in real time like online transactions, which makes the transaction process more risky. If the transaction information is intercepted and tampered with in the middle, the two parties may use the wrong transaction information to trade, which will cause greater economic losses to users.
[0004] An existing offline payment method based on digital currency, when the transaction is in progress, the digital currency delivery device sends the payee user identification, the payee user public key and the payee user's digital certificate to the payment terminal; if the digital certificate is within the validity period, the payment terminal receives the transaction information signed by the payee user's private key, including the offline digital currency paid by the payee, and the offline digital currency is encrypted by the payee user's public key; the payee user's public key is used to verify the legitimacy of the transaction information, and the payee user's private key is used to verify the validity of the offline digital currency; the payment terminal is notified to deduct the money; when the payment terminal receives the successful deduction notification, the offline transaction record is registered and the offline digital currency count in the account is increased. However, this solution is prone to the risk of balance tampering or account number duplication. Summary of the invention
[0005] A technical problem to be solved by the present disclosure is to provide a method and device for risk control of offline digital currency transactions, which can improve the security of offline digital currency transactions.
[0006] According to one aspect of the present disclosure, a digital currency offline transaction risk control method is proposed, including: obtaining the balance data of the payer's account after the transaction is completed; generating a first verification code based on the balance data after the transaction and the device fingerprint information; before conducting an offline transaction, generating a second verification code based on the current balance data of the account and the device fingerprint information; if the first verification code and the second verification code match, allowing the digital currency offline transaction.
[0007] In some embodiments, if the first verification code and the second verification code match, the first verification code or the second verification code, as well as the current balance data and the device fingerprint information are sent to the payee terminal; wherein the payee terminal generates a third verification code based on the current balance data and the device fingerprint information; if the first verification code or the second verification code matches the third verification code, digital currency offline transactions are allowed.
[0008] In some embodiments, if the first verification code and the second verification code do not match, the payer's account is locked.
[0009] In some embodiments, the balance data of the payer's account after completing the transaction and the first verification code are stored in the security chip of the payer's terminal.
[0010] In some embodiments, the balance data of the account is the balance data after hash calculation.
[0011] According to another aspect of the present disclosure, a digital currency offline transaction risk control device is also proposed, including: a data acquisition unit, configured to obtain the balance data of the payer's account after the transaction is completed; a first verification code generation unit, configured to generate a first verification code based on the balance data after the transaction and the device fingerprint information; a second verification code generation unit, configured to generate a second verification code according to the current balance data of the account and the device fingerprint information before conducting an offline transaction; a first matching unit, configured to determine whether the first verification code and the second verification code match; an offline transaction execution unit, configured to allow digital currency offline transactions if the first verification code and the second verification code match.
[0012] In some embodiments, the data sending unit is configured to send the first verification code or the second verification code, as well as the current balance data and the device fingerprint information to the payee terminal if the first verification code and the second verification code match; the third verification code generation unit is configured to generate a third verification code based on the current balance data and the device fingerprint information; the second matching unit is configured to determine whether the first verification code or the second verification code matches the third verification code; the offline transaction execution unit is also configured to allow digital currency offline transactions if the first verification code or the second verification code matches the third verification code.
[0013] In some embodiments, the self-locking unit is configured to lock the payer's account if the first verification code and the second verification code do not match.
[0014] In some embodiments, the data acquisition unit, the first verification code generation unit, the second verification code generation unit, the first matching unit, the offline transaction execution unit and the data sending unit are located at the payee terminal; the third verification code generation unit and the second matching unit are located at the payee terminal.
[0015] According to another aspect of the present disclosure, a digital currency offline transaction risk control device is also proposed, including: a memory; and a processor coupled to the memory, the processor being configured to execute the digital currency offline transaction risk control method as described above based on instructions stored in the memory.
[0016] According to another aspect of the present disclosure, a computer-readable storage medium is also proposed, on which computer program instructions are stored, and when the instructions are executed by a processor, the above-mentioned digital currency offline transaction risk control method is implemented.
[0017] Compared with the related art, the embodiment of the present disclosure determines whether the first verification code generated by the balance data of the account and the device fingerprint information after the payer completes the transaction is consistent with the second verification code generated by the balance data of the account and the device fingerprint information before the offline transaction. Only when they are consistent, digital currency offline transactions are allowed. This can prevent transaction risks caused by tampering with the balance or device fingerprint, improve the security of the digital currency offline transaction process, and reduce users' economic losses.
[0018] Other features and advantages of the present disclosure will become apparent from the following detailed description of exemplary embodiments of the present disclosure with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] The accompanying drawings, which constitute a part of the specification, illustrate embodiments of the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0020] The present disclosure may be more clearly understood from the following detailed description with reference to the accompanying drawings, in which:
[0021] Figure 1 The present invention is a flowchart of some embodiments of the digital currency offline transaction risk control method disclosed in the present invention.
[0022] Figure 2 Schematic diagram of the flow chart of other embodiments of the digital currency offline transaction risk control method disclosed in the present invention.
[0023] Figure 3 This is a schematic diagram of the structure of some embodiments of the digital currency offline transaction risk control device disclosed in the present invention.
[0024] Figure 4 Schematic diagram of the structure of other embodiments of the digital currency offline transaction risk control device disclosed in the present invention.
[0025] Figure 5 Schematic diagram of the structure of other embodiments of the digital currency offline transaction risk control device disclosed in the present invention.
[0026] Figure 6Schematic diagram of the structure of other embodiments of the digital currency offline transaction risk control device disclosed in the present invention.
[0027] Figure 7 This is a schematic diagram of the structure of some embodiments of the digital currency offline transaction risk control system disclosed in the present invention. DETAILED DESCRIPTION
[0028] Various exemplary embodiments of the present disclosure will now be described in detail with reference to the accompanying drawings. It should be noted that the relative arrangement of components and steps, numerical expressions and numerical values set forth in these embodiments do not limit the scope of the present disclosure unless otherwise specifically stated.
[0029] At the same time, it should be understood that for the convenience of description, the sizes of the various parts shown in the drawings are not drawn according to the actual proportional relationship.
[0030] The following description of at least one exemplary embodiment is merely illustrative in nature and is in no way intended to limit the present disclosure, its application, or uses.
[0031] Technologies, methods, and apparatus known to ordinary technicians in the relevant field may not be discussed in detail, but where appropriate, such technologies, methods, and apparatus should be considered part of the authorization specification.
[0032] In all examples shown and discussed herein, any specific values should be interpreted as merely exemplary and not as limiting. Therefore, other examples of the exemplary embodiments may have different values.
[0033] It should be noted that like reference numerals and letters refer to similar items in the following figures, and therefore, once an item is defined in one figure, it need not be further discussed in subsequent figures.
[0034] In order to make the objectives, technical solutions and advantages of the present disclosure more clearly understood, the present disclosure is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.
[0035] Figure 1 The present invention is a flowchart of some embodiments of the digital currency offline transaction risk control method disclosed in the present invention.
[0036] In step 110, the balance data of the account of the payer after the transaction is completed is obtained. For example, after each transaction occurs, it is necessary to record the account balance information, transaction serial number, offline transaction times, timestamp, identification numbers of both parties to the transaction, and signatures, among which the transaction information can be stored in the exclusive area of the SE (Secure Element, security chip) of the SIM card to ensure that the account balance data cannot be changed.
[0037] In step 120, a first verification code is generated based on the balance data after the transaction and the device fingerprint information. The device fingerprint is, for example, the IMSI (International Mobile Subscriber Identity) number of the SIM card.
[0038] In some embodiments, the IMSI number of the SIM card is combined with the balance data, and the first verification code is calculated using the SM4 encryption MAC algorithm, and the first verification code is also stored in the exclusive area of the SE of the SIM card.
[0039] In step 130, before the offline transaction is performed, a second verification code is generated based on the current balance data of the account and the device fingerprint information. That is, a new SM4 encryption MAC operation is performed on the balance and device fingerprint information in the existing account to generate the second verification code.
[0040] In step 140, if the first verification code and the second verification code match, the digital currency offline transaction is allowed. That is, before the transaction, the account balance and the mobile phone card number are verified to see if they have changed. If any one of them has changed, the verification code will not match. If neither of them has changed, the verification code matches. Only when the verification code matches can the digital currency offline transaction be allowed.
[0041] In the above embodiment, by judging whether the first verification code generated by the balance data of the account and the device fingerprint information after the payer completes the transaction is consistent with the second verification code generated by the balance data of the account and the device fingerprint information before the offline transaction, digital currency offline transactions are allowed only when they are consistent. This can prevent transaction risks caused by tampering with the balance or card number, improve the security of the digital currency offline transaction process, and reduce users' economic losses.
[0042] Figure 2 Schematic diagram of the flow chart of other embodiments of the digital currency offline transaction risk control method disclosed in the present invention.
[0043] In step 210, the payer terminal stores the balance data of the payer's account after the transaction is completed, the transaction serial number, the number of offline transactions, the timestamp, the identification numbers of both parties to the transaction, and the signature in the security chip. The timestamp information can be transmitted by the terminal to the IC card.
[0044] In some embodiments, the balance data, transaction serial number, offline transaction times, timestamp, identification numbers of both transaction parties and signature are data after HASH calculation to ensure data security.
[0045] In step 220, the payer terminal performs encryption operation on the balance data and device fingerprint information after the transaction to generate a first verification code.
[0046] In step 230, the first verification code is stored in the security chip.
[0047] In step 240, before the offline transaction, the payer terminal performs encryption operation on the current balance data of the account and the device fingerprint information to generate a second verification code. The encryption algorithm used in step 220 and step 240 is the same, for example, both use the SM4 encryption MAC algorithm.
[0048] In step 250 , it is determined whether the first verification code and the second verification code are consistent. If they are inconsistent, step 260 is executed. If they are consistent, step 270 is executed.
[0049] In step 260, the payer's account is locked. For example, if the balance data changes, or the mobile phone card number changes, the verification code will change. At this time, the account should be locked. Once the account is locked, it needs to be unlocked by connecting to the Internet. After connecting to the Internet, the operating institution platform can trace the source and find the point where the hacker tampered with the data, thereby achieving the purpose of tracing the source.
[0050] In step 270, the payer terminal sends the second verification code, current balance data and device fingerprint information to the payee terminal. Since the first verification code and the second verification code are the same, this step is to send the verification code generated by the payer to the payee terminal.
[0051] The balance data sent by the payer is the balance data after HASH calculation. Therefore, when it is sent to the payee terminal, the payee terminal cannot know the real balance of the specific payer's account. Therefore, it can prevent other users from snooping into the payer's personal privacy.
[0052] In step 280, the payee terminal generates a third verification code based on the current balance data and the device fingerprint information. The payer terminal uses the same encryption algorithm as step 220 or step 240 to encrypt and calculate the current balance data and the device fingerprint information to generate the third verification code.
[0053] In step 290, the payee terminal determines whether the third verification code is consistent with the second verification code, if consistent, execute step 2100, otherwise, execute step 2110. This step can avoid data tampering during the transmission process from the payer terminal to the payee terminal.
[0054] In step 2100, offline transactions of digital currency are allowed.
[0055] In step 2110, offline transactions of digital currency are not allowed.
[0056] In the above embodiment, the payer generates a trusted verification code and stores the balance data and the verification code in a security chip, which can ensure that the balance data and the verification code are not tampered with; before the offline transaction, the verification code is generated again. If any of the balance data or device fingerprint is sent and changed, the newly generated verification code will be inconsistent with the originally generated verification code, and the account will be automatically locked to ensure account security; if the verification codes generated by the payer are consistent twice, the payee will determine whether the generated verification code is consistent with the verification code generated by the payer. If they are consistent, offline transactions of digital currency are allowed, which improves the security of offline transactions.
[0057] Figure 3 The structure diagram of some embodiments of the digital currency offline transaction risk control device disclosed in the present invention includes a data acquisition unit 310 located at the payer terminal, a first verification code generation unit 320, a second verification code generation unit 330, a first matching unit 340 and an offline transaction execution unit 350.
[0058] The data acquisition unit 310 is configured to acquire the balance data of the account of the payer after the transaction is completed.
[0059] For example, after each transaction occurs, it is necessary to record information such as account balance, transaction serial number, number of offline transactions, timestamp, identification numbers of both parties to the transaction, and signatures. Among them, this transaction information can be stored in the exclusive area of the SE of the SIM card to ensure that the account balance data cannot be changed.
[0060] In some embodiments, the balance data, transaction serial number, offline transaction times, timestamp, identification numbers of both transaction parties and signature are data after HASH calculation to ensure data security.
[0061] The first verification code generating unit 320 is configured to generate a first verification code based on the balance data after the transaction and the device fingerprint information.
[0062] In some embodiments, the IMSI number of the SIM card is combined with the balance data, and the first verification code is calculated using the SM4 encryption MAC algorithm, and the first verification code is also stored in the exclusive area of the SE of the SIM card.
[0063] The second verification code generation unit 330 is configured to generate a second verification code according to the current balance data of the account and the device fingerprint information before performing an offline transaction, that is, to perform a new SM4 encryption MAC operation on the balance and the device fingerprint information in the existing account to generate the second verification code.
[0064] The first matching unit 340 is configured to determine whether the first verification code matches the second verification code.
[0065] The offline transaction execution unit 350 is configured to allow the digital currency offline transaction if the first verification code and the second verification code match. That is, before the transaction, the account balance and the mobile phone card number are verified to see if they have changed. If any one of them has changed, the verification code will not match. If neither of them has changed, the verification code will match. Only when the verification code matches can the digital currency offline transaction be allowed.
[0066] In the above embodiment, by judging whether the first verification code generated by the balance data of the account and the device fingerprint information after the payer completes the transaction is consistent with the second verification code generated by the balance data of the account and the device fingerprint information before the offline transaction, digital currency offline transactions are allowed only when they are consistent. This can prevent transaction risks caused by tampering with the balance or card number, improve the security of the digital currency offline transaction process, and reduce the risk of economic loss to users.
[0067] Figure 4 The structure diagram of some other embodiments of the digital currency offline transaction risk control device disclosed in the present invention further includes a data sending unit 410 located at the payee terminal, and a third verification code generating unit 420 and a second matching unit 430 at the payee terminal.
[0068] The data sending unit 410 is configured to send the first verification code or the second verification code, as well as the current balance data and the device fingerprint information to the payee terminal if the first verification code and the second verification code match.
[0069] The third verification code generating unit 420 is configured to generate a third verification code according to the current balance data and the device fingerprint information.
[0070] The second matching unit 430 is configured to determine whether the first verification code or the second verification code matches the third verification code.
[0071] The offline transaction execution unit 350 is further configured to allow the digital currency offline transaction if the first verification code or the second verification code matches the third verification code. For example, after the payer terminal receives the matching success message fed back by the payee terminal, the digital currency offline transaction is allowed.
[0072] In this embodiment, if the verification codes generated twice by the payee are consistent, the payee determines whether the generated verification code is consistent with the verification code generated by the payee. If they are consistent, offline transactions of digital currency are allowed, further improving the security of offline transactions.
[0073] In some other embodiments of the present disclosure, the digital currency offline transaction risk control device further includes a self-locking unit 440, which is configured to lock the payer's account if the first verification code and the second verification code do not match, thereby ensuring account security.
[0074] Figure 5 The schematic diagram of the structure of some other embodiments of the digital currency offline transaction risk control device disclosed in the present invention. The payer terminal includes a memory 510 and a processor 520, wherein the memory 510 can be a disk, a flash memory or any other non-volatile storage medium. The memory is used to store Figure 1-2 The processor 520 is coupled to the memory 510 and can be implemented as one or more integrated circuits, such as a microprocessor or a microcontroller. The processor 520 is used to execute the instructions stored in the memory.
[0075] In some embodiments, it is also possible to Figure 6 As shown, the digital currency offline transaction risk control device 600 includes a memory 610 and a processor 620. The processor 620 is coupled to the memory 610 via a BUS bus 630. The digital currency offline transaction risk control device 600 can also be connected to an external storage device 650 through a storage interface 640 to call external data, and can also be connected to a network or another computer system (not shown) through a network interface 660, which will not be described in detail here.
[0076] In this embodiment, the data instructions are stored in the memory and then processed by the processor, thereby improving the security of the digital currency offline transaction process.
[0077] like Figure 7 As shown, the payer terminal 710 and the payee terminal 720 constitute a digital currency offline transaction risk control system, which also includes a digital currency delivery management device 730 and an agent delivery device 740.
[0078] The digital currency delivery management device 730 is deployed in the People's Bank of China to manage the digital currency delivery quota of each agency delivery institution, wherein the digital currency delivery quota is set by the digital currency delivery management device according to the delivery demand of the agency delivery institution, and the deposit reserve of the corresponding amount of the agency delivery institution is frozen. The digital currency delivery management device generates delivery coins according to the digital currency delivery quota, and sends the delivery coin information in the form of a message or the like to the agency delivery device 740 deployed in each agency delivery institution.
[0079] The proxy delivery device 740 receives the delivery coin information sent by the digital currency delivery management device 730, and produces the corresponding amount of digital currency for the user according to the user's demand for exchanging digital currency, and manages the digital currency account book to provide the user with services such as relevant account balance inquiry, online transaction entry and offline amount deposit. The proxy delivery device includes: an information communication module, which is used to receive the user information, user public key and the amount of offline digital currency applied by the user sent by the terminal, and the user information includes the user identification, terminal identification and SIM card identification; a certificate generation module, which is used to generate a digital certificate according to the user information, user public key, the public key of the proxy delivery institution to which the proxy delivery device belongs and the certificate validity period received by the information communication module; a digital currency generation unit, which is used to generate offline digital currency corresponding to the amount of offline digital currency applied by the user when the amount of offline digital currency applied by the user does not exceed the amount of deposit of the user in the proxy delivery institution; the information communication module is also used to send offline digital currency and digital certificate to the terminal, so that the terminal can verify the identity of the other party through the digital certificate when making offline payment.
[0080] In some other embodiments, a computer readable storage medium stores computer program instructions, which when executed by a processor implement Figure 1-2 The steps of the method in the corresponding embodiment. Those skilled in the art will appreciate that the embodiments of the present disclosure may be provided as methods, devices, or computer program products. Therefore, the present disclosure may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present disclosure may take the form of a computer program product implemented on one or more computer-usable non-transient storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0081] The present disclosure is described with reference to flowcharts and / or block diagrams of methods, devices (systems) and computer program products according to embodiments of the present disclosure. It should be understood that each process and / or block in the flowchart and / or block diagram and the combination of processes and / or blocks 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 processes in the flowchart and / or block diagram. 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.
[0082] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate 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 A function specified in one or more boxes.
[0083] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0084] So far, the present disclosure has been described in detail. In order to avoid obscuring the concept of the present disclosure, some details known in the art are not described. Based on the above description, those skilled in the art can fully understand how to implement the technical solution disclosed here.
[0085] Although some specific embodiments of the present disclosure have been described in detail by way of example, it should be understood by those skilled in the art that the above examples are for illustration only and are not intended to limit the scope of the present disclosure. It should be understood by those skilled in the art that the above embodiments may be modified without departing from the scope and spirit of the present disclosure. The scope of the present disclosure is defined by the appended claims.
Claims
1. A digital currency offline transaction risk control method, comprising: Get the balance data of the payer's account after the transaction is completed; Generate a first verification code based on the balance data and device fingerprint information after the transaction; Before conducting an offline transaction, generating a second verification code based on the current balance data of the account and the device fingerprint information; If the first verification code matches the second verification code, the first verification code or the second verification code, as well as the current balance data and the device fingerprint information are sent to the payee terminal; Among them, the payee terminal generates a third verification code according to the current balance data and device fingerprint information; if the first verification code or the second verification code matches the third verification code, digital currency offline transaction is allowed.
2. The digital currency offline transaction risk control method according to claim 1, further comprising: If the first verification code and the second verification code do not match, the payer's account is locked.
3. The digital currency offline transaction risk control method according to claim 1 or 2, wherein: The balance data of the payer's account after completing the transaction and the first verification code are stored in the security chip of the payer's terminal.
4. The digital currency offline transaction risk control method according to claim 3, wherein: The balance data of the account is the balance data after hash calculation.
5. A digital currency offline transaction risk control device, comprising: A data acquisition unit, configured to acquire balance data of the account of the payer after the transaction is completed; A first verification code generating unit is configured to generate a first verification code based on the balance data and device fingerprint information after the transaction; A second verification code generating unit is configured to generate a second verification code according to the current balance data of the account and the device fingerprint information before performing an offline transaction; A first matching unit is configured to determine whether the first verification code matches the second verification code; a data sending unit, configured to send the first verification code or the second verification code, the current balance data and the device fingerprint information to a payee terminal if the first verification code matches the second verification code; A third verification code generating unit is configured to generate a third verification code according to the current balance data and the device fingerprint information; A second matching unit is configured to determine whether the first verification code or the second verification code matches the third verification code; The offline transaction execution unit is configured to allow offline digital currency transactions if the first verification code or the second verification code matches the third verification code.
6. The digital currency offline transaction risk control device according to claim 5, further comprising: The self-locking unit is configured to lock the payer's account if the first verification code and the second verification code do not match.
7. The digital currency offline transaction risk control device according to claim 5 or 6, wherein: The data acquisition unit, the first verification code generation unit, the second verification code generation unit, the first matching unit, the offline transaction execution unit and the data sending unit are located in the payer terminal; The third verification code generating unit and the second matching unit are located in the payee terminal.
8. A digital currency offline transaction risk control device, comprising: Memory; as well as A processor coupled to the memory, the processor being configured to execute the digital currency offline transaction risk control method as described in any one of claims 1 to 4 based on instructions stored in the memory.
9. A computer-readable storage medium having computer program instructions stored thereon, which, when executed by a processor, implement the digital currency offline transaction risk control method described in any one of claims 1 to 4.
