WO2020134591A1 - 一种硬件钱包可脱机进行初始化的实现方法及装置 - Google Patents

一种硬件钱包可脱机进行初始化的实现方法及装置 Download PDF

Info

Publication number
WO2020134591A1
WO2020134591A1 PCT/CN2019/115620 CN2019115620W WO2020134591A1 WO 2020134591 A1 WO2020134591 A1 WO 2020134591A1 CN 2019115620 W CN2019115620 W CN 2019115620W WO 2020134591 A1 WO2020134591 A1 WO 2020134591A1
Authority
WO
WIPO (PCT)
Prior art keywords
mnemonic
user
length
hardware wallet
module
Prior art date
Application number
PCT/CN2019/115620
Other languages
English (en)
French (fr)
Inventor
陆舟
于华章
Original Assignee
飞天诚信科技股份有限公司
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 飞天诚信科技股份有限公司 filed Critical 飞天诚信科技股份有限公司
Priority to US17/294,496 priority Critical patent/US20210409213A1/en
Publication of WO2020134591A1 publication Critical patent/WO2020134591A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0894Escrow, recovery or storing of secret information, e.g. secret key escrow or cryptographic key storage
    • H04L9/0897Escrow, recovery or storing of secret information, e.g. secret key escrow or cryptographic key storage involving additional devices, e.g. trusted platform module [TPM], smartcard or USB
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • H04L9/0869Generation of secret information including derivation or calculation of cryptographic keys or passwords involving random numbers or seeds
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/70Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer
    • G06F21/71Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information
    • G06F21/76Protecting specific internal or peripheral components, in which the protection of a component leads to protection of the entire computer to assure secure computing or processing of information in application-specific integrated circuits [ASIC] or field-programmable devices, e.g. field-programmable gate arrays [FPGA] or programmable logic devices [PLD]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/06Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols the encryption apparatus using shift registers or memories for block-wise or stream coding, e.g. DES systems or RC4; Hash functions; Pseudorandom sequence generators
    • H04L9/0643Hash functions, e.g. MD5, SHA, HMAC or f9 MAC
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • H04L9/0863Generation of secret information including derivation or calculation of cryptographic keys or passwords involving passwords or one-time passwords
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3226Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using a predetermined code, e.g. password, passphrase or PIN
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3236Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using cryptographic hash functions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2209/00Additional information or applications relating to cryptographic mechanisms or cryptographic arrangements for secret or secure communication H04L9/00
    • H04L2209/56Financial cryptography, e.g. electronic payment or e-cash

