A keyless blockchain wallet implementation method based on Passkey

Through the Passkey-free blockchain wallet implementation method, the problem of difficulty in managing private keys and insufficient convenience for multiple clients is solved, and higher convenience and security is achieved. Users can log in to the wallet or confirm transactions without memorizing and entering complex passwords or mnemonics. The private key storage is secure, reducing the risk of private key leakage caused by phishing and malware.

CN119338461BActive Publication Date: 2025-03-11DONGSHISHAN (SHANGHAI) DIGITAL TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411876809.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-12-19
Publication Date
2025-03-11
Estimated Expiration
2044-12-19

AI Technical Summary

Technical Problem

In the existing blockchain wallet technology, it is difficult for users to manage private keys, resulting in theft of assets; at the same time, the convenience of multiple clients is insufficient, which increases security risks.

Method used

The Passkey-free blockchain wallet implementation method is adopted to generate Passkey through the WebAuthn API. The public key is used for blockchain address generation and transaction signatures. The private key is stored in the security module of the device to avoid plaintext key exposure.

Benefits of technology

It significantly improves the convenience and security of users. Users can log in to their wallet or confirm transactions without memorizing and entering complex passwords or mnemonics. The private key storage is secure, reducing the risk of private key leakage caused by phishing and malware.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119338461B_ABST
    Figure CN119338461B_ABST
Patent Text Reader

Abstract

The present invention discloses a Passkey-based keyless blockchain wallet implementation method, which relates to the field of blockchain technology, and includes the following steps: S1, account creation operation: Passkey creation; public key extraction and use; public key submission and wallet address calculation; wallet address inspection and deployment; account creation completion; S2, transaction operation: transaction request initiation and basic information filling; transaction signature generation using Passkey; transaction data submission after signature; transaction request verification by entry contract; transaction fee inspection; fee deduction and transaction submission; transaction completion and transaction hash generation. In the Passkey-based keyless blockchain wallet implementation method, users can log in to the wallet or confirm transactions through device authentication, without the need to remember and enter complex passwords or mnemonics, and the private key is stored in the security module of the device, which is not easily extracted and attacked.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of blockchain, and in particular to a method for implementing a keyless blockchain wallet based on Passkey. Background Art

[0002] Blockchain wallets are used to manage users' digital assets. Users have full control over private keys, generate addresses through private keys, and sign transactions. The wallet supports multi-chain compatibility (such as Ethereum, Polygon, etc.), DApp interaction, and smart contract access, making it convenient for users to manage cross-chain assets and participate in DeFi, NFT and other ecosystems. In terms of security, mnemonic backup is provided to ensure key security. Specific implementations include Metamask and ImToken.

[0003] However, existing wallet technology faces several major problems. First, it becomes difficult for users to save private keys. Many wallet asset thefts are due to improper private key management, which leads to leakage. Another problem is the lack of convenience. If users want to use it on multiple clients, they need to export the mnemonics, install the corresponding wallet software or plug-ins on different clients, and then import the account information. This increases the convenience of user use to a certain extent, but also increases security risks.

[0004] Therefore, it is urgent to improve this shortcoming. The present invention studies and improves the existing technology and its shortcomings, and provides a keyless blockchain wallet implementation method based on Passkey. Summary of the invention

[0005] The purpose of the present invention is to provide a keyless blockchain wallet implementation method based on Passkey to solve the problems raised in the above background technology.

[0006] To achieve the above purpose, the present invention provides the following technical solution: a method for implementing a keyless blockchain wallet based on Passkey, comprising the following steps:

[0007] S1. Create an account:

