WO2018153378A1 - 区块链中账户的处理方法和装置、存储介质、计算机设备 - Google Patents
区块链中账户的处理方法和装置、存储介质、计算机设备 Download PDFInfo
- Publication number
- WO2018153378A1 WO2018153378A1 PCT/CN2018/077391 CN2018077391W WO2018153378A1 WO 2018153378 A1 WO2018153378 A1 WO 2018153378A1 CN 2018077391 W CN2018077391 W CN 2018077391W WO 2018153378 A1 WO2018153378 A1 WO 2018153378A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- freeze
- request
- target account
- lock
- blockchain
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Payment architectures, schemes or protocols
- G06Q20/04—Payment circuits
- G06Q20/06—Private payment circuits, e.g. involving electronic currency used among participants of a common payment scheme
- G06Q20/065—Private payment circuits, e.g. involving electronic currency used among participants of a common payment scheme using e-cash
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Payment architectures, schemes or protocols
- G06Q20/38—Payment protocols; Details thereof
- G06Q20/382—Payment protocols; Details thereof insuring higher security of transaction
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/10—File systems; File servers
- G06F16/18—File system types
- G06F16/182—Distributed file systems
- G06F16/1824—Distributed file systems implemented using Network-attached Storage [NAS] architecture
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Payment architectures, schemes or protocols
- G06Q20/38—Payment protocols; Details thereof
- G06Q20/382—Payment protocols; Details thereof insuring higher security of transaction
- G06Q20/3829—Payment protocols; Details thereof insuring higher security of transaction involving key management
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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/00—Payment architectures, schemes or protocols
- G06Q20/38—Payment protocols; Details thereof
- G06Q20/40—Authorisation, e.g. identification of payer or payee, verification of customer or shop credentials; Review and approval of payers, e.g. check credit lines or negative lists
- G06Q20/405—Establishing or using transaction specific rules
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/06—Cryptographic 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/0618—Block ciphers, i.e. encrypting groups of characters of a plain text message using fixed encryption transformation
- H04L9/0631—Substitution permutation network [SPN], i.e. cipher composed of a number of stages or rounds each involving linear and nonlinear transformations, e.g. AES algorithms
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/08—Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
- H04L9/0816—Key establishment, i.e. cryptographic processes or cryptographic protocols whereby a shared secret becomes available to two or more parties, for subsequent use
- H04L9/0819—Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s)
- H04L9/0825—Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s) using asymmetric-key encryption or public key infrastructure [PKI], e.g. key signature or public key certificates
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/14—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using a plurality of keys or algorithms
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION 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
- G06Q2220/00—Business processing using cryptography
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/10—Network architectures or network communication protocols for network security for controlling access to devices or network resources
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L63/00—Network architectures or network communication protocols for network security
- H04L63/14—Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
- H04L63/1441—Countermeasures against malicious traffic
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/50—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols using hash chains, e.g. blockchains or hash trees
Definitions
- the present application relates to the field of blockchain, and in particular to a method and apparatus for processing an account in a blockchain, a storage medium, and a computer device.
- the account is a collection account that users post to their customers, and it takes time to republish a new account.
- the embodiment of the present application provides a method and a device for processing an account in a blockchain, a storage medium, and a computer device, so as to at least solve the technical problem that the account is insecure due to the leakage of the account private key.
- a method for processing an account in a blockchain includes: receiving, by a computer device, a freeze instruction sent by a user, wherein the freeze instruction is used to indicate that the target account is frozen; and the computer device is configured according to The received freeze instruction generates a freeze lock, wherein the freeze lock includes a freeze lock public key; the computer device generates a first freeze request according to the freeze instruction and the freeze lock public key, wherein the first freeze request is used Requesting to freeze the target account with the freeze lock; the computer device sends the freeze request to a device in the blockchain, so that the device in the blockchain records a freeze event according to the freeze request, The freeze event is used to indicate that the device in the blockchain refuses to perform resource transfer on the target account.
- a method for processing an account in a blockchain including: a device in a blockchain receives a first freeze request, wherein the first freeze request is frozen by a user An instruction and a freeze lock public key are generated, the first freeze request is for requesting to freeze the target account, the freeze lock is generated according to a freeze instruction sent by the user, and the freeze lock includes a freeze lock public key;
- the device in the blockchain verifies the first freeze request; in the case of successfully verifying the first freeze request, the device in the blockchain records a freeze event according to the first freeze request, wherein the freeze The event is for indicating that the device in the blockchain refuses to perform resource transfer on the target account.
- a processing apparatus for an account in a blockchain including: a first receiving unit configured to receive a freeze instruction sent by a user, wherein the freeze instruction is used to indicate that a target account freeze; a first generating unit configured to generate a freeze lock according to the received freeze instruction, wherein the freeze lock includes a freeze lock public key; and a second generation unit configured to be according to the freeze instruction and the The freeze lock public key generates a first freeze request, wherein the first freeze request is used to request to freeze the target account by using the freeze lock; and the first sending unit is configured to send the first freeze request Giving a device in the blockchain to cause a device in the blockchain to record a freeze event according to the first freeze request, wherein the freeze event is used to indicate that a device in the blockchain rejects the The target account performs resource transfer.
- a processing apparatus for an account in a blockchain comprising: a third receiving unit configured to receive a first freeze request by a device in a blockchain, wherein The first freeze request is generated by a freeze command sent by the user and a freeze lock public key, the first freeze request is used to request to freeze the target account, and the freeze lock is generated according to a freeze instruction sent by the user, the freeze lock Include a freeze lock public key; a second verification unit configured to verify the first freeze request by a device in the blockchain; and a third record unit set to successfully verify the first freeze request And, by the device in the blockchain, the freeze event is recorded according to the first freeze request, wherein the freeze event is used to indicate that the device in the blockchain refuses to perform resource transfer on the target account.
- a storage medium comprising a stored program, wherein the program is configured to execute any of the methods described above at runtime.
- a computer device comprising a memory, a processor, and a computer program stored on the memory and operable on the processor, the processor being configured to be executed by a computer program Any of the above methods.
- a freeze instruction sent by a user is received, wherein the freeze instruction is used to indicate that the target account is frozen; and the freeze lock is generated according to the received freeze instruction, wherein the freeze lock includes a freeze lock public key.
- Generating a first freeze request according to the freeze instruction and the freeze lock public key wherein the first freeze request is for requesting to freeze the target account by using the freeze lock; and the first freeze request is Transmitting to a device in the blockchain to cause a device in the blockchain to record a freeze event according to the first freeze request, wherein the freeze event is used to indicate that the device in the blockchain rejects the
- the target account performs resource transfer, and the target account is frozen by generating a freeze lock and using the freeze lock public key in the freeze lock, thereby achieving the purpose of ensuring the security of the target account, thereby ensuring that when the account private key is leaked, it is ensured
- the technical effect of account security further solves the technical problem of account insecurity caused by the leakage of the account private key.
- FIG. 1 is a schematic diagram of a hardware environment of a method for processing an account in a blockchain according to an embodiment of the present application
- FIG. 2 is a flowchart of an optional method for processing an account in a blockchain according to an embodiment of the present application
- FIG. 3 is a schematic diagram of first data generated by an optional method for processing an account in a blockchain according to an embodiment of the present application
- FIG. 4 is a schematic diagram of a defrosting request generated by an optional method for processing an account in a blockchain according to an embodiment of the present application
- FIG. 5 is a flowchart of another method for processing an account in a blockchain according to an embodiment of the present application.
- FIG. 6 is a schematic diagram of an apparatus for processing an account in an optional blockchain according to an embodiment of the present application.
- FIG. 7 is a schematic diagram of an optional processing device for an account in a blockchain according to an embodiment of the present application.
- FIG. 8 is a structural block diagram of a terminal according to an embodiment of the present application.
- a freeze lock can be a pair of temporarily generated public-private key pairs.
- the account is locked, ie frozen, by submitting the freeze lock public key to the device network in the blockchain; the corresponding lock is released by submitting the freeze lock private key signature to the device network in the blockchain That is thawed.
- a method embodiment of a method for processing an account in a blockchain is provided.
- the method can be used to ensure that the target account is securely frozen by freezing the lock when the user finds that the private key of the target account has a risk of leakage or has caused a certain loss due to the leakage of the private key.
- the target account is quickly frozen by freezing the lock, and the target account can be guaranteed.
- Security after the user determines that the private key of the target account has not been leaked, it is thawed. If the user believes that it is impossible to confirm whether the private key of the target account is leaked, or the user can confirm that the private key of the target account does leak, the resources in the target account can be transferred to the new account.
- the private key of the target account is kept by multiple people.
- User A knows that the target account has an unexplained transaction, it is suspected that the private key of the target account may be leaked.
- User A may choose to freeze the target account immediately.
- the transaction of the target account is completely forbidden to ensure the security of the target account.
- User A can determine whether the unknown transaction is initiated by another user and other users who have the private key of the target account. If confirmed, the above unknown transaction is initiated by another user. If the private key of the target account is not leaked, user A can release the freezing of the target account; if it is confirmed that the private key of the target account has been leaked, user A maintains the frozen state of the target account.
- the user can also repeatedly freeze the target account so that the target account is in multiple lock state, and the target account in the multiple lock state cannot be unlocked by a single “key”. After all the freezes are thawed, the target account is only The normal tradable status can be restored. Repeated freezing can improve the security of the target account. The user can also not completely freeze the target account.
- the target account when the user confirms that the private key of the target account has been leaked, if the target account is completely frozen, the target account will no longer receive the resources transferred to it, so the user will Before the new account informs other users, you can choose to not completely freeze the target account, so that the target account can receive the resources transferred to it, but the resources in the target account cannot be transferred out, after the user informs the other users of the new account address. And then transfer the resources in the target account to the new account by initiating a resource transfer request.
- Blockchain is a blockchain data structure to verify and store data, use distributed node consensus algorithms to generate and update data, use cryptography to ensure data transmission and access security, and utilize smart contracts composed of automated script code
- a device in a blockchain is equivalent to a node in a blockchain.
- a blockchain can include multiple nodes.
- the node can be a server. 102 or terminal 104.
- the processing method of the account in the blockchain may be applied to the hardware environment formed by the server 102 and the terminal 104 as shown in FIG. 1, and the terminal 104 or the server 102 is a computer device.
- User A may initiate a freeze request and a thaw request through the computer device; optionally, when the terminal 104 processes the freeze request and the thaw request sent by the user B through another terminal or server, the terminal 104 may also be considered as a blockchain.
- Terminal 104 or server 102 i.e., a computer device, can be considered a node in a blockchain.
- the server 102 is connected to the terminal 104 through a network.
- the network includes but is not limited to a wide area network, a metropolitan area network, or a local area network.
- the terminal 104 is not limited to a PC, a mobile phone, a tablet, or the like.
- the processing method of the account in the blockchain of the embodiment of the present application may be executed by the server 102, may be performed by the terminal 104, or may be jointly performed by the server 102 and the terminal 104.
- the method for processing the account in the blockchain of the embodiment of the present application may also be performed by a client installed on the terminal. The following describes the processing method of the account in the above blockchain by taking the client installed on the terminal 104 as an example.
- FIG. 2 is a flowchart of a method for processing an account in an optional blockchain according to an embodiment of the present application. As shown in FIG. 2, the method may include the following steps:
- Step S202 the client receives a freeze instruction sent by the user, where the freeze instruction is used to indicate that the target account is frozen;
- Step S204 the client generates a freeze lock according to the received freeze instruction, wherein the freeze lock includes a freeze lock public key;
- Step S206 the client generates a first freeze request according to the freeze instruction and the freeze lock public key, where the first freeze request is used to request to freeze the target account by using the freeze lock;
- Step S208 the client sends the first freeze request to the device in the blockchain, so that the device in the blockchain records the freeze event according to the first freeze request, wherein the freeze event is used to indicate the device rejection in the blockchain. Perform resource transfer on the target account.
- execution of the above steps is for the client only for illustrative purposes, and the execution subject may also be a computer device or the like.
- step S202 when the user finds that the account private key of the target account has a risk of leakage, or has caused a loss due to the leakage of the account private key of the target account, or the target account is frozen by an unknown person, the user may send the message to the client. Freeze the instruction to freeze the target account to ensure the security of the target account.
- the private key of the target account can be used, and when the user finds that the target account is frozen by an unknown person, , indicating that the unidentified person has the private key of the target account, and the target account private key has been leaked.
- the client receives the freeze command sent by the user, and then freezes the target account according to the instruction of the freeze command, and the resource in the frozen target account cannot be transferred, thereby ensuring the security of the account. .
- the client generates a freeze lock according to the received freeze instruction, and freezes the target account through the freeze lock, thereby ensuring the security of the target account.
- the freeze lock is a pair of temporary public and private key pairs, including a freeze lock public key and a freeze unlock private key, and the freeze lock public key is used to submit to the device in the block chain to lock the target account. Therefore, the target account is frozen, and after the account is frozen, the user can release the frozen lock private key to the device in the blockchain, thereby releasing the corresponding lock, that is, releasing the lock of the target account by the freeze lock corresponding to the frozen lock public key. .
- the client generates a first freeze request according to the instruction of the freeze instruction and the freeze lock public key in the freeze lock, and the first freeze request is used to submit to the device in the blockchain to make the zone
- the device in the blockchain refuses to perform resource transfer on the target account.
- the client sends the first freeze request to the device in the blockchain, and the device in the blockchain records a freeze event according to the received first freeze request, and records the freeze. After the event, according to the recorded freezing event, the resource transfer is refused to the target account, thereby completing the security of the target account and ensuring the security of the target account.
- the generating, by the client, the first freeze request according to the freeze instruction and the freeze lock public key comprises: obtaining an account address of the target account, a private key of the target account, and a freeze lock public key according to the freeze instruction; and using the private key of the target account to target
- the account address of the account and the freeze lock public key are signed to obtain first data
- the first data may include a private key signature of the target account, and may further include at least one of an account address of the target account and a freeze lock public key
- the private key signature is signature data obtained by signing at least one of the target account address and the frozen lock public key by using the private key of the target account; generating a first freeze request according to the first data, wherein the first freeze request includes the target The account address of the account, the freeze lock public key, and the private key signature of the target account.
- the client freezes the target account
- the account address of the target account is used as the identifier of the target account
- the freeze lock public key is submitted to the device in the blockchain by generating a freeze lock. Therefore, the target account is locked by the lock corresponding to the freeze lock.
- the user with the target account private key can freeze the target account. Therefore, when the first freeze request is generated, the client obtains the freeze command issued by the user.
- the account address of the target account to be frozen, the private key of the target account, and the freeze lock public key and then use the private key of the target account to sign the account address of the target account and the freeze lock public key, and according to the account address of the target account, Freezing the lock public key and the private key signature of the target account to obtain the first data, and finally generating a first freeze request according to the first data, including the account address of the target account, freezing the lock public key, and the private key of the target account in the first freeze request Signature, after sending the first freeze request to the device in the blockchain, the device in the blockchain can be based on the first The freeze request refuses to perform a resource transfer to the target account, thereby completing the freezing of the target account.
- the method further includes: the device in the blockchain verifying the private key signature of the target account according to the first freeze request; Thereafter, the device in the blockchain records the account address of the target account and the freeze lock public key; the device in the blockchain records the freeze event according to the first freeze request, wherein the freeze event is used to indicate that the freeze lock public key is used to target the account Freeze.
- the device in the blockchain can verify the received freeze request, and the target account is frozen after the verification is passed.
- the device in the block chain verifies the private key signature of the target account in the first freeze request, and the private key of the target account
- the public key of the target account is a key pair.
- the private key of the target account is only known by the user. In other words, the private key of the target account can be used to characterize the legitimacy of the user.
- the public key decrypts the first freeze request (ie, verifies the private key signature of the target account in the first freeze request), and can decrypt, indicating that the public key used and the private key for signature are a pair of keys, and
- the private key is the private key of the target account of the above user, which is equivalent to the verification pass.
- the device in the blockchain determines the account address of the record target account and the legality of the freeze lock public key, and the account address and The freeze lock public key is recorded in the freeze event to freeze the target account corresponding to the target address according to the freeze lock associated with the freeze lock public key, optionally, after the record freeze event,
- the block chain transfer devices refuse to perform certain types of resources on the target account.
- the first freeze request includes a freeze type
- the client sends the first freeze request to the device in the block chain, so that the device in the block chain records the freeze event according to the first freeze request, including: first freezing
- the request is sent to a device in the blockchain to indicate that the device in the blockchain refuses to perform a frozen type of resource transfer to the target account based on the first freeze request.
- the present application further provides an optional embodiment.
- the first freeze request generated by the client further includes a freeze type to perform freezing on the target account corresponding to the freeze type.
- the freeze type may be, but is not limited to, "freeze of the transaction completely prohibited” or "only freeze of the asset transfer out". In order to ensure the security of the account, the type of freezing must at least prohibit the transfer of assets.
- the client may use the private key of the target account to sign the account address of the target account, the freeze lock public key, and the freeze type to obtain the first data, and then generate a first freeze request according to the first data, and finally A freeze request is sent to the device in the blockchain, so that after the device in the blockchain successfully verifies the first freeze request, the resource transfer defined in the freeze type is refused to be performed on the target account corresponding to the target address.
- FIG. 3 is a schematic diagram of first data generated by an optional method for processing an account in a blockchain according to an embodiment of the present application. As shown in FIG. 3, an account address, a freeze type, and a freeze of a client account to a target account.
- the lock public key is signed to obtain the first data
- the generated first data includes the account address of the target account, the freeze type, the freeze lock public key, and the account private key signature.
- the method further includes: the client receives the thaw from the user. An instruction, wherein the thaw instruction is used to instruct to release the freeze on the target account by using the freeze lock; the client generates a thaw request according to the thaw instruction and the freeze lock private key, wherein the thaw request is used to request to unfreeze the target account by using the freeze lock private key
- the freeze lock private key matches the freeze lock public key; the client sends the defrosting request to the device in the block chain, so that the device in the block chain records the defrosting event according to the thawing request, wherein the defrosting event is used to indicate the area
- the device in the blockchain releases the freeze on the target account with the freeze lock.
- the target account may also be thawed.
- the user sends a defrosting instruction
- the client receives the defrosting instruction sent by the user, and generates a defrosting request according to the defrosting instruction and the freeze lock private key, where the freeze lock private key is compared with the frozen key public key that freezes the target account Matching, and by using the freeze lock private key, the freeze using the frozen lock public key matched with it can be released.
- the client sends the defrosting request to the device in the blockchain.
- the device in the blockchain records the defrosting event according to the thawing request, and allows the resource transfer to be performed on the target account according to the defrosted event recorded, thereby unfreezing the target account.
- the device in the blockchain can release the freeze of the target account by using the freeze lock public key matched with the freeze lock private key according to the defrosting event recorded by the defrosting request.
- a single thaw request can release the freeze lock corresponding to the freeze lock private key contained in the thaw request, and the target account cannot be completely thawed.
- the client generates the defrosting request according to the defrosting instruction and the freeze lock private key, including: obtaining an account address of the target account, a private key of the target account, and a freeze lock public key according to the thawing instruction; and using the freeze lock private key to the account of the target account
- the address and the freeze lock public key are signed, and the private key signature of the freeze lock is obtained; the account address of the target account, the freeze lock public key, and the freeze lock private key signature are signed by the private key of the target account to obtain the second data;
- the data generates a thaw request including a account address of the target account, a freeze lock public key, a freeze lock private key signature, and second data.
- the account address of the target account is also used as the identifier of the target account, and the target account is used by using the freeze lock private key pair matching the frozen lock public key at the time of freezing. Unlock. And, the user who also has the target account private key can unfreeze the target account. Therefore, when generating the defrosting request, the client obtains the account address of the target account to be thawed, the private key of the target account, and the frozen lock public key for freezing the target account according to the defrosting instruction sent by the user, and then uses the freeze lock private key pair.
- FIG. 4 is a schematic diagram of a thawing request generated by an optional method for processing an account in a blockchain according to an embodiment of the present application.
- the generated second data includes an account address of a target account, The freeze lock public key, the freeze lock private key signature, and the account private key signature of the target account.
- the generating, by the client, the defrosting request according to the thawing instruction and the freeze lock private key comprises: obtaining an account address of the target account, a private key of the target account, and a freeze lock public key according to the thawing instruction; and using the private key of the target account to the target account
- the account address, the freeze lock public key, and the freeze lock private key are signed to obtain the third data; finally, the thaw request is generated according to the third data, and the thaw request includes the account address of the target account, the freeze lock public key, the freeze lock private key, and the third data.
- the client may also generate a defrosting request by using another method.
- the client obtains the account address of the target account to be thawed and the private key of the target account according to the thawing instruction sent by the client. And freezing the public key to the target account, and then using the private key of the target account to sign the account address, the freeze lock public key, and the freeze lock private key of the target account, thereby obtaining the third data, further according to the third
- the data generation thawing request includes the account address of the target account, the freeze lock public key, the freeze lock private key, and the third data in the defrosting request generated according to the third data.
- the hacker can also use the obtained private key to freeze the target account, that is, the user performs the target account.
- the target account is repeatedly frozen, so that the target account is in multiple lock state.
- any single "key" (freeze lock private key) cannot completely release the frozen state of the target account. Therefore, although the user cannot unfreeze the account due to repeated freezing of the target account by the hacker, the user does not unfreeze the target account, and the resources in the target account are safe. In this case, the user can utilize the method of transferring the account resource. Transfer the resources in the target account to the new account without unfreezing the target account.
- Another method embodiment of a method for processing an account in a blockchain is also provided.
- FIG. 5 is a flowchart of another method for processing an account in a blockchain according to an embodiment of the present application. As shown in FIG. 5, the method may include the following steps:
- Step S502 the device in the blockchain receives the first freeze request, the first freeze request is generated by the freeze command sent by the user and the freeze lock public key, and the first freeze request is used to request to freeze the target account, and the freeze lock is sent according to the user.
- the freeze instruction is generated, and the freeze lock includes the freeze lock public key;
- Step S504 the device in the blockchain verifies the first freeze request
- Step S506 in the case that the first freeze request is successfully verified, the device in the blockchain records a freeze event according to the first freeze request, wherein the freeze event is used to indicate that the device in the blockchain refuses to perform resource transfer on the target account.
- the first freeze request is received by the device in the blockchain, and the target account is frozen by using the freeze lock public key according to the first freeze request, thereby solving the leakage caused by the account private key being leaked.
- the technical problem of insecure accounts in order to achieve the technical effect of ensuring account security when the account private key is leaked.
- the device in the blockchain verifies the first freeze request, including: the device in the blockchain acquires the public key of the target account; the device in the blockchain uses the public key of the target account to verify the target in the first freeze request The first data obtained by signing the account address of the account and the frozen lock public key by the private key of the account; in the case of successfully verifying the first data, the device in the block chain records the frozen lock carried in the first freeze request The account address of the key and target account.
- the device in the blockchain after receiving the first freeze request, needs to verify the identity of the user who initiated the first freeze request by verifying the private key signature of the target account.
- the device in the blockchain verifies the private key signature of the target account in the first freeze request
- the device in the blockchain The certificate center obtains the public key of the target account, and uses the public key of the target account to verify the private key signature of the target account in the first freeze request.
- the blockchain usually includes a plurality of nodes, wherein each node verifies the private key signature of the target account according to the public key of the target account, and after the majority node verifies the pass, the device in the block chain is considered to be the first freeze request.
- the method further includes: the device in the blockchain receives the thaw request, and the thaw request is generated by the thaw instruction and the freeze lock private key sent by the user,
- the thawing request is used to request to release the freeze of the target account by using the freeze lock;
- the defrosting request may also carry the freeze lock public key, the freeze lock public key carried by the defrosting request is the same as the freeze lock public key carried by the freeze request, and the freeze lock private key is The freeze lock public key matches; the device in the block chain verifies the freeze lock private key signature and the second data in the defrosting request, or the device in the block chain verifies the third data in the defrosting request, wherein the freeze lock The key signature is obtained by signing the account address of the target account and the freeze lock public key by using the freeze lock private key, and the second data is the account address of the target account, the freeze lock public key, and the freeze lock private key by using the private key of the target
- the third data is obtained by using the signature of the target account, the account address of the target account, the freeze lock public key, and the freeze lock private key.
- Signature obtained in the case of successfully verifying the freeze lock private key signature and the second data, or, in the case of successfully verifying the third data, the device in the blockchain records the defrosting event based on the account address and the freeze lock public key , wherein the thawing event is used to indicate that the device in the blockchain releases the freeze on the target account by using the freeze lock.
- the target account may also be thawed.
- the defrosting instruction is sent by the user, the client receives the defrosting instruction sent by the user, and generates a defrosting request according to the defrosting instruction, the freeze lock public key, and the freeze lock private key, where the freeze lock private key and the foregoing target account are frozen.
- the freeze lock public key matches, and the freeze lock private key can and can be used to release the freeze using the frozen lock public key that matches it.
- the client sends the thaw request to the device in the blockchain, and the device in the blockchain receives the thaw request and verifies the data in the thaw request.
- the above thawing request is generated by the client.
- the client can use the freeze lock private key to sign the account address of the target account and the freeze lock public key to obtain a freeze lock private key signature, and then use the private key pair of the target account.
- the account address of the target account, the freeze lock public key, and the freeze lock private key signature are signed to obtain the second data, and finally the thawing request is generated according to the second data.
- the client may use the private key of the target account to sign the account address of the target account, the freeze lock public key, and the freeze lock private key to obtain the third data, and finally generate a defrosting request according to the third data.
- Devices in the blockchain can verify the signature in the thaw request.
- the device in the blockchain can verify the freeze lock private key signature and the second data, and when the thawing request is generated by the third data, the device in the blockchain needs to be verified.
- Third data In the case of successful verification, the device in the blockchain records the defrosting event according to the thawing request, and allows the resource transfer to be performed on the target account according to the defrosted event recorded, thereby unfreezing the target account.
- the method further includes: the device in the blockchain receives the second freeze request, wherein the second freeze request is used to request the target account
- the device in the block chain determines whether the first sending address for sending the first freezing request is consistent with the second sending address for sending the second freezing request; if the first sending address is consistent with the second sending address, determining to send the first Whether the time interval between the freeze request and the second freeze request is greater than a preset time; if the time interval is less than or equal to the preset time, the second freeze request is rejected.
- the time interval for submitting the freeze request for the same address is limited.
- the device in the block chain first determines to send the first address of the first freeze request and send the first Whether the second address of the second freeze request is the same address, if the first address and the second address are the same address, it is determined again whether the time interval between sending the first freeze request and the second freeze request is greater than a preset time, in the sending The device in the blockchain will accept the second freeze request when the time interval between the second freeze request and the first freeze request is greater than the preset time. If the time interval is less than or equal to the preset time, the device in the blockchain Reject the second freeze request.
- the method further includes: the device in the blockchain receives the second freeze request, wherein the second freeze request is used to request the target account Freeze; the device in the blockchain determines whether the number of times the target account is currently frozen by the frozen lock is equal to a preset threshold; if the number of times the target account is currently frozen by the frozen lock is equal to a preset threshold, the device in the blockchain rejects the second freeze. request.
- the maximum number of freezes of the same account may also be limited to prevent someone from attacking the device network in the blockchain by continuously sending a freeze request to the same account.
- the device in the block chain determines whether the current target account is set to freeze by the freeze lock. For the preset threshold, if the target account is set to freeze by the freeze lock equal to the preset threshold, indicating that the target account is currently locked multiple times, the device in the blockchain rejects the second freeze request.
- the device in the blockchain is not allowed to thaw the target account, and the user can transfer the target account resource to the new account by means of resource recovery.
- Disabling the target account freeze after the target account freezes the upper limit can prevent the hacker from repeatedly locking the target account to reach the freeze limit, and the user cannot freeze the account again, and then the hacker releases the lock again one by one, thereby causing the account risk to the user.
- the target account is quickly frozen, thereby ensuring the security of the target account.
- the user can immediately initiate a freeze on the target account, whether the user confirms that the target account private key is leaked, or suspects that the private key of the target account is leaked, or the target account is unclearly frozen. Time protects the security of the target account by freezing the target account.
- the target account When it is confirmed that the private key of the target account has not been leaked, the target account is thawed, and the target account is frozen when it is confirmed that the private key of the target account does leak, or if it is impossible to confirm whether the private key of the target account is leaked.
- the user freezes the account and confirms that the private key of the target account has not been leaked, it can be thawed, and the target account cannot be unfreely freed.
- each user since there may be multiple users of the target account, each user has the private key of the target account, and the target account may be frozen. Therefore, the target account may be repeatedly frozen, and it is confirmed that the target account private key does not occur.
- the target account is thawed after all users who have frozen the target account initiate a thaw request.
- the maximum number of times the target account is repeatedly frozen should be set to prevent the hacker from attacking the devices in the blockchain by continuously freezing the target account, so that the blockchain network is heavily loaded. And a crash.
- the target account can be permanently frozen when the number of times the target account is frozen reaches a maximum number, and the target account is prohibited from being thawed again by the freeze request, thereby preventing the illegal user from acquiring the target account.
- the target account is repeatedly frozen to reach the maximum number of freezes of the target account, so that the real user can not ensure the security of the target account by freezing the target account, and the illegal user can find the opportunity to unfreeze the target account user and then steal Take the resources in the target account.
- the target account maximum freeze number is set to 1
- the target account can be substantially frozen once and cannot be repeatedly frozen.
- the freezing of the target account at this time is a permanent freeze.
- the target account is permanently frozen, the user can transfer the resources in the target account to the new account by means of resource recovery.
- the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, by hardware, but in many cases, the former is A better implementation.
- the technical solution of the present application which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a storage medium (such as ROM/RAM, disk,
- the optical disc includes a number of instructions for causing a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to perform the methods described in various embodiments of the present application.
- FIG. 6 is a schematic diagram of an apparatus for processing an account in an optional blockchain according to an embodiment of the present application. As shown in FIG. 6, the apparatus may include: a first receiving unit 610, a first generating unit 620, and a second The generating unit 630 and the first transmitting unit 640.
- the first receiving unit 610 is configured to receive a freeze instruction sent by the user, where the freeze instruction is used to indicate that the target account is frozen; and the first generating unit 620 is configured to generate, according to the received freeze instruction, a freeze lock, wherein the freeze lock includes a freeze lock public key; and a second generation unit 630 configured to generate a first freeze request according to the freeze instruction and the freeze lock public key, wherein the first a freeze request for requesting to freeze the target account by using the freeze lock; a first sending unit 640, configured to send the first freeze request to a device in a blockchain to make the area
- the device in the blockchain records a freeze event according to the first freeze request, wherein the freeze event is used to indicate that a device in the blockchain refuses to perform resource transfer on the target account.
- the first receiving unit 610 in this embodiment may be used to perform step S202 in the embodiment of the present application.
- the first generating unit 620 in this embodiment may be used to perform step S204 in the embodiment of the present application.
- the second generating unit 630 in this embodiment may be used to perform step S206 in the embodiment of the present application.
- the first sending unit 640 in this embodiment may be used to perform step S208 in the embodiment of the present application.
- the foregoing units are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the contents disclosed in the foregoing embodiments. It should be noted that the foregoing unit may be implemented in a hardware environment as shown in FIG. 1 as part of the device, and may be implemented by software or by hardware.
- the technical problem of the account being insecure due to the leakage of the account private key can be solved, thereby achieving the technical effect of ensuring the account security when the account private key is leaked.
- the second generating unit includes: a first acquiring module, configured to acquire an account address of the target account, a private key of the target account, and a freeze lock public key according to the freeze instruction; the first signature module is configured to utilize the target account The private key signs the account address of the target account and the freeze lock public key to obtain the first data; the first generating module is configured to generate a first freeze request according to the first data, wherein the first freeze request includes the target account The account address, the freeze lock public key, and the private key signature of the target account.
- the account address of the target account is used as the identifier of the target account, and the freeze lock public key is submitted to the device in the block chain by generating a freeze lock, thereby adopting The lock corresponding to the freeze lock locks the target account.
- the user with the private key of the target account can freeze the target account. Therefore, when the first freeze request is generated, the first acquisition module acquires according to the freeze instruction issued by the user. The account address of the target account to be frozen, the private key of the target account, and the freeze lock public key, and then the first signature module uses the private key of the target account to sign the account address of the target account and the freeze lock public key to obtain the first data.
- the first generation module generates a first freeze request according to the first data, includes an account address of the target account, a freeze lock public key, and a private key signature of the target account in the first freeze request, and sends the first freeze request to the block.
- the devices in the blockchain can refuse to perform resource transfer on the target account according to the first freeze request. , thus completing the freezing of the target account.
- the apparatus further includes: a first verification unit, configured to: after transmitting the first freeze request to the device in the blockchain, the private key of the target account according to the first freeze request by the device in the blockchain The signature is verified; the first recording unit is configured to record the account address of the target account and the freeze lock public key through the device in the blockchain after the verification is passed; the second recording unit is set to pass through the blockchain The device records a freeze event according to the first freeze request, wherein the freeze event is used to indicate that the target account is frozen by using the freeze lock public key.
- the device in the blockchain needs to verify the received freeze request, and the target account is frozen after the verification is passed.
- the first verification unit verifies the private key signature of the target account in the first freeze request by using the device in the blockchain, and is verified.
- the device in the blockchain determines the account address of the record target account and the legality of the freeze lock public key, and the second record unit records the account address and the freeze lock public key in the freeze event, according to the freeze lock
- the key-associated freeze lock freezes the target account corresponding to the target address.
- the device in the blockchain refuses to perform some type of resource transfer to the target account.
- the first freeze request includes a freeze type
- the first sending unit includes: a sending module, configured to send the first freeze request to the device in the blockchain to indicate that the device in the block chain is frozen according to the first Request to refuse to perform a frozen type of resource transfer on the target account.
- the present application further provides an optional embodiment.
- the first freeze request generated by the client further includes a freeze type to perform freezing on the target account corresponding to the freeze type.
- the freeze type may be, but is not limited to, "freeze of the transaction completely prohibited” or "only freeze of the asset transfer out". In order to keep the account secure, the type of freeze must at least prohibit the transfer of assets.
- the client may use the private key of the target account to sign the account address of the target account, the freeze lock public key, and the freeze type to obtain the first data, and then generate a first freeze request according to the first data, and finally send the module.
- the first freeze request is sent to the device in the blockchain, so that after the device in the blockchain successfully verifies the first freeze request, the resource transfer defined in the freeze type is refused to be performed on the target account corresponding to the target address.
- the apparatus further comprises: a second receiving unit configured to: send the first freeze request to the device in the blockchain, so that the device in the block chain receives the freeze event according to the first freeze request, and receives a thaw instruction sent by the user, wherein the thaw instruction is used to instruct to release the freeze on the target account by using the freeze lock; and the third generation unit is configured to generate a thaw request according to the thaw instruction and the freeze lock private key, wherein the thaw request is used for Requesting to use the freeze lock private key to unfreeze the target account, the freeze lock private key matches the freeze lock public key; the second sending unit is configured to send the thaw request to the device in the blockchain so that the block chain The device records the defrosting event according to the defrosting request, wherein the thawing event is used to instruct the device in the blockchain to release the freezing of the target account by using the freeze lock.
- a second receiving unit configured to: send the first freeze request to the device in the blockchain, so that the
- the target account may also be thawed.
- the user sends a defrosting instruction
- the second receiving unit receives the defrosting instruction sent by the user
- the third generating unit generates a defrosting request according to the defrosting instruction and the freeze lock private key, where the freeze lock private key and the target account are frozen.
- the freeze lock public key matches, and the freeze lock key can be used to release the freeze using the frozen lock that matches it.
- the second sending unit sends the defrosting request to the device in the blockchain, and the device in the blockchain records the defrosting event according to the thawing request, and allows the resource transfer to be performed on the target account according to the recorded thawing event, thereby unfreezing the target account.
- the device in the blockchain can release the freeze of the target account by using the freeze lock matched with the freeze lock private key according to the defrosting event recorded by the defrosting request.
- the target account is frozen by multiple freeze locks, the single thawing The request can release the freeze lock corresponding to the freeze lock private key contained in the defrosting request, and the target account cannot be completely thawed.
- the third generating unit includes: a second acquiring module, configured to acquire an account address of the target account, a private key of the target account, and a freeze lock public key according to the defrosting instruction; and the second signature module is configured to utilize the freeze lock The private key signs the account address of the target account and the freeze lock public key, and obtains the freeze lock private key signature; the third signature module is set to use the private key of the target account to the account address of the target account, freeze the lock public key, and freeze The lock private key signature is signed to obtain the second data; the second generating module is configured to generate a defrosting request according to the second data, the thawing request includes an account address of the target account, a freeze lock public key, a freeze lock private key signature, and a second data.
- the account address of the target account is also used as the identifier of the target account, and the target account is used by using the freeze lock private key pair matching the frozen lock public key at the time of freezing. Unlock. And, the user who also has the target account private key can unfreeze the target account.
- the second obtaining module acquires the account address of the target account to be thawed, the private key of the target account, and the frozen lock public key for freezing the target account according to the defrosting instruction sent by the user, and then the second signature module
- the address of the target account and the freeze lock public key are signed by using the freeze lock private key to obtain a freeze lock private key signature
- the third signature module uses the private key of the target account to address the target account, the freeze lock public key, and the freeze lock.
- the private key signature performs a second signature to obtain the second data
- the second generation module generates a defrosting request according to the second data.
- the third generating unit includes: a third obtaining module, configured to acquire an account address of the target account, a private key of the target account, and a freeze lock public key according to the defrosting instruction; and a fourth signature module configured to utilize the target account
- the private key signs the account address of the target account, the freeze lock public key and the freeze lock private key to obtain third data
- the third generation module is configured to generate a defrosting request according to the third data, and the thawing request includes the account of the target account Address, freeze lock public key, freeze lock private key, and third data.
- the client may also generate a defrosting request by using another method.
- the third obtaining module acquires an account address of the target account to be thawed and a target account according to the thawing instruction sent by the user.
- the private key and the frozen lock public key for freezing the target account and then the fourth signature module uses the private key of the target account to sign the account address, the freeze lock public key, and the freeze lock private key of the target account, thereby obtaining the third data.
- the third generation module generates a defrosting request according to the third data, and the defrosting request generated according to the third data includes an account address of the target account, a freeze lock public key, a freeze lock private key, and third data.
- the hacker can also use the obtained private key to freeze the target account, that is, the user performs the target account.
- the target account On the basis of the freeze, the target account is repeatedly frozen, so that the target account is in multiple lock state. In the state where the target account is in multiple locks, any single "key" (freeze lock private key) cannot completely release the frozen state of the target account. Therefore, although the hacker does not freeze the account due to the repeated freezing of the target account, the user does not unfreeze the target account, and the resources in the target account are safe.
- FIG. 7 is a schematic diagram of an apparatus for processing an account in an optional blockchain according to an embodiment of the present application. As shown in FIG. 7, the apparatus may include: a third receiving unit 710, a second verifying unit 720, and a third Recording unit 730.
- the third receiving unit 710 is configured to receive a first freeze request by using a device in the blockchain, where the first freeze request is generated by a freeze command sent by the user and a freeze lock public key, where the first freeze request is used And requesting to freeze the target account, the freeze lock is generated according to a freeze instruction sent by the user, the freeze lock includes a freeze lock public key; and the second verification unit 720 is configured to pass the device in the blockchain Verifying the first freeze request; the third record unit 730 is configured to record a freeze event according to the first freeze request by the device in the blockchain if the first freeze request is successfully verified, The freeze event is used to indicate that the device in the blockchain refuses to perform resource transfer on the target account.
- the third receiving unit 710 in this embodiment may be used to perform step S502 in the embodiment of the present application.
- the second verification unit 720 in this embodiment may be used to perform step S504 in the embodiment of the present application.
- the third recording unit 730 in this embodiment may be used to perform step S506 in the embodiment of the present application.
- the foregoing units are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the contents disclosed in the foregoing embodiments. It should be noted that the foregoing unit may be implemented in a hardware environment as shown in FIG. 1 as part of the device, and may be implemented by software or by hardware.
- the technical problem of the account being insecure due to the leakage of the account private key can be solved, thereby achieving the technical effect of ensuring the account security when the account private key is leaked.
- the second verification unit includes: a fourth obtaining module, configured to acquire a public key of the target account by using a device in the blockchain; and a verification module configured to use the target account by the device in the blockchain
- the first data obtained by signing the account address of the target account and the frozen lock public key by the private key of the target account in the first freezing request;
- the fifth obtaining module is configured to successfully verify the first data,
- the frozen lock public key carried in the first freeze request and the account address of the target account are recorded by the device in the blockchain.
- the device in the blockchain after receiving the first freeze request, needs to verify the identity of the user who initiated the first freeze request by verifying the private key signature of the target account.
- the device in the blockchain verifies the private key signature of the target account in the first freeze request, optionally, the fourth acquiring module passes the block.
- the device in the chain obtains the public key of the target account from the certificate center, and uses the public key of the target account to verify the private key signature of the target account in the first freeze request.
- the blockchain usually includes a plurality of nodes, wherein each node verifies the private key signature of the target account according to the public key of the target account, and after the majority node verifies the pass, the device in the block chain is considered to be the first freeze request.
- the verification passed.
- the device in the blockchain acquires the account address of the target account and the freeze lock public key, so that the fifth acquisition module obtains the information according to the device in the blockchain.
- the account address and the freeze lock public key record the freeze event and refuse to perform any resource transfer to the target account based on the recorded freeze event.
- the apparatus further includes: a fourth receiving unit, configured to: after the device in the blockchain records the freezing event according to the first freeze request, receive the defrosting request by the device in the blockchain, and the thawing request is sent by the user.
- the defrosting instruction and the freeze lock private key are generated, and the defrosting request is used to request to release the freezing of the target account by using the freeze lock;
- the defrosting request may also carry the frozen lock public key, the frozen lock public key carried by the thawing request and the frozen lock carried by the freezing request
- the public key is the same, the freeze lock private key matches the freeze lock public key;
- the third verification unit is set to verify the freeze lock private key signature and the second data in the defrosting request through the device in the blockchain, or, the block
- the device in the chain verifies the third data in the defrosting request, wherein the freeze lock private key signature is obtained by signing the account address of the target account and the freeze lock public key by using the freeze lock private key,
- the second data is an account address
- the target account may also be thawed.
- the defrosting instruction is sent by the user
- the client receives the defrosting instruction sent by the user, and generates a defrosting request according to the defrosting instruction, the freeze lock public key, and the freeze lock private key, where the freeze lock private key and the foregoing target account are frozen.
- the freeze lock public key matches, and the freeze lock private key can be used to release the freeze using the frozen lock public key that matches it.
- the client sends the unfreeze request to the device in the blockchain, and the fourth receiving unit receives the thaw request through the device in the blockchain and verifies the data in the thaw request.
- the above thawing request is generated by the client.
- the client can use the freeze lock private key to sign the account address of the target account and the freeze lock public key to obtain a freeze lock private key signature, and then use the private key pair of the target account.
- the account address of the target account, the freeze lock public key, and the freeze lock private key signature are signed to obtain the second data, and finally the thawing request is generated according to the second data.
- the client may use the private key of the target account to sign the account address of the target account, the freeze lock public key, and the freeze lock private key to obtain the third data, and finally generate a defrosting request according to the third data.
- Devices in the blockchain need to verify the signature in the thaw request.
- the third verification unit needs to verify the freeze lock private key signature and the second data by the device in the blockchain, and when the thawing request is generated by the third data, the third verification The unit needs to verify the third data through the devices in the blockchain.
- the fourth recording unit records the defrosting event according to the thawing request through the device in the blockchain, and allows the resource transfer to be performed on the target account according to the defrosted event recorded, thereby thawing the target account.
- the apparatus further includes: a fifth receiving unit, configured to: after the device in the blockchain records the freezing event according to the first freezing request, receive the second freezing request by the device in the blockchain, where the second The freeze request is used to request to freeze the target account; the determining unit is configured to determine, by the device in the blockchain, whether the number of times the target account is currently frozen by the frozen lock is equal to a preset threshold; the reject unit is set to be currently in the target account When the number of times the frozen lock is frozen is equal to the preset threshold, the second freeze request is rejected by the device in the blockchain.
- a fifth receiving unit configured to: after the device in the blockchain records the freezing event according to the first freezing request, receive the second freezing request by the device in the blockchain, where the second The freeze request is used to request to freeze the target account; the determining unit is configured to determine, by the device in the blockchain, whether the number of times the target account is currently frozen by the frozen lock is equal to a preset threshold; the reject unit is set to be currently in the target account When the number of times
- the maximum number of freezes of the same account may also be limited to prevent someone from attacking the blockchain network by continuously sending a freeze request to the same account.
- the fifth receiving unit receives the second freeze request again through the device in the blockchain, and the determining unit determines by using the device in the blockchain. Whether the current target account is set to freeze by the freeze lock is a preset threshold. If the target account is set to freeze by the freeze lock, the number of times is equal to the preset threshold, indicating that the target account is currently locked multiple times has reached the upper limit, rejecting The unit rejects the second freeze request through the device in the blockchain.
- the device in the blockchain is not allowed to thaw the target account, and the user can transfer the target account resource to the new account by means of resource recovery.
- Disabling the target account freeze after the target account freezes the upper limit can prevent the hacker from repeatedly locking the target account to reach the freeze limit, and the user cannot freeze the account again, and then the hacker releases the lock again one by one, thereby causing the account risk to the user.
- the foregoing modules are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the contents disclosed in the foregoing embodiments. It should be noted that the foregoing module may be implemented in a hardware environment as shown in FIG. 1 as part of the device, and may be implemented by software or by hardware, where the hardware environment includes a network environment.
- a storage medium also referred to as a memory
- the storage medium comprising a stored program, wherein the program is set to execute any of the above methods at runtime.
- a terminal also referred to as a computer device for implementing a processing method of an account in the above blockchain.
- FIG. 8 is a structural block diagram of a terminal according to an embodiment of the present application.
- the terminal may include: one or more (only one shown in FIG. 8) processor 801, memory 803, and transmission device. 805 (such as the transmitting device in the above embodiment), as shown in FIG. 8, the terminal may further include an input and output device 807.
- the memory 803 can be used to store the software program and the module, such as the processing method of the account in the blockchain and the program instruction/module corresponding to the device in the embodiment of the present application, and the processor 801 runs the software program stored in the memory 803 and The module, thereby performing various functional applications and data processing, that is, implementing the processing method of the account in the above blockchain.
- Memory 803 can include high speed random access memory, and can also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid state memory.
- memory 803 can further include memory remotely located relative to processor 801, which can be connected to the terminal over a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
- the transmission device 805 described above is used to receive or transmit data via a network, and can also be used for data transmission between the processor and the memory. Specific examples of the above network may include a wired network and a wireless network.
- the transmission device 805 includes a Network Interface Controller (NIC) that can be connected to other network devices and routers via a network cable to communicate with the Internet or a local area network.
- the transmission device 805 is a Radio Frequency (RF) module for communicating wirelessly with the Internet.
- NIC Network Interface Controller
- RF Radio Frequency
- the memory 803 is configured to store an application.
- the processor 801 can call the application stored in the memory 803 through the transmission device 805 to perform the steps of: receiving a freeze instruction sent by the user, wherein the freeze instruction is used to indicate that the target account is frozen; and the freeze lock is generated according to the received freeze instruction.
- the freeze lock includes a freeze lock public key; and the first freeze request is generated according to the freeze instruction and the freeze lock public key, wherein the first freeze request is used to request to freeze the target account by using the freeze lock; and the first freeze request is sent to A device in the blockchain, such that the device in the blockchain records a freeze event according to the first freeze request, wherein the freeze event is used to indicate that the device in the blockchain refuses to perform resource transfer on the target account.
- the processor 801 is further configured to: obtain an account address of the target account, a private key of the target account, and a freeze lock public key according to the freeze instruction; perform the account address of the target account and the freeze lock public key by using the private key of the target account Signing, obtaining first data; generating a first freeze request according to the first data, wherein the first freeze request includes an account address of the target account, a freeze lock public key, and a private key signature of the target account.
- the processor 801 is further configured to: perform verification on the private key signature of the target account according to the first freeze request by the device in the blockchain; after the verification is passed, record the account of the target account through the device in the blockchain Address and freeze lock public key; the freeze event is recorded by the device in the blockchain according to the first freeze request, wherein the freeze event is used to indicate that the target account is frozen by using the freeze lock public key.
- the processor 801 is further configured to: send the first freeze request to the device in the blockchain to indicate that the device in the blockchain refuses to perform a frozen type resource transfer on the target account according to the first freeze request.
- the processor 801 is further configured to: receive a defrosting instruction sent by the user, where the defrosting instruction is used to instruct to release the freezing of the target account by using the freeze lock; and the thawing request is generated according to the thawing instruction and the freeze lock private key, where The thawing request is used to request to unfreeze the target account with the freeze lock private key, and the freeze lock private key matches the freeze lock public key; the thawing request is sent to the device in the block chain, so that the device in the block chain according to the thawing request A defrosting event is recorded, wherein the thawing event is used to indicate that the device in the blockchain releases the freeze on the target account using the freeze lock.
- the processor 801 is further configured to: obtain an account address of the target account, a private key of the target account, and a freeze lock public key according to the thawing instruction; and sign the account address of the target account and the freeze lock public key by using the freeze lock private key Obtaining a freeze lock private key signature; using the private key of the target account to sign the account address of the target account, the freeze lock public key, and the freeze lock private key signature to obtain the second data; generating a defrosting request according to the second data, the thawing request includes The account address of the target account, the freeze lock public key, the freeze lock private key signature, and the second data.
- the processor 801 is further configured to: obtain an account address of the target account, a private key of the target account, and a freeze lock public key according to the thawing instruction; use the private key of the target account to the account address of the target account, freeze the lock public key, and The freeze lock private key is signed to obtain the third data; and the defrosting request is generated according to the third data, the defrosting request includes the account address of the target account, the freeze lock public key, the freeze lock private key, and the third data.
- the processor 801 is further configured to: receive, by the device in the blockchain, a first freeze request, where the first freeze request is generated by a freeze command sent by the user and a freeze lock public key, where the first freeze request is used for the request Freeze the target account, the freeze lock is generated according to the freeze instruction sent by the user, the freeze lock includes the freeze lock public key; the first freeze request is verified by the device in the blockchain; and the pass zone is successfully verified in the case of successfully verifying the first freeze request
- the device in the blockchain records a freeze event according to the first freeze request, wherein the freeze event is used to indicate that the device in the blockchain refuses to perform resource transfer on the target account.
- the processor 801 is further configured to: obtain a public key of the target account by using a device in the blockchain; and verify, by the device in the blockchain, the private key of the target account in the first freeze request by using the public key of the target account; The first data obtained by signing the account address of the target account and the freeze lock public key; in case the first data is successfully verified, the frozen lock public key and the target carried in the first freeze request are recorded by the device in the blockchain The account address of the account.
- the processor 801 is further configured to: receive a defrosting request by a device in the blockchain, the defrosting request is generated by a defrosting instruction and a freeze lock private key sent by the user, and the thawing request is used to request to release the target account by using the freeze lock Freeze; verify the frozen lock private key signature and the second data in the defrosting request by the device in the blockchain, or the device in the blockchain verifies the third data in the defrosting request, wherein the freeze lock private key signature is Using the freeze lock private key to sign the account address of the target account and the freeze lock public key, the second data is to use the private key of the target account to sign the account address of the target account, the freeze lock public key and the freeze lock private key signature.
- the third data is obtained by using the private key of the target account to sign the account address of the target account, the freeze lock public key, and the freeze lock private key; in the case of successfully verifying the freeze lock private key signature and the second data, Alternatively, in the case of successfully verifying the third data, the device in the blockchain records the defrosting event according to the account address and the freeze lock public key, wherein The defrosting event is used to indicate that the device in the blockchain releases the freeze on the target account by using the freeze lock.
- the processor 801 is further configured to: receive a second freeze request by using a device in the blockchain, where the second freeze request is used to request to freeze the target account; and the device in the blockchain determines the target account current Whether the number of freezes blocked by the freeze lock is equal to a preset threshold; if the number of times the target account is currently frozen by the freeze lock is equal to a preset threshold, the device in the blockchain rejects the second freeze request.
- a solution for implementing a terminal for processing an account in a blockchain is provided.
- the purpose of ensuring the security of the target account is achieved, thereby realizing the technical effect of ensuring account security when the account private key is leaked.
- the structure shown in FIG. 8 is only illustrative, and the terminal can be a smart phone (such as an Android mobile phone, an iOS mobile phone, etc.), a tablet computer, a palm computer, and a mobile Internet device (MID). Terminal equipment such as PAD.
- FIG. 8 does not limit the structure of the above electronic device.
- the terminal may also include more or less components (such as a network interface, display device, etc.) than shown in FIG. 8, or have a different configuration than that shown in FIG.
- Embodiments of the present application also provide a storage medium.
- the storage medium may store program code for executing the processing method of the account in the blockchain described above.
- the foregoing storage medium may be located on at least one of the plurality of network devices in the network shown in the foregoing embodiment.
- the storage medium is arranged to store program code for performing the following steps:
- the storage medium is further configured to store program code for: obtaining an account address of the target account, a private key of the target account, and a freeze lock public key according to the freeze instruction; using the private key of the target account to the target account The account address and the freeze lock public key are signed to obtain the first data; and the first freeze request is generated according to the first data, wherein the first freeze request includes the account address of the target account, the freeze lock public key, and the private key signature of the target account. .
- the storage medium is further configured to store program code for performing the step of: the device in the blockchain validating the private key signature of the target account according to the first freeze request; after the verification is passed, in the blockchain
- the device records the account address of the target account and the freeze lock public key; the device in the blockchain records the freeze event according to the first freeze request, wherein the freeze event is used to indicate that the target account is frozen by using the freeze lock public key.
- the storage medium is further configured to store program code for performing the step of: transmitting a first freeze request to a device in the blockchain to indicate that the device in the blockchain rejects the target according to the first freeze request The account performs a frozen type of resource transfer.
- the storage medium is further configured to store program code for performing the following steps: receiving a defrosting instruction sent by the user, wherein the thawing instruction is used to instruct to release the freezing of the target account by using the freeze lock; according to the thawing instruction and freezing
- the lock private key generates a thaw request, wherein the thaw request is used to request to unfreeze the target account by using the freeze lock private key, and the freeze lock private key matches the freeze lock public key;
- the thaw request is sent to the device in the block chain, so that The device in the blockchain records the thaw event according to the thaw request, wherein the thaw event is used to instruct the device in the blockchain to unfreeze the target account with the freeze lock.
- the storage medium is further configured to store program code for: obtaining an account address of the target account, a private key of the target account, and a freeze lock public key according to the defrosting instruction; using the freeze lock private key to the target account The account address and the freeze lock public key are signed, and the freeze lock private key signature is obtained; the account account address, the freeze lock public key and the freeze lock private key signature of the target account are signed by the private key of the target account to obtain the second data; The second data generates a defrosting request, and the thawing request includes an account address of the target account, a freeze lock public key, a freeze lock private key signature, and second data.
- the storage medium is further configured to store program code for: obtaining an account address of the target account, a private key of the target account, and a freeze lock public key according to the defrosting instruction; using the private key of the target account to the target account
- the account address, the freeze lock public key, and the freeze lock private key are signed to obtain the third data
- the thaw request is generated according to the third data, and the thaw request includes the account address of the target account, the freeze lock public key, the freeze lock private key, and the third data.
- the storage medium is further configured to store program code for performing the step of: receiving, by the device in the blockchain, a first freeze request, wherein the first freeze request is sent by the user with a freeze instruction and a freeze lock public key Generate, the first freeze request is used to request to freeze the target account, the freeze lock is generated according to the freeze instruction sent by the user, the freeze lock includes the freeze lock public key; the first freeze request is verified by the device in the blockchain; In the case of a freeze request, the freeze event is recorded by the device in the blockchain according to the first freeze request, wherein the freeze event is used to indicate that the device in the block chain refuses to perform resource transfer on the target account.
- the storage medium is further configured to store program code for performing the steps of: obtaining a public key of the target account through a device in the blockchain; verifying the first by using a public key of the target account by the device in the blockchain The first data obtained by signing the account address of the target account and the frozen lock public key by the private key of the target account in the freeze request; in the case of successfully verifying the first data, the first freeze request is recorded by the device in the blockchain The frozen lock public key carried in and the account address of the target account.
- the storage medium is further configured to store program code for performing the steps of: receiving a defrosting request by a device in the blockchain, the thawing request being generated by a defrosting instruction and a freeze lock private key sent by the user, the defrosting request being used for Requesting to unfreeze the target account with the freeze lock; verifying the freeze lock private key signature and the second data in the defrosting request by the device in the blockchain, or verifying the third data in the defrosting request by the device in the blockchain , wherein the freeze lock private key signature is obtained by using the freeze lock private key to sign the account address of the target account and the freeze lock public key, and the second data is to use the private key of the target account to the account address of the target account, freeze the lock public The key is obtained by signing the key and the freeze lock private key signature.
- the third data is obtained by signing the account address of the target account, the freeze lock public key and the freeze lock private key by using the private key of the target account; and successfully verifying the freeze lock private key
- the device in the blockchain is based on the account address Thaw frozen locks public record event, which thaw event is used to indicate the block chain lock device to lift the freeze on the use of frozen accounts of target.
- the storage medium is further configured to store program code for performing the step of: receiving, by the device in the blockchain, a second freeze request, wherein the second freeze request is for requesting to freeze the target account;
- the device in the blockchain determines whether the number of times the target account is currently frozen by the frozen lock is equal to a preset threshold; if the number of times the target account is currently frozen by the frozen lock is equal to a preset threshold, the device in the blockchain rejects the second freeze request.
- the foregoing storage medium may include, but is not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory.
- ROM Read-Only Memory
- RAM Random Access Memory
- a mobile hard disk e.g., a hard disk
- magnetic memory e.g., a hard disk
- the integrated unit in the above embodiment if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in the above-described computer readable storage medium.
- the technical solution of the present application in essence or the contribution to the prior art, or all or part of the technical solution may be embodied in the form of a software product, which is stored in a storage medium.
- a number of instructions are included to cause one or more computer devices (which may be a personal computer, server or network device, etc.) to perform all or part of the steps of the methods described in various embodiments of the present application.
- the disclosed client may be implemented in other manners.
- the device embodiments described above are merely illustrative.
- the division of the unit is only a logical function division.
- multiple units or components may be combined or may be Integrate into another system, or some features can be ignored or not executed.
- the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, unit or module, and may be electrical or otherwise.
- the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
- each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
- the above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
Landscapes
- Engineering & Computer Science (AREA)
- Business, Economics & Management (AREA)
- Accounting & Taxation (AREA)
- Computer Security & Cryptography (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Finance (AREA)
- Strategic Management (AREA)
- General Business, Economics & Management (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Development Economics (AREA)
- Economics (AREA)
- General Engineering & Computer Science (AREA)
- Computer Hardware Design (AREA)
- Computing Systems (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
本申请公开了一种区块链中账户的处理方法和装置、存储介质、计算机设备。其中,该方法包括:接收用户发送的冻结指令,其中,冻结指令用于指示将目标账户冻结;根据接收到的冻结指令生成冻结锁,其中,冻结锁包括冻结锁公钥;根据冻结指令和冻结锁公钥生成冻结请求,其中,冻结请求用于请求利用冻结锁公钥对目标账户进行冻结;将冻结请求发送给区块链中的设备,以使区块链中的设备根据冻结请求记录冻结事件,其中,冻结事件用于指示区块链中的设备拒绝对目标账户执行资源转移。本申请可以解决由于账户私钥发生泄露造成的账户不安全的技术问题。
Description
本申请要求于提交中国专利局,申请号为2017101107368、发明名称“区块链中账户的处理方法和装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
本申请涉及区块链领域,具体而言,涉及一种区块链中账户的处理方法和装置、存储介质、计算机设备。
在区块链中,如果用户发现账户私钥存在泄露风险,可以通过将账户资产转移到其持有的其他账户中的办法解决。但这样做存在的问题是:
1、用户只是怀疑账户泄露,在证实之前并不想立即弃用该账户。比如,该账户是用户发布给其客户的收款账户,要重新发布一个新的账户需要时间。
2、该账户存在未完成的、或即将发生的交易。虽然可以将现有资产转移走,但是将要接收到的资产仍然有风险。
针对上述的问题,目前尚未提出有效的解决方案。
发明内容
本申请实施例提供了一种区块链中账户的处理方法和装置、存储介质、计算机设备,以至少解决由于账户私钥发生泄露造成的账户不安全的技术问题。
根据本申请实施例的一个方面,提供了一种区块链中账户的处理方法,包括:计算机设备接收用户发送的冻结指令,其中,所述冻结指令用于指 示将目标账户冻结;计算机设备根据接收到的冻结指令生成冻结锁,其中,所述冻结锁包括冻结锁公钥;计算机设备根据所述冻结指令和所述冻结锁公钥生成第一冻结请求,其中,所述第一冻结请求用于请求利用所述冻结锁对所述目标账户进行冻结;计算机设备将所述冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
根据本申请实施例的一方面,还提供了一种区块链中账户的处理方法,包括:区块链中的设备接收第一冻结请求,其中,所述第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,所述第一冻结请求用于请求对目标账户进行冻结,所述冻结锁根据所述用户发送的冻结指令生成,所述冻结锁包括冻结锁公钥;所述区块链中的设备验证所述第一冻结请求;在成功验证所述第一冻结请求的情况下,所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
根据本申请实施例的一方面,还提供了一种区块链中账户的处理装置,包括:第一接收单元,被设置为接收用户发送的冻结指令,其中,所述冻结指令用于指示将目标账户冻结;第一生成单元,被设置为根据接收到的冻结指令生成冻结锁,其中,所述冻结锁包括冻结锁公钥;第二生成单元,被设置为根据所述冻结指令和所述冻结锁公钥生成第一冻结请求,其中,所述第一冻结请求用于请求利用所述冻结锁对所述目标账户进行冻结;第一发送单元,被设置为将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
根据本申请实施例的一方面,还提供了一种区块链中账户的处理装置,包括:第三接收单元,被设置为通过区块链中的设备接收第一冻结请求,其中,所述第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,所述 第一冻结请求用于请求对目标账户进行冻结,所述冻结锁根据所述用户发送的冻结指令生成,所述冻结锁包括冻结锁公钥;第二验证单元,被设置为通过所述区块链中的设备验证所述第一冻结请求;第三记录单元,被设置为在成功验证所述第一冻结请求的情况下,通过所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
根据本申请实施例的另一方面,还提供了一种存储介质,该存储介质包括存储的程序,其中,该程序被设置为运行时执行上述的任一种方法。
根据本申请实施例的另一方面,还提供了一种计算机设备,包括存储器、处理器及存储在存储器上并可在所述处理器上运行的计算机程序,处理器被设置为通过计算机程序执行上述的任一种方法。
在本申请实施例中,采用接收用户发送的冻结指令,其中,所述冻结指令用于指示将目标账户冻结;根据接收到的冻结指令生成冻结锁,其中,所述冻结锁包括冻结锁公钥;根据所述冻结指令和所述冻结锁公钥生成第一冻结请求,其中,所述第一冻结请求用于请求利用所述冻结锁对所述目标账户进行冻结;将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移,通过生成由冻结锁,并利用冻结锁中的冻结锁公钥对目标账户进行冻结,达到了确保目标账户安全的目的,从而实现了在账户私钥发生泄露时,确保账户安全的技术效果,进而解决了由于账户私钥发生泄露造成的账户不安全的技术问题。
此处所说明的附图用来提供对本申请的进一步理解,构成本申请的一部分,本申请的示意性实施例及其说明用于解释本申请,并不构成对本申请的不当限定。在附图中:
图1是根据本申请实施例的区块链中账户的处理方法的硬件环境的示意图;
图2是根据本申请实施例的一种可选的区块链中账户的处理方法的流程图;
图3是根据本申请实施例的一种可选的区块链中账户的处理方法所生成的第一数据的示意图;
图4是根据本申请实施例的一种可选的区块链中账户的处理方法所生成的解冻请求的示意图;
图5是根据本申请实施例的另一种可选的区块链中账户的处理方法的流程图;
图6是根据本申请实施例的一种可选的区块链中账户的处理装置的示意图;
图7是根据本申请实施例的一种可选的区块链中账户的处理装置的示意图;以及
图8是根据本申请实施例的一种终端的结构框图。
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分的实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本申请保护的范围。
需要说明的是,本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本申请的实施例能够以除了在这里图示或描述的那些以外的顺序实 施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。
首先,在对本申请实施例进行描述的过程中出现的部分名词或者术语适用于如下解释:
冻结锁:冻结锁可以是一对临时生成的公私钥对。在本申请中,通过将冻结锁公钥提交给区块链中的设备网络来对账户加锁,即冻结;通过将冻结锁私钥签名提交给区块链中的设备网络来解除对应的锁,即解冻。
根据本申请实施例,提供了一种区块链中账户的处理方法的方法实施例。
该方法可以用于当用户发现目标账户的私钥存在泄露的风险或者已经因私钥泄露造成一定损失时,通过冻结锁将目标账户快速冻结,以保证目标账户的安全。尤其是在目标账户的私钥疑似泄露,但用户还不能确定其真实情况,并且用户在正式确认之前不想立即弃用该账户的情况下,通过冻结锁将目标账户快速冻结,可以保证目标账户的安全,待用户确定目标账户的私钥未泄露之后,对其进行解冻。如果用户认为无法确认目标账户的私钥是否泄露,或者用户能够确认目标账户的私钥确实发生泄露之后,可以将目标账户中的资源转移到新的账户。
例如:目标账户的私钥由多个人保管,其中,当用户A获知目标账户发生一笔不明原因的交易时,怀疑目标账户的私钥可能泄露,此时用户A可以选择立即对目标账户进行冻结,完全禁止目标账户发生交易,以保证目标账户的安全,随后用户A可以同保管有目标账户私钥的其他用户确定该不明交易是否由其他用户发起,如果经过确认,上述不明交易由其他用户发起,则目标账户的私钥未泄露,用户A可以解除对目标账户的冻结;如果经过确认,目标账户的私钥确实发生了泄露,则用户A保持目标账户的冻结状态。用户还可以对目标账户进行重复冻结,以使目标账户处于多 重锁定状态,并且处于多重锁定状态的目标账户无法通过单一的“钥匙”对其进行解锁,所有的冻结全部被解冻之后,目标账户才可以恢复正常的可交易状态。重复冻结可以提高目标账户的安全性。用户还可以对目标账户进行不完全冻结,例如:当用户确认目标账户的私钥发生了泄露,如果对目标账户进行完全冻结,目标账户将无法再接收转入到其中的资源,因此在用户将新账户告知其他用户之前,可以选择对目标账户进行不完全冻结,使目标账户能接收转入到其中的资源,但目标账户中的资源无法被转出,待用户将新账户地址告知其他用户之后,再通过发起资源转移请求将目标账户中的资源转移到新的账户中。
区块链是利用块链式数据结构来验证与存储数据、利用分布式节点共识算法来生成和更新数据、利用密码学的方式保证数据传输和访问的安全、利用由自动化脚本代码组成的智能合约来编程和操作数据的一种全新的分布式基础架构与计算范式,在区块链中的一个设备相当于区块链中的一个节点,区块链可以包括多个节点,该节点可以是服务器102或终端104。
可选地,在本实施例中,上述区块链中账户的处理方法可以应用于如图1所示的由服务器102和终端104所构成的硬件环境中,终端104或服务器102即为计算机设备,用户A可以通过计算机设备发起冻结请求、解冻请求;可选地,当终端104处理用户B通过另一终端或服务器发送的冻结请求、解冻请求时,那么终端104也可以被认为是区块链中的一个节点。终端104或服务器102即计算机设备可以被认为是区块链中的一个节点。如图1所示,服务器102通过网络与终端104进行连接,上述网络包括但不限于:广域网、城域网或局域网,终端104并不限定于PC、手机、平板电脑等。本申请实施例的区块链中账户的处理方法可以由服务器102来执行,也可以由终端104来执行,还可以是由服务器102和终端104共同执行。其中,终端104执行本申请实施例的区块链中账户的处理方法也可以是由安装在其上的客户端来执行。下面以安装于终端104上的客户端为例对上述区块链中账户的处理方法进行说明。
图2是根据本申请实施例的一种可选的区块链中账户的处理方法的流程图,如图2所示,该方法可以包括以下步骤:
步骤S202,客户端接收用户发送的冻结指令,其中,冻结指令用于指示将目标账户冻结;
步骤S204,客户端根据接收到的冻结指令生成冻结锁,其中,冻结锁包括冻结锁公钥;
步骤S206,客户端根据冻结指令和冻结锁公钥生成第一冻结请求,其中,第一冻结请求用于请求利用冻结锁对目标账户进行冻结;
步骤S208,客户端将第一冻结请求发送给区块链中的设备,以使区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示区块链中的设备拒绝对目标账户执行资源转移。
上述步骤的执行主体为客户端仅用于示意性的说明,执行主体还可为计算机设备等。
通过上述步骤S202至步骤S208,通过生成由冻结锁,并利用冻结锁中的冻结锁公钥对目标账户进行冻结,可以解决由于账户私钥发生泄露造成的账户不安全的技术问题,可以达到在账户私钥发生泄露时,确保账户安全的技术效果。
在步骤S202提供的技术方案中,当用户发现目标账户的账户私钥存在泄露风险,或者已经因目标账户的账户私钥泄露造成损失,或者目标账户被不明人员冻结时,用户可以向客户端发出冻结指令,以将目标账户冻结,从而确保目标账户的安全,其中,作为一种可选的实施例,由于对目标账户进行冻结可用目标账户的私钥,在用户发现目标账户被不明人员冻结时,说明该不明人员拥有了目标账户的私钥,目标账户私钥已发生泄露。可选的,在用户发出冻结指令之后,客户端接收用户发送的冻结指令,进而根据该冻结指令的指示将目标账户冻结,冻结后的目标账户中的资源无 法被转移,从而确保了账户的安全。
在步骤S204提供的技术方案中,客户端根据接收到的冻结指令生成一把冻结锁,并通过该冻结锁对目标账户进行冻结,从而确保目标账户的安全。可选地,上述冻结锁是一对临时的公私钥对,其中包括一个冻结锁公钥和一个冻解锁私钥,冻结锁公钥用于提交给区块链中的设备以对目标账户加锁从而将目标账户冻结,账户冻结之后,用户可以通过将冻结锁私钥提交给区块链中的设备,从而解除对应的锁,即解除由上述冻结锁公钥对应的冻结锁对目标账户的锁定。
在步骤S206提供的技术方案中,客户端根据冻结指令的指示和冻结锁中的冻结锁公钥生成第一冻结请求,该第一冻结请求用于提交给区块链中的设备,以使区块链中的设备拒绝对目标账户执行资源转移。
在步骤S208提供的技术方案中,客户端将该第一冻结请求发送给区块链中的设备,区块链中的设备根据接收到的第一冻结请求记录一个冻结事件,并在记录该冻结事件之后,根据记录的冻结事件,拒绝对目标账户执行资源转移,从而完成对目标账户的安全,确保目标账户的安全。
可选地,客户端根据冻结指令和冻结锁公钥生成第一冻结请求包括:根据冻结指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名,得到第一数据,第一数据可以包括目标账户的私钥签名,还可以包括目标账户的账户地址和冻结锁公钥中的至少一个;目标账户的私钥签名即是利用目标账户的私钥对目标账户地址和冻结锁公钥中的至少一个数据进行签名得到的签名数据;根据第一数据生成第一冻结请求,其中,第一冻结请求包括目标账户的账户地址、冻结锁公钥和目标账户的私钥签名。
作为一种可选的实施例,客户端在对目标账户进行冻结时,以目标账户的账户地址作为目标账户的标识,通过生成冻结锁,将冻结锁公钥提交给区块链中的设备,从而采用冻结锁对应的锁对目标账户加锁,除此以外,具有目标账户私钥的用户可以对目标账户进行冻结,因此,生成第一冻结 请求时,客户端根据用户发出的冻结指令,获取要冻结的目标账户的账户地址、目标账户的私钥,以及冻结锁公钥,然后利用目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名,并根据目标账户的账户地址、冻结锁公钥和目标账户的私钥签名得到第一数据,最后根据第一数据生成第一冻结请求,在第一冻结请求中包括目标账户的账户地址,冻结锁公钥以及目标账户的私钥签名,在将第一冻结请求发送给区块链中的设备之后,区块链中的设备可以根据第一冻结请求拒绝对目标账户执行资源转移,从而完成对目标账户的冻结。
可选地,客户端在将第一冻结请求发送给区块链中的设备之后,方法还包括:区块链中的设备根据第一冻结请求对目标账户的私钥签名进行验证;在验证通过之后,区块链中的设备记录目标账户的账户地址和冻结锁公钥;区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示采用冻结锁公钥对目标账户进行冻结。
作为一种可选的实施例,区块链中的设备可对接收到的冻结请求进行验证,验证通过后对目标账户进行冻结。可选地,在客户端将生成的第一冻结请求发送给区块链中的设备之后,区块链中的设备对第一冻结请求中目标账户的私钥签名进行验证,目标账户的私钥和目标账户的公钥为一个密钥对,一般而言,目标账户的私钥仅用户自己知晓,换言之,目标账户的私钥可用于表征该用户的合法性,在验证时,可用目标账户的公钥对第一冻结请求进行解密(即对第一冻结请求中目标账户的私钥签名进行验证),能够解密,则说明所使用的公钥与签名用的私钥是一对密钥,且私钥是上述用户的目标账户的私钥,相当于验证通过,在验证通过之后,区块链中的设备确定记录目标账户的账户地址和冻结锁公钥的合法性,并将该账户地址和冻结锁公钥记录在冻结事件中,以根据该冻结锁公钥关联的冻结锁对目标地址对应的目标账户进行冻结,可选地,在记录冻结事件后,区块链中的设备拒绝对目标账户执行某些类型的资源转移。
可选地,第一冻结请求包括冻结类型,客户端将第一冻结请求发送给 区块链中的设备,以使区块链中的设备根据第一冻结请求记录冻结事件包括:将第一冻结请求发送给区块链中的设备,以指示区块链中的设备根据第一冻结请求拒绝对目标账户执行冻结类型的资源转移。
本申请还提供了一种可选实施例,该可选实施例中,在客户端生成的第一冻结请求中还包括冻结类型,以对目标账户进行与上述冻结类型相对应的冻结。可选地,该冻结类型可以但不限定为“完全禁止交易的冻结”或者“只禁止资产转出的冻结”等。为了保证账户安全,该冻结类型至少要禁止资产转出。可选地,客户端可以利用目标账户的私钥对目标账户的账户地址、冻结锁公钥以及上述冻结类型进行签名,得到第一数据,再根据第一数据生成第一冻结请求,最后将第一冻结请求发送给区块链中的设备,从而在区块链中的设备对第一冻结请求成功验证之后,拒绝对目标地址所对应的目标账户执行冻结类型中限定的资源转移。图3是根据本申请实施例的一种可选的区块链中账户的处理方法所生成的第一数据的示意图,如图3所示,客户端对目标账户的账户地址、冻结类型和冻结锁公钥进行签名得到第一数据,在生成的第一数据中,包括有目标账户的账户地址、冻结类型、冻结锁公钥以及账户私钥签名。
可选地,在客户端将第一冻结请求发送给区块链中的设备,以使区块链中的设备根据第一冻结请求记录冻结事件之后,方法还包括:客户端接收用户发送的解冻指令,其中,解冻指令用于指示解除利用冻结锁对目标账户进行的冻结;客户端根据解冻指令和冻结锁私钥生成解冻请求,其中,解冻请求用于请求利用冻结锁私钥将目标账户解冻,冻结锁私钥与冻结锁公钥相匹配;客户端将解冻请求发送给区块链中的设备,以使区块链中的设备根据解冻请求记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
作为一种可选的实施例,在对目标账户进行冻结之后,还可以对目标账户进行解冻。可选地,用户发送解冻指令,客户端接收用户发送的解冻指令,并根据解冻指令和冻结锁私钥生成解冻请求,这里的冻结锁私钥与 上述对目标账户进行冻结的冻结锁公钥相匹配,并且通过该冻结锁私钥能解除利用与其相匹配的冻结锁公钥进行的冻结。客户端将解冻请求发送给区块链中的设备,区块链中的设备根据解冻请求记录解冻事件,并根据记录的解冻事件允许对目标账户执行资源转移,从而对将目标账户解冻。需要说明的是区块链中的设备根据解冻请求记录的解冻事件,能解除利用与冻结锁私钥相匹配的冻结锁公钥对目标账户的冻结,当目标账户被多个冻结锁冻结时,单个解冻请求能解除解冻请求中包含的冻结锁私钥所对应的冻结锁,而无法使目标账户完全解冻。
可选地,客户端根据解冻指令和冻结锁私钥生成解冻请求包括:根据解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名,得到冻结锁私钥签名;利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名,得到第二数据;根据第二数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥签名和第二数据。
作为一种可选的实施例,在对目标账户进行解冻时,同样以目标账户的账户地址作为目标账户的标识,采用与冻结时的冻结锁公钥相匹配的冻结锁私钥对将目标账户解锁。并且,同样具有目标账户私钥的用户可以对目标账户进行解冻。因此,生成解冻请求时,客户端根据用户发送的解冻指令,获取要解冻的目标账户的账户地址、目标账户的私钥和对目标账户进行冻结的冻结锁公钥,然后利用冻结锁私钥对上述目标账户的地址和冻结锁公钥进行签名,得到冻结锁私钥签名,再利用目标账户的私钥对上述目标账户的地址、冻结锁公钥以及冻结锁私钥签名进行第二次签名得到第二数据,最后根据第二数据生成解冻请求。图4是根据本申请实施例的一种可选的区块链中账户的处理方法所生成的解冻请求的示意图,如图4所示,在生成的第二数据中包括目标账户的账户地址、冻结锁公钥、冻结锁私钥签名和目标账户的账户私钥签名。
可选地,客户端根据解冻指令和冻结锁私钥生成解冻请求包括:根据 解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,得到第三数据;最后根据第三数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥和第三数据。
作为一种可选的实施例,客户端还可以通过另一种方式生成解冻请求,可选地,客户端根据用户发送的解冻指令,获取要解冻的目标账户的账户地址、目标账户的私钥和对目标账户进行冻结的冻结锁公钥,然后利用目标账户的私钥对上述目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,从而得到第三数据,进一步地根据第三数据生成解冻请求,根据上述第三数据生成的解冻请求中包括有目标账户的账户地址、冻结锁公钥、冻结锁私钥以及第三数据。
需要说明的是,如果目标账户的私钥确定发生了泄露,如:目标账户的私钥已经被黑客获取,则黑客也可以利用获取的私钥对目标账户进行冻结,即在用户对目标账户进行冻结的基础上对目标账户进行重复冻结,使目标账户处于多重锁定状态。在目标账户处于多重锁定的状态下,任何单把“钥匙”(冻结锁私钥)都无法完全解除目标账户的冻结状态。因此,尽管由于黑客对目标账户进行重复冻结,使用户无法将账户解冻,但用户不对目标账户进行解冻,目标账户内的资源就是安全的,在该情况下,用户可以利用账户资源转移的方法,在不解冻目标账户的情况下将目标账户中的资源转移到新账户中。
根据本申请实施例,还提供了另一种区块链中账户的处理方法的方法实施例。
图5是根据本申请实施例的另一种可选的区块链中账户的处理方法的流程图,如图5所示,该方法可以包括以下步骤:
步骤S502,区块链中的设备接收第一冻结请求,第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,第一冻结请求用于请求对目标账户进行冻结,冻结锁根据用户发送的冻结指令生成,冻结锁包括冻结锁公钥;
步骤S504,区块链中的设备验证第一冻结请求;
步骤S506,在成功验证第一冻结请求的情况下,区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示区块链中的设备拒绝对目标账户执行资源转移。
通过上述步骤S502至步骤S506,通过区块链中的设备接收第一冻结请求,并根据第一冻结请求,利用冻结锁公钥对目标账户进行冻结,可以解决了由于账户私钥发生泄露造成的账户不安全的技术问题,进而达到在账户私钥发生泄露时,确保账户安全的技术效果。
可选地,区块链中的设备验证第一冻结请求包括:区块链中的设备获取目标账户的公钥;区块链中的设备利用目标账户的公钥验证第一冻结请求中由目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名得到的第一数据;在成功验证第一数据的情况下,区块链中的设备记录第一冻结请求中携带的冻结锁公钥和目标账户的账户地址。
作为一种可选的实施例,区块链中的设备在接收到第一冻结请求之后,需要通过验证目标账户的私钥签名,以确认发起第一冻结请求的用户的身份。可选地,区块链中的设备接收到第一冻结请求之后,区块链中的设备对第一冻结请求中目标账户的私钥签名进行验证,可选地,区块链中的设备从证书中心中获取目标账户的公钥,并利用目标账户的公钥对第一冻结请求中目标账户的私钥签名进行验证。区块链中通常包括多个节点,其中每个节点根据目标账户的公钥对目标账户的私钥签名进行验证,并在多数节点验证通过之后,认为区块链中的设备对第一冻结请求的验证通过。在区块链中的设备对第一冻结请求验证通过之后,区块链中的设备获取到目标账户的账户地址和冻结锁公钥,从而根据获取的账户地址和冻结锁公钥记录冻结事件,并根据记录的冻结事件拒绝对目标账户执行任何的资源转移。
可选地,在区块链中的设备根据第一冻结请求记录冻结事件之后,方法还包括:区块链中的设备接收解冻请求,解冻请求由用户发送的解冻指 令和冻结锁私钥生成,解冻请求用于请求解除利用冻结锁对目标账户进行的冻结;解冻请求还可以携带冻结锁公钥,解冻请求携带的冻结锁公钥与冻结请求携带的冻结锁公钥相同,冻结锁私钥与冻结锁公钥相匹配;区块链中的设备验证解冻请求中的冻结锁私钥签名和第二数据,或者,区块链中的设备验证解冻请求中的第三数据,其中,冻结锁私钥签名为利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名得到的,第二数据为利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名得到的,第三数据为利用目标账户的私钥对目标账户的账户地址、所述冻结锁公钥和冻结锁私钥进行签名得到的;在成功验证冻结锁私钥签名和第二数据的情况下,或者,在成功验证第三数据的情况下,区块链中的设备根据账户地址和冻结锁公钥记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
作为一种可选的实施例,在对目标账户进行冻结之后,还可以对目标账户进行解冻。可选地,由用户发送解冻指令,客户端接收用户发送的解冻指令,并根据解冻指令、冻结锁公钥和冻结锁私钥生成解冻请求,这里的冻结锁私钥与上述对目标账户进行冻结的冻结锁公钥相匹配,并且通过该冻结锁私钥可以并且能解除利用与其相匹配的冻结锁公钥进行的冻结。客户端将解冻请求发送给区块链中的设备,区块链中的设备接收该解冻请求,并对解冻请求中的数据进行验证。上述解冻请求是由客户端生成的,可选地,客户端可以利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名得到冻结锁私钥签名,再利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名,得到第二数据,最后根据第二数据生成解冻请求。或者,客户可以利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,得到第三数据,最后根据第三数据生成解冻请求。区块链中的设备可对解冻请求中的签名进行验证。可选地,当解冻请求由第二数据生成时,区块链中的设备可验证冻结锁私钥签名和第二数据,当解冻请求由第三数据生成时,区块链中的设备需要验证第三数据。区块链中的设备在验证成功的情况下,根据解冻请求 记录解冻事件,并根据记录的解冻事件允许对目标账户执行资源转移,从而对将目标账户解冻。
可选地,在区块链中的设备根据第一冻结请求记录冻结事件之后,方法还包括:区块链中的设备接收第二冻结请求,其中,第二冻结请求用于请求对目标账户进行冻结;区块链中的设备判断发送第一冻结请求的第一发送地址与发送第二冻结请求的第二发送地址是否一致;如果第一发送地址与第二发送地址一致,则判断发送第一冻结请求与发送第二冻结请求的时间间隔是否大于预设时间;如果时间间隔小于或者等于预设时间,则拒绝第二冻结请求。
作为一种可选的实施例,由于可以对目标账户进行重复冻结,为了避免有人通过不停地提交冻结请求来攻击区块链网络,对同一地址提交冻结请求的时间间隔进行限制。可选地,在区块链中的设备在接收到第一冻结请求之后,又再次接收到第二冻结请求,则区块链中的设备首先判断发送第一冻结请求的第一地址和发送第二冻结请求的第二地址是否是同一地址,如果第一地址和第二地址为同一地址,则再次判断发送第一冻结请求与发送第二冻结请求的时间间隔是否大于预设时间,在发送第二冻结请求与发送第一冻结请求的时间间隔大于预设时间时,区块链中的设备才会接受第二冻结请求,如果上述时间间隔小于或者等于预设时间,则区块链中的设备拒绝第二次冻结请求。
可选地,在区块链中的设备根据第一冻结请求记录冻结事件之后,方法还包括:区块链中的设备接收第二冻结请求,其中,第二冻结请求用于请求对目标账户进行冻结;区块链中的设备判断目标账户当前被冻结锁冻结的次数是否等于预设阈值;如果目标账户当前被冻结锁冻结的次数等于预设阈值,则区块链中的设备拒绝第二冻结请求。
作为一种可选的实施例,还可以对同一账户的最大冻结次数进行限定,以避免有人通过不停对同一账户发送冻结请求来攻击区块链中的设备网络。可选地,在区块链中的设备在接收到第一冻结请求之后,又再次接收 到第二冻结请求,则区块链中的设备判断当前目标账户被通过冻结锁设置为冻结的次数是否为预设阈值,如果目标账户被通过冻结锁设置为冻结的次数等于预设阈值,表明目标账户当前被多重锁定的次数已经达到了上限,区块链中的设备拒绝第二次冻结请求。并且,在当前被多重锁定的次数已经达到了上限后,区块链中的设备不允许再对目标账户进行解冻,用户能通过资源找回的方式将目标账户资源转移到新账户中。在目标账户冻结次数达到上限之后禁止目标账户冻结可以防止黑客对目标账户进行重复锁定以达到冻结上限,而让用户无法再次冻结账户,而后黑客再逐个解冻重复锁定,从而给用户造成账户风险。
通过上述本申请实施例提供的区块链中账户的处理方法,在目标账户的私钥发生泄露或者疑似泄露时,对目标账户进行快速冻结,从而确保了目标账户的安全。在本申请实施例中,用户无论在确认目标账户私钥泄露,还是怀疑目标账户的私钥发生泄露,也或者目标账户被不明冻结时,用户可以立即发起对目标账户的冻结,以在第一时间通过冻结目标账户的方式保护目标账户的安全。在确认目标账户的私钥未发生泄露时,将目标账户解冻,而在确认目标账户的私钥确实发生泄露,或者已无法确认目标账户的私钥究竟是否发生泄露时,保持目标账户的冻结。用户冻结账户之后,确认目标账户的私钥确实未发生泄露时才能将其解冻,而不能随意将目标账户解冻。可选地,由于目标账户的用户可能存在多个,每一个用户都拥有目标账户的私钥,可以对目标账户进行冻结,因此,目标账户可以被重复冻结,在确认目标账户私钥确实未发生泄露时,在对目标账户发起冻结的所有用户发起解冻请求之后,目标账户解冻。当目标账户可以被进行重复冻结时,应当设置目标账户被重复冻结的最大次数,以防止黑客通过不停对目标账户进行冻结对区块链中的设备进行攻击,使区块链网络因重负荷而发生崩溃。而在设置了目标账户最大冻结次数之后,可以在目标账户被冻结的次数达到最大次数时,永久冻结目标账户,禁止通过冻结请求将目标账户再次解冻,以此来防止非法用户在获取目标账户的私钥之后,对目标账户进行重复冻结达到目标账户的最大冻结次数,使真正的用户无法 通过将目标账户冻结来确保目标账户的安全,而非法用户则可以寻找机会将目标账用户解冻,进而盗取目标账户中的资源。需要说明的是,当将目标账户最大冻结次数设置为1时,目标账户实质上能被冻结一次,而不能被重复冻结。此时对目标账户进行的冻结即为永久冻结。当目标账户被永久冻结时,用户可以通过资源找回的方式,将目标账户中的资源转移到新账户中。
需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请并不受所描述的动作顺序的限制,因为依据本申请,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本申请所必须的。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到根据上述实施例的方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,或者网络设备等)执行本申请各个实施例所述的方法。
根据本申请实施例,还提供了一种用于实施上述区块链中账户的处理方法的区块链中账户的处理装置。图6是根据本申请实施例的一种可选的区块链中账户的处理装置的示意图,如图6所示,该装置可以包括:第一接收单元610、第一生成单元620、第二生成单元630和第一发送单元640。
第一接收单元610,用于被设置为接收用户发送的冻结指令,其中,所述冻结指令用于指示将目标账户冻结;第一生成单元620,用于被设置为根据接收到的冻结指令生成冻结锁,其中,所述冻结锁包括冻结锁公钥;第二生成单元630,用于被设置为根据所述冻结指令和所述冻结锁公钥生 成第一冻结请求,其中,所述第一冻结请求用于请求利用所述冻结锁对所述目标账户进行冻结;第一发送单元640,用于被设置为将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
需要说明的是,该实施例中的第一接收单元610可以用于执行本申请实施例中的步骤S202,该实施例中的第一生成单元620可以用于执行本申请实施例中的步骤S204,该实施例中的第二生成单元630可以用于执行本申请实施例中的步骤S206,该实施例中的第一发送单元640可以用于执行本申请实施例中的步骤S208。
此处需要说明的是,上述单元与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。需要说明的是,上述单元作为装置的一部分可以运行在如图1所示的硬件环境中,可以通过软件实现,也可以通过硬件实现。
通过上述单元,可以解决由于账户私钥发生泄露造成的账户不安全的技术问题,进而达到在账户私钥发生泄露时,确保账户安全的技术效果。
可选地,第二生成单元包括:第一获取模块,被设置为根据冻结指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;第一签名模块,被设置为利用目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名,得到第一数据;第一生成模块,被设置为根据第一数据生成第一冻结请求,其中,第一冻结请求包括目标账户的账户地址、冻结锁公钥和目标账户的私钥签名。
作为一种可选的实施例,在对目标账户进行冻结时,以目标账户的账户地址作为目标账户的标识,通过生成冻结锁,将冻结锁公钥提交给区块链中的设备,从而采用冻结锁对应的锁对目标账户加锁,除此以外,具有目标账户私钥的用户可以对目标账户进行冻结,因此,生成第一冻结请求时,第一获取模块根据用户发出的冻结指令,获取要冻结的目标账户的账 户地址、目标账户的私钥,以及冻结锁公钥,然后第一签名模块利用目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名得到第一数据,最后第一生成模块根据第一数据生成第一冻结请求,在第一冻结请求中包括目标账户的账户地址,冻结锁公钥以及目标账户的私钥签名,在将第一冻结请求发送给区块链中的设备之后,区块链中的设备可以根据第一冻结请求拒绝对目标账户执行资源转移,从而完成对目标账户的冻结。
可选地,装置还包括:第一验证单元,被设置为在将第一冻结请求发送给区块链中的设备之后,通过区块链中的设备根据第一冻结请求对目标账户的私钥签名进行验证;第一记录单元,被设置为在验证通过之后,通过区块链中的设备记录目标账户的账户地址和冻结锁公钥;第二记录单元,被设置为通过区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示采用冻结锁公钥对目标账户进行冻结。
作为一种可选的实施例,区块链中的设备需要对接收到的冻结请求进行验证,验证通过后对目标账户进行冻结。可选地,在将生成的第一冻结请求发送给区块链中的设备之后,第一验证单元通过区块链中的设备对第一冻结请求中目标账户的私钥签名进行验证,在验证通过之后,区块链中的设备确定记录目标账户的账户地址和冻结锁公钥的合法性,第二记录单元将该账户地址和冻结锁公钥记录在冻结事件中,以根据该冻结锁公钥关联的冻结锁对目标地址对应的目标账户进行冻结,可选地,在记录冻结事件后,区块链中的设备拒绝对目标账户执行某些类型的资源转移。
可选地,第一冻结请求包括冻结类型,第一发送单元包括:发送模块,被设置为将第一冻结请求发送给区块链中的设备,以指示区块链中的设备根据第一冻结请求拒绝对目标账户执行冻结类型的资源转移。
本申请还提供了一种可选实施例,该可选实施例中,在客户端生成的第一冻结请求中还包括冻结类型,以对目标账户进行与上述冻结类型相对应的冻结。可选地,该冻结类型可以但不限定为“完全禁止交易的冻结”或者“只禁止资产转出的冻结”等。为了保证账户安全,该冻结类型至少 要禁止资产转出。可选地,客户端可以利用目标账户的私钥对目标账户的账户地址、冻结锁公钥以及上述冻结类型进行签名,得到第一数据,再根据第一数据生成第一冻结请求,最后发送模块将第一冻结请求发送给区块链中的设备,从而在区块链中的设备对第一冻结请求成功验证之后,拒绝对目标地址所对应的目标账户执行冻结类型中限定的资源转移。
可选地,装置还包括:第二接收单元,被设置为在将第一冻结请求发送给区块链中的设备,以使区块链中的设备根据第一冻结请求记录冻结事件之后,接收用户发送的解冻指令,其中,解冻指令用于指示解除利用冻结锁对目标账户进行的冻结;第三生成单元,被设置为根据解冻指令和冻结锁私钥生成解冻请求,其中,解冻请求用于请求利用冻结锁私钥将目标账户解冻,冻结锁私钥与冻结锁公钥相匹配;第二发送单元,被设置为将解冻请求发送给区块链中的设备,以使区块链中的设备根据解冻请求记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
作为一种可选的实施例,在对目标账户进行冻结之后,还可以对目标账户进行解冻。可选地,用户发送解冻指令,第二接收单元接收用户发送的解冻指令,第三生成单元根据解冻指令和冻结锁私钥生成解冻请求,这里的冻结锁私钥与上述对目标账户进行冻结的冻结锁公钥相匹配,并且通过该冻结锁私钥能够解除利用与其相匹配的冻结锁进行的冻结。第二发送单元将解冻请求发送给区块链中的设备,区块链中的设备根据解冻请求记录解冻事件,并根据记录的解冻事件允许对目标账户执行资源转移,从而对将目标账户解冻。需要说明的是区块链中的设备根据解冻请求记录的解冻事件,能解除利用与冻结锁私钥相匹配的冻结锁对目标账户的冻结,当目标账户被多个冻结锁冻结时,单个解冻请求能解除解冻请求中包含的冻结锁私钥所对应的冻结锁,而无法使目标账户完全解冻。
可选地,第三生成单元包括:第二获取模块,被设置为根据解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;第二签名模块, 被设置为利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名,得到冻结锁私钥签名;第三签名模块,被设置为利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名,得到第二数据;第二生成模块,被设置为根据第二数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥签名和第二数据。
作为一种可选的实施例,在对目标账户进行解冻时,同样以目标账户的账户地址作为目标账户的标识,采用与冻结时的冻结锁公钥相匹配的冻结锁私钥对将目标账户解锁。并且,同样具有目标账户私钥的用户可以对目标账户进行解冻。因此,生成解冻请求时,第二获取模块根据用户发送的解冻指令,获取要解冻的目标账户的账户地址、目标账户的私钥和对目标账户进行冻结的冻结锁公钥,然后第二签名模块利用冻结锁私钥对上述目标账户的地址和冻结锁公钥进行签名,得到冻结锁私钥签名,第三签名模块利用目标账户的私钥对上述目标账户的地址、冻结锁公钥以及冻结锁私钥签名进行第二次签名得到第二数据,最后第二生成模块根据第二数据生成解冻请求。
可选地,第三生成单元包括:第三获取模块,被设置为根据解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;第四签名模块,被设置为利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,得到第三数据;第三生成模块,被设置为根据第三数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥和第三数据。
作为一种可选的实施例,客户端还可以通过另一种方式生成解冻请求,可选地,第三获取模块根据用户发送的解冻指令,获取要解冻的目标账户的账户地址、目标账户的私钥和对目标账户进行冻结的冻结锁公钥,然后第四签名模块利用目标账户的私钥对上述目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,从而得到第三数据,进一步地第三生成模块根据第三数据生成解冻请求,根据上述第三数据生成的解冻请求中包括有目 标账户的账户地址、冻结锁公钥、冻结锁私钥以及第三数据。
需要说明的是,如果目标账户的私钥确定发生了泄露,如:目标账户的私钥已经被黑客获取,则黑客也可以利用获取的私钥对目标账户进行冻结,即在用户对目标账户进行冻结的基础上对目标账户进行重复冻结,使目标账户处于多重锁定状态。在目标账户处于多重锁定的状态下,任何单把“钥匙”(冻结锁私钥)都无法完全解除目标账户的冻结状态。因此,尽管由于黑客对目标账户进行重复冻结,使用户无法将账户解冻,但用户不对目标账户进行解冻,目标账户内的资源就是安全的。
根据本申请实施例,还提供了另一种用于实施上述区块链中账户的处理方法的区块链中账户的处理装置。图7是根据本申请实施例的一种可选的区块链中账户的处理装置的示意图,如图7所示,该装置可以包括:第三接收单元710、第二验证单元720和第三记录单元730。
第三接收单元710,被设置为通过区块链中的设备接收第一冻结请求,其中,所述第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,所述第一冻结请求用于请求对目标账户进行冻结,所述冻结锁根据所述用户发送的冻结指令生成,所述冻结锁包括冻结锁公钥;第二验证单元720,被设置为通过所述区块链中的设备验证所述第一冻结请求;第三记录单元730,被设置为在成功验证所述第一冻结请求的情况下,通过所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
需要说明的是,该实施例中的第三接收单元710可以用于执行本申请实施例中的步骤S502,该实施例中的第二验证单元720可以用于执行本申请实施例中的步骤S504,该实施例中的第三记录单元730可以用于执行本申请实施例中的步骤S506。
此处需要说明的是,上述单元与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。需要说明的是,上述单元作为装置的一部分可以运行在如图1所示的硬件环境中,可以通过软件实现, 也可以通过硬件实现。
通过上述单元,可以解决了由于账户私钥发生泄露造成的账户不安全的技术问题,进而达到在账户私钥发生泄露时,确保账户安全的技术效果。
可选地,第二验证单元包括:第四获取模块,被设置为通过区块链中的设备获取目标账户的公钥;验证模块,被设置为通过区块链中的设备利用目标账户的公钥验证第一冻结请求中由目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名得到的第一数据;第五获取模块,被设置为在成功验证第一数据的情况下,通过区块链中的设备记录第一冻结请求中携带的冻结锁公钥和目标账户的账户地址。
作为一种可选的实施例,区块链中的设备在接收到第一冻结请求之后,需要通过验证目标账户的私钥签名,以确认发起第一冻结请求的用户的身份。可选地,区块链中的设备接收到第一冻结请求之后,区块链中的设备对第一冻结请求中目标账户的私钥签名进行验证,可选地,第四获取模块通过区块链中的设备从证书中心中获取目标账户的公钥,并利用目标账户的公钥对第一冻结请求中目标账户的私钥签名进行验证。区块链中通常包括多个节点,其中每个节点根据目标账户的公钥对目标账户的私钥签名进行验证,并在多数节点验证通过之后,认为区块链中的设备对第一冻结请求的验证通过。在区块链中的设备对第一冻结请求验证通过之后,区块链中的设备获取到目标账户的账户地址和冻结锁公钥,从而第五获取模块通过区块链中的设备根据获取的账户地址和冻结锁公钥记录冻结事件,并根据记录的冻结事件拒绝对目标账户执行任何的资源转移。
可选地,装置还包括:第四接收单元,被设置为在区块链中的设备根据第一冻结请求记录冻结事件之后,通过区块链中的设备接收解冻请求,解冻请求由用户发送的解冻指令和冻结锁私钥生成,解冻请求用于请求解除利用冻结锁对目标账户进行的冻结;解冻请求还可以携带冻结锁公钥,解冻请求携带的冻结锁公钥与冻结请求携带的冻结锁公钥相同,冻结锁私钥与冻结锁公钥相匹配;第三验证单元,被设置为通过区块链中的设备验 证解冻请求中的冻结锁私钥签名和第二数据,或者,区块链中的设备验证解冻请求中的第三数据,其中,所述冻结锁私钥签名为利用所述冻结锁私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名得到的,所述第二数据为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥目标账户的私钥和所述冻结锁私钥签名进行签名得到的,所述第三数据为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥所述目标账户的私钥和所述冻结锁私钥进行签名得到的;第四记录单元,被设置为在成功验证冻结锁私钥签名和第二数据的情况下,或者,在成功验证第三数据的情况下,通过区块链中的设备根据账户地址和冻结锁公钥记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
作为一种可选的实施例,在对目标账户进行冻结之后,还可以对目标账户进行解冻。可选地,由用户发送解冻指令,客户端接收用户发送的解冻指令,并根据解冻指令、冻结锁公钥和冻结锁私钥生成解冻请求,这里的冻结锁私钥与上述对目标账户进行冻结的冻结锁公钥相匹配,并且通过该冻结锁私钥可以解除利用与其相匹配的冻结锁公钥进行的冻结。客户端将解冻请求发送给区块链中的设备,第四接收单元通过区块链中的设备接收该解冻请求,并对解冻请求中的数据进行验证。上述解冻请求是由客户端生成的,可选地,客户端可以利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名得到冻结锁私钥签名,再利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名,得到第二数据,最后根据第二数据生成解冻请求。或者,客户可以利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,得到第三数据,最后根据第三数据生成解冻请求。区块链中的设备需要对解冻请求中的签名进行验证。可选地,当解冻请求由第二数据生成时,第三验证单元通过区块链中的设备需要验证冻结锁私钥签名和第二数据,当解冻请求由第三数据生成时,第三验证单元通过区块链中的设备需要验证第三数据。第四记录单元通过区块链中的设备在验证成功的情况下,根据解冻请求记录解 冻事件,并根据记录的解冻事件允许对目标账户执行资源转移,从而对将目标账户解冻。
可选地,装置还包括:第五接收单元,被设置为在区块链中的设备根据第一冻结请求记录冻结事件之后,通过区块链中的设备接收第二冻结请求,其中,第二冻结请求用于请求对目标账户进行冻结;判断单元,被设置为通过区块链中的设备判断目标账户当前被冻结锁冻结的次数是否等于预设阈值;拒绝单元,被设置为在目标账户当前被冻结锁冻结的次数等于预设阈值时,通过区块链中的设备拒绝第二冻结请求。
作为一种可选的实施例,还可以对同一账户的最大冻结次数进行限定,以避免有人通过不停对同一账户发送冻结请求来攻击区块链网络。可选地,在区块链中的设备在接收到第一冻结请求之后,第五接收单元通过区块链中的设备再次接收到第二冻结请求,则判断单元通过区块链中的设备判断当前目标账户被通过冻结锁设置为冻结的次数是否为预设阈值,如果目标账户被通过冻结锁设置为冻结的次数等于预设阈值,表明目标账户当前被多重锁定的次数已经达到了上限,拒绝单元通过区块链中的设备拒绝第二次冻结请求。并且,在当前被多重锁定的次数已经达到了上限后,区块链中的设备不允许再对目标账户进行解冻,用户能通过资源找回的方式将目标账户资源转移到新账户中。在目标账户冻结次数达到上限之后禁止目标账户冻结可以防止黑客对目标账户进行重复锁定以达到冻结上限,而让用户无法再次冻结账户,而后黑客再逐个解冻重复锁定,从而给用户造成账户风险。
此处需要说明的是,上述模块与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例所公开的内容。需要说明的是,上述模块作为装置的一部分可以运行在如图1所示的硬件环境中,可以通过软件实现,也可以通过硬件实现,其中,硬件环境包括网络环境。
根据本申请实施例的另一方面,还提供了一种存储介质(也称为存储器),该存储介质包括存储的程序,其中,该程序被设置为运行时执行上 述的任一种方法。
根据本申请实施例,还提供了一种用于实施上述区块链中账户的处理方法的终端(也称为计算机设备)。
图8是根据本申请实施例的一种终端的结构框图,如图8所示,该终端可以包括:一个或多个(图8中仅示出一个)处理器801、存储器803、以及传输装置805(如上述实施例中的发送装置),如图8所示,该终端还可以包括输入输出设备807。
其中,存储器803可用于存储软件程序以及模块,如本申请实施例中的区块链中账户的处理方法和装置对应的程序指令/模块,处理器801通过运行存储在存储器803内的软件程序以及模块,从而执行各种功能应用以及数据处理,即实现上述的区块链中账户的处理方法。存储器803可包括高速随机存储器,还可以包括非易失性存储器,如一个或者多个磁性存储装置、闪存、或者其他非易失性固态存储器。在一些实例中,存储器803可进一步包括相对于处理器801远程设置的存储器,这些远程存储器可以通过网络连接至终端。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。
上述的传输装置805用于经由一个网络接收或者发送数据,还可以用于处理器与存储器之间的数据传输。上述的网络具体实例可包括有线网络及无线网络。在一个实例中,传输装置805包括一个网络适配器(Network Interface Controller,NIC),其可通过网线与其他网络设备与路由器相连从而可与互联网或局域网进行通讯。在一个实例中,传输装置805为射频(Radio Frequency,RF)模块,其用于通过无线方式与互联网进行通讯。
其中,可选地,存储器803用于存储应用程序。
处理器801可以通过传输装置805调用存储器803存储的应用程序,以执行下述步骤:接收用户发送的冻结指令,其中,冻结指令用于指示将目标账户冻结;根据接收到的冻结指令生成冻结锁,其中,冻结锁包括冻 结锁公钥;根据冻结指令和冻结锁公钥生成第一冻结请求,其中,第一冻结请求用于请求利用冻结锁对目标账户进行冻结;将第一冻结请求发送给区块链中的设备,以使区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示区块链中的设备拒绝对目标账户执行资源转移。
处理器801还用于执行下述步骤:根据冻结指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名,得到第一数据;根据第一数据生成第一冻结请求,其中,第一冻结请求包括目标账户的账户地址、冻结锁公钥和目标账户的私钥签名。
处理器801还用于执行下述步骤:通过区块链中的设备根据第一冻结请求对目标账户的私钥签名进行验证;在验证通过之后,通过区块链中的设备记录目标账户的账户地址和冻结锁公钥;通过区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示采用冻结锁公钥对目标账户进行冻结。
处理器801还用于执行下述步骤:将第一冻结请求发送给区块链中的设备,以指示区块链中的设备根据第一冻结请求拒绝对目标账户执行冻结类型的资源转移。
处理器801还用于执行下述步骤:接收用户发送的解冻指令,其中,解冻指令用于指示解除利用冻结锁对目标账户进行的冻结;根据解冻指令和冻结锁私钥生成解冻请求,其中,解冻请求用于请求利用冻结锁私钥将目标账户解冻,冻结锁私钥与冻结锁公钥相匹配;将解冻请求发送给区块链中的设备,以使区块链中的设备根据解冻请求记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
处理器801还用于执行下述步骤:根据解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名,得到冻结锁私钥签名;利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名,得到第 二数据;根据第二数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥签名和第二数据。
处理器801还用于执行下述步骤:根据解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,得到第三数据;根据第三数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥和第三数据。
处理器801还用于执行下述步骤:通过区块链中的设备接收第一冻结请求,其中,第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,第一冻结请求用于请求对目标账户进行冻结,冻结锁根据用户发送的冻结指令生成,冻结锁包括冻结锁公钥;通过区块链中的设备验证第一冻结请求;在成功验证第一冻结请求的情况下,通过区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示区块链中的设备拒绝对目标账户执行资源转移。
处理器801还用于执行下述步骤:通过区块链中的设备获取目标账户的公钥;通过区块链中的设备利用目标账户的公钥验证第一冻结请求中由目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名得到的第一数据;在成功验证第一数据的情况下,通过区块链中的设备记录第一冻结请求中携带的冻结锁公钥和目标账户的账户地址。
处理器801还用于执行下述步骤:通过区块链中的设备接收解冻请求,解冻请求由用户发送的解冻指令和冻结锁私钥生成,解冻请求用于请求解除利用冻结锁对目标账户进行的冻结;通过区块链中的设备验证解冻请求中的冻结锁私钥签名和第二数据,或者,区块链中的设备验证解冻请求中的第三数据,其中,冻结锁私钥签名为利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名得到的,第二数据为利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名得到的,第三数据为利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁 私钥进行签名得到的;在成功验证冻结锁私钥签名和第二数据的情况下,或者,在成功验证第三数据的情况下,通过区块链中的设备根据账户地址和冻结锁公钥记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
处理器801还用于执行下述步骤:通过区块链中的设备接收第二冻结请求,其中,第二冻结请求用于请求对目标账户进行冻结;通过区块链中的设备判断目标账户当前被冻结锁冻结的次数是否等于预设阈值;如果目标账户当前被冻结锁冻结的次数等于预设阈值,则区块链中的设备拒绝第二冻结请求。
采用本申请实施例,提供了一种实施区块链中账户的处理方法的终端的方案。通过生成由冻结锁,并利用冻结锁中的冻结锁公钥对目标账户进行冻结,达到了确保目标账户安全的目的,从而实现了在账户私钥发生泄露时,确保账户安全的技术效果,进而解决了由于账户私钥发生泄露造成的账户不安全的技术问题。
可选地,本实施例中的具体示例可以参考上述实施例中所描述的示例,本实施例在此不再赘述。
本领域普通技术人员可以理解,图8所示的结构仅为示意,终端可以是智能手机(如Android手机、iOS手机等)、平板电脑、掌上电脑以及移动互联网设备(Mobile Internet Devices,MID)、PAD等终端设备。图8其并不对上述电子装置的结构造成限定。例如,终端还可包括比图8中所示更多或者更少的组件(如网络接口、显示装置等),或者具有与图8所示不同的配置。
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令终端设备相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:闪存盘、只读存储器(Read‐Only Memory,ROM)、随机存取器(Random Access Memory,RAM)、磁盘或光盘等。
本申请的实施例还提供了一种存储介质。可选地,在本实施例中,上述存储介质可以存储用于执行上述的区块链中账户的处理方法的程序代码。
可选地,在本实施例中,上述存储介质可以位于上述实施例所示的网络中的多个网络设备中的至少一个网络设备上。
可选地,在本实施例中,存储介质被设置为存储用于执行以下步骤的程序代码:
S1,接收用户发送的冻结指令;
S2,根据接收到的冻结指令生成冻结锁;
S3,根据冻结指令和冻结锁公钥生成第一冻结请求;
S4,将第一冻结请求发送给区块链中的设备,以使区块链中的设备根据第一冻结请求记录冻结事件。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:根据冻结指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名,得到第一数据;根据第一数据生成第一冻结请求,其中,第一冻结请求包括目标账户的账户地址、冻结锁公钥和目标账户的私钥签名。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:区块链中的设备根据第一冻结请求对目标账户的私钥签名进行验证;在验证通过之后,区块链中的设备记录目标账户的账户地址和冻结锁公钥;区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示采用冻结锁公钥对目标账户进行冻结。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:将第一冻结请求发送给区块链中的设备,以指示区块链中的设备根据第一冻结请求拒绝对目标账户执行冻结类型的资源转移。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:接收用户发送的解冻指令,其中,解冻指令用于指示解除利用冻结锁对目标账户进行的冻结;根据解冻指令和冻结锁私钥生成解冻请求,其中,解冻请求用于请求利用冻结锁私钥将目标账户解冻,冻结锁私钥与冻结锁公钥相匹配;将解冻请求发送给区块链中的设备,以使区块链中的设备根据解冻请求记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:根据解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名,得到冻结锁私钥签名;利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名,得到第二数据;根据第二数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥签名和第二数据。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:根据解冻指令获取目标账户的账户地址、目标账户的私钥和冻结锁公钥;利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名,得到第三数据;根据第三数据生成解冻请求,解冻请求包括目标账户的账户地址、冻结锁公钥、冻结锁私钥和第三数据。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:通过区块链中的设备接收第一冻结请求,其中,第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,第一冻结请求用于请求对目标账户进行冻结,冻结锁根据用户发送的冻结指令生成,冻结锁包括冻结锁公钥;通过区块链中的设备验证第一冻结请求;在成功验证第一冻结请求的情况下,通过区块链中的设备根据第一冻结请求记录冻结事件,其中,冻结事件用于指示区块链中的设备拒绝对目标账户执行资源转移。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:通 过区块链中的设备获取目标账户的公钥;通过区块链中的设备利用目标账户的公钥验证第一冻结请求中由目标账户的私钥对目标账户的账户地址和冻结锁公钥进行签名得到的第一数据;在成功验证第一数据的情况下,通过区块链中的设备记录第一冻结请求中携带的冻结锁公钥和目标账户的账户地址。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:通过区块链中的设备接收解冻请求,解冻请求由用户发送的解冻指令和冻结锁私钥生成,解冻请求用于请求解除利用冻结锁对目标账户进行的冻结;通过区块链中的设备验证解冻请求中的冻结锁私钥签名和第二数据,或者,区块链中的设备验证解冻请求中的第三数据,其中,冻结锁私钥签名为利用冻结锁私钥对目标账户的账户地址和冻结锁公钥进行签名得到的,第二数据为利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥签名进行签名得到的,第三数据为利用目标账户的私钥对目标账户的账户地址、冻结锁公钥和冻结锁私钥进行签名得到的;在成功验证冻结锁私钥签名和第二数据的情况下,或者,在成功验证第三数据的情况下,通过区块链中的设备根据账户地址和冻结锁公钥记录解冻事件,其中,解冻事件用于指示区块链中的设备解除利用冻结锁对目标账户进行的冻结。
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:通过区块链中的设备接收第二冻结请求,其中,第二冻结请求用于请求对目标账户进行冻结;通过区块链中的设备判断目标账户当前被冻结锁冻结的次数是否等于预设阈值;如果目标账户当前被冻结锁冻结的次数等于预设阈值,则区块链中的设备拒绝第二冻结请求。
可选地,本实施例中的具体示例可以参考上述实施例中所描述的示例,本实施例在此不再赘述。
可选地,在本实施例中,上述存储介质可以包括但不限于:U盘、只读存储器(ROM,Read‐Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介 质。
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。
上述实施例中的集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在上述计算机可读取的存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在存储介质中,包括若干指令用以使得一台或多台计算机设备(可为个人计算机、服务器或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。
在本申请的上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。
在本申请所提供的几个实施例中,应该理解到,所揭露的客户端,可通过其它的方式实现。其中,以上所描述的装置实施例仅仅是示意性的,例如所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,单元或模块的间接耦合或通信连接,可以是电性或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
以上所述仅是本申请的可选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本申请原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本申请的保护范围。
Claims (24)
- 一种区块链中账户的处理方法,包括:计算机设备接收用户发送的冻结指令,其中,所述冻结指令用于指示将目标账户冻结;所述计算机设备根据接收到的冻结指令生成冻结锁,其中,所述冻结锁包括冻结锁公钥;所述计算机设备根据所述冻结指令和所述冻结锁公钥生成第一冻结请求,其中,所述第一冻结请求用于请求利用所述冻结锁对所述目标账户进行冻结;所述计算机设备将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
- 根据权利要求1所述的方法,其中,根据所述冻结指令和所述冻结锁公钥生成第一冻结请求包括:根据所述冻结指令获取所述目标账户的账户地址、所述目标账户的私钥和所述冻结锁公钥;利用所述目标账户的私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名,得到第一数据;根据所述第一数据生成所述第一冻结请求,其中,所述第一冻结请求包括所述目标账户的账户地址、所述冻结锁公钥和所述目标账户的私钥签名。
- 根据权利要求2所述的方法,其中,在将所述第一冻结请求发送给区块链中的设备之后,所述方法还包括:所述区块链中的设备根据所述第一冻结请求对所述目标账户的私钥签名进行验证;在验证通过之后,所述区块链中的设备记录所述目标账户的账户地址和所述冻结锁公钥;所述区块链中的设备根据所述第一冻结请求记录所述冻结事件,其中,所述冻结事件用于指示采用所述冻结锁公钥对所述目标账户进行冻结。
- 根据权利要求1所述的方法,其中,所述第一冻结请求包括冻结类型,将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件包括:将所述第一冻结请求发送给区块链中的设备,以指示所述区块链中的设备根据所述第一冻结请求拒绝对所述目标账户执行所述冻结类型的资源转移。
- 根据权利要求1所述的方法,其中,在将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件之后,所述方法还包括:所述计算机设备接收所述用户发送的解冻指令,其中,所述解冻指令用于指示解除利用所述冻结锁对所述目标账户进行的冻结;所述计算机设备根据所述解冻指令和冻结锁私钥生成解冻请求,其中,所述解冻请求用于请求利用所述冻结锁私钥将所述目标账户解冻,所述冻结锁私钥与所述冻结锁公钥相匹配;所述计算机设备将所述解冻请求发送给所述区块链中的设备,以使所述区块链中的设备根据所述解冻请求记录解冻事件,其中,所述解冻事件用于指示所述区块链中的设备解除利用所述冻结锁对所述目标账户进行的冻结。
- 根据权利要求5所述的方法,其中,根据所述解冻指令和所述冻结锁私钥生成解冻请求包括:根据所述解冻指令获取所述目标账户的账户地址、所述目标账户的私钥和所述冻结锁公钥;利用所述冻结锁私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名,得到冻结锁私钥签名;利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥签名进行签名,得到第二数据;根据所述第二数据生成所述解冻请求,所述解冻请求包括所述目标账户的账户地址、所述冻结锁公钥、所述冻结锁私钥签名和第二数据。
- 根据权利要求5所述的方法,其中,根据所述解冻指令和所述冻结锁私钥生成解冻请求包括:根据所述解冻指令获取所述目标账户的账户地址、所述目标账户的私钥和所述冻结锁公钥;利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥进行签名,得到第三数据;根据所述第三数据生成所述解冻请求,所述解冻请求包括所述目标账户的账户地址、所述冻结锁公钥、所述冻结锁私钥和所述第三数据。
- 一种区块链中账户的处理方法,包括:区块链中的设备接收第一冻结请求,其中,所述第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,所述第一冻结请求用于请求对目标账户进行冻结,所述冻结锁根据所述用户发送的冻结指令生成,所述冻结锁包括冻结锁公钥;所述区块链中的设备验证所述第一冻结请求;在成功验证所述第一冻结请求的情况下,所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
- 根据权利要求8所述的方法,其中,所述区块链中的设备验证所述第一冻结请求包括:所述区块链中的设备获取所述目标账户的公钥;所述区块链中的设备利用所述目标账户的公钥验证所述第一冻结请求中由所述目标账户的私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名得到的第一数据;在成功验证所述第一数据的情况下,所述区块链中的设备记录所述第一冻结请求中携带的所述冻结锁公钥和目标账户的账户地址。
- 根据权利要求9所述的方法,其中,在所述区块链中的设备根据所述第一冻结请求记录冻结事件之后,所述方法还包括:所述区块链中的设备接收解冻请求,所述解冻请求由用户发送的解冻指令和冻结锁私钥生成,所述解冻请求用于请求解除利用所述冻结锁对所述目标账户进行的冻结;所述区块链中的设备验证所述解冻请求中的冻结锁私钥签名和第二数据,或者,所述区块链中的设备验证所述解冻请求中的第三数据,其中,所述冻结锁私钥签名为利用所述冻结锁私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名得到的,所述第二数据为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥签名进行签名得到的,所述第三数据为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥进行签名得到的;在成功验证所述冻结锁私钥签名和所述第二数据的情况下,或者,在成功验证所述第三数据的情况下,所述区块链中的设备根据所述账户地址和所述冻结锁公钥记录解冻事件,其中,所述解冻事件用于指示所述区块链中的设备解除利用所述冻结锁对所述目标账户进行的冻结。
- 根据权利要求8所述的方法,其中,在所述区块链中的设备根据所述第一冻结请求记录冻结事件之后,所述方法还包括:所述区块链中的设备接收第二冻结请求,其中,所述第二冻结请求用于请求对所述目标账户进行冻结;所述区块链中的设备判断所述目标账户当前被冻结锁冻结的次数是否等于预设阈值;如果所述目标账户当前被冻结锁冻结的次数等于所述预设阈值,则所述区块链中的设备拒绝所述第二冻结请求。
- 一种区块链中账户的处理装置,包括:第一接收单元,被设置为接收用户发送的冻结指令,其中,所述冻结指令用于指示将目标账户冻结;第一生成单元,被设置为根据接收到的冻结指令生成冻结锁,其中,所述冻结锁包括冻结锁公钥;第二生成单元,被设置为根据所述冻结指令和所述冻结锁公钥生成第一冻结请求,其中,所述第一冻结请求用于请求利用所述冻结锁对所述目标账户进行冻结;第一发送单元,被设置为将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中,所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
- 根据权利要求12所述的装置,其中,所述第二生成单元包括:第一获取模块,被设置为根据所述冻结指令获取所述目标账户的账户地址、所述目标账户的私钥和所述冻结锁公钥;第一签名模块,被设置为利用所述目标账户的私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名,得到第一数据;第一生成模块,被设置为根据所述第一数据生成所述第一冻结请求,其中,所述第一冻结请求包括所述目标账户的账户地址、所述冻结锁公钥和所述目标账户的私钥签名。
- 根据权利要求13所述的装置,其中,所述装置还包括:第一验证单元,被设置为在将所述第一冻结请求发送给区块链中的设备之后,通过所述区块链中的设备根据所述第一冻结请求对所述目标账户的私钥签名进行验证;第一记录单元,被设置为在验证通过之后,通过所述区块链中的设备记录所述目标账户的账户地址和所述冻结锁公钥;第二记录单元,被设置为通过所述区块链中的设备根据所述第一冻结请求记录所述冻结事件,其中,所述冻结事件用于指示采用所述冻结锁公钥对所述目标账户进行冻结。
- 根据权利要求12所述的装置,其中,所述第一冻结请求包括冻结类型,所述第一发送单元包括:发送模块,被设置为将所述第一冻结请求发送给区块链中的设备,以指示所述区块链中的设备根据所述第一冻结请求拒绝对所述目标账户执行所述冻结类型的资源转移。
- 根据权利要求12所述的装置,其中,所述装置还包括:第二接收单元,被设置为在将所述第一冻结请求发送给区块链中的设备,以使所述区块链中的设备根据所述第一冻结请求记录冻结事件之后,接收所述用户发送的解冻指令,其中,所述解冻指令用于指示解除利用所述冻结锁对所述目标账户进行的冻结;第三生成单元,被设置为根据所述解冻指令和冻结锁私钥生成解冻请求,其中,所述解冻请求用于请求利用所述冻结锁私钥将所述目标账户解冻,所述冻结锁私钥与所述冻结锁公钥相匹配;第二发送单元,被设置为将所述解冻请求发送给所述区块链中的设备,以使所述区块链中的设备根据所述解冻请求记录解冻事件,其中,所述解冻事件用于指示所述区块链中的设备解除利用所述冻结锁对所述目标账户进行的冻结。
- 根据权利要求16所述的装置,其中,所述第三生成单元包括:第二获取模块,被设置为根据所述解冻指令获取所述目标账户的 账户地址、所述目标账户的私钥和所述冻结锁公钥;第二签名模块,被设置为利用所述冻结锁私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名,得到冻结锁私钥签名;第三签名模块,被设置为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥签名进行签名,得到第二数据;第二生成模块,被设置为根据所述第二数据生成所述解冻请求,所述解冻请求包括所述目标账户的账户地址、所述冻结锁公钥、所述冻结锁私钥签名和所述第二数据。
- 根据权利要求16所述的装置,其中,所述第三生成单元包括:第三获取模块,被设置为根据所述解冻指令获取所述目标账户的账户地址、所述目标账户的私钥和所述冻结锁公钥;第四签名模块,被设置为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥进行签名,得到第三数据;第三生成模块,被设置为根据所述第三数据生成所述解冻请求,所述解冻请求包括所述目标账户的账户地址、所述冻结锁公钥、所述冻结锁私钥和所述第三数据。
- 一种区块链中账户的处理装置,包括:第三接收单元,被设置为通过区块链中的设备接收第一冻结请求,其中,所述第一冻结请求由用户发送的冻结指令和冻结锁公钥生成,所述第一冻结请求用于请求对目标账户进行冻结,所述冻结锁根据所述用户发送的冻结指令生成,所述冻结锁包括冻结锁公钥;第二验证单元,被设置为通过所述区块链中的设备验证所述第一冻结请求;第三记录单元,被设置为在成功验证所述第一冻结请求的情况下,通过所述区块链中的设备根据所述第一冻结请求记录冻结事件,其中, 所述冻结事件用于指示所述区块链中的设备拒绝对所述目标账户执行资源转移。
- 根据权利要求19所述的装置,其中,所述第二验证单元包括:第四获取模块,被设置为通过所述区块链中的设备获取所述目标账户的公钥;验证模块,被设置为通过所述区块链中的设备利用所述目标账户的公钥验证所述第一冻结请求中由所述目标账户的私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名得到的第一数据;第五获取模块,被设置为在成功验证所述第一数据的情况下,通过所述区块链中的设备记录所述第一冻结请求中携带的所述冻结锁公钥和目标账户的账户地址。
- 根据权利要求20所述的装置,其中,所述装置还包括:第四接收单元,被设置为在所述区块链中的设备根据所述第一冻结请求记录冻结事件之后,通过所述区块链中的设备接收解冻请求,所述解冻请求由用户发送的解冻指令和冻结锁私钥生成,所述解冻请求用于请求解除利用所述冻结锁对所述目标账户进行的冻结;第三验证单元,被设置为通过所述区块链中的设备验证所述解冻请求中的冻结锁私钥签名和第二数据,或者,所述区块链中的设备验证所述解冻请求中的第三数据,其中,所述冻结锁私钥签名为利用所述冻结锁私钥对所述目标账户的账户地址和所述冻结锁公钥进行签名得到的,所述第二数据为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥签名进行签名得到的,所述第三数据为利用所述目标账户的私钥对所述目标账户的账户地址、所述冻结锁公钥和所述冻结锁私钥进行签名得到的;第四记录单元,被设置为在成功验证所述冻结锁私钥签名和所述第二数据的情况下,或者,在成功验证所述第三数据的情况下,通过 所述区块链中的设备根据所述账户地址和所述冻结锁公钥记录解冻事件,其中,所述解冻事件用于指示所述区块链中的设备解除利用所述冻结锁对所述目标账户进行的冻结。
- 根据权利要求19所述的装置,其中,所述装置还包括:第五接收单元,被设置为在所述区块链中的设备根据所述第一冻结请求记录冻结事件之后,通过所述区块链中的设备接收第二冻结请求,其中,所述第二冻结请求用于请求对所述目标账户进行冻结;判断单元,被设置为通过所述区块链中的设备判断所述目标账户当前被冻结锁冻结的次数是否等于预设阈值;拒绝单元,被设置为在所述目标账户当前被冻结锁冻结的次数等于所述预设阈值时,通过所述区块链中的设备拒绝所述第二冻结请求。
- 一种存储介质,其中,所述存储介质中存储有计算机程序,所述计算机程序被设置为运行时执行权利要求1至11中任意一项所述的方法。
- 一种计算机设备,包括存储器和处理器,其中,所述存储器中存储有计算机程序,所述处理器被设置为运行所述计算机程序,以执行权利要求1至11中任意一项所述的方法。
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
EP18758390.1A EP3588415A4 (en) | 2017-02-27 | 2018-02-27 | ACCOUNT PROCESSING METHOD AND DEVICE IN A BLOCKCHAIN, STORAGE MEDIUM AND COMPUTER DEVICE |
US16/435,992 US11095679B2 (en) | 2017-02-27 | 2019-06-10 | Method and apparatus for processing account in blockchain, storage medium, and computer device |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710110736.8 | 2017-02-27 | ||
CN201710110736.8A CN107067255B (zh) | 2017-02-27 | 2017-02-27 | 区块链中账户的处理方法和装置 |
Related Child Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
US16/435,992 Continuation US11095679B2 (en) | 2017-02-27 | 2019-06-10 | Method and apparatus for processing account in blockchain, storage medium, and computer device |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2018153378A1 true WO2018153378A1 (zh) | 2018-08-30 |
Family
ID=59621807
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2018/077391 WO2018153378A1 (zh) | 2017-02-27 | 2018-02-27 | 区块链中账户的处理方法和装置、存储介质、计算机设备 |
Country Status (4)
Country | Link |
---|---|
US (1) | US11095679B2 (zh) |
EP (1) | EP3588415A4 (zh) |
CN (1) | CN107067255B (zh) |
WO (1) | WO2018153378A1 (zh) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110493220A (zh) * | 2019-08-16 | 2019-11-22 | 腾讯科技(深圳)有限公司 | 一种基于区块链的数据共享方法、设备及存储介质 |
EP3668045A1 (en) * | 2018-12-14 | 2020-06-17 | The Boeing Company | Interlocking blockchains for aircraft part history and current aircraft configuration |
CN113487315A (zh) * | 2021-07-12 | 2021-10-08 | 网易(杭州)网络有限公司 | 一种账户合约的处理方法、装置、设备及存储介质 |
US11315369B2 (en) | 2018-03-23 | 2022-04-26 | The Boeing Company | Blockchain configuration history for vehicle maintenance, modification, and activity tracking |
Families Citing this family (25)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107067255B (zh) | 2017-02-27 | 2019-02-26 | 腾讯科技(深圳)有限公司 | 区块链中账户的处理方法和装置 |
CN107784580B (zh) * | 2017-09-15 | 2020-10-27 | 数据通信科学技术研究所 | 一种基于公私钥对派生的无中心数字货币交易方法 |
CN108009441B (zh) | 2017-11-23 | 2023-05-30 | 创新先进技术有限公司 | 资源转移和资金转移的方法和装置 |
CN108696514B (zh) * | 2018-04-27 | 2022-04-01 | 腾讯科技(深圳)有限公司 | 资源收集任务管理方法、装置、存储介质及系统 |
CN109011583B (zh) * | 2018-05-28 | 2024-08-13 | 腾讯科技(深圳)有限公司 | 虚拟资源转移方法和装置、存储介质及电子装置 |
CN109493024B (zh) * | 2018-09-29 | 2021-02-09 | 杭州复杂美科技有限公司 | 数字资产托管方法、设备和存储介质 |
CN109636597A (zh) * | 2018-10-31 | 2019-04-16 | 阿里巴巴集团控股有限公司 | 一种基于区块链的财产执行方法及系统 |
CN109767221B (zh) * | 2019-01-16 | 2021-05-11 | 杭州趣链科技有限公司 | 一种面向区块链安全的移动跨平台签名方法 |
CN110245182B (zh) * | 2019-04-25 | 2021-12-07 | 腾讯科技(深圳)有限公司 | 用于处理分布式数据的方法、设备、装置和介质 |
CN110415114A (zh) * | 2019-06-12 | 2019-11-05 | 阿里巴巴集团控股有限公司 | 一种在区块链中解锁账户的方法和装置 |
US10826801B1 (en) | 2019-07-31 | 2020-11-03 | Bank Of America Corporation | Multi-level data channel and inspection architectures |
US11115310B2 (en) | 2019-08-06 | 2021-09-07 | Bank Of America Corporation | Multi-level data channel and inspection architectures having data pipes in parallel connections |
US11470046B2 (en) | 2019-08-26 | 2022-10-11 | Bank Of America Corporation | Multi-level data channel and inspection architecture including security-level-based filters for diverting network traffic |
CN110599170B (zh) * | 2019-09-16 | 2021-06-25 | 腾讯科技(深圳)有限公司 | 基于区块链的交易信息处理方法和系统、存储介质 |
CN110688679B (zh) * | 2019-09-30 | 2023-09-05 | 湖南天河国云科技有限公司 | 一种基于区块链的账户锁定/解锁方法及装置 |
CN110889145B (zh) * | 2019-11-06 | 2024-02-23 | 腾讯科技(深圳)有限公司 | 区块链资源处理方法、平台、系统及计算机可读存储介质 |
US12099997B1 (en) | 2020-01-31 | 2024-09-24 | Steven Mark Hoffberg | Tokenized fungible liabilities |
CN112395258A (zh) * | 2020-09-01 | 2021-02-23 | 苏州园启软件有限公司 | 一种区块链的文件处理方法、装置、设备及介质 |
CN112258184B (zh) * | 2020-10-28 | 2023-08-01 | 成都质数斯达克科技有限公司 | 冻结区块链网络的方法、装置、电子设备及可读存储介质 |
CN112669036B (zh) * | 2020-12-28 | 2024-03-29 | 杭州趣链科技有限公司 | 账户管理方法、系统、服务器及介质 |
CN112907245A (zh) * | 2021-03-08 | 2021-06-04 | 北京邮电大学 | 区块链中的密钥管理方法、装置、电子设备及存储介质 |
CN112948358B (zh) * | 2021-03-18 | 2024-05-28 | 上海零数众合信息科技有限公司 | 一种链上冰封表维护办法 |
CN114172660B (zh) * | 2021-12-03 | 2024-03-26 | 浙商银行股份有限公司 | 联盟链的账户管理方法、装置、设备以及存储介质 |
CN114285894B (zh) * | 2021-12-28 | 2024-01-16 | 浙江吉利控股集团有限公司 | 出行平台任务处理方法、装置、设备及介质 |
US12034807B1 (en) | 2023-09-29 | 2024-07-09 | Bank Of America Corporation | System and method to manage data exchanges in a decentralized network |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103873437A (zh) * | 2012-12-11 | 2014-06-18 | 姚德明 | 账户管理及保护方法和账户管理中介 |
CN104753886A (zh) * | 2013-12-31 | 2015-07-01 | 中国科学院信息工程研究所 | 一种对远程用户的加锁方法、解锁方法及装置 |
CN106296138A (zh) * | 2016-08-09 | 2017-01-04 | 西安电子科技大学 | 基于部分盲签名技术的比特币支付系统及其方法 |
WO2017011601A1 (en) * | 2015-07-14 | 2017-01-19 | Fmr Llc | Computationally efficient transfer processing, auditing, and search apparatuses, methods and systems |
CN107067255A (zh) * | 2017-02-27 | 2017-08-18 | 腾讯科技(深圳)有限公司 | 区块链中账户的处理方法和装置 |
Family Cites Families (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101431561B (zh) * | 2007-11-05 | 2012-04-25 | 中国移动通信集团公司 | 账户锁定方法、系统及相关装置 |
CN104751323B (zh) * | 2013-12-31 | 2020-04-24 | 腾讯科技(深圳)有限公司 | 一种电子账户数据转移方法及相关设备、系统 |
FR3018378A1 (fr) * | 2014-03-12 | 2015-09-11 | Enrico Maim | Systeme et procede transactionnels a architecture repartie fondees sur des transactions de transferts d'unites de compte entre adresses |
US20150348017A1 (en) * | 2014-06-03 | 2015-12-03 | Jonathan Allmen | Method for integrating cryptocurrency transfer on a social network interface |
US10515409B2 (en) * | 2016-03-23 | 2019-12-24 | Domus Tower, Inc. | Distributing work load of high-volume per second transactions recorded to append-only ledgers |
US10114970B2 (en) * | 2015-06-02 | 2018-10-30 | ALTR Solutions, Inc. | Immutable logging of access requests to distributed file systems |
EP3320457B1 (en) | 2015-07-10 | 2021-04-07 | Whether Or Knot LLC | System and method for electronic data distribution |
CN105096118B (zh) * | 2015-08-21 | 2019-04-16 | 廖小谦 | 一种电子货币转付系统及方法 |
CN105468994B (zh) * | 2015-11-26 | 2019-03-15 | 布比(北京)网络技术有限公司 | 一种对象转移方法、装置及系统 |
US10135616B2 (en) * | 2016-05-07 | 2018-11-20 | Keir Finlow-Bates | Revocation of cryptographic keys in the absence of a trusted central authority |
CN106096926B (zh) * | 2016-05-26 | 2021-03-26 | 腾讯科技(深圳)有限公司 | 事件处理方法、装置、电子装置和存储介质 |
US20180082287A1 (en) * | 2016-09-18 | 2018-03-22 | Howard H. Sheerin | Cryptocurrency lock for online accounts |
US20180082267A1 (en) * | 2016-09-18 | 2018-03-22 | Howard H. Sheerin | Configuring an online account based on a public cryptocurrency key |
US10528947B2 (en) * | 2016-09-18 | 2020-01-07 | Howard H Sheerin | Locking an online account based on a public cryptocurrency address |
-
2017
- 2017-02-27 CN CN201710110736.8A patent/CN107067255B/zh active Active
-
2018
- 2018-02-27 WO PCT/CN2018/077391 patent/WO2018153378A1/zh active Application Filing
- 2018-02-27 EP EP18758390.1A patent/EP3588415A4/en not_active Ceased
-
2019
- 2019-06-10 US US16/435,992 patent/US11095679B2/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103873437A (zh) * | 2012-12-11 | 2014-06-18 | 姚德明 | 账户管理及保护方法和账户管理中介 |
CN104753886A (zh) * | 2013-12-31 | 2015-07-01 | 中国科学院信息工程研究所 | 一种对远程用户的加锁方法、解锁方法及装置 |
WO2017011601A1 (en) * | 2015-07-14 | 2017-01-19 | Fmr Llc | Computationally efficient transfer processing, auditing, and search apparatuses, methods and systems |
CN106296138A (zh) * | 2016-08-09 | 2017-01-04 | 西安电子科技大学 | 基于部分盲签名技术的比特币支付系统及其方法 |
CN107067255A (zh) * | 2017-02-27 | 2017-08-18 | 腾讯科技(深圳)有限公司 | 区块链中账户的处理方法和装置 |
Non-Patent Citations (1)
Title |
---|
See also references of EP3588415A4 * |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US11315369B2 (en) | 2018-03-23 | 2022-04-26 | The Boeing Company | Blockchain configuration history for vehicle maintenance, modification, and activity tracking |
US11393266B2 (en) | 2018-03-23 | 2022-07-19 | The Boeing Company | Blockchain configuration history for aircraft maintenance, modification, and activity tracking |
EP3668045A1 (en) * | 2018-12-14 | 2020-06-17 | The Boeing Company | Interlocking blockchains for aircraft part history and current aircraft configuration |
US11151512B2 (en) | 2018-12-14 | 2021-10-19 | The Boeing Company | Interlocking blockchains for aircraft part history and current aircraft configuration |
CN110493220A (zh) * | 2019-08-16 | 2019-11-22 | 腾讯科技(深圳)有限公司 | 一种基于区块链的数据共享方法、设备及存储介质 |
CN113487315A (zh) * | 2021-07-12 | 2021-10-08 | 网易(杭州)网络有限公司 | 一种账户合约的处理方法、装置、设备及存储介质 |
Also Published As
Publication number | Publication date |
---|---|
EP3588415A1 (en) | 2020-01-01 |
CN107067255A (zh) | 2017-08-18 |
US20190297109A1 (en) | 2019-09-26 |
EP3588415A4 (en) | 2020-02-26 |
CN107067255B (zh) | 2019-02-26 |
US11095679B2 (en) | 2021-08-17 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2018153378A1 (zh) | 区块链中账户的处理方法和装置、存储介质、计算机设备 | |
US12034865B2 (en) | Secure dynamic threshold signature scheme employing trusted hardware | |
AU2019201720B2 (en) | Method of using one device to unlock another device | |
WO2018157788A1 (zh) | 区块链中账户信息的处理方法和装置、存储介质和电子装置 | |
US10693853B2 (en) | Method and system for policy enforcement in trusted ad hoc networks | |
KR102179497B1 (ko) | 멀티 클라우드 기반의 데이터 저장 및 관리 시스템 및 그 구동방법 | |
CN112989426B (zh) | 授权认证方法及装置、资源访问令牌的获取方法 | |
US9853971B2 (en) | Proximity based authentication using bluetooth | |
CN110278084B (zh) | eID建立方法、相关设备及系统 | |
CN104660412A (zh) | 一种移动设备无密码安全认证方法及系统 | |
US20210241270A1 (en) | System and method of blockchain transaction verification | |
CN110545285B (zh) | 一种基于安全芯片的物联网终端安全认证方法 | |
CN111723384B (zh) | 数据处理方法、系统及设备 | |
JP2007529935A (ja) | 匿名認証方法 | |
CN114401091B (zh) | 基于区块链的设备跨域认证管理方法及装置 | |
CN112733129B (zh) | 一种服务器带外管理的可信接入方法 | |
Tomar et al. | Blockchain-assisted authenticated key agreement scheme for IoT-based healthcare system | |
Yu et al. | LAKA-UAV: Lightweight authentication and key agreement scheme for cloud-assisted Unmanned Aerial Vehicle using blockchain in flying ad-hoc networks | |
Zhang et al. | PRLAP-IoD: A PUF-based robust and lightweight authentication protocol for Internet of Drones | |
Andola et al. | An enhanced smart card and dynamic ID based remote multi-server user authentication scheme | |
CN114064800A (zh) | 用户资产视图计算方法、系统、计算机设备及存储介质 | |
CN111355588B (zh) | 一种基于puf与指纹特征的可穿戴设备双因子认证方法及系统 | |
CN112184150A (zh) | 数据共享交换中的多方审批方法、装置、系统和电子装置 | |
Kim et al. | UAV‐Undertaker: Securely Verifiable Remote Erasure Scheme with a Countdown‐Concept for UAV via Randomized Data Synchronization | |
CN110535657B (zh) | 一种多个私钥管理设备相互身份认证的方法及装置 |
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: 18758390 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
WWE | Wipo information: entry into national phase |
Ref document number: 2018758390 Country of ref document: EP |