Definitions

  • the present disclosure relates to the field of electronic products, and in particular to a method and device for implementing a hardware wallet that can be initialized offline.
  • the hardware wallet refers to storing the private keys of digital assets in a single chip, isolated from the Internet, and plug and play.
  • the existing hardware wallet must be connected to the host computer by wire, such as a USB cable.
  • the hardware wallet When the hardware wallet is connected to the host computer by wired method, the user needs to enter confidential information in the host computer during the initialization process. Once the host computer is controlled by the malware, it will be able to intercept the user's private information and then steal the user Digital assets, causing losses.
  • the purpose of the present disclosure is to overcome the shortcomings of the prior art, and to provide a method and a device for implementing a hardware wallet that can be initialized offline.
  • the present disclosure provides a method for implementing a hardware wallet that can be initialized offline, including:
  • Step S1 When the hardware wallet receives the operation trigger information of the user, it determines the type of the operation trigger information, if the hardware wallet is created, step S2 is performed, and if the hardware wallet is restored, step S4 is performed;
  • Step S2 The hardware wallet prompts the user to input a mnemonic phrase length, generates a key seed based on the received mnemonic phrase length, and generates multiple mnemonic word identifiers based on the mnemonic phrase length and the key seed , Sequentially searching for the corresponding mnemonic word in the preset dictionary according to different mnemonic word identifiers, and splicing the found mnemonic words in sequence to obtain a mnemonic phrase, and generating a master key according to the key seed and storing it;
  • Step S3 the hardware wallet sets the hardware wallet status to initialized and performs normal work
  • Step S4 The hardware wallet prompts the user to input word letters, and searches for the corresponding mnemonic word in a preset dictionary according to the received word letter and displays the found mnemonic word, prompting the user to make a selection;
  • Step S5 When the hardware wallet receives the user's selection information, the hardware wallet judges whether the selection information input by the user is a complete mnemonic phrase, if yes, step S6 is executed, otherwise step S4 is returned;
  • Step S6 The hardware wallet obtains a key seed according to the length of the selection information input by the user, generates a master key according to the key seed and performs verification, and if verified, saves the master key and stores the hardware wallet status Set to initialized for normal work.
  • the method includes: the hardware wallet is powered on, and it is determined whether the hardware wallet has been initialized. If yes, the hardware wallet is working normally, otherwise, the step S1 is executed.
  • the judging whether the hardware wallet has been initialized specifically means: the hardware wallet judges whether the hardware wallet has been initialized according to the state of the hardware wallet, if the hardware wallet state is initialized, the hardware wallet performs normal work, otherwise it is executed Step S1.
  • step S1 is specifically:
  • the hardware wallet displays an initial interaction option interface, waits for and receives the operation trigger information sent by the user through the human-machine interaction module, and determines the type of operation trigger information received. If the hardware wallet is created, step S2 is performed, and if the hardware wallet is restored, Then step S4 is executed.
  • step S1 includes: the hardware wallet notifies the user to set the identity authentication method, if the setting is successful, step S2 is executed, otherwise an error is reported;
  • step S1 and step S4 includes: the hardware wallet notifies the user to set the identity authentication method, if the setting is successful, step S4 is executed, otherwise an error is reported.
  • the hardware wallet notifies the user to set the identity authentication method, specifically: the hardware wallet notifies the user to set the PIN code.
  • the hardware wallet notifies the user to set the PIN code, including:
  • Step A1 The hardware wallet prompts the user to set a PIN code.
  • PIN code input by the user it is judged whether the PIN code is legal. If yes, step A2 is executed; otherwise, step A1 is returned;
  • Step A2 The hardware wallet judges the number of times the user enters the legal PIN code. If it is twice, step A3 is executed. If it is once, the number of times the user enters the legal PIN code is updated. Return to step A1. If it is three times, an error is reported;
  • Step A3 The hardware wallet judges whether the legal PIN codes received twice are the same, if yes, the user identity verification is passed, otherwise returns to step S1.
  • the judging whether the PIN code is legal is specifically: judging whether the length of the PIN code is within a preset range, it is legal, otherwise it is illegal.
  • the method further includes: the hardware wallet determines whether the number of set PIN code errors has reached a predetermined number, if yes, an error is reported, and returns to step S1; otherwise, the number of set PIN code errors is updated, and returns to step A1 .
  • step S2 includes:
  • Step S2-1 The hardware wallet prompts the user to input the length of the mnemonic phrase.
  • the key seed length and the first verification value are calculated according to the length of the mnemonic phrase, and Key seed length generates a key seed of corresponding length;
  • Step S2-2 the hardware wallet clears the data in the secure storage area, generates a master key according to the key seed through a second preset algorithm, and saves the master key in the secure storage area;
  • Step S2-3 The hardware wallet calculates the key seed using the first preset algorithm to obtain the first calculation result, and intercepts the data of the first check value length from the starting position of the first calculation result to obtain the first calibration Check the value, and splice the first check value into the key seed to obtain the mnemonic phrase identifier; in the mnemonic phrase identifier, successively intercept data segments of a preset length to obtain multiple mnemonic word identifiers; Set up a dictionary to search for the corresponding mnemonic word, and splice the found mnemonic words in sequence to get the mnemonic phrase.
  • step S2-1 of calculating the key seed length and the first verification value according to the mnemonic phrase length is specifically: the hardware wallet generates the mnemonic phrase length by a second preset value The mnemonic phrase identification length; the key seed length and the first check value length are obtained from the mnemonic phrase identification length according to a preset ratio;
  • the generating a key seed of a corresponding length according to the length of the key seed is specifically: the hardware wallet uses a true random number generator to generate a random number with a length of the key seed as the key seed.
  • step S2-2 of generating the master key through the second preset algorithm according to the key seed is specifically: performing hash operation on the key seed according to the second preset algorithm to obtain a hash Value; the data of the predetermined length of the upper end of the obtained hash value is used as the master key.
  • step S2 includes:
  • Step P1 the hardware wallet generates and displays test words according to the mnemonic phrase and the preset dictionary, prompting the user to make a selection;
  • Step P2 When the hardware wallet receives the user's selection information, it is determined whether the selection information input by the user is correct according to the mnemonic word, if yes, step S3 is executed, otherwise step P1 is returned.
  • step P1 is specifically: the hardware wallet displays a mnemonic phrase through the display screen of the human-computer interaction module, generates test words according to the subject phrase and the preset dictionary and displays it on the display screen, and then prompts the user through the display screen Make a selection.
  • step P2 determines whether or not further includes: the number of times the hardware wallet resets the user selection;
  • step P2 and step S3 the method further includes: the hardware wallet judges whether the number of user selections reaches a preset number of times, if yes, executes step S3, otherwise updates the number of user selections, and returns to step P1.
  • step S4 is specifically: the hardware wallet prompts the user to input word letters through the display screen of the human-computer interaction module, and when receiving the letters input by the user through the keys of the human-computer interaction module, the Set up a dictionary to query the corresponding mnemonic words; the hardware wallet displays the inquired mnemonic words through the display screen of the human-computer interaction module and displays information prompting the user to make a selection on the display screen.
  • step S4 it includes: the hardware wallet prompts the user to input the length of the mnemonic phrase, and when the length of the mnemonic phrase is received, step S4 is executed;
  • the step S5 is specifically: when the hardware wallet receives the user's selection information, the hardware wallet determines whether the length of the selection information input by the user is equal to the length of the mnemonic phrase, if yes, execute step S6, otherwise return to step S4.
  • step S6 includes:
  • Step S6-1 The hardware wallet clears the data in the secure storage area, finds the mnemonic word identifiers corresponding to each mnemonic word in the mnemonic phrase preset dictionary, and joins the found mnemonic word identifiers in sequence to obtain assistance
  • Step S6-2 the hardware wallet calculates the length of the key seed according to the length of the mnemonic phrase identifier, sequentially intercepts the data of the key seed length from the mnemonic phrase identifier to obtain the key seed, and removes the key from the mnemonic phrase identifier Data other than seeds is used as the second check value;
  • Step S6-3 The hardware wallet uses a first preset algorithm to calculate the key seed to obtain a first calculation result, and intercepts data with the same length as the second check value from the start position of the first calculation result to obtain a first comparison Value, to determine whether the second check value matches the first comparison value, if yes, step S6-4 is executed, otherwise an error is reported;
  • Step S6-4 The hardware wallet generates a master key through a second preset algorithm according to the key seed and saves it in a secure storage area, sets the hardware wallet status to initialized, and notifies the user that the initialization is successful through the display screen and proceeds normally jobs.
  • the present disclosure also provides a device for implementing a hardware wallet that can be initialized offline, including:
  • the first receiving module is used to receive the user's operation trigger information
  • the first judgment module is used to judge the type of operation trigger information received by the first receiving module, such as a reminder generation module to trigger a hardware wallet creation and a reminder search module to restore a hardware wallet;
  • the prompt generation module is configured to prompt the user to input a mnemonic phrase length, generate a key seed according to the received mnemonic phrase length, and generate multiple mnemonic words according to the mnemonic phrase length and the key seed Logo, sequentially search for the corresponding mnemonic word in the preset dictionary according to different mnemonic word identifiers, and stitch the found mnemonic words in sequence to obtain a mnemonic phrase, generate a master key according to the key seed and save it, Trigger the first setting module;
  • the first setting module is used to set the state of the hardware wallet to initialized and the hardware wallet to work normally;
  • the prompt searching module is used for prompting the user to input the letter of the word, searching the corresponding mnemonic word in the preset dictionary according to the received word letter and displaying the found mnemonic word, prompting the user to make a selection, and receiving the user Selection information
  • a second judgment module used to judge whether the selection information received by the prompt search module is a complete mnemonic phrase, if yes, trigger the acquisition verification module, otherwise trigger the prompt search module;
  • the acquisition verification module is configured to acquire a key seed according to the length of the selection information input by the user, generate a master key according to the key seed and perform verification;
  • the save setting module is used to save the master key after the acquisition verification module passes verification, and set the hardware wallet status to initialized, and the hardware wallet performs normal work.
  • the device further includes:
  • the third judging module is used to judge whether the hardware wallet has been initialized after the hardware wallet is powered on. If the hardware wallet is working normally, otherwise the first receiving module is triggered.
  • the third judgment module is specifically used to judge whether the hardware wallet has been initialized according to the hardware wallet status after the hardware wallet is powered on, if the hardware wallet status is initialized, the hardware wallet performs normal work, otherwise trigger The first receiving module.
  • the first receiving module is specifically used to display an initial interaction option interface, and wait for and receive operation trigger information sent by the user through the human-computer interaction module.
  • the device further includes:
  • the second setting module is used to notify the user to set the identity authentication method when the first judgment module judges yes, and triggers the prompt generation module if the setting is successful; and also used when the first judgment module judges no Notify the user to set the identity authentication method. If the setting is successful, the prompt search module is triggered. If the setting is unsuccessful, an error is reported.
  • the second setting module is specifically used to notify the user to set a PIN code when the first judgment module judges yes, and triggers the prompt generation module if the setting is successful; and is also used in the first judgment module When the judgment is no, the user is notified to set a PIN code, if the setting is successful, the prompt searching module is triggered, and if the setting is unsuccessful, an error is reported.
  • the second setting module includes:
  • the first prompt receiving unit is used to prompt the user to set a PIN code and receive the PIN code input by the user;
  • the first judgment unit is used to judge whether the PIN code is legal when the prompt receiving unit receives the PIN code input by the user, if yes, trigger the second judgment unit, otherwise trigger the prompt receiving unit;
  • the second judgment unit is used to judge the number of times the user enters the legal PIN code. If it is twice, the third judgment unit is triggered. If it is once, the number of times the user enters the legal PIN code is updated to trigger the prompt judgment unit, such as Report errors for three times;
  • the third judging unit is used to judge whether the legal PIN codes received twice are consistent. If the user identity verification is passed, the prompt generating module or the prompt searching module is triggered; otherwise, the prompt receiving unit is triggered.
  • the first determining unit is specifically configured to determine whether the length of the PIN code is within a preset range when the prompt receiving unit receives the PIN code input by the user, is it legal to trigger the second determining unit, Otherwise, it is illegal, and the prompt receiving unit is triggered.
  • the second setting module further includes:
  • the fourth judging unit is used for judging whether the number of set PIN code errors reaches a predetermined number of times when the first judging unit judges NO, if yes, an error is reported, and the first receiving module is triggered, otherwise, the set PIN code error times are updated, and triggered The first prompt receiving unit.
  • the prompt generation module includes:
  • the second prompt receiving unit is used to prompt the user to input the length of the mnemonic phrase and receive the length of the mnemonic phrase input by the user;
  • a calculation generating unit configured to calculate a key seed length and a first check value according to the mnemonic phrase length received by the second prompt receiving unit, and generate a key seed of a corresponding length according to the key seed length;
  • a generation and storage unit for clearing the data in the secure storage area, generating a master key according to the key seed generated by the calculation and generation unit through a second preset algorithm, and saving the master key in the secure storage area;
  • the calculation splicing unit is used to calculate the key seed using the first preset algorithm to obtain the first calculation result, and intercept the data of the first check value length from the starting position of the first calculation result to obtain the first check value, Merge the first check value after the key seed to obtain the mnemonic phrase identifier; in the mnemonic phrase identifier, successively intercept the data segment of the preset length to obtain multiple mnemonic word identifiers; according to the mnemonic word identifier in the preset dictionary Find corresponding mnemonic words, and splice the found mnemonic words in sequence to obtain mnemonic phrases, and trigger the first setting module.
  • the calculation generating unit is specifically configured to multiply the mnemonic phrase length by a second preset value to generate the mnemonic phrase identification length; obtain the key seed length and the first collation from the mnemonic phrase identification length according to a preset ratio Check length; use a true random number generator to generate a random number with the length of the key seed as the key seed.
  • the generating and storing unit is specifically used for clearing the data in the secure storage area, and performing a hash operation on the key seed generated by the calculating and generating unit according to a second preset algorithm to obtain a hash value;
  • the data of a predetermined length at the upper end of the hash value is used as a master key, and the master key is stored in a secure storage area.
  • the device further includes:
  • a first generating module configured to generate test words according to the mnemonic phrase obtained by the prompt generating module and the preset dictionary
  • a display prompting module for displaying the test words generated by the first generating module, prompting the user to make a selection and receiving the user's selection information
  • the fourth judgment module is used to judge whether the selection information input by the user received by the display prompt module is correct according to the mnemonic word, if yes, trigger the first setting module, otherwise trigger the first generation module.
  • the display prompt module is specifically used to display a mnemonic phrase through the display screen of the human-computer interaction module, display the test words generated by the first generation module on the display screen, and prompt the user to select and receive the user through the display screen Selection information.
  • the device further includes:
  • a reset module configured to reset the user selection times when the fourth judgment module judges negative
  • the judgment update module is used to judge whether the number of user selections reaches the preset number of times when the fourth judgment module judges yes, and trigger the first setting module if it is, otherwise, update the number of user selections and trigger the The first generation module.
  • the prompt search module is specifically configured to prompt the user to input word letters through the display screen of the human-computer interaction module, and when receiving the letters input by the user through the keys of the human-computer interaction module, according to the letters in the preset dictionary Query the corresponding mnemonic word; display the mnemonic word found through the display screen of the human-computer interaction module and display information prompting the user to make a selection on the display screen, and receive the user's selection information.
  • the device further includes:
  • a prompt receiving module configured to prompt the user to input a mnemonic phrase length when the first judgment module determines that the hardware wallet is restored, and trigger the prompt search module when the mnemonic phrase length is received;
  • the second judgment module is specifically configured to judge whether the length of the selection information of the prompt search module is equal to the length of the mnemonic phrase, if yes, trigger the acquisition verification module, otherwise trigger the prompt search module.
  • the acquisition verification module includes:
  • Search and splicing unit used to clear the data in the secure storage area, find the mnemonic word identifiers corresponding to each mnemonic word in the mnemonic phrase preset dictionary, and splice the found mnemonic word identifiers sequentially to obtain the mnemonic phrase identifiers ;
  • the calculation interception unit is used for calculating the length of the key seed according to the length of the mnemonic phrase identifier, sequentially intercepting the data of the key seed length from the mnemonic phrase identifier to obtain the key seed, and excluding the key seed from the mnemonic phrase identifier Data as the second check value;
  • the calculation and judgment unit is configured to perform a calculation on the key seed using the first preset algorithm to obtain a first calculation result, intercept data from the start position of the first calculation result with the same length as the second check value to obtain a first comparison value, and determine Whether the second check value matches the first comparison value, if yes, the save setting module is triggered, otherwise an error is reported;
  • the save setting module is specifically used to generate the master key according to the key seed through the second preset algorithm and save it to the secure storage area, set the hardware wallet status to initialized, notify the user through the display screen that the initialization is successful, and the hardware wallet performs normal work.
  • the present disclosure has the following advantages:
  • the technical solution of the present disclosure realizes that the hardware wallet can also be initialized in an offline state, and the process of using the hardware wallet is more safe and reliable.
  • FIG. 1 is a flowchart of a method for implementing a hardware wallet that can be initialized offline in a first embodiment of the present invention
  • FIG. 2 is a flowchart of a method for implementing a hardware wallet that can be initialized offline while provided in Embodiment 2 of the present invention
  • FIG. 3 is a block diagram of a device for implementing a hardware wallet that can be initialized offline while provided in Embodiment 3 of the present invention.
  • Embodiment 1 of the present invention provides an implementation method of a hardware wallet that can be initialized offline, as shown in FIG. 1, including:
  • Step S1 When the hardware wallet receives the user's operation trigger information, it determines the type of operation trigger information. If the hardware wallet is created, step S2 is performed, and if the hardware wallet is restored, step S4 is performed.
  • step S1 it includes: the hardware wallet is powered on, and it is determined whether the hardware wallet has been initialized; if yes, step S1 is executed; otherwise, the hardware wallet performs normal work.
  • the determination of whether the hardware wallet has been initialized specifically includes: the hardware wallet determines whether the hardware wallet has been initialized according to the state of the hardware wallet. If the hardware wallet state is initialized, the hardware wallet performs normal work, otherwise step S1 is executed.
  • Step S2 The hardware wallet prompts the user to input the mnemonic phrase length, generates a key seed based on the received mnemonic phrase length, generates multiple mnemonic word identifiers based on the mnemonic phrase length and key seed, and then sequentially generates different mnemonic word
  • the identifier searches for the corresponding mnemonic word in the preset dictionary, and joins the found mnemonic words in sequence to obtain the mnemonic phrase, and generates and saves the master key according to the key seed.
  • Step S3 The hardware wallet sets the hardware wallet status to initialized and performs normal work.
  • Step S4 The hardware wallet prompts the user to input the letter of the word, searches the corresponding mnemonic word in the preset dictionary according to the received word letter and displays the found mnemonic word, and prompts the user to make a selection.
  • Step S5 When the hardware wallet receives the user's selection information, the hardware wallet determines whether the selection information input by the user is a complete mnemonic phrase, if yes, step S6 is executed, otherwise, step S4 is returned to.
  • Step S6 The hardware wallet obtains the key seed according to the length of the selection information input by the user, generates a master key according to the key seed and performs verification, if the verification is passed, the master key is saved, and the hardware wallet status is set to initialized to proceed normal work.
  • step S6 if the verification of the master key fails in step S6, an error is reported.
  • step S1 and step S2 includes: the hardware wallet notifies the user to set the identity authentication method, if the setting is successful, step S2 is executed, otherwise an error is reported.
  • step S1 and step S4 includes: the hardware wallet notifies the user to set the identity authentication method, if the setting is successful, step S4 is executed, otherwise an error is reported.
  • the identity authentication method in this embodiment includes, but is not limited to, PIN code, fingerprint, iris, etc.; the PIN code will be used as an example for details.
  • the hardware wallet informs the user to set the PIN code, including:
  • Step A1 The hardware wallet prompts the user to set a PIN code.
  • PIN code input by the user it is judged whether the PIN code is legal. If yes, step A2 is executed; otherwise, step A1 is returned.
  • judging whether the PIN code is legal is specifically as follows: judging whether the length of the PIN code is within a preset range, it is legal, otherwise it is illegal.
  • the method further includes: the hardware wallet determines whether the number of set PIN code errors has reached a predetermined number, if yes, an error is reported, and returns to step S1; otherwise, the number of set PIN code errors is updated and returns to step A1.
  • Step A2 The hardware wallet judges the number of times the user enters the legal PIN code. If it is twice, step A3 is executed. If it is once, the number of times the user enters the legal PIN code is updated. Return to step A1. If it is three times, an error is reported.
  • Step A3 The hardware wallet judges whether the legal PIN codes received twice are the same, if yes, the user's identity verification is passed, otherwise returns to step S1.
  • Embodiment 2 of the present invention provides an implementation method of a hardware wallet that can be initialized offline, as shown in FIG. 2, including:
  • Step 101 The hardware wallet is powered on to determine whether it has been initialized. If the hardware wallet is working normally, otherwise step 102 is performed.
  • the hardware wallet determines whether initialization has been performed according to the hardware wallet status. If the hardware wallet status is initialized, step 124 is performed, otherwise step 102 is performed.
  • Step 102 The hardware wallet displays an initial interaction option interface, waits for and receives the operation trigger information sent by the user through the human-computer interaction module, and determines the type of operation trigger information received. If the hardware wallet is created, step 103 is performed, if the hardware is restored The wallet then executes step 113.
  • the human-computer interaction module includes buttons and a display screen; the hardware wallet displays an initial interaction option interface through the display screen, and then the user inputs operation trigger information through the buttons and the display screen.
  • Step 103 The hardware wallet prompts the user to set a PIN code. When the PIN code input by the user is received, it is judged whether the PIN code is legal. If yes, step 104 is executed; otherwise, step 103 is returned.
  • step 103 includes: the hardware wallet prompts the user to set a PIN code through the display screen of the human-machine interaction module.
  • the PIN code input by the user through the keys of the human-machine interaction module is received, it is judged whether the PIN code is legal, and then the step is executed 104, otherwise return to step 103.
  • judging whether the PIN code is legal is specifically: judging whether the length of the PIN code is within a preset range, which is legal, otherwise it is illegal.
  • the method further includes: the hardware wallet determines whether the number of set PIN code errors has reached a predetermined number, if yes, display an error message through the display screen, and return to step 102, otherwise update the set number of PIN code errors, Return to step 103.
  • the number of times to update the PIN code error can be increased by 1 for the number of times to update the PIN code error.
  • Step 104 The hardware wallet judges the number of times the user enters the legal PIN code. If it is twice, the step 105 is executed. If it is once, the number of times the user enters the legal PIN code is updated. Return to step 103. If it is three times, an error is reported.
  • the error report in this embodiment may be an error message displayed on the display screen; for example, the number of times the user enters a valid PIN code may be increased by one for the number of times the user enters a valid PIN code.
  • Step 105 The hardware wallet judges whether the legal PIN codes received twice are the same. If yes, step 106 is executed; otherwise, step 102 is returned to.
  • Step 106 The hardware wallet prompts the user to input the length of the mnemonic phrase.
  • the key seed length and the first check value length are calculated according to the length of the mnemonic phrase, and the correspondence is generated according to the key seed length The length of the key seed.
  • the key seed in this embodiment is a random number; the hardware wallet prompts the user to input the length of the mnemonic phrase through the display screen in the human-computer interaction module.
  • the length of the mnemonic phrase is specifically the number of mnemonic words contained in the mnemonic phrase, for example, it may be 12 or 15 or 18 or 21 or 24.
  • the hardware wallet multiplies the mnemonic phrase length by the second preset value to generate the mnemonic phrase identification length; and obtains the key seed length and the first check value length from the mnemonic phrase identification length according to the preset ratio.
  • the second preset value is the number of bits for each mnemonic word in the mnemonic phrase to be identified in the mnemonic word in the preset dictionary; for example, the second preset value is 11 bits and the length of the mnemonic phrase is 24, Then the length of the obtained mnemonic phrase identifier is 264bit.
  • the mnemonic phrase identification length key seed length + first check value length
  • the preset ratio of the key seed length to the first check value length is 32, according to the above relationship, it can be calculated according to the mnemonic phrase identification length
  • the hardware wallet uses a true random number generator to generate a random number with a key seed length (that is, 256 bits) as the key seed.
  • Step 107 The hardware wallet clears the data in the secure storage area, generates a master key through a second preset algorithm according to the key seed, and saves the master key in the secure storage area.
  • step 107 generating the master key through the second preset algorithm according to the key seed specifically includes: performing a hash operation on the key seed according to the second preset algorithm to obtain a hash value; The data of a predetermined length at the upper end is used as the master key.
  • the second preset algorithm is preferably the HMAC-SHA512 algorithm.
  • the data of a predetermined length at the upper end is preferably data of 256 bits higher, and the data of a predetermined length at the lower end is preferably data of 256 bits lower.
  • Step 108 The hardware wallet uses the first preset algorithm to calculate the key seed to obtain the first calculation result, and intercepts the data of the first verification value length from the starting position of the first calculation result to obtain the first verification value.
  • the first check value is concatenated after the key seed to obtain the mnemonic phrase identifier; the mnemonic phrase identifier is sequentially intercepted to obtain multiple mnemonic word identifiers; and the mnemonic word identifier is searched in the preset dictionary Corresponding mnemonic words, and splicing the found mnemonic words in sequence to get mnemonic phrases.
  • the instruction for creating a hardware wallet further includes: language type; language type specifically includes: simplified Chinese, traditional Chinese and English.
  • step 107 and step 108 can be switched.
  • Step 109 The hardware wallet displays the mnemonic phrase, generates and displays the test words according to the mnemonic phrase and the preset dictionary, and prompts the user to make a selection.
  • step 109 is specifically: the hardware wallet displays mnemonic phrases through the display screen of the human-computer interaction module, generates test words based on the subject phrase and the preset dictionary and displays them on the display screen, and then prompts the user through the display screen to proceed select.
  • Step 110 When the hardware wallet receives the user's selection information, it is determined whether the selection information input by the user is correct according to the mnemonic word. If yes, step 111 is executed; otherwise, the number of user selections is reset and step 109 is returned to.
  • the initial value of the number of user selections in this embodiment is 0.
  • Step 111 The hardware wallet judges whether the number of user selections reaches the preset number of times. If yes, step 112 is executed; otherwise, the number of user selections is updated, and step 109 is returned to.
  • the number of times of updating the user selection in this embodiment may be incremented by 1 for the number of user selections.
  • Step 112 The hardware wallet sets the state of the hardware wallet to initialized, and notifies the user through the display screen that the initialization is successful and performs normal work.
  • Step 113 The hardware wallet prompts the user to set a PIN code. When the PIN code input by the user is received, it is judged whether the PIN code is legal. If yes, step 114 is executed; otherwise, step 113 is returned.
  • step 113 includes: the hardware wallet prompts the user to set a PIN code through the display screen of the human-machine interaction module, and when the PIN code input by the user through the keys of the human-machine interaction module is received, determines whether the PIN code is legal, and then executes the step 114, otherwise return to step 113.
  • determining whether the PIN code is legal is specifically: determining whether the length of the PIN code is within a preset range, which is legal, otherwise it is illegal.
  • the method further includes: the hardware wallet determines whether the number of set PIN code errors has reached a predetermined number, if yes, display an error message through the display screen, and return to step 102, otherwise update the set number of PIN code errors, Return to step 113.
  • the number of times to update the PIN code error can be increased by 1 for the number of times to update the PIN code error.
  • Step 114 The hardware wallet judges the number of times the user enters the legal PIN code. If it is two times, step 115 is executed. If it is one time, the number of times the user enters the legal PIN code is updated. Return to step 113. If it is three times, an error is reported.
  • the error report in this embodiment may be an error message displayed on the display screen; for example, the number of times the user enters a valid PIN code may be increased by one for the number of times the user enters a valid PIN code.
  • Step 115 The hardware wallet judges whether the legal PIN codes entered twice are the same. If yes, step 116 is executed; otherwise, step 101 is returned to.
  • Step 116 The hardware wallet prompts the user to input the length of the mnemonic phrase.
  • step 117 is executed.
  • step 116 is specifically: the hardware wallet prompts the user to input the length of the mnemonic phrase through the display screen of the human-computer interaction module.
  • Step 117 The hardware wallet prompts the user to input word letters. When the word letters are received, the corresponding mnemonic words are queried in the preset dictionary according to the word letters.
  • step 117 is specifically: the hardware wallet prompts the user to input word letters through the display screen of the human-computer interaction module, and when receiving the letters input by the user through the keys of the human-computer interaction module, the preset dictionary is based on the word letters To query the corresponding mnemonic word.
  • Step 118 The hardware wallet displays the found mnemonic word and prompts the user to make a selection.
  • the hardware wallet displays the inquired mnemonic words through the display screen of the human-computer interaction module and displays information prompting the user to make a selection on the display screen.
  • Step 119 When the hardware wallet receives the user's selection information, it is determined whether the received selection information is a complete mnemonic phrase according to the length of the mnemonic phrase. If yes, step 120 is executed; otherwise, step 117 is returned to.
  • the hardware wallet judges whether the length of the received selection information is equal to the length of the mnemonic phrase, if it is a completed mnemonic phrase length phrase, otherwise it is an incomplete mnemonic phrase.
  • Step 120 The hardware wallet clears the data in the secure storage area, searches for a mnemonic word identifier corresponding to each mnemonic word in a mnemonic phrase preset dictionary, and joins the found mnemonic word identifiers in sequence to obtain a mnemonic phrase identifier.
  • Step 121 The hardware wallet calculates the length of the key seed according to the length of the mnemonic phrase identifier, sequentially intercepts the data of the key seed length from the mnemonic phrase identifier to obtain the key seed, and removes the mnemonic phrase identifier except the key seed The data is used as the second check value.
  • Step 122 The hardware wallet uses the first preset algorithm to calculate the key seed to obtain the first calculation result, and intercepts data with the same length as the second verification value from the starting position of the first calculation result to obtain the first comparison value, and determines the first If the second check value matches the first comparison value, step 123 is executed; otherwise, an error is reported.
  • Step 123 The hardware wallet generates the master key through the second preset algorithm according to the key seed and saves it in the secure storage area, sets the hardware wallet status to initialized, and notifies the user that the initialization is successful through the display screen and performs normal work.
  • Embodiment 3 of the present invention provides an implementation device for a hardware wallet to be initialized offline, as shown in FIG. 3, including:
  • the first receiving module 301 is configured to receive user operation trigger information
  • the first judgment module 302 is used to judge the type of operation trigger information received by the first receiving module 301, such as the prompt generation module 303 to trigger the hardware wallet creation, and the prompt search module 305 to restore the hardware wallet;
  • the prompt generation module 303 is used to prompt the user to input the length of the mnemonic phrase, generate a key seed according to the length of the received mnemonic phrase, generate a plurality of mnemonic word identifiers according to the length of the mnemonic phrase and the key seed, and according to different mnemonics in turn
  • the mnemonic identifier searches for the corresponding mnemonic word in the preset dictionary, and joins the found mnemonic words in sequence to obtain the mnemonic phrase, and generates and saves the master key according to the key seed, triggering the first setting module 304;
  • the first setting module 304 is used to set the state of the hardware wallet to initialized and the hardware wallet to work normally;
  • Prompt search module 305 is used to prompt the user to input the letter of the word, find the corresponding mnemonic word in the preset dictionary according to the received word letter and display the found mnemonic word, prompt the user to make a selection, and receive the user's selection information ;
  • the second judgment module 306 is used to judge whether the selection information received by the prompt search module is a complete mnemonic phrase, if yes, trigger the acquisition verification module 307, otherwise trigger the prompt search module 305;
  • the acquisition verification module 307 is used to acquire a key seed according to the length of the selection information input by the user, generate a master key according to the key seed and verify it;
  • the save setting module 308 is used to save the master key after the verification by the acquisition verification module 307 is passed, and set the hardware wallet status to initialized, and the hardware wallet performs normal work.
  • the device of this embodiment further includes:
  • the third judging module is used to judge whether the hardware wallet has been initialized after the hardware wallet is powered on, otherwise, the hardware wallet performs normal work, otherwise, the first receiving module 301 is triggered.
  • the third determination module is specifically used to determine whether the hardware wallet has been initialized according to the state of the hardware wallet after the hardware wallet is powered on. If the state of the hardware wallet is initialized, the hardware wallet operates normally, otherwise the first receiving module 301 is triggered.
  • the first receiving module 301 is specifically used to display an initial interaction option interface, and wait for and receive operation trigger information sent by the user through the human-machine interaction module.
  • the device of this embodiment further includes:
  • the second setting module is used to notify the user to set the identity authentication method when the first judgment module 302 judges yes, and to trigger the prompt generation module 303 if the setting is successful; and also to notify the user to set when the first judgment module 302 judges no In the identity authentication mode, if the setting is successful, the prompt search module 305 is triggered, and if the setting is unsuccessful, an error is reported.
  • the second setting module is specifically used to notify the user to set the PIN code when the first judgment module 302 judges yes, and triggers the prompt generation module 303 if the setting is successful; it is also used to notify the user when the first judgment module 302 judges no Set the PIN code. If the setting is successful, the prompt search module 305 is triggered, and if the setting is unsuccessful, an error is reported.
  • the second setting module includes:
  • the first prompt receiving unit is used to prompt the user to set a PIN code and receive the PIN code input by the user;
  • the first judgment unit is used to judge whether the PIN code is legal when the prompt receiving unit receives the PIN code input by the user, if yes, trigger the second judgment unit, otherwise trigger the prompt receiving unit;
  • the first judging unit is specifically used to judge whether the length of the PIN code is within a preset range when the prompt receiving unit receives the PIN code input by the user, it is legal to trigger the second judging unit, otherwise it is illegal to trigger the prompt Receiving unit
  • the second judgment unit is used to judge the number of times the user enters the legal PIN code. If it is twice, the third judgment unit is triggered. If it is once, the number of times the user enters the legitimate PIN code is updated. The prompt judgment unit is triggered. If it is three times, an error is reported. ;
  • the third judgment unit is used to judge whether the legal PIN codes received twice are the same. If the user identity verification is passed, the prompt generation module 303 or the prompt search module 305 is triggered; otherwise, the first prompt receiving unit is triggered.
  • the second setting module further includes:
  • the fourth judging unit is used for judging whether the number of set PIN code errors reaches a predetermined number of times when the first judging unit judges NO, if yes, an error is reported, and the first receiving module 301 is triggered, otherwise, the number of set PIN code errors is updated, and the prompt receiving unit is triggered .
  • the prompt generation module 303 includes:
  • the second prompt receiving unit is used to prompt the user to input the length of the mnemonic phrase and receive the length of the mnemonic phrase input by the user;
  • a calculation generating unit configured to calculate a key seed length and a first check value according to the mnemonic phrase length received by the second prompt receiving unit, and generate a key seed of a corresponding length according to the key seed length;
  • the calculation generating unit is specifically configured to multiply the mnemonic phrase length by a second preset value to generate the mnemonic phrase identification length; obtain the key seed length and the first check value from the mnemonic phrase identification length according to the preset ratio Length; use a true random number generator to generate a random number with the length of the key seed as the key seed;
  • the generation and storage unit is used to clear the data in the secure storage area, generate a master key through a second preset algorithm according to the key seed generated by the calculation and generation unit, and save the master key to the secure storage area;
  • the generating and storing unit is specifically used for clearing the data in the secure storage area, and performing a hash operation on the key seed generated by the calculating and generating unit according to a second preset algorithm to obtain a hash value;
  • the data of a predetermined length at the high end of the hash value is used as a master key, and the master key is stored in a secure storage area;
  • the calculation splicing unit is used to calculate the key seed using the first preset algorithm to obtain the first calculation result, and intercept the data of the first check value length from the starting position of the first calculation result to obtain the first check value, Merge the first check value after the key seed to obtain the mnemonic phrase identifier; in the mnemonic phrase identifier, successively intercept the data segment of the preset length to obtain multiple mnemonic word identifiers; according to the mnemonic word identifier in the preset dictionary Find corresponding mnemonic words, and splice the found mnemonic words in sequence to get mnemonic phrases.
  • the device of this embodiment further includes:
  • the first generating module is used to generate test words according to the mnemonic phrase and the preset dictionary obtained by the prompt generating module 303;
  • a display prompt module for displaying the test words generated by the first generating module, prompting the user to make a selection and receiving the user's selection information
  • the display prompt module is specifically used to display the mnemonic phrase through the display screen of the human-computer interaction module, display the test words generated by the first generation module on the display screen, and prompt the user to make a selection through the display screen and receive the user's selection information;
  • the fourth judgment module is used for judging whether the selection information input by the display prompt module received by the display prompt module is correct according to the mnemonic words, if yes, trigger the first setting module 304, otherwise trigger the first generating module.
  • the device of this embodiment further includes:
  • the reset module is used to reset the user selection times when the fourth judgment module judges NO;
  • the judgment update module is used to judge whether the number of user selections reaches the preset number when the fourth judgment module judges yes, and the first setting module 304 is triggered if it is, otherwise the user selection is updated and the first generation module is triggered.
  • the prompt search module 305 in this embodiment is specifically used to prompt the user to input word letters through the display screen of the human-machine interaction module.
  • the Set the dictionary to query the corresponding mnemonic words; display the mnemonic words found through the display screen of the human-computer interaction module and display information prompting the user to make a selection on the display screen, and receive the user's selection information.
  • the device of this embodiment further includes:
  • the prompt receiving module is configured to prompt the user to input the length of the mnemonic phrase when the first judgment module 302 determines that the hardware wallet is restored, and trigger the prompt search module 305 when the length of the mnemonic phrase is received;
  • the second judgment module 306 is specifically used to judge whether the length of the selection information of the prompt search module 305 is equal to the length of the mnemonic phrase, if yes, trigger the acquisition verification module 307, otherwise trigger the prompt search module 305.
  • the acquisition verification module 307 in this embodiment includes:
  • Search and splicing unit used to clear the data in the secure storage area, find the mnemonic word identifiers corresponding to each mnemonic word in the mnemonic phrase preset dictionary, and splice the found mnemonic word identifiers sequentially to obtain the mnemonic phrase identifiers ;
  • the calculation interception unit is used for calculating the length of the key seed according to the length of the mnemonic phrase identifier, sequentially intercepting the data of the key seed length from the mnemonic phrase identifier to obtain the key seed, and excluding the key seed from the mnemonic phrase identifier Data as the second check value;
  • the calculation and judgment unit is configured to perform a calculation on the key seed using the first preset algorithm to obtain a first calculation result, intercept data from the start position of the first calculation result with the same length as the second check value to obtain a first comparison value, and determine Whether the second check value matches the first comparison value, if yes, trigger the save setting module to be specific, otherwise an error will be reported;
  • the save setting module is specifically used to generate the master key through the second preset algorithm according to the key seed and save it in the secure storage area, set the hardware wallet status to initialized, notify the user through the display screen that the initialization is successful, and the hardware wallet performs normal work .
  • the technical solution provided by the present disclosure realizes that the hardware wallet can also be initialized in an offline state, and the process of using the hardware wallet is more safe and reliable.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Hardware Design (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Microelectronics & Electronic Packaging (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Power Engineering (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

本公开提供了一种硬件钱包可脱机进行初始化的实现方法及装置,该方法包括:当硬件钱包接收到创建硬件钱的操作触发信息时,根据用户输入的助记短语长度生成密钥种子,根据助记短语长度和密钥种子生成多个助记单词标识,根据助记单词标识在预设字典中查找对应的助记单词,将助记单词依次拼接得到助记短语,根据密钥种子生成主密钥并保存;将硬件钱包状态设置为已初始化;当接收到恢复硬件钱包的操作触发信息时,根据用户输入的单词字母在预设字典中查找对应的助记单词,根据选择信息的长度获取密钥种子,根据密钥种子生成主密钥并进行验证,如验证通过则保存主密钥,并将硬件钱包状态设置为已初始化。本公开的方案使用硬件钱包过程更加安全可靠。

Description

一种硬件钱包可脱机进行初始化的实现方法及装置 技术领域
本公开涉及电子产品领域,尤其涉及一种硬件钱包可脱机进行初始化的实现方法及装置。
背景技术
硬件钱包是指将数字资产私钥单独储存在一个芯片中,与互联网隔离,即插即用。现有硬件钱包必须使用有线方式与上位机进行连接,例如USB连接线。
硬件钱包使用有线方式与上位机连接时在进行初始化过程中,需要使用者在上位机中输入机密信息,一旦上位机被恶意软件所控制,将能够截取到使用者的隐私信息,进而偷盗使用者的数字资产,造成损失。
发明内容
本公开的目的是为了克服现有技术的不足,提供一种硬件钱包可脱机进行初始化的实现方法及装置。
本公开提供了一种硬件钱包可脱机进行初始化的实现方法,包括:
步骤S1:当硬件钱包接收到用户的操作触发信息时,判断所述操作触发信息的类型,如为创建硬件钱包则执行步骤S2,如为恢复硬件钱包则执行步骤S4;
步骤S2:所述硬件钱包提示用户输入助记短语长度,根据接收到的所述助记短语长度生成密钥种子,根据所述助记短语长度和所述密钥种子生成多个助记单词标识,依次根据不同的助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词依次拼接得到助记短语,根据所述密钥种子生成主密钥并保存;
步骤S3:所述硬件钱包将硬件钱包状态设置为已初始化,进行正常工作;
步骤S4:所述硬件钱包提示用户输入单词字母,根据接收到的单词字母在预设字典中查找对应的助记单词并显示所述查找到的助记单词,提示用户进行选择;
步骤S5:当所述硬件钱包接收到用户的选择信息时,所述硬件钱包判断用户输入的选择信息是否为完整的助记短语,是则执行步骤S6,否则返回步骤S4;
步骤S6:所述硬件钱包根据用户输入的选择信息的长度获取密钥种子,根据所述密钥种子生成主密钥并进行验证,如验证通过则保存所述主密钥,并将硬件钱包状态设置为已初始化,进行正常工作。
进一步地,所述步骤S1之前包括:所述硬件钱包上电,判断硬件钱包是否进行过初始化,是则所述硬件钱包进行正常工作,否则执行步骤S1。
进一步地,所述判断硬件钱包是否进行过初始化,具体为:所述硬件钱包根据所述硬件钱包状态判断是否进行过初始化,如硬件钱包状态为已初始化则所述硬件钱包进行正常工作,否则执行步骤S1。
进一步地,所述步骤S1具体为:
所述硬件钱包显示初始化交互选项界面,等待并接收用户通过人机交互模块发送的操作触发信息,判断接收到的操作触发信息的类型,如为创建硬件钱包则执行步骤S2,如为恢复硬件钱包则执行步骤S4。
进一步地,在所述步骤S1与所述步骤S2之间包括:所述硬件钱包通知用户设置身份认证方式,如设置成功则执行步骤S2,否则报错;
在所述步骤S1与所述步骤S4之间包括:所述硬件钱包通知用户设置身份认证方式,如设置成功则执行步骤S4,否则报错。
进一步地,所述硬件钱包通知用户设置身份认证方式,具体为:所述硬件钱包通知用户设置PIN码。
进一步地,所述硬件钱包通知用户设置PIN码,包括:
步骤A1:所述硬件钱包提示用户设置PIN码,当接收到用户输入的PIN码时判断PIN码是否合法,是则执行步骤A2,否则返回步骤A1;
步骤A2:所述硬件钱包判断用户输入合法PIN码的次数,如为两次则执行步骤A3,如为一次则更新用户输入合法PIN码的次数,返回步骤A1,如为三次则报错;
步骤A3:所述硬件钱包判断两次接收到的合法PIN码是否一致,是则用户身份验证通过,否则返回步骤S1。
进一步地,所述判断PIN码是否合法具体为:判断所述PIN码的长度是否在预设范围内,是则合法,否则不合法。
进一步地,在步骤A1判断为否返回步骤A1之前还包括:硬件钱包判断设置PIN码错误次数是否达到预定次数,是则报错,返回步骤S1,否则更新所述设置PIN码错误次数,返回步骤A1。
进一步地,所述步骤S2包括:
步骤S2-1:所述硬件钱包提示用户输入助记短语长度,当接收到用户输入的助记短语长度时,根据助记短语长度计算密钥种子长度和第一校验值,根据所述密钥种子长度生成对应长度的密钥种子;
步骤S2-2:所述硬件钱包清空安全存储区中的数据,根据所述密钥种子通过第二预设算法生成主密钥,并将所述主密钥保存到安全存储区中;
步骤S2-3:所述硬件钱包使用第一预设算法对密钥种子进行计算得到第一计算结果,从第一计算结果的起始位置开始截取第一校验值长度的数据得到第一校验值,将第一校验值拼接在密钥种子之后得到助记短语标识;在助记短语标识中依次截取预设长度的数据段得到多个助记单词标识;根据助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词顺序拼接得到助记短语。
进一步地,所述步骤S2-1中的所述根据助记短语长度计算密钥种子长度和第一校验值,具体为:所述硬件钱包将助记短语长度乘以第二预设值生成助记短语标识长度;根据预设比值从助记短语标识长度中获取密钥种子长度和第一校验值长度;
所述根据密钥种子长度生成对应长度的密钥种子,具体为:所述硬件钱包使用真随机数生成器生成长度为密钥种子长度的随机数作为密钥种子。
进一步地,所述步骤S2-2中的所述根据所述密钥种子通过第二预设算法生成主密钥,具体为:根据第二预设算法对密钥种子进行哈希运算得到哈希值;将得到的所述哈希值的高位端预定长度的数据作为主密钥。
进一步地,在所述步骤S2与步骤S3之间包括:
步骤P1:所述硬件钱包根据所述助记短语和所述预设字典生成考试词语并显示,提示用户进行选择;
步骤P2:当所述硬件钱包接收到用户的选择信息时,根据所述助记单词判断用户输入的选择信息是否正确,是则执行步骤S3,否则返回步骤P1。
进一步地,所述步骤P1具体为:所述硬件钱包通过人机交互模块的显示屏显示助记短语,根据主语短语和预设字典生成考试词语并在显示屏上显示,然后通过显示屏提示用户进行选择。
进一步地,所述步骤P2判断为否还包括:所述硬件钱包复位用户选择次数;
所述步骤P2与步骤S3之间还包括:所述硬件钱包判断所述用户选择次数是否到达预设次数,是则执行步骤S3,否则更新所述用户选择次数,返回步骤P1。
进一步地,所述步骤S4具体为:所述硬件钱包通过人机交互模块的显示屏提示用户输入单词字母,当接收到用户通过人机交互模块的按键输入的字母时,根据所述字母在预设字典中查询对应的助记单词;所述硬件钱包通过人机交互模块的显示屏显示查询到的助记单词并在显示屏上显示提示用户进行选择的信息。
进一步地,所述步骤S4之前包括:所述硬件钱包提示用户输入助记短语长度,当接收到助记短语长度时执行步骤S4;
所述步骤S5具体为:当所述硬件钱包接收到用户的选择信息时,所述硬件钱包判断用户输入的选择信息的长度是否等于所述助记短语长度,是则执行步骤S6,否则返回步骤S4。
进一步地,所述步骤S6包括:
步骤S6-1:所述硬件钱包清空安全存储区中的数据,在助记短语预设字典中查找与各个助记单词对应的助记单词标识,将查找到的助记单词标识顺序拼接得到助记短语标识;
步骤S6-2:所述硬件钱包根据助记短语标识的长度计算密钥种子长度,从助记短语标识中顺序截取密钥种子长度的数据得到密钥种子,将助记短语标识中除密钥种子之外的数据作为第二校验值;
步骤S6-3:所述硬件钱包使用第一预设算法对密钥种子进行运算得到第一计算结果,从第一计算结果的开始位置截取长度与第二校验值相同的数据得到第一比较值,判断第二校验值与第一比较值是否匹配,是则执行步骤S6-4,否则报错;
步骤S6-4:所述硬件钱包根据密钥种子通过第二预设算法生成主密钥并保存到安全存储区中,将硬件钱包状态设置为已初始化,通过显示屏通知用户初始化成功,进行正常工作。
本公开又提供了一种硬件钱包可脱机进行初始化的实现装置,包括:
第一接收模块,用于接收用户的操作触发信息;
第一判断模块,用于判断所述第一接收模块接收到的操作触发信息的类型,如为创建硬件钱包则触发提示生成模块,如为恢复硬件钱包则触发提示查找模块;
所述提示生成模块,用于提示用户输入助记短语长度,根据接收到的所述助记短语长度生成密钥种子,根据所述助记短语长度和所述密钥种子生成多个助记单词标识,依次根据不同的助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词依次拼接得到助记短语,根据所述密钥种子生成主密钥并保存,触发第一设置模块;
所述第一设置模块,用于将硬件钱包状态设置为已初始化,硬件钱包进行正常工作;
所述提示查找模块,用于提示用户输入单词字母,根据接收到的单词字母在预设字典中查找对应的助记单词并显示所述查找到的助记单词,提示用户进行选择,并接收用户的选择信息;
第二判断模块,用于判断所述提示查找模块接收到的选择信息是否为完整的助记短语,是则触发获取验证模块,否则触发所述提示查找模块;
所述获取验证模块,用于根据用户输入的选择信息的长度获取密钥种子,根据所述密钥种子生成主密钥并进行验证;
保存设置模块,用于在所述获取验证模块验证通过后保存所述主密钥,并将硬件钱包状态设置为已初始化,硬件钱包进行正常工作。
进一步地,所述装置还包括:
第三判断模块,用于在所述硬件钱包上电后判断硬件钱包是否进行过 初始化,是则所述硬件钱包进行正常工作,否则触发所述第一接收模块。
进一步地,所述第三判断模块具体用于在所述硬件钱包上电后根据所述硬件钱包状态判断是否进行过初始化,如硬件钱包状态为已初始化则所述硬件钱包进行正常工作,否则触发所述第一接收模块。
进一步地,所述第一接收模块,具体用于显示初始化交互选项界面,等待并接收用户通过人机交互模块发送的操作触发信息。
进一步地,所述装置还包括:
第二设置模块,用于在所述第一判断模块判断为是时通知用户设置身份认证方式,如设置成功则触发所述提示生成模块;还用于在所述第一判断模块判断为否时通知用户设置身份认证方式,如设置成功则触发所述提示查找模块,设置不成功则报错。
进一步地,所述第二设置模块具体用于在所述第一判断模块判断为是时通知用户设置PIN码,如设置成功则触发所述提示生成模块;还用于在所述第一判断模块判断为否时通知用户设置PIN码,如设置成功则触发所述提示查找模块,设置不成功则报错。
进一步地,所述第二设置模块包括:
第一提示接收单元,用于提示用户设置PIN码,并接收用户输入的PIN码;
第一判断单元,用于当所述提示接收单元接收到用户输入的PIN码时判断PIN码是否合法,是则触发第二判断单元,否则触发所述提示接收单元;
所述第二判断单元,用于判断用户输入合法PIN码的次数,如为两次则触发第三判断单元,如为一次则更新用户输入合法PIN码的次数,触发所述提示判断单元,如为三次则报错;
所述第三判断单元,用于判断两次接收到的合法PIN码是否一致,是则用户身份验证通过,触发所述提示生成模块或所述提示查找模块,否则触发所述提示接收单元。
进一步地,所述第一判断单元具体用于当所述提示接收单元接收到用户输入的PIN码时判断所述PIN码的长度是否在预设范围内,是则合法,触发第二判断单元,否则不合法,触发所述提示接收单元。
进一步地,所述第二设置模块还包括:
第四判断单元,用于在第一判断单元判断为否时判断设置PIN码错误次数是否达到预定次数,是则报错,触发所述第一接收模块,否则更新所述设置PIN码错误次数,触发所述第一提示接收单元。
进一步地,所述提示生成模块包括:
第二提示接收单元,用于提示用户输入助记短语长度,并接收用户输入的助记短语长度;
计算生成单元,用于根据所述第二提示接收单元接收到的助记短语长度计算密钥种子长度和第一校验值,根据所述密钥种子长度生成对应长度的密钥种子;
生成保存单元,用于清空安全存储区中的数据,根据所述计算生成单元生成的密钥种子通过第二预设算法生成主密钥,并将所述主密钥保存到安全存储区中;
计算拼接单元,用于使用第一预设算法对密钥种子进行计算得到第一计算结果,从第一计算结果的起始位置开始截取第一校验值长度的数据得到第一校验值,将第一校验值拼接在密钥种子之后得到助记短语标识;在助记短语标识中依次截取预设长度的数据段得到多个助记单词标识;根据助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词顺序拼接得到助记短语,触发所述第一设置模块。
进一步地,所述计算生成单元具体用于将助记短语长度乘以第二预设值生成助记短语标识长度;根据预设比值从助记短语标识长度中获取密钥种子长度和第一校验值长度;使用真随机数生成器生成长度为密钥种子长度的随机数作为密钥种子。
进一步地,所述生成保存单元具体用于清空安全存储区中的数据,根据第二预设算法对所述计算生成单元生成的密钥种子进行哈希运算得到哈希值;将得到的所述哈希值的高位端预定长度的数据作为主密钥,并将所述主密钥保存到安全存储区中。
进一步地,所述装置还包括:
第一生成模块,用于根据所述提示生成模块得到的助记短语和所述预设字典生成考试词语;
显示提示模块,用于显示所述第一生成模块生成的考试词语,提示用户进行选择并接收用户的选择信息;
第四判断模块,用于根据所述助记单词判断所述显示提示模块接收到的用户输入的选择信息是否正确,是则触发所述第一设置模块,否则触发所述第一生成模块。
进一步地,所述显示提示模块具体用于通过人机交互模块的显示屏显示助记短语,在显示屏上显示所述第一生成模块生成的考试词语,通过显示屏提示用户进行选择并接收用户的选择信息。
进一步地,所述装置还包括:
复位模块,用于当所述第四判断模块判断为否时复位用户选择次数;
判断更新模块,用于在所述第四判断模块判断为是时判断所述用户选择次数是否到达预设次数,是则触发所述第一设置模块,否则更新所述用户选择次数,触发所述第一生成模块。
进一步地,所述提示查找模块具体用于通过人机交互模块的显示屏提示用户输入单词字母,当接收到用户通过人机交互模块的按键输入的字母时,根据所述字母在预设字典中查询对应的助记单词;通过人机交互模块的显示屏显示查询到的助记单词并在显示屏上显示提示用户进行选择的信息,并接收用户的选择信息。
进一步地,所述装置还包括:
提示接收模块,用于在所述第一判断模块判断为恢复硬件钱包时提示用户输入助记短语长度,当接收到助记短语长度时触发所述提示查找模块;
所述第二判断模块具体用于判断所述提示查找模块的选择信息的长度是否等于所述助记短语长度,是则触发获取验证模块,否则触发所述提示查找模块。
进一步地,所述获取验证模块包括:
查找拼接单元,用于清空安全存储区中的数据,在助记短语预设字典中查找与各个助记单词对应的助记单词标识,将查找到的助记单词标识顺序拼接得到助记短语标识;
计算截取单元,用于根据助记短语标识的长度计算密钥种子长度,从助记短语标识中顺序截取密钥种子长度的数据得到密钥种子,将助记短语 标识中除密钥种子之外的数据作为第二校验值;
计算判断单元,用于使用第一预设算法对密钥种子进行运算得到第一计算结果,从第一计算结果的开始位置截取长度与第二校验值相同的数据得到第一比较值,判断第二校验值与第一比较值是否匹配,是则触发所述保存设置模块具体,否则报错;
所述保存设置模块具体用于根据密钥种子通过第二预设算法生成主密钥并保存到安全存储区中,将硬件钱包状态设置为已初始化,通过显示屏通知用户初始化成功,硬件钱包进行正常工作。
本公开与现有技术相比,具有以下优点:
本公开技术方案实现了硬件钱包在脱机状态下同样能够进行初始化操作,使用硬件钱包过程更加安全可靠。
附图说明
图1为本发明实施例一提供的一种硬件钱包可脱机进行初始化的实现方法流程图;
图2为本发明实施例二提供的一种硬件钱包可脱机进行初始化的实现方法流程图;
图3为本发明实施例三提供的一种硬件钱包可脱机进行初始化的实现装置方框图。
具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
实施例一
本发明实施例一提供了一种硬件钱包可脱机进行初始化的实现方法,如图1所示,包括:
步骤S1:当硬件钱包接收到用户的操作触发信息时,判断操作触发信息的类型,如为创建硬件钱包则执行步骤S2,如为恢复硬件钱包则执行步 骤S4。
优选的,在步骤S1之前包括:硬件钱包上电,判断硬件钱包是否进行过初始化,是则执行步骤S1,否则硬件钱包进行正常工作。
其中,判断硬件钱包是否进行过初始化,具体为:硬件钱包根据硬件钱包状态判断是否进行过初始化,如硬件钱包状态为已初始化则硬件钱包进行正常工作,否则执行步骤S1。
步骤S2:硬件钱包提示用户输入助记短语长度,根据接收到的助记短语长度生成密钥种子,根据助记短语长度和密钥种子生成多个助记单词标识,依次根据不同的助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词依次拼接得到助记短语,根据密钥种子生成主密钥并保存。
步骤S3:硬件钱包将硬件钱包状态设置为已初始化,进行正常工作。
步骤S4:硬件钱包提示用户输入单词字母,根据接收到的单词字母在预设字典中查找对应的助记单词并显示查找到的助记单词,提示用户进行选择。
步骤S5:当硬件钱包接收到用户的选择信息时,硬件钱包判断用户输入的选择信息是否为完整的助记短语,是则执行步骤S6,否则返回步骤S4。
步骤S6:硬件钱包根据用户输入的选择信息的长度获取密钥种子,根据密钥种子生成主密钥并进行验证,如验证通过则保存主密钥,并将硬件钱包状态设置为已初始化,进行正常工作。
在本实施例中,步骤S6中如对主密钥进行验证未通过则报错。
可选的,在本实施例中,步骤S1与步骤S2之间包括:硬件钱包通知用户设置身份认证方式,如设置成功则执行步骤S2,否则报错。
在步骤S1与步骤S4之间包括:硬件钱包通知用户设置身份认证方式,如设置成功则执行步骤S4,否则报错。
本实施例中的身份认证方式包括但不限于PIN码、指纹、虹膜等;具体的以PIN码为例进行详述。
具体的,硬件钱包通知用户设置PIN码,包括:
步骤A1:硬件钱包提示用户设置PIN码,当接收到用户输入的PIN 码时判断PIN码是否合法,是则执行步骤A2,否则返回步骤A1。
可选的,判断PIN码是否合法具体为:判断PIN码的长度是否在预设范围内,是则合法,否则不合法。
在步骤A1判断为否返回步骤A1之前还包括:硬件钱包判断设置PIN码错误次数是否达到预定次数,是则报错,返回步骤S1,否则更新设置PIN码错误次数,返回步骤A1。
步骤A2:硬件钱包判断用户输入合法PIN码的次数,如为两次则执行步骤A3,如为一次则更新用户输入合法PIN码的次数,返回步骤A1,如为三次则报错。
步骤A3:硬件钱包判断两次接收到的合法PIN码是否一致,是则用户身份验证通过,否则返回步骤S1。
实施例二
本发明实施例二提供了一种硬件钱包可脱机进行初始化的实现方法,如图2所示,包括:
步骤101:硬件钱包上电,判断是否进行过初始化,是则硬件钱包进行正常工作,否则执行步骤102。
可选的,在本实施例中,硬件钱包根据硬件钱包状态判断是否进行过初始化,如硬件钱包状态为已初始化则执行步骤124,否则执行步骤102。
步骤102:硬件钱包显示初始化交互选项界面,等待并接收用户通过人机交互模块发送的操作触发信息,判断接收到的操作触发信息的类型,如为创建硬件钱包则执行步骤103,如为恢复硬件钱包则执行步骤113。
在本实施例中,人机交互模块包括按键和显示屏;硬件钱包通过显示屏显示初始化交互选项界面,然后用户通过按键和显示屏输入操作触发信息。
步骤103:硬件钱包提示用户设置PIN码,当接收到用户输入的PIN码时判断PIN码是否合法,是则执行步骤104,否则返回步骤103。
具体的,步骤103包括:硬件钱包通过人机交互模块的显示屏提示用户设置PIN码,当接收到用户通过人机交互模块的按键输入的PIN码时,判断PIN码是否合法,是则执行步骤104,否则返回步骤103。
在本实施例中,判断PIN码是否合法具体为:判断PIN码的长度是否 在预设范围内,是则合法,否则不合法。
优选的,在步骤103判断为否返回步骤103之前还包括:硬件钱包判断设置PIN码错误次数是否达到预定次数,是则通过显示屏显示错误信息,返回步骤102,否则更新设置PIN码错误次数,返回步骤103。
例如更新设置PIN码错误次数可以为更新设置PIN码错误次数自加1。
步骤104:硬件钱包判断用户输入合法PIN码的次数,如为两次则执行步骤105,如为一次则更新用户输入合法PIN码的次数,返回步骤103,如为三次则报错。
具体的,本实施例中的报错可以为通过显示屏显示错误信息;例如更新用户输入合法PIN码的次数可以为更新用户输入合法PIN码的次数自加1。
步骤105:硬件钱包判断两次接收到的合法PIN码是否一致,是则执行步骤106,否则返回步骤102。
步骤106:硬件钱包提示用户输入助记短语长度,当接收到用户输入的助记短语长度时,根据助记短语长度计算密钥种子长度和第一校验值长度,根据密钥种子长度生成对应长度的密钥种子。
优选的,本实施例中的密钥种子为一随机数;硬件钱包通过人机交互模块中的显示屏提示用户输入助记短语长度。
可选的,助记短语长度具体为助记短语中包含的助记单词的个数,例如可以为12或者15或者18或者21或者24。
具体的,硬件钱包将助记短语长度乘以第二预设值生成助记短语标识长度;根据预设比值从助记短语标识长度中获取密钥种子长度和第一校验值长度。
在本实施例中,第二预设值为助记短语中每个助记单词在预设字典中助记单词标识的比特数;例如第二预设值为11bit,助记短语长度为24,则得到的助记短语标识长度为264bit。
由于助记短语标识长度=密钥种子长度+第一校验值长度,且密钥种子长度与第一校验值长度的预设比值为32,根据上述关系,可以根据助记短语标识长度计算出密钥种子长度和第一校验值长度;本实施例中,密钥种子长度为256bit,第一校验值长度为8bit。
随后硬件钱包使用真随机数生成器生成长度为密钥种子长度(即256bit)的随机数作为密钥种子。
步骤107:硬件钱包清空安全存储区中的数据,根据密钥种子通过第二预设算法生成主密钥,并将主密钥保存到安全存储区中。
具体地,步骤107中的根据密钥种子通过第二预设算法生成主密钥具体为:根据第二预设算法对密钥种子进行哈希运算得到哈希值;将得到的哈希值的高位端预定长度的数据作为主密钥。
本实施例中,第二预设算法优选为HMAC-SHA512算法。
本实施例中,高位端预定长度的数据优选为高256比特的数据,低位端预定长度的数据优选为低256比特的数据。
步骤108:硬件钱包使用第一预设算法对密钥种子进行计算得到第一计算结果,从第一计算结果的起始位置开始截取第一校验值长度的数据得到第一校验值,将第一校验值拼接在密钥种子之后得到助记短语标识;在助记短语标识中依次截取预设长度的数据段得到多个助记单词标识;根据助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词顺序拼接得到助记短语。
例如,本实施例中的预设字典里有2048个单词。
优选的,创建硬件钱包指令中还包括:语言类型;语言类型具体包括:简体中文、繁体中文和英语。
可选的,在本实施例,步骤107与步骤108的顺序可调换。
步骤109:硬件钱包显示助记短语,根据助记短语和预设字典生成考试词语并显示,提示用户进行选择。
在本实施例中,步骤109具体为:硬件钱包通过人机交互模块的显示屏显示助记短语,根据主语短语和预设字典生成考试词语并在显示屏上显示,然后通过显示屏提示用户进行选择。
步骤110:当硬件钱包接收到用户的选择信息时,根据助记单词判断用户输入的选择信息是否正确,是则执行步骤111,否则复位用户选择次数,返回步骤109。
例如,本实施例中的用户选择次数初始值为0。
步骤111:硬件钱包判断用户选择次数是否达到预设次数,是则执行 步骤112,否则更新用户选择次数,返回步骤109。
例如,本实施例中的更新用户选择次数可以为用户选择次数自加1。
步骤112:硬件钱包将硬件钱包状态设置为已初始化,通过显示屏通知用户初始化成功,进行正常工作。
步骤113:硬件钱包提示用户设置PIN码,当接收到用户输入的PIN码时判断PIN码是否合法,是则执行步骤114,否则返回步骤113。
具体的,步骤113包括:硬件钱包通过人机交互模块的显示屏提示用户设置PIN码,当接收到用户通过人机交互模块的按键输入的PIN码时,判断PIN码是否合法,是则执行步骤114,否则返回步骤113。
在本实施例中,判断PIN码是否合法具体为:判断PIN码的长度是否在预设范围内,是则合法,否则不合法。
优选的,在步骤113判断为否返回步骤113之前还包括:硬件钱包判断设置PIN码错误次数是否达到预定次数,是则通过显示屏显示错误信息,返回步骤102,否则更新设置PIN码错误次数,返回步骤113。
例如更新设置PIN码错误次数可以为更新设置PIN码错误次数自加1。
步骤114:硬件钱包判断用户输入合法PIN码的次数,如为两次则执行步骤115,如为一次则更新用户输入合法PIN码的次数,返回步骤113,如为三次则报错。
具体的,本实施例中的报错可以为通过显示屏显示错误信息;例如更新用户输入合法PIN码的次数可以为更新用户输入合法PIN码的次数自加1。
步骤115:硬件钱包判断两次输入的合法PIN码是否一致,是则执行步骤116,否则返回步骤101。
步骤116:硬件钱包提示用户输入助记短语长度,当接收到助记短语长度时执行步骤117。
在本实施例中,步骤116具体为:硬件钱包通过人机交互模块的显示屏提示用户输入助记短语长度。
步骤117:硬件钱包提示用户输入单词字母,当接收到单词字母时,根据单词字母在预设字典中查询对应的助记单词。
在本实施例中,步骤117具体为:硬件钱包通过人机交互模块的显示 屏提示用户输入单词字母,当接收到用户通过人机交互模块的按键输入的字母时,根据单词字母在预设字典中查询对应的助记单词。
步骤118:硬件钱包显示查询到的助记单词并提示用户进行选择。
具体的,在本实施例中,硬件钱包通过人机交互模块的显示屏显示查询到的助记单词并在显示屏上显示提示用户进行选择的信息。
步骤119:当硬件钱包接收到用户的选择信息时根据助记短语长度判断接收到的选择信息是否为完整的助记短语,是则执行步骤120,否则返回步骤117。
具体的,硬件钱包判断接收到的选择信息的长度是否等于助记短语长度,是则为完成的助记短语长度短语,否则为不完整的助记短语。
步骤120:硬件钱包清空安全存储区中的数据,在助记短语预设字典中查找与各个助记单词对应的助记单词标识,将查找到的助记单词标识顺序拼接得到助记短语标识。
步骤121:硬件钱包根据助记短语标识的长度计算密钥种子长度,从助记短语标识中顺序截取密钥种子长度的数据得到密钥种子,将助记短语标识中除密钥种子之外的数据作为第二校验值。
步骤122:硬件钱包使用第一预设算法对密钥种子进行运算得到第一计算结果,从第一计算结果的开始位置截取长度与第二校验值相同的数据得到第一比较值,判断第二校验值与第一比较值是否匹配,是则执行步骤123,否则报错。
步骤123:硬件钱包根据密钥种子通过第二预设算法生成主密钥并保存到安全存储区中,将硬件钱包状态设置为已初始化,通过显示屏通知用户初始化成功,进行正常工作。
实施例三
本发明实施例三提供一种硬件钱包可脱机进行初始化的实现装置,如图3所示,包括:
第一接收模块301,用于接收用户的操作触发信息;
第一判断模块302,用于判断第一接收模块301接收到的操作触发信息的类型,如为创建硬件钱包则触发提示生成模块303,如为恢复硬件钱包则触发提示查找模块305;
提示生成模块303,用于提示用户输入助记短语长度,根据接收到的助记短语长度生成密钥种子,根据助记短语长度和密钥种子生成多个助记单词标识,依次根据不同的助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词依次拼接得到助记短语,根据密钥种子生成主密钥并保存,触发第一设置模块304;
第一设置模块304,用于将硬件钱包状态设置为已初始化,硬件钱包进行正常工作;
提示查找模块305,用于提示用户输入单词字母,根据接收到的单词字母在预设字典中查找对应的助记单词并显示查找到的助记单词,提示用户进行选择,并接收用户的选择信息;
第二判断模块306,用于判断提示查找模块接收到的选择信息是否为完整的助记短语,是则触发获取验证模块307,否则触发提示查找模块305;
获取验证模块307,用于根据用户输入的选择信息的长度获取密钥种子,根据密钥种子生成主密钥并进行验证;
保存设置模块308,用于在获取验证模块307验证通过后保存主密钥,并将硬件钱包状态设置为已初始化,硬件钱包进行正常工作。
可选的,本实施例的装置还包括:
第三判断模块,用于在硬件钱包上电后判断硬件钱包是否进行过初始化,是则硬件钱包进行正常工作,否则触发第一接收模块301。
其中,第三判断模块具体用于在硬件钱包上电后根据硬件钱包状态判断是否进行过初始化,如硬件钱包状态为已初始化则硬件钱包进行正常工作,否则触发第一接收模块301。
在本实施例中,第一接收模块301,具体用于显示初始化交互选项界面,等待并接收用户通过人机交互模块发送的操作触发信息。
可选的,本实施例的装置还包括:
第二设置模块,用于在第一判断模块302判断为是时通知用户设置身份认证方式,如设置成功则触发提示生成模块303;还用于在第一判断模块302判断为否时通知用户设置身份认证方式,如设置成功则触发提示查找模块305,设置不成功则报错。
其中,第二设置模块具体用于在第一判断模块302判断为是时通知用 户设置PIN码,如设置成功则触发提示生成模块303;还用于在第一判断模块302判断为否时通知用户设置PIN码,如设置成功则触发提示查找模块305,设置不成功则报错。
进一步地,第二设置模块包括:
第一提示接收单元,用于提示用户设置PIN码,并接收用户输入的PIN码;
第一判断单元,用于当提示接收单元接收到用户输入的PIN码时判断PIN码是否合法,是则触发第二判断单元,否则触发提示接收单元;
优选的,第一判断单元具体用于当提示接收单元接收到用户输入的PIN码时判断PIN码的长度是否在预设范围内,是则合法,触发第二判断单元,否则不合法,触发提示接收单元;
第二判断单元,用于判断用户输入合法PIN码的次数,如为两次则触发第三判断单元,如为一次则更新用户输入合法PIN码的次数,触发提示判断单元,如为三次则报错;
第三判断单元,用于判断两次接收到的合法PIN码是否一致,是则用户身份验证通过,触发提示生成模块303或提示查找模块305,否则触发第一提示接收单元。
可选的,第二设置模块还包括:
第四判断单元,用于在第一判断单元判断为否时判断设置PIN码错误次数是否达到预定次数,是则报错,触发第一接收模块301,否则更新设置PIN码错误次数,触发提示接收单元。
在本实施例中,提示生成模块303包括:
第二提示接收单元,用于提示用户输入助记短语长度,并接收用户输入的助记短语长度;
计算生成单元,用于根据第二提示接收单元接收到的助记短语长度计算密钥种子长度和第一校验值,根据密钥种子长度生成对应长度的密钥种子;
进一步地,计算生成单元具体用于将助记短语长度乘以第二预设值生成助记短语标识长度;根据预设比值从助记短语标识长度中获取密钥种子长度和第一校验值长度;使用真随机数生成器生成长度为密钥种子长度的 随机数作为密钥种子;
生成保存单元,用于清空安全存储区中的数据,根据计算生成单元生成的密钥种子通过第二预设算法生成主密钥,并将主密钥保存到安全存储区中;
进一步地,所述生成保存单元具体用于清空安全存储区中的数据,根据第二预设算法对所述计算生成单元生成的密钥种子进行哈希运算得到哈希值;将得到的所述哈希值的高位端预定长度的数据作为主密钥,并将所述主密钥保存到安全存储区中;
计算拼接单元,用于使用第一预设算法对密钥种子进行计算得到第一计算结果,从第一计算结果的起始位置开始截取第一校验值长度的数据得到第一校验值,将第一校验值拼接在密钥种子之后得到助记短语标识;在助记短语标识中依次截取预设长度的数据段得到多个助记单词标识;根据助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词顺序拼接得到助记短语。
可选的,本实施例的装置还包括:
第一生成模块,用于根据提示生成模块303得到的助记短语和预设字典生成考试词语;
显示提示模块,用于显示第一生成模块生成的考试词语,提示用户进行选择并接收用户的选择信息;
进一步地,显示提示模块具体用于通过人机交互模块的显示屏显示助记短语,在显示屏上显示第一生成模块生成的考试词语,通过显示屏提示用户进行选择并接收用户的选择信息;
第四判断模块,用于根据助记单词判断显示提示模块接收到的用户输入的选择信息是否正确,是则触发第一设置模块304,否则触发第一生成模块。
可选的,本实施例的装置还包括:
复位模块,用于当第四判断模块判断为否时复位用户选择次数;
判断更新模块,用于在第四判断模块判断为是时判断用户选择次数是否到达预设次数,是则触发第一设置模块304,否则更新用户选择次数,触发第一生成模块。
优选的,在本实施例中的提示查找模块305具体用于通过人机交互模块的显示屏提示用户输入单词字母,当接收到用户通过人机交互模块的按键输入的字母时,根据字母在预设字典中查询对应的助记单词;通过人机交互模块的显示屏显示查询到的助记单词并在显示屏上显示提示用户进行选择的信息,并接收用户的选择信息。
可选的,本实施例的装置还包括:
提示接收模块,用于在第一判断模块302判断为恢复硬件钱包时提示用户输入助记短语长度,当接收到助记短语长度时触发提示查找模块305;
第二判断模块306具体用于判断提示查找模块305的选择信息的长度是否等于助记短语长度,是则触发获取验证模块307,否则触发提示查找模块305。
优选的,本实施例中的获取验证模块307包括:
查找拼接单元,用于清空安全存储区中的数据,在助记短语预设字典中查找与各个助记单词对应的助记单词标识,将查找到的助记单词标识顺序拼接得到助记短语标识;
计算截取单元,用于根据助记短语标识的长度计算密钥种子长度,从助记短语标识中顺序截取密钥种子长度的数据得到密钥种子,将助记短语标识中除密钥种子之外的数据作为第二校验值;
计算判断单元,用于使用第一预设算法对密钥种子进行运算得到第一计算结果,从第一计算结果的开始位置截取长度与第二校验值相同的数据得到第一比较值,判断第二校验值与第一比较值是否匹配,是则触发保存设置模块具体,否则报错;
保存设置模块具体用于根据密钥种子通过第二预设算法生成主密钥并保存到安全存储区中,将硬件钱包状态设置为已初始化,通过显示屏通知用户初始化成功,硬件钱包进行正常工作。
本公开提供的技术方案实现了硬件钱包在脱机状态下同样能够进行初始化操作,使用硬件钱包过程更加安全可靠。
以上所述,仅为本发明较佳的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明公开的技术范围内,可轻易想到的变化或替换,都应涵盖在本发明的保护范围之内。因此,本 发明的保护范围应该以权利要求的保护范围为准。

Claims (20)

  1. 一种硬件钱包可脱机进行初始化的实现方法,其特征在于,包括:
    步骤S1:当硬件钱包接收到用户的操作触发信息时,判断所述操作触发信息的类型,如为创建硬件钱包则执行步骤S2,如为恢复硬件钱包则执行步骤S4;
    步骤S2:所述硬件钱包提示用户输入助记短语长度,根据接收到的所述助记短语长度生成密钥种子,根据所述助记短语长度和所述密钥种子生成多个助记单词标识,依次根据不同的助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词依次拼接得到助记短语,根据所述密钥种子生成主密钥并保存;
    步骤S3:所述硬件钱包将硬件钱包状态设置为已初始化,进行正常工作;
    步骤S4:所述硬件钱包提示用户输入单词字母,根据接收到的单词字母在预设字典中查找对应的助记单词并显示所述查找到的助记单词,提示用户进行选择;
    步骤S5:当所述硬件钱包接收到用户的选择信息时,所述硬件钱包判断用户输入的选择信息是否为完整的助记短语,是则执行步骤S6,否则返回步骤S4;
    步骤S6:所述硬件钱包根据用户输入的选择信息的长度获取密钥种子,根据所述密钥种子生成主密钥并进行验证,如验证通过则保存所述主密钥,并将硬件钱包状态设置为已初始化,进行正常工作。
  2. 如权利要求1所述的方法,其特征在于,所述步骤S1之前包括:所述硬件钱包上电,判断硬件钱包是否进行过初始化,是则所述硬件钱包进行正常工作,否则执行步骤S1。
  3. 如权利要求1所述的方法,其特征在于,所述步骤S1具体为:
    所述硬件钱包显示初始化交互选项界面,等待并接收用户通过人机交互模块发送的操作触发信息,判断接收到的操作触发信息的类型,如为创建硬件钱包则执行步骤S2,如为恢复硬件钱包则执行步骤S4。
  4. 如权利要求1所述的方法,其特征在于,在所述步骤S1与所述步骤S2之间包括:所述硬件钱包通知用户设置身份认证方式,如设置成功 则执行步骤S2,否则报错;
    在所述步骤S1与所述步骤S4之间包括:所述硬件钱包通知用户设置身份认证方式,如设置成功则执行步骤S4,否则报错。
  5. 如权利要求1所述的方法,其特征在于,所述步骤S2包括:
    步骤S2-1:所述硬件钱包提示用户输入助记短语长度,当接收到用户输入的助记短语长度时,根据助记短语长度计算密钥种子长度和第一校验值,根据所述密钥种子长度生成对应长度的密钥种子;
    步骤S2-2:所述硬件钱包清空安全存储区中的数据,根据所述密钥种子通过第二预设算法生成主密钥,并将所述主密钥保存到安全存储区中;
    步骤S2-3:所述硬件钱包使用第一预设算法对密钥种子进行计算得到第一计算结果,从第一计算结果的起始位置开始截取第一校验值长度的数据得到第一校验值,将第一校验值拼接在密钥种子之后得到助记短语标识;在助记短语标识中依次截取预设长度的数据段得到多个助记单词标识;根据助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词顺序拼接得到助记短语。
  6. 如权利要求5所述的方法,其特征在于,所述步骤S2-1中的所述根据助记短语长度计算密钥种子长度和第一校验值,具体为:所述硬件钱包将助记短语长度乘以第二预设值生成助记短语标识长度;根据预设比值从助记短语标识长度中获取密钥种子长度和第一校验值长度;
    所述根据密钥种子长度生成对应长度的密钥种子,具体为:所述硬件钱包使用真随机数生成器生成长度为密钥种子长度的随机数作为密钥种子。
  7. 如权利要求5所述的方法,其特征在于,所述步骤S2-2中的所述根据所述密钥种子通过第二预设算法生成主密钥,具体为:根据第二预设算法对密钥种子进行哈希运算得到哈希值;将得到的所述哈希值的高位端预定长度的数据作为主密钥。
  8. 如权利要求1所述的方法,其特征在于,在所述步骤S2与步骤S3之间包括:
    步骤P1:所述硬件钱包根据所述助记短语和所述预设字典生成考试词语并显示,提示用户进行选择;
    步骤P2:当所述硬件钱包接收到用户的选择信息时,根据所述助记单词判断用户输入的选择信息是否正确,是则执行步骤S3,否则返回步骤P1。
  9. 如权利要求8所述的方法,其特征在于,
    所述步骤P1具体为:所述硬件钱包通过人机交互模块的显示屏显示助记短语,根据主语短语和预设字典生成考试词语并在显示屏上显示,然后通过显示屏提示用户进行选择。
  10. 如权利要求1所述的方法,其特征在于,所述步骤S4具体为:所述硬件钱包通过人机交互模块的显示屏提示用户输入单词字母,当接收到用户通过人机交互模块的按键输入的字母时,根据所述字母在预设字典中查询对应的助记单词;所述硬件钱包通过人机交互模块的显示屏显示查询到的助记单词并在显示屏上显示提示用户进行选择的信息。
  11. 一种硬件钱包可脱机进行初始化的实现装置,其特征在于,包括:
    第一接收模块,用于接收用户的操作触发信息;
    第一判断模块,用于判断所述第一接收模块接收到的操作触发信息的类型,如为创建硬件钱包则触发提示生成模块,如为恢复硬件钱包则触发提示查找模块;
    所述提示生成模块,用于提示用户输入助记短语长度,根据接收到的所述助记短语长度生成密钥种子,根据所述助记短语长度和所述密钥种子生成多个助记单词标识,依次根据不同的助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词依次拼接得到助记短语,根据所述密钥种子生成主密钥并保存,触发第一设置模块;
    所述第一设置模块,用于将硬件钱包状态设置为已初始化,硬件钱包进行正常工作;
    所述提示查找模块,用于提示用户输入单词字母,根据接收到的单词字母在预设字典中查找对应的助记单词并显示所述查找到的助记单词,提示用户进行选择,并接收用户的选择信息;
    第二判断模块,用于判断所述提示查找模块接收到的选择信息是否为完整的助记短语,是则触发获取验证模块,否则触发所述提示查找模块;
    所述获取验证模块,用于根据用户输入的选择信息的长度获取密钥种 子,根据所述密钥种子生成主密钥并进行验证;
    保存设置模块,用于在所述获取验证模块验证通过后保存所述主密钥,并将硬件钱包状态设置为已初始化,硬件钱包进行正常工作。
  12. 如权利要求11所述的装置,其特征在于,还包括:
    第三判断模块,用于在所述硬件钱包上电后判断硬件钱包是否进行过初始化,是则所述硬件钱包进行正常工作,否则触发所述第一接收模块。
  13. 如权利要求11所述的装置,其特征在于,所述第一接收模块,具体用于显示初始化交互选项界面,等待并接收用户通过人机交互模块发送的操作触发信息。
  14. 如权利要求11所述的装置,其特征在于,还包括:
    第二设置模块,用于在所述第一判断模块判断为是时通知用户设置身份认证方式,如设置成功则触发所述提示生成模块;还用于在所述第一判断模块判断为否时通知用户设置身份认证方式,如设置成功则触发所述提示查找模块,设置不成功则报错。
  15. 如权利要求11所述的装置,其特征在于,所述提示生成模块包括:
    第二提示接收单元,用于提示用户输入助记短语长度,并接收用户输入的助记短语长度;
    计算生成单元,用于根据所述第二提示接收单元接收到的助记短语长度计算密钥种子长度和第一校验值,根据所述密钥种子长度生成对应长度的密钥种子;
    生成保存单元,用于清空安全存储区中的数据,根据所述计算生成单元生成的密钥种子通过第二预设算法生成主密钥,并将所述主密钥保存到安全存储区中;
    计算拼接单元,用于使用第一预设算法对密钥种子进行计算得到第一计算结果,从第一计算结果的起始位置开始截取第一校验值长度的数据得到第一校验值,将第一校验值拼接在密钥种子之后得到助记短语标识;在助记短语标识中依次截取预设长度的数据段得到多个助记单词标识;根据助记单词标识在预设字典中查找对应的助记单词,并将查找到的助记单词顺序拼接得到助记短语,触发所述第一设置模块。
  16. 如权利要求15所述的装置,其特征在于,所述计算生成单元具体用于将助记短语长度乘以第二预设值生成助记短语标识长度;根据预设比值从助记短语标识长度中获取密钥种子长度和第一校验值长度;使用真随机数生成器生成长度为密钥种子长度的随机数作为密钥种子。
  17. 如权利要求15所述的装置,其特征在于,所述生成保存单元具体用于清空安全存储区中的数据,根据第二预设算法对所述计算生成单元生成的密钥种子进行哈希运算得到哈希值;将得到的所述哈希值的高位端预定长度的数据作为主密钥,并将所述主密钥保存到安全存储区中。
  18. 如权利要求11所述的装置,其特征在于,还包括:
    第一生成模块,用于根据所述提示生成模块得到的助记短语和所述预设字典生成考试词语;
    显示提示模块,用于显示所述第一生成模块生成的考试词语,提示用户进行选择并接收用户的选择信息;
    第四判断模块,用于根据所述助记单词判断所述显示提示模块接收到的用户输入的选择信息是否正确,是则触发所述第一设置模块,否则触发所述第一生成模块。
  19. 如权利要求18所述的装置,其特征在于,
    所述显示提示模块具体用于通过人机交互模块的显示屏显示助记短语,在显示屏上显示所述第一生成模块生成的考试词语,通过显示屏提示用户进行选择并接收用户的选择信息。
  20. 如权利要求11所述的装置,其特征在于,所述提示查找模块具体用于通过人机交互模块的显示屏提示用户输入单词字母,当接收到用户通过人机交互模块的按键输入的字母时,根据所述字母在预设字典中查询对应的助记单词;通过人机交互模块的显示屏显示查询到的助记单词并在显示屏上显示提示用户进行选择的信息,并接收用户的选择信息。
PCT/CN2019/115620 2018-12-29 2019-11-05 一种硬件钱包可脱机进行初始化的实现方法及装置 WO2020134591A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US17/294,496 US20210409213A1 (en) 2018-12-29 2019-11-05 Method for realizing off-line initialization of hardware wallet and equipment thereof

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201811630994.XA CN109687975B (zh) 2018-12-29 2018-12-29 一种硬件钱包可脱机进行初始化的实现方法及装置
CN201811630994.X 2018-12-29

Publications (1)

Publication Number Publication Date
WO2020134591A1 true WO2020134591A1 (zh) 2020-07-02

Family

ID=66190121

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/115620 WO2020134591A1 (zh) 2018-12-29 2019-11-05 一种硬件钱包可脱机进行初始化的实现方法及装置

Country Status (3)

Country Link
US (1) US20210409213A1 (zh)
CN (1) CN109687975B (zh)
WO (1) WO2020134591A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023022535A1 (ko) * 2021-08-20 2023-02-23 삼성전자 주식회사 개인키의 복원 문구를 생성하기 위한 전자 장치 및 그 전자 장치에서의 동작 방법

Families Citing this family (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8579853B2 (en) * 2006-10-31 2013-11-12 Abbott Diabetes Care Inc. Infusion devices and methods
CN109687975B (zh) * 2018-12-29 2020-11-03 飞天诚信科技股份有限公司 一种硬件钱包可脱机进行初始化的实现方法及装置
US10614208B1 (en) * 2019-02-21 2020-04-07 Capital One Services, Llc Management of login information affected by a data breach
CN110310105B (zh) * 2019-06-28 2022-03-18 飞天诚信科技股份有限公司 一种安全的恢复硬件钱包主密钥的实现方法及装置
CN112732288B (zh) * 2020-12-11 2024-05-28 北京握奇智能科技有限公司 一种数字货币硬件钱包应用升级的方法和装置
US11973865B2 (en) * 2021-03-05 2024-04-30 Michael Heu Device and method of storing a seed phrase
US11777727B1 (en) * 2022-08-29 2023-10-03 Osom Products, Inc. Distributed digital wallet seed phrase
KR102629335B1 (ko) * 2023-01-11 2024-01-25 주식회사 그루핀 이중화된 니모닉 코드 기반 디지털 월렛 관리를 위한 전자 장치 및 이의 동작 방법
CN117235761B (zh) * 2023-09-22 2024-04-19 北京宝联之星科技股份有限公司 一种基于云计算的数据安全处理方法、系统和存储介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107480986A (zh) * 2017-08-14 2017-12-15 飞天诚信科技股份有限公司 一种利用硬件实现数字货币钱包的方法及硬件钱包
US20180075453A1 (en) * 2016-09-15 2018-03-15 American Express Travel Related Services Company, Inc. Systems and methods for blockchain based payment networks
CN108510258A (zh) * 2018-06-01 2018-09-07 黄君 一种基于usb otg设备的区块链数字货币转账系统
CN108960824A (zh) * 2018-06-22 2018-12-07 杨俊佳 基于区块链的移动终端
CN109687975A (zh) * 2018-12-29 2019-04-26 飞天诚信科技股份有限公司 一种硬件钱包可脱机进行初始化的实现方法及装置

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160117679A1 (en) * 2014-10-28 2016-04-28 Total System Services, Inc. Automated Payment Information Update With Vendors
CN108665250B (zh) * 2018-05-21 2022-05-31 北京橙鑫数据科技有限公司 一种信息处理方法、装置、硬件钱包以及系统
US20200193420A1 (en) * 2018-09-04 2020-06-18 Bit Key, Inc. Data management systems and methods
CA3115834A1 (en) * 2018-10-12 2020-04-16 Zeu Crypto Networks Inc. Biocrypt digital wallet
CN109687959B (zh) * 2018-12-29 2021-11-12 上海唯链信息科技有限公司 密钥安全管理系统和方法、介质和计算机程序

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180075453A1 (en) * 2016-09-15 2018-03-15 American Express Travel Related Services Company, Inc. Systems and methods for blockchain based payment networks
CN107480986A (zh) * 2017-08-14 2017-12-15 飞天诚信科技股份有限公司 一种利用硬件实现数字货币钱包的方法及硬件钱包
CN108510258A (zh) * 2018-06-01 2018-09-07 黄君 一种基于usb otg设备的区块链数字货币转账系统
CN108960824A (zh) * 2018-06-22 2018-12-07 杨俊佳 基于区块链的移动终端
CN109687975A (zh) * 2018-12-29 2019-04-26 飞天诚信科技股份有限公司 一种硬件钱包可脱机进行初始化的实现方法及装置

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023022535A1 (ko) * 2021-08-20 2023-02-23 삼성전자 주식회사 개인키의 복원 문구를 생성하기 위한 전자 장치 및 그 전자 장치에서의 동작 방법

Also Published As

Publication number Publication date
US20210409213A1 (en) 2021-12-30
CN109687975A (zh) 2019-04-26
CN109687975B (zh) 2020-11-03

Similar Documents

Publication Publication Date Title
WO2020134591A1 (zh) 一种硬件钱包可脱机进行初始化的实现方法及装置
US9350728B2 (en) Method and system for generating and authorizing dynamic password
EP3319292B1 (en) Methods, client and server for checking security based on biometric features
US10084602B2 (en) Dynamic token and a working method thereof
US9384369B2 (en) Information processing method and electronic device
US10943002B2 (en) Password authenticating apparatus for executing user authentication using password
US10693661B1 (en) Dynamic signature generation from keystroke dynamics
JP2017531234A (ja) パスワード検証装置及び方法
US10007781B2 (en) Method and system for password setting and authentication
JP2012133717A (ja) パスワード入力認証装置及びこれを用いた携帯端末装置
WO2021244531A1 (zh) 一种基于人脸识别的支付方法及装置
WO2017198098A1 (zh) 一种登录云桌面的虚拟机系统的方法及装置
JP4905390B2 (ja) クライアント装置、認証システム、認証要求方法、認証方法、及び、プログラム
CN105069332A (zh) 基于指纹的密码验证方法和密码验证装置
KR20100088261A (ko) 입력장치를 통한 패스워드 데이터의 다차원 패턴을 이용한 인증 시스템 및 방법
KR102401127B1 (ko) 히든 패스워드 입력시스템 및 이를 이용한 패스워드 입력방법
KR20180112302A (ko) 얼굴 인식에 기초한 사용자 인증 방법
WO2019179041A1 (zh) 账号登陆验证方法、装置、计算机设备及存储介质
TWI546693B (zh) 整合驗證碼及密碼的登入系統及其方法
US10387138B2 (en) Electronic device and software updating and registration template generating method
CN113487783B (zh) 基于智能手机生物特征识别功能实现门禁系统控制的方法
KR102390173B1 (ko) 패스워드 입력방법
CN108830073B (zh) 解锁方法、装置、终端及计算机可读存储介质
KR101980483B1 (ko) 머신러닝을 이용한 사용자 행동 인식 기반의 pin 입력 방법 및 시스템
US20210209216A1 (en) System and user pattern authentication method for preventing smudge and shoulder surfing attack of mobile device

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19906204

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19906204

Country of ref document: EP

Kind code of ref document: A1