[0008] S11. The user initiates a Passkey creation request through a browser client that supports Passkey, and by using the WebAuthnAPI (passkey's API), the client generates a passkey;

[0009] S12. After the passkey is created, the client extracts the public key from the generated passkey, and the public key itself does not contain the user's privacy information;

[0010] S13. The client submits the public key to the blockchain to trigger the calculation process of the wallet address;

[0011] S14. The smart contract checks whether the wallet address has been deployed on the blockchain;

[0012] If it is not deployed, the wallet address will be added to the account list of the smart contract, triggering the initialization and deployment process of the wallet. When deployed, the public key and ERC1271 related protocol code will be written into the blockchain, making the wallet have the function of a contract wallet.

[0013] If it has been deployed, the contract will directly return the user's wallet address without having to create it again;

[0014] S15. The smart contract returns the generated blockchain wallet address to the client, completing the user account creation process, and this wallet address will be used as the sender address of the user's subsequent transactions;

[0015] S2. Trading operations:

[0016] S21. The user initiates a transaction request on the client (browser wallet application that supports Passkey) and fills in the basic information of the transaction. The client packages this information as the transaction data to be signed;

[0017] S22. The client uses the WebAuthn API to call passkey to generate a signature using the secp256r1 algorithm.

[0018] S23. After the signature is completed, the client packages the signature result together with the transaction information and prepares to submit it to the blockchain. The client sends the signed transaction data to the Bundler, and the Bundler submits the packaged transaction request to the entry contract on the blockchain. The entry contract is responsible for verifying and processing the transaction request.

[0019] S24. The entry contract verifies the basic information of the transaction request and calls the ERC1271 protocol to verify the validity of the transaction signature. The ERC1271 protocol ensures that the signature verification of the contract wallet complies with the blockchain standards, so that the transaction can be executed safely.

[0020] If the signature verification passes, the transaction will proceed, otherwise, the transaction will be rejected;

[0021] S25. The smart contract checks whether the transaction data contains sufficient transaction fees to ensure that the absenteeism fee has been paid when executing the transaction;

[0022] S26. The entry contract deducts the corresponding handling fee from the transaction amount to ensure the operating cost of the transaction on the payment chain. After the verification and deduction are completed, the entry contract submits the transaction information to the blockchain and executes the final transfer operation;

[0023] S27. After the transaction is completed, a transaction hash is generated to identify the transaction, and the smart contract returns the unique hash of the transaction. The client can use the hash to query the transaction status on the blockchain browser.

[0024] Furthermore, in step S11, the passkey includes a public key and a private key pair, and the private key is stored in a security module (such as TPM, Secure Element, etc.) of the user device. The plaintext key cannot be exported by an external program and will not be exposed to applications and external services.

[0025] Furthermore, in step S12, the public key is used as a unique identifier of the user's identity for subsequent on-chain calculations and generation of wallet addresses.

[0026] Furthermore, in step S13, the calculation process will call the smart contract on the blockchain, and the smart contract will calculate a corresponding decentralized wallet address through the public key. The specific process is: the smart contract generates and verifies the user's wallet address based on the incoming public key using the ERC1271 (a protocol that allows contracts to implement signatures) protocol.

[0027] Furthermore, the ERC1271 protocol specifies the signature verification standard for contract wallets, so that contract-based wallets can effectively support Passkey signatures in secp256r1 format.

[0028] Furthermore, in step S21, the basic information of the transaction includes:

[0029] From: sender’s wallet address, which is the wallet address generated previously;

[0030] To: The recipient’s wallet address, i.e. the destination address to which the user wants to transfer funds;

[0031] Value: Transaction amount, i.e. the number of tokens the user wants to transfer.

[0032] Furthermore, in step S22, the signing step includes encoding the basic information (from, to, value) to generate a unique transaction signature, and the signature is generated by the private key of the passkey to ensure the authenticity of the transaction and the consistency of the user's identity.

[0033] Furthermore, in step S23, the Bundler is responsible for monitoring transaction requests, and aggregating and organizing the transaction requests for subsequent submission to the entry contract of the blockchain.

[0034] Furthermore, in step S24, basic information verification specifically includes: checking the validity of the from address and the to address, and verifying the rationality of the value to ensure that the transaction amount meets the balance requirements on the chain.

[0035] Furthermore, in step S25, the payment of the handling fee may be deducted from the transaction amount, or the user may be required to add an additional handling fee field in the transaction request.

[0036] The present invention provides a Passkey-based keyless blockchain wallet implementation method, which has the following beneficial effects:

[0037] The present invention significantly improves convenience and security. Users can log in to the wallet or confirm transactions through device authentication without having to remember and enter complex passwords or mnemonics. In addition, through passkey technology, the private key is stored in the security module of the device, which is not easy to be extracted and attacked, avoiding the risk of private keys caused by phishing websites or malware. At the same time, through secure storage mechanisms (such as Apple iCloud Keychain and Google Account synchronization), users can use wallets seamlessly across multiple devices to achieve more convenient key recovery.

[0038] This method combines blockchain, smart contracts and oracle services to improve data reliability because more independent nodes can reduce the risk of errors and manipulation. Secondly, the system security is enhanced, and it is more difficult for attackers to control the entire system. The improved mechanism can also reduce operating costs by optimizing the fee structure through efficient incentives. Finally, more node participation can indirectly reduce latency and improve data transmission efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] Figure 1 This is a schematic diagram of the overall steps of a method for implementing a keyless blockchain wallet based on Passkey in the present invention;

