CN109255612B - Backup method and device for digital currency private key and terminal - Google Patents

Backup method and device for digital currency private key and terminal Download PDF

Info

Publication number
CN109255612B
CN109255612B CN201810919993.0A CN201810919993A CN109255612B CN 109255612 B CN109255612 B CN 109255612B CN 201810919993 A CN201810919993 A CN 201810919993A CN 109255612 B CN109255612 B CN 109255612B
Authority
CN
China
Prior art keywords
private key
random
confusion
original
character
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810919993.0A
Other languages
Chinese (zh)
Other versions
CN109255612A (en
Inventor
刘志
黄何
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chengdu Tongchuang Jialian Technology Co ltd
Original Assignee
Hainan Xinruan Software Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hainan Xinruan Software Co ltd filed Critical Hainan Xinruan Software Co ltd
Priority to CN201810919993.0A priority Critical patent/CN109255612B/en
Publication of CN109255612A publication Critical patent/CN109255612A/en
Application granted granted Critical
Publication of CN109255612B publication Critical patent/CN109255612B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q20/00Payment architectures, schemes or protocols
    • G06Q20/38Payment protocols; Details thereof
    • G06Q20/382Payment protocols; Details thereof insuring higher security of transaction
    • G06Q20/3829Payment protocols; Details thereof insuring higher security of transaction involving key management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1448Management of the data involved in backup or backup restore

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • Accounting & Taxation (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • General Engineering & Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Finance (AREA)
  • Strategic Management (AREA)
  • General Business, Economics & Management (AREA)
  • Storage Device Security (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The embodiment of the application discloses a backup method, a device and a terminal of a private key of digital currency, wherein the method comprises the steps of receiving a private key generation request, generating an original private key according to the private key generation request, conducting confusion processing on the original private key to obtain a confusion private key, displaying the confusion private key to a first display area of a display interface, displaying confusion prompt information in a second display area of the display interface, receiving a copying instruction of the confusion private key, copying the confusion private key to a shear plate, receiving a pasting instruction of data of the shear plate, and pasting the confusion private key to a backup area; the method and the device have the advantages that the contents of the private key are mixed when the private key is generated, the mixed contents are prompted at positions except for the private key, the user is informed of mixed information, the private key is convenient to backup for the user, the private key address is prevented from being revealed due to the fact that data of the shear plate are monitored by trojans or viruses, even if a monitor obtains the mixed private key in the shear plate, the original private key cannot be obtained, and the safety of user assets is remarkably improved.

Description

Backup method and device for digital currency private key and terminal
Technical Field
The present application relates to the field of information security technologies, and in particular, to a method, an apparatus, and a terminal for backing up a private key of digital currency.
Background
In the field of digital currency, the address of the digital currency corresponds to a bank account, and the private key of the digital currency corresponds to a password for opening the bank account, namely, one address of the digital currency corresponds to one private key. Taking bit coins as an example, the bit coin private key cannot be known only by obtaining the bit coin address, and the bit coins under the corresponding bit coin address cannot be used, but the bit coin address can be known through the bit coin private key, and the bit coins under the address can be transferred, that is, the obtained bit coin private key has the complete control right of the private key and the bit coins under the address, that is, the digital currency assets in the address can be controlled and transferred.
The private key is a string of numbers randomly chosen by an encryption algorithm. In the transaction of digital currency assets, the private key is used to generate the signature necessary to pay the bitcoin to prove ownership of the funds, and therefore the private key must remain confidential at all times. The private key is difficult to recover once it is lost, so it must also usually be backed up to prevent accidental loss. Some digital asset management software on the market today has the function of generating an account, i.e. a private key and its corresponding address. However, because the private key address is too long and complicated, current digital asset management software does not perform any processing on the generated private key for convenience, displays the generated private key in a clear text form, and can copy and paste the generated private key for storage in other secure places.
However, the existing backup method of the digital currency private key has a great safety hazard, when a user copies and backs up the private key generated in the digital currency asset management tool after the user's device is unknowingly installed with trojans or viruses, the data of the clipboard and the private key are easily monitored by the trojans or the viruses, so that the generated private key is leaked, and asset loss is caused.
Disclosure of Invention
The application provides a backup method, a device and a terminal of a digital currency private key, which aim to solve the problem that in the existing backup mode of the digital currency private key, when a user copies and backs up the private key generated in a digital currency asset management tool, the data of a shear plate and the private key are easily monitored by trojans or viruses, so that the generated private key is leaked, and thus the asset is lost.
In a first aspect, the present application provides a method for backing up a private key of digital currency, the method comprising:
receiving a private key generation request;
generating an original private key according to the private key generation request;
performing confusion processing on the original private key to obtain a confusion private key;
displaying the confusion private key to a first display area of a display interface, and simultaneously displaying confusion prompt information in a second display area of the display interface;
receiving a copying instruction of the obfuscated private key, and copying the obfuscated private key to a clipboard;
and receiving a pasting instruction of the data of the clipboard, and pasting the confusion private key to a backup area.
With reference to the first aspect, in a first implementable manner of the first aspect, obfuscating the original private key to obtain an obfuscated private key includes:
generating a random number and a random character, wherein the size of the random number is smaller than the length of a character string of the original private key;
and determining the position of the character to be replaced in the original private key according to the random number, and replacing the character at the position in the original private key with the random character to obtain the confusion private key.
With reference to the first aspect, in a second implementation manner of the first aspect, obfuscating the original private key to obtain an obfuscated private key includes:
generating a random number and a random character string, wherein the size of the random number and the length of the random character string are both smaller than the length of the character string of the original private key;
and determining the position of the character string to be replaced in the original private key according to the random number, and replacing the character string with the corresponding length at the position in the original private key with the random character string to obtain the confusion private key.
With reference to the first aspect, in a third implementation manner of the first aspect, obfuscating the original private key to obtain an obfuscated private key includes:
generating two or more random numbers and random characters, wherein the size of the random numbers is smaller than the length of a character string of an original private key, and the number of the random characters is the same as that of the random numbers;
and respectively determining the position of each character to be replaced in the original private key according to the random number, and respectively replacing the characters at the positions in the original private key with the random characters to obtain a confusion private key.
With reference to the first aspect, in a fourth implementable manner of the first aspect, the obfuscating the original private key to obtain an obfuscated private key includes:
generating two or more random numbers and random character strings, wherein the size of the random numbers and the length of the random character strings are both smaller than the length of the character strings of the original private key, and the number of the random character strings is the same as the number of the random numbers;
and respectively determining the position of each character string to be replaced in the original private key according to the random number, and respectively replacing the character strings with the same length at the positions in the original private key with the random character strings to obtain a mixed private key.
In a second aspect, the present application provides an apparatus for backing up private keys of digital currency, the apparatus comprising:
a receiving unit configured to receive a private key generation request;
the generating unit is used for generating an original private key according to the private key generating request;
the processing unit is used for performing confusion processing on the original private key to obtain a confusion private key;
the display unit is used for displaying the confusion private key to a first display area of a display interface and displaying confusion prompt information in a second display area of the display interface;
the copying unit is used for receiving a copying instruction of the obfuscated private key and copying the obfuscated private key to a clipboard;
and the pasting unit is used for receiving a pasting instruction of the data of the clipboard and pasting the confusion private key to the backup area.
With reference to the second aspect, in a first implementable manner of the second aspect, the processing unit includes:
the generating subunit is used for generating a random number and a random character, wherein the size of the random number is smaller than the length of a character string of the original private key;
and the replacing subunit is used for determining the position of the character to be replaced in the original private key according to the random number, and replacing the character at the position in the original private key with the random character to obtain the confusion private key.
With reference to the second aspect, in a second implementable manner of the second aspect, the processing unit includes:
the generation subunit is used for generating a random number and a random character string, and the size of the random number and the length of the random character string are both smaller than the character string length of the original private key;
and the replacing subunit is used for determining the position of the character string to be replaced in the original private key according to the random number, and replacing the character string with the corresponding length at the position in the original private key with the random character string to obtain the confusion private key.
With reference to the second aspect, in a third implementable manner of the second aspect, the processing unit includes:
the generation subunit is used for generating two or more random numbers and random characters, the size of the random numbers is smaller than the length of a character string of the original private key, and the number of the random characters is the same as that of the random numbers;
and the replacing subunit is used for respectively determining the position of each character to be replaced in the original private key according to the random number, and respectively replacing the characters at the positions in the original private key with the random characters to obtain the confusion private key.
With reference to the second aspect, in a fourth implementable manner of the second aspect, the processing unit includes:
the generation subunit is used for generating two or more random numbers and random character strings, wherein the size of the random numbers and the length of the random character strings are both smaller than the length of the character strings of the original private key, and the number of the random character strings is the same as the number of the random numbers;
and the replacing subunit is used for respectively determining the position of each character string to be replaced in the original private key according to the random number, and respectively replacing the character strings with the same length at the position in the original private key with the random character strings to obtain the confusion private key.
In a third aspect, the present application provides a backup terminal for a private key of digital currency, the terminal comprising: a processor, and a memory for storing processor-executable instructions;
wherein the processor is configured to:
receiving a private key generation request;
generating an original private key according to the private key generation request;
performing confusion processing on the original private key to obtain a confusion private key;
displaying the confusion private key to a first display area of a display interface, and simultaneously displaying confusion prompt information in a second display area of the display interface;
receiving a copying instruction of the obfuscated private key, and copying the obfuscated private key to a clipboard;
and receiving a pasting instruction of the data of the clipboard, and pasting the confusion private key to a backup area.
According to the technical scheme, the method, the device and the terminal for backing up the private key of the digital currency receive a private key generation request, generate an original private key according to the private key generation request, perform confusion processing on the original private key to obtain a confusion private key, display the confusion private key to a first display area of a display interface, display confusion prompt information in a second display area of the display interface, receive a copying instruction of the confusion private key, copy the confusion private key to a shear plate, receive a pasting instruction of data of the shear plate, and paste the confusion private key to a backup area; when the private key is generated, the content of the private key is confused, the confused content is prompted at other positions except for the private key, and the user is informed of the confused detailed information, so that the private key is convenient for the user to back up, the private key address is prevented from being revealed due to the fact that data of the shear plate is monitored by trojans or viruses, even if a monitor obtains the confused private key in the shear plate, the original private key cannot be obtained, and the safety of user assets is remarkably improved.
Drawings
In order to more clearly explain the technical solution of the present application, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious to those skilled in the art that other drawings can be obtained according to the drawings without any creative effort.
Fig. 1 is a flowchart of a backup method for a private key of digital currency according to the present application.
Fig. 2 is a flowchart of a first embodiment of a method for backing up a private key of digital currency according to the present application.
Fig. 3 is a flowchart of a second embodiment of a method for backing up a private key of digital currency according to the present application.
Fig. 4 is a flowchart of a third embodiment of a method for backing up a private key of digital currency according to the present application.
Fig. 5 is a flowchart of a fourth embodiment of a backup method for a private key of digital currency according to the present application.
Fig. 6 is a block diagram of a backup device for a private key of digital currency according to the present application.
Fig. 7 is a schematic diagram of an embodiment of a backup device for private keys of digital currency according to the present application.
Fig. 8 is a schematic diagram of a backup terminal for a private key of digital currency according to the present application.
Fig. 9 is a schematic view of a display interface of a backup terminal for a private key of digital currency according to the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the technical solutions of the present application will be described in detail and completely with reference to the following specific embodiments of the present application and the accompanying drawings. It should be apparent that the described embodiments are only some of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application. The technical solutions provided by the embodiments of the present application are described in detail below with reference to the accompanying drawings.
Referring to fig. 1, a flowchart of a method for backing up a private key of digital currency is provided, where the method includes:
step 101, a private key generation request is received.
Specifically, digital currency asset management software commonly used in the market at present generally has a function of generating an account number, that is, generating a private key and an address corresponding to the private key.
And 102, generating an original private key according to the private key generation request.
The address and private key of the bitcoin are calculated by the ECDSA elliptic curve encryption algorithm.
For example, the address format of a bitcoin is similar to:
1HvQb2hbkMpsJzNXU8ePX55TE9vDPDxJxh;
the private key format of bitcoin is similar to:
L2kVdpKzCQHrxFzv5MNCyDF86LonYjSKwm23k4AanjCe2WhX7ozR。
the private key of the bitcoin is unique, and the length of the private key of other similar digital currency assets such as the Laite coin, Ether Fang and the like is also large. Because the address of the private key is too long and complex, the digital asset management software does not usually perform any processing on the generated private key for convenience, all plaintext is displayed, and the user can store the private key to other safe places in a copying and pasting manner.
And 103, performing confusion processing on the original private key to obtain a confusion private key.
Specifically, when a user copies and backs up a private key generated in a digital currency asset management tool after the user's device is unknowingly installed with trojan or virus, the data of the clipboard and the private key are easily monitored by the trojan or virus, so that the generated private key is leaked, and asset loss is caused. Therefore, after the private key is generated, the private key is not directly displayed on a display interface, but is subjected to confusion processing.
And 104, displaying the confusion private key to a first display area of a display interface, and simultaneously displaying confusion prompt information in a second display area of the display interface.
Referring to fig. 9, after obtaining the obfuscated private key, the obfuscated private key is displayed in a first display area of the display interface, and meanwhile, obfuscation prompt information is displayed in a second display area outside the first display area to inform a user of the original private key before obfuscation. In this embodiment, the confusion prompt information is specifically displayed in the area below the confusion private key, and the confusion prompt information needs to be described clearly, so that the user can see the prompt information in time, and the prompt information can easily obtain the original private key.
And 105, receiving a copying instruction of the obfuscated private key, and copying the obfuscated private key to a clipboard.
Specifically, when the user copies the private key at the display interface, the processed obfuscated private key is actually copied to the clipboard, so that when the device of the user is unknowingly installed with trojan or medium virus, and the data of the clipboard is monitored by the trojan or the virus, even if the listener acquires the obfuscated private key in the clipboard, the digital goods of the user cannot be threatened, because the obfuscated private key is equivalent to an incorrect private key, the listener cannot obtain the original private key, and thus the security of the goods of the user can be remarkably improved.
And 106, receiving a pasting instruction of the data of the clipboard, and pasting the confusion private key to a backup area.
Specifically, after the user pastes the data of the clipboard to the safe backup area, the obfuscated private key can be corrected to be the correct original private key according to the obfuscation prompt information, so that backup and storage are completed.
According to the technical scheme, when the private key is generated, the content of the private key is confused, the confused content is prompted and explained at other positions except for the position where the private key is displayed, and the user is informed of the confused detailed information, so that the private key is convenient to backup for the user, the private key address is prevented from being revealed due to the fact that data of the shear plate is monitored by trojans or viruses, even if a monitor obtains the confused private key in the shear plate, the original private key cannot be obtained, and the safety of the user asset is remarkably improved.
Referring to fig. 2, in a first embodiment of the method for backing up a private key of digital currency, the obfuscating the original private key to obtain an obfuscated private key may specifically include:
step 201, a random number and a random character are generated, and the size of the random number is smaller than the length of the character string of the original private key.
Specifically, the random number is used to determine the position of the character to be replaced in the original private key, and therefore, the length of the character string needs to be smaller than that of the original private key to ensure that the position determined according to the random number is valid.
Step 202, determining the position of the character to be replaced in the original private key according to the random number, and replacing the character at the position in the original private key with the random character to obtain a confusion private key.
For example, if the generated random number is "2", it indicates that the character to be replaced in the original private key is the second bit character, and the random character is used to replace the second bit character, for example, if the second bit character in the original private key is "a" and the random character is "b", the obtained private key is the confusion private key after replacing the second bit character "a" in the original private key with the random character "b".
In the embodiment, the original private key is converted into the obfuscated private key, so that the original private key cannot be obtained even if the listener acquires the obfuscated private key in the clipboard when the user backs up the private key.
Referring to fig. 3, in a second embodiment of the method for backing up a private key of digital currency, the obfuscating is performed on the original private key to obtain an obfuscated private key, which may specifically include:
step 301, generating a random number and a random character string, wherein the size of the random number and the length of the random character string are both smaller than the character string length of the original private key.
Specifically, the random number is used to determine the position of the character string to be replaced in the original private key, and the random character string is used to replace the character string with the same length in the original private key, so that both the size of the random number and the length of the random character string need to be smaller than the length of the character string of the original private key.
Step 302, determining the position of the character string to be replaced in the original private key according to the random number, and replacing the character string with the corresponding length at the position in the original private key with the random character string to obtain the confusion private key.
For example, if the generated random number is "3", it indicates that the character string to be replaced in the original private key is a character string counted from the third position, and the random character string is used to replace the character string counted from the third position, for example, the character string composed of the third and fourth characters in the original private key is "kV", the random character string is "Xm", and after the character string composed of the third and fourth characters in the original private key is replaced with the random character string of "Xm", the obtained private key is the obfuscated private key. Compared with the first embodiment, the embodiment replaces the character strings with the same length in the original private key with the random character strings, and improves the security to a certain extent.
Referring to fig. 4, in a third embodiment of the backup method for a private key of digital currency provided in the present application, the obfuscating is performed on the original private key to obtain an obfuscated private key, which may specifically include:
step 401, generating two or more random numbers and random characters, wherein the size of the random numbers is smaller than the length of the character string of the original private key, and the number of the random characters is the same as the number of the random numbers.
Specifically, taking two random numbers as an example, the two random numbers are respectively used for determining positions of two characters to be replaced in the original private key, and correspondingly, the number of the random characters should also be two, and the two random characters are respectively used for replacing two characters corresponding to the two random numbers in the original private key, so that the size of the random number is required to be smaller than the length of a character string of the original private key, and the number of the random characters is the same as the number of the random numbers.
Step 402, respectively determining the position of each character to be replaced in the original private key according to the random numbers, and respectively replacing the characters at the positions in the original private key with the random characters to obtain a confusion private key.
For example, if the two generated random numbers are "3" and "7", respectively, it indicates that the two characters to be replaced in the original private key are two characters located at the third bit and the seventh bit, and the two random characters are two characters used to replace the third bit and the seventh bit, respectively. For example, two characters of the third bit and the seventh bit in the original private key are "Y" and "j", respectively, and two random characters are "C" and "e", respectively, then the two characters of the third bit and the seventh bit in the original private key are replaced by the random characters "C" and "e", respectively, and the obtained private key is the confusion private key.
Compared with the first embodiment, the embodiment replaces a plurality of characters in the original private key by a plurality of random characters, and the security is improved to a certain extent.
Referring to fig. 5, in a fourth embodiment of the backup method for a private key of digital currency provided in the present application, the obfuscating the original private key to obtain an obfuscated private key may further include:
step 501, two or more random numbers and random character strings are generated, the size of the random numbers and the length of the random character strings are both smaller than the length of the character strings of the original private key, and the number of the random character strings is the same as the number of the random numbers.
Specifically, taking two random numbers as an example, the two random numbers are respectively used for determining positions of two character strings to be replaced in the original private key, correspondingly, the number of the random character strings should also be two, and the two random character strings are respectively used for replacing two character strings corresponding to the two random numbers in the original private key, so that the size of the random numbers and the length of the random character strings are both required to be smaller than the length of the character strings of the original private key, and the number of the random character strings is the same as the number of the random numbers.
Step 502, respectively determining the position of each character string to be replaced in the original private key according to the random numbers, and respectively replacing the character strings with the same length at the positions in the original private key with the random character strings to obtain a mixed private key.
For example, if the two generated random numbers are "3" and "7", respectively, it indicates that the two character strings to be replaced in the original private key are two character strings counted from the third bit and the seventh bit, and the two random character strings are two character strings counted from the third bit and the seventh bit and having the same number of bits as that of the random character string. For example, two character strings calculated from the third bit and the seventh bit in the original private key are respectively "MN" and "4A", and two random character strings are respectively "F8" and "nj", then the two character strings "MN" and "4A" calculated from the third bit and the seventh bit in the original private key are respectively replaced by the two random character strings "F8" and "nj", and the obtained private key is the confusion private key. In addition, in this embodiment, a random character string and a random character may also be generated at the same time to replace the character string and the character at the corresponding position in the original private key, so as to obtain the obfuscated private key.
Compared with the first to third embodiments, the present embodiment further improves security by replacing a plurality of random character strings with a plurality of character strings in the original private key.
Referring to fig. 6, the present application provides a device for backing up private keys of digital currency, the device comprising:
the receiving unit 601 is configured to receive a private key generation request.
A generating unit 602, configured to generate an original private key according to the private key generation request.
The processing unit 603 is configured to perform obfuscation processing on the original private key to obtain an obfuscated private key.
The display unit 604 is configured to display the confusion private key to a first display area of a display interface, and simultaneously display confusion prompt information in a second display area of the display interface.
The copying unit 605 is configured to receive a copy instruction for the obfuscated private key, and copy the obfuscated private key to the clipboard.
And the pasting unit 606 is configured to receive a pasting instruction for the data of the clipboard, and paste the obfuscated private key to the backup area.
Referring to fig. 7, in an embodiment of the backup apparatus for a private key of digital currency, the processing unit 603 may specifically include:
the generating subunit 701 is configured to generate a random number and a random character, where the size of the random number is smaller than the length of the character string of the original private key.
And the replacing subunit 702 is configured to determine, according to the random number, a position of a character to be replaced in the original private key, and replace the character at the position in the original private key with the random character to obtain an obfuscated private key.
Referring to fig. 7, in another embodiment of the backup device for private keys of digital currency of the present application, the processing unit may specifically include:
the generating subunit 701 is configured to generate a random number and a random character string, where both the size of the random number and the length of the random character string are smaller than the length of the character string of the original private key.
And the replacing subunit 702 is configured to determine, according to the random number, a position of a character string to be replaced in the original private key, and replace, in the original private key, the character string with the corresponding length at the position with the random character string, so as to obtain an obfuscated private key.
Referring to fig. 7, in another embodiment of the backup device for private keys of digital currency of the present application, the processing unit may specifically include:
the generation subunit 701 is configured to generate two or more random numbers and random characters, where the size of the random numbers is smaller than the length of the character string of the original private key, and the number of the random characters is the same as the number of the random numbers.
And the replacing subunit 702 is configured to determine, according to the random numbers, positions of each character to be replaced in the original private key, and replace the characters at the positions in the original private key with the random characters, so as to obtain an obfuscated private key.
Referring to fig. 7, in another embodiment of the backup device for private keys of digital currency of the present application, the processing unit may specifically include:
the generation subunit 701 is configured to generate two or more random numbers and random character strings, where the size of the random numbers and the length of the random character strings are both smaller than the length of the character string of the original private key, and the number of the random character strings is the same as the number of the random numbers.
And the replacing subunit 702 is configured to determine, according to the random numbers, a position of each character string to be replaced in the original private key, and replace, at the position, character strings with the same length in the original private key with the random character strings, so as to obtain an obfuscated private key.
Referring to fig. 8, the present application further provides a backup terminal for a private key of digital currency, where the terminal includes: a processor 81, and a memory 82 for storing instructions executable by the processor 81.
Wherein the processor 81 is configured to: the method comprises the steps of receiving a private key generation request, generating an original private key according to the private key generation request, conducting confusion processing on the original private key to obtain a confusion private key, displaying the confusion private key to a first display area of a display interface, simultaneously displaying confusion prompt information in a second display area of the display interface, receiving a copying instruction of the confusion private key, copying the confusion private key to a shear plate, receiving a pasting instruction of data of the shear plate, and pasting the confusion private key to a backup area.
In specific implementation, the present application further provides a computer storage medium, where the computer storage medium may store a program, and the program may include some or all of the steps in the embodiments of the backup method for a digital currency private key provided by the present invention when executed. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM) or a Random Access Memory (RAM).
Those skilled in the art will readily appreciate that the techniques of the embodiments of the present invention may be implemented as software plus a required general purpose hardware platform. Based on such understanding, the technical solutions in the embodiments of the present invention may be essentially or partially implemented in the form of a software product, which may be stored in a storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the embodiments or some parts of the embodiments.
The same and similar parts in the various embodiments in this specification may be referred to each other. Especially, as for the backup device of the digital currency private key and the terminal embodiment, since the backup device is basically similar to the method embodiment, the description is simple, and the relevant points can be referred to the description in the method embodiment.
The above-described embodiments of the present application do not limit the scope of the present application.

Claims (11)

1. A method for backing up a private key of digital currency, the method comprising:
receiving a private key generation request;
generating an original private key according to the private key generation request;
performing confusion processing on the original private key to obtain a confusion private key;
displaying the confusion private key to a first display area of a display interface, and simultaneously displaying confusion prompt information in a second display area of the display interface;
receiving a copying instruction of the obfuscated private key, and copying the obfuscated private key to a clipboard;
and receiving a pasting instruction of the data of the clipboard, and pasting the confusion private key to a backup area.
2. The method of claim 1, wherein obfuscating the original private key to obtain an obfuscated private key comprises:
generating a random number and a random character, wherein the size of the random number is smaller than the length of a character string of the original private key;
and determining the position of the character to be replaced in the original private key according to the random number, and replacing the character at the position in the original private key with the random character to obtain the confusion private key.
3. The method of claim 1, wherein obfuscating the original private key to obtain an obfuscated private key comprises:
generating a random number and a random character string, wherein the size of the random number and the length of the random character string are both smaller than the length of the character string of the original private key;
and determining the position of the character string to be replaced in the original private key according to the random number, and replacing the character string with the corresponding length at the position in the original private key with the random character string to obtain the confusion private key.
4. The method of claim 1, wherein obfuscating the original private key to obtain an obfuscated private key comprises:
generating two or more random numbers and random characters, wherein the size of the random numbers is smaller than the length of a character string of an original private key, and the number of the random characters is the same as that of the random numbers;
and respectively determining the position of each character to be replaced in the original private key according to the random number, and respectively replacing the characters at the positions in the original private key with the random characters to obtain a confusion private key.
5. The method of claim 1, wherein obfuscating the original private key to obtain an obfuscated private key comprises:
generating two or more random numbers and random character strings, wherein the size of the random numbers and the length of the random character strings are both smaller than the length of the character strings of the original private key, and the number of the random character strings is the same as the number of the random numbers;
and respectively determining the position of each character string to be replaced in the original private key according to the random number, and respectively replacing the character strings with the same length at the positions in the original private key with the random character strings to obtain a mixed private key.
6. An apparatus for backing up a private key of digital currency, the apparatus comprising:
a receiving unit configured to receive a private key generation request;
the generating unit is used for generating an original private key according to the private key generating request;
the processing unit is used for performing confusion processing on the original private key to obtain a confusion private key;
the display unit is used for displaying the confusion private key to a first display area of a display interface and displaying confusion prompt information in a second display area of the display interface;
the copying unit is used for receiving a copying instruction of the obfuscated private key and copying the obfuscated private key to a clipboard;
and the pasting unit is used for receiving a pasting instruction of the data of the clipboard and pasting the confusion private key to the backup area.
7. The apparatus of claim 6, wherein the processing unit comprises:
the generating subunit is used for generating a random number and a random character, wherein the size of the random number is smaller than the length of a character string of the original private key;
and the replacing subunit is used for determining the position of the character to be replaced in the original private key according to the random number, and replacing the character at the position in the original private key with the random character to obtain the confusion private key.
8. The apparatus of claim 6, wherein the processing unit comprises:
the generation subunit is used for generating a random number and a random character string, and the size of the random number and the length of the random character string are both smaller than the character string length of the original private key;
and the replacing subunit is used for determining the position of the character string to be replaced in the original private key according to the random number, and replacing the character string with the corresponding length at the position in the original private key with the random character string to obtain the confusion private key.
9. The apparatus of claim 6, wherein the processing unit comprises:
the generation subunit is used for generating two or more random numbers and random characters, the size of the random numbers is smaller than the length of a character string of the original private key, and the number of the random characters is the same as that of the random numbers;
and the replacing subunit is used for respectively determining the position of each character to be replaced in the original private key according to the random number, and respectively replacing the characters at the positions in the original private key with the random characters to obtain the confusion private key.
10. The apparatus of claim 6, wherein the processing unit comprises:
the generation subunit is used for generating two or more random numbers and random character strings, wherein the size of the random numbers and the length of the random character strings are both smaller than the length of the character strings of the original private key, and the number of the random character strings is the same as the number of the random numbers;
and the replacing subunit is used for respectively determining the position of each character string to be replaced in the original private key according to the random number, and respectively replacing the character strings with the same length at the position in the original private key with the random character strings to obtain the confusion private key.
11. A backup terminal for a private key of digital currency, said terminal comprising: a processor, and a memory for storing processor-executable instructions;
wherein the processor is configured to:
receiving a private key generation request;
generating an original private key according to the private key generation request;
performing confusion processing on the original private key to obtain a confusion private key;
displaying the confusion private key to a first display area of a display interface, and simultaneously displaying confusion prompt information in a second display area of the display interface;
receiving a copying instruction of the obfuscated private key, and copying the obfuscated private key to a clipboard;
and receiving a pasting instruction of the data of the clipboard, and pasting the confusion private key to a backup area.
CN201810919993.0A 2018-08-14 2018-08-14 Backup method and device for digital currency private key and terminal Active CN109255612B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810919993.0A CN109255612B (en) 2018-08-14 2018-08-14 Backup method and device for digital currency private key and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810919993.0A CN109255612B (en) 2018-08-14 2018-08-14 Backup method and device for digital currency private key and terminal

Publications (2)

Publication Number Publication Date
CN109255612A CN109255612A (en) 2019-01-22
CN109255612B true CN109255612B (en) 2020-06-23

Family

ID=65050153

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810919993.0A Active CN109255612B (en) 2018-08-14 2018-08-14 Backup method and device for digital currency private key and terminal

Country Status (1)

Country Link
CN (1) CN109255612B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101359991A (en) * 2008-09-12 2009-02-04 湖北电力信息通信中心 Public key cipher system private key escrowing system based on identification
CN101488858A (en) * 2008-02-13 2009-07-22 刘海云 Random ciphering method which needs to be deciphered by exhaust algorithm
CN105978691A (en) * 2016-07-26 2016-09-28 西安酷派软件科技有限公司 Private key backup method and device and Softsim terminal switching method and device
CN107370596A (en) * 2017-06-15 2017-11-21 重庆移动金融有限责任公司 A kind of user cipher encrypted transmission method, system and storage medium
CN107392014A (en) * 2017-06-23 2017-11-24 复旦大学 The SQL injection defence method and system changed at random based on database structure

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9363259B2 (en) * 2013-05-23 2016-06-07 Symantec Corporation Performing client authentication using onetime values recovered from barcode graphics

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101488858A (en) * 2008-02-13 2009-07-22 刘海云 Random ciphering method which needs to be deciphered by exhaust algorithm
CN101359991A (en) * 2008-09-12 2009-02-04 湖北电力信息通信中心 Public key cipher system private key escrowing system based on identification
CN105978691A (en) * 2016-07-26 2016-09-28 西安酷派软件科技有限公司 Private key backup method and device and Softsim terminal switching method and device
CN107370596A (en) * 2017-06-15 2017-11-21 重庆移动金融有限责任公司 A kind of user cipher encrypted transmission method, system and storage medium
CN107392014A (en) * 2017-06-23 2017-11-24 复旦大学 The SQL injection defence method and system changed at random based on database structure

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
区块链中的密码学技术;王化群,吴涛;《南京邮电大学学报(自然科学版)》;20171231;第37卷(第6期);全文 *

Also Published As

Publication number Publication date
CN109255612A (en) 2019-01-22

Similar Documents

Publication Publication Date Title
CN109412812B (en) Data security processing system, method, device and storage medium
US20160117262A1 (en) Hybrid Cryptographic Key Derivation
CN109766134A (en) System start method, device, electronic equipment and storage medium
CN110290102A (en) Service security system and method based on application
CN106899552A (en) Authentication method, certification terminal and system
CN107454048B (en) Information processing method and device, and information authentication method, device and system
EP3804213A1 (en) Shared secret establishment
CN102801710A (en) Networked transaction method and system
CN111178884A (en) Information processing method, device, equipment and readable storage medium
CN106897761A (en) A kind of two-dimensional code generation method and device
CN112507326B (en) Encryption method and device for password information based on SM3 hash algorithm and computer equipment
US20210334809A1 (en) Transaction method and apparatus based on blind signature
CN111967032A (en) File encryption method and decryption method based on obfuscation processing
CN106685945B (en) Service request processing method, service handling number verification method and terminal thereof
CN110753257A (en) Data display method, display terminal, server, display system, and storage medium
US10841099B2 (en) Method for generating a digital signature
CN106341226A (en) Data encryption and decryption method and system
CN117632099A (en) Multi-language calling method, device, equipment and medium based on application program interface
CN112199730A (en) Method and device for processing application data on terminal and electronic equipment
CN109255612B (en) Backup method and device for digital currency private key and terminal
CN110502909B (en) File encryption method and device and file decryption method and device
WO2020000753A1 (en) Device security monitoring method and apparatus
CN111064736A (en) Data transmission method and equipment
JP2020140695A (en) Apparatus for evacuating encrypted currency, method thereof, and program therefor
CN109525747B (en) Picture uploading method, encryption and decryption method, device and system and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20230901

Address after: No. 1303, 13th Floor, Building 1, No. 166 Tianfu Second Street, Chengdu High tech Zone, China (Sichuan) Pilot Free Trade Zone, Chengdu, Sichuan, 610095

Patentee after: Chengdu Tongchuang Jialian Technology Co.,Ltd.

Address before: 571924 building 8830, Hainan eco software Walker Park, Haikou old town high tech Industrial Demonstration Park, Hainan Province

Patentee before: HAINAN XINRUAN SOFTWARE Co.,Ltd.