[0040] Figure 2 A schematic diagram of the account creation operation steps of a Passkey-based keyless blockchain wallet implementation method of the present invention;

[0041] Figure 3 The present invention is a flowchart of transaction operation steps of a method for implementing a keyless blockchain wallet based on Passkey. DETAILED DESCRIPTION

[0042] The following embodiments of the present invention are described in further detail in conjunction with the accompanying drawings and examples. The following examples are used to illustrate the present invention, but are not intended to limit the scope of the present invention.

[0043] like Figure 1-Figure 3 As shown, a method for implementing a keyless blockchain wallet based on Passkey includes the following steps:

[0044] S1. Create an account:

[0045] S11: Creation of Passkey

[0046] User request: The user initiates a request to create a Passkey through a browser client that supports Passkey. This request is triggered by a form or button, and the user needs to agree to the terms and conditions for generating the passkey.

[0047] Generate Passkey: The client uses the WebAuthn API to generate a Passkey containing a public key and a private key pair. The private key is securely stored in the security module of the user's device (such as TPM, Secure Element, etc.), and the plaintext key cannot be exported by external programs and will not be exposed to applications and external services.

[0048] S12: Extraction and use of public keys

[0049] Public key extraction: After the passkey is created, the client extracts the public key from the generated passkey. The public key itself does not contain the user's private information, such as name, address, password, etc. It is only a mathematical object used for identity authentication and authorization and will not disclose the user's personal privacy.

[0050] Identity: The public key is the unique identifier of the user and is used for subsequent on-chain calculations and wallet address generation.

[0051] S13: Public key submission and wallet address calculation

[0052] Public key submission: The client submits the public key to the blockchain.

[0053] Smart contract call: call the smart contract on the blockchain and calculate a corresponding decentralized wallet address through the public key.

[0054] ERC1271 protocol: Smart contracts use the ERC1271 protocol to generate and verify the user's wallet address. The ERC1271 protocol provides a signature verification standard for contract-based wallets and supports Passkey signatures in secp256r1 format.

[0055] S14: Check and deploy wallet addresses

[0056] Check wallet address: The smart contract checks whether the wallet address has been deployed on the blockchain.

[0057] For non-deployment: add the wallet address to the account list of the smart contract to trigger the wallet initialization and deployment process. During deployment, write the public key and ERC1271 related protocol code into the blockchain to enable the wallet to function as a contract wallet.

[0058] For deployed cases: the contract directly returns the user’s wallet address without the need for repeated creation.

[0059] S15: Complete account creation

[0060] Wallet address return: The smart contract returns the generated blockchain wallet address to the client.

[0061] Account creation completed: This wallet address will be used as the sender address for subsequent transactions of the user, completing the user account creation process.

[0062] S2. Trading operations:

[0063] S21: Initiation of transaction request and filling in basic information

[0064] User operation: The user initiates a transaction request on the client (browser wallet application that supports Passkey).

[0065] Information filling: The user fills in the basic information of the transaction; in this embodiment, the basic information of the transaction specifically includes:

[0066] From: sender’s wallet address (previously generated wallet address);

[0067] To: The recipient’s wallet address (the destination address to which the user wants to transfer funds);

[0068] Value: Transaction amount (the number of tokens the user wants to transfer).

[0069] Data packaging: The client packages this information into transaction data to be signed.

[0070] S22: Generate transaction signature using Passkey

[0071] WebAuthn API call: The client uses the WebAuthn API call Passkey for signing.

[0072] Signature step: The signature uses the secp256r1 algorithm, which is one of the signature algorithms supported by Passkey. It encodes the basic information (From, To, Value) and uses the Passkey private key to generate a unique transaction signature to ensure the authenticity of the transaction and the consistency of the user's identity.

[0073] S23: Submission of transaction data after signing

[0074] Data packaging: The client packages the signature result together with the transaction information.

[0075] Submit to Bundler: The client sends the signed transaction data to Bundler.

[0076] Bundler's role: Bundler is a service that monitors transaction requests and is responsible for aggregating and organizing transaction requests for subsequent submission to the blockchain's entry contract.

[0077] S24: Verification of transaction request by entry contract

[0078] Basic information verification: The entry contract checks the validity of the From address and the To address, and verifies the rationality of the Value to ensure that the transaction amount meets the balance requirements on the chain.

[0079] Signature verification: Call the ERC1271 protocol to verify the validity of the transaction signature. The ERC1271 protocol ensures that the signature verification of the contract wallet complies with the blockchain standard.

[0080] Verification result: If the signature verification passes, the transaction continues; otherwise, the transaction is rejected.

[0081] S25: Check transaction fees

[0082] Fee verification: The smart contract checks whether the transaction data contains enough transaction fees.

[0083] Fee Payment: The fee can be deducted from the transaction amount, or the user is required to add an additional fee field in the transaction request.

[0084] S26: Fee deduction and transaction submission

[0085] Fee deduction: The entry contract deducts the corresponding fee from the transaction amount.

[0086] Transaction submission: After verification and deduction are completed, the entry contract submits the transaction information to the blockchain and executes the final transfer operation.

[0087] S27: Transaction completion and transaction hash generation

[0088] Transaction hash: After the transaction is completed, a unique transaction hash is generated to identify the transaction.

[0089] Hash return: The smart contract returns the unique hash of the transaction.

[0090] Transaction status query: The client can use the hash to query the transaction status on the blockchain browser.

[0091] The embodiments of the present invention are given for the purpose of illustration and description, and are not intended to be exhaustive or to limit the invention to the disclosed forms. Many modifications and variations will be apparent to those of ordinary skill in the art. The embodiments are selected and described in order to better illustrate the principles and practical applications of the present invention and to enable those of ordinary skill in the art to understand the present invention and thereby design various embodiments with various modifications suitable for specific uses.

Claims

1. A method for implementing a keyless blockchain wallet based on Passkey, characterized in that: include: Step S1, create an account operation; Step S2, transaction operation; The step S1 specifically includes the following sub-steps: S11. The user initiates a Passkey creation request through the client, and by using the WebAuthn API, the client generates a passkey; S12. After the passkey is created, the client extracts the public key from the generated passkey, and the public key itself does not contain the user's privacy information; S13. The client submits the public key to the blockchain to trigger the calculation process of the wallet address; S14. The smart contract checks whether the wallet address has been deployed on the blockchain; If it is not deployed, the wallet address will be added to the account list of the smart contract, triggering the initialization and deployment process of the wallet. When deployed, the public key and ERC1271 related protocol code will be written into the blockchain, making the wallet have the function of a contract wallet. If it has been deployed, the contract will directly return the user's wallet address without having to create it again; S15. The smart contract returns the generated blockchain wallet address to the client, completing the user account creation process, and this wallet address will be used as the sender address of the user's subsequent transactions; The step S2 specifically includes the following sub-steps: S21. The user initiates a transaction request on the client and fills in the basic information of the transaction. The client packages the information as transaction data to be signed; S22. The client uses the WebAuthn API to call passkey to generate a signature using the secp256r1 algorithm. S23. After the signature is completed, the client packages the signature result together with the transaction information, and sends the signed transaction data to the Bundler, which submits the packaged transaction request to the entry contract on the blockchain through the Bundler; S24. The entry contract verifies the basic information of the transaction request and calls the ERC1271 protocol to verify the validity of the transaction signature; If the signature verification passes, the transaction will proceed, otherwise, the transaction will be rejected; S25. The smart contract checks whether the transaction data contains sufficient transaction fees to ensure that the absenteeism fee has been paid when executing the transaction; S26. The entry contract deducts the corresponding handling fee from the transaction amount. After verification and deduction, the transaction information is submitted to the blockchain to perform the final transfer operation. S27. After the transaction is completed, a transaction hash is generated, and the smart contract returns the hash of the transaction. The client can use the hash to query the transaction status on the blockchain browser.

2. According to claim 1, a method for implementing a keyless blockchain wallet based on Passkey is characterized in that: In step S11, the passkey includes a public key and a private key pair, and the private key is stored in the security module of the user device. The plaintext key cannot be exported by external programs and will not be exposed to applications and external services.

3. According to a Passkey-based keyless blockchain wallet implementation method according to claim 1, it is characterized in that: In step S12, the public key is used as the unique identifier of the user and is used for subsequent on-chain calculations and wallet address generation.

4. According to claim 1, a method for implementing a keyless blockchain wallet based on Passkey, characterized in that: In step S13, the calculation process will call the smart contract on the blockchain, and the smart contract will calculate a corresponding decentralized wallet address through the public key. The specific process is: the smart contract generates and verifies the user's wallet address based on the incoming public key using the ERC1271 protocol.

5. According to claim 4, a method for implementing a keyless blockchain wallet based on Passkey is characterized in that: The ERC1271 protocol specifies the signature verification standard for contract wallets and supports Passkey signatures in secp256r1 format.

6. According to claim 1, a method for implementing a keyless blockchain wallet based on Passkey, characterized in that: In step S21, the basic information of the transaction includes: From: sender’s wallet address, which is the wallet address generated previously; To: The recipient’s wallet address, i.e. the destination address to which the user wants to transfer funds; Value: Transaction amount, i.e. the number of tokens the user wants to transfer.

7. According to claim 1, a method for implementing a keyless blockchain wallet based on Passkey, characterized in that: In step S22, the signing step includes encoding the basic information to generate a unique transaction signature, and the signature is generated by the private key of the passkey to ensure the authenticity of the transaction and the consistency of the user's identity.

8. According to claim 1, a method for implementing a keyless blockchain wallet based on Passkey, characterized in that: In step S23, Bundler is responsible for monitoring transaction requests, and aggregating and organizing the transaction requests so as to subsequently submit them to the entry contract of the blockchain.

9. A Passkey-based keyless blockchain wallet implementation method according to claim 6, characterized in that: In step S24, basic information verification specifically includes: checking the validity of the from address and the to address, and verifying the rationality of the value to ensure that the transaction amount meets the balance requirements on the chain.

10. A Passkey-based keyless blockchain wallet implementation method according to claim 1, characterized in that: In step S25, the payment of the handling fee can be deducted from the transaction amount, or the user is required to add an additional handling fee field in the transaction request.

Citation Information

Patent Citations

  • Method for preventing hardware wallet from being maliciously paired

    CN110602676A

  • Block chain account generation method and system

    CN119005980A