A mailbox-based identity authentication method and device
By generating and using an email verification identifier signed with the DKIM protocol on blockchain nodes, and combining this with smart contract verification of signature information, the problem of the lack of identity binding between public and private key systems in blockchain is solved, thus achieving a more secure identity verification method.
Patent Information
- Application Number
- CN202211384518.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-07
- Publication Date
- 2026-02-27
- Estimated Expiration
- 2042-11-07
AI Technical Summary
In existing blockchain technology, the public and private key systems lack identity information binding, which leads to the inability to operate after the private key is lost and the fragmentation of identity information, resulting in a lack of security.
The system generates an identity verification identifier through blockchain nodes, uses the user's email address and the target email signed with the DKIM protocol for identity verification, and combines smart contracts to verify the signature information to achieve user terminal identity verification.
It improves the security and consistency of blockchain authentication, ensuring the integrity and reliability of identity information.
Smart Images

Figure CN115694839B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of blockchains, and particularly relates to a mailbox-based identity authentication method and device. BACKGROUND
[0002] A blockchain is a chain-like data structure composed of one block after another, each block storing certain information, the blocks being spliced in time sequence according to their respective generation times to form a chain, the chain being saved in all nodes, and the entire blockchain being secure as long as one node in the system can work.
[0003] The existing blockchain adopts a public key and private key system and a certificate system based on the public key and private key system, in which the public key and the private key are independent and have no binding relationship with identity information. If the private key of the blockchain is forgotten, the blockchain cannot be operated, and if identity information needs to be attached, other auxiliary modules are needed, and the standards of various blockchains are different, making the identity information more fragmented and lacking security. SUMMARY
[0004] Therefore, the mailbox-based identity authentication method and device are provided, aiming to improve the security of identity authentication.
[0005] In a first aspect, the mailbox-based identity authentication method is provided, and is executed by a blockchain node, and includes the following steps.
[0006] Receiving an identity authentication request sent by a user terminal;
[0007] Generating an identity authentication identifier through a smart contract according to the identity authentication request;
[0008] Sending the identity authentication identifier to the user terminal, the identity authentication identifier being used to inform the user terminal to send a target email including the identity authentication identifier to a target mailbox through a user mailbox, the target email being signed by a domain name key identification email standard DKIM protocol;
[0009] Receiving the target email and signature information of the target email sent by the user terminal;
[0010] Performing identity authentication on the target email and the signature information through a smart contract to obtain an identity authentication result of the user terminal.
[0011] Optionally, the identity authentication identifier includes a random number, a universally unique identifier UUID, and / or a self-increasing serial number.
[0012] Optionally, the identity verification of the target mail and the signature information through the smart contract obtains an identity verification result of the user terminal, and the identity verification result includes:
[0013] The identity verification of the identity verification identifier in the target mail and the signature information through the smart contract obtains an identity verification result of the user terminal.
[0014] Optionally, after the identity verification result of the user terminal is obtained, the method further includes:
[0015] When the identity verification result is identity verification passed, the user terminal is allowed to send an identity information change request, and the identity information change request includes adding a public key, modifying a public key, or deleting a public key.
[0016] When the identity verification result is identity verification failed, identity verification failure information is sent to the user terminal.
[0017] Optionally, the target mailbox includes a black hole mailbox.
[0018] In a second aspect, an identity verification device based on a mailbox is provided, and the device is deployed on a block chain node, and the device includes:
[0019] A first receiving module is configured to receive an identity verification request sent by a user terminal.
[0020] A generating module is configured to generate an identity verification identifier through a smart contract according to the identity verification request.
[0021] A first sending module is configured to send the identity verification identifier to the user terminal, and the identity verification identifier is used to inform the user terminal to send a target mail including the identity verification identifier to a target mailbox through a user mailbox, and the target mail is signed by a domain name key identification mail standard DKIM protocol.
[0022] A second receiving module is configured to receive the target mail and signature information of the target mail sent by the user terminal.
[0023] An identity verification module is configured to perform identity verification of the target mail and the signature information through the smart contract to obtain an identity verification result of the user terminal.
[0024] Optionally, the identity verification identifier includes a random number, a universally unique identifier UUID, and / or a self-incrementing serial number.
[0025] Optionally, the identity verification module includes:
[0026] The verification unit is specifically configured to verify the identity authentication identification in the target email and the signature information by using the smart contract to obtain an identity authentication result of the user terminal.
[0027] Optionally, the apparatus further comprises:
[0028] The second sending module is configured to allow the user terminal to send an identity information change request when the identity authentication result is identity authentication passed, the identity information change request comprising adding a public key, modifying a public key, or deleting a public key.
[0029] When the identity authentication result is identity authentication failed, identity authentication failure information is sent to the user terminal.
[0030] Optionally, the target mailbox comprises a black hole mailbox.
[0031] In a third aspect, an embodiment of the present application provides a mailbox-based identity authentication device, the device comprising:
[0032] A memory is configured to store a computer program.
[0033] A processor is configured to execute the computer program to enable the device to perform the mailbox-based identity authentication method of the first aspect.
[0034] In a fourth aspect, an embodiment of the present application provides a computer readable storage medium, the computer readable storage medium storing a computer program, the computer program being executed by a processor to implement the mailbox-based identity authentication method of the first aspect.
[0035] As can be seen from the above technical solutions, the embodiments of the present application have the following advantages:
[0036] The embodiment of the application provides a mailbox-based identity authentication method and device. First, a blockchain node receives an identity authentication request sent by a user terminal, and generates an identity authentication identifier through a smart contract according to the identity authentication request. Then, the blockchain node sends the identity authentication identifier to the user terminal, for notifying the user terminal to send a target mail including the identity authentication identifier to a target mailbox through a user mailbox, wherein the target mail is signed by a domain name key identification mail standard DKIM protocol. Finally, the blockchain node receives the target mail and signature information of the target mail sent by the user terminal, and performs identity authentication on the target mail and the signature information through the smart contract, to obtain an identity authentication result of the user terminal. The blockchain node responds to the identity authentication request sent by the user terminal, generates the identity authentication identifier through the smart contract, and returns the identity authentication identifier to the user terminal, so that the user terminal sends the target mail with the identity authentication identifier to the target mailbox through the user mailbox, and the target mail is signed by the domain name key identification mail standard DKIM protocol. Based on this, the blockchain node performs identity authentication on the target mail and the signature information of the target mail sent by the user terminal through the smart contract. The method provides a user terminal identity information verification method based on a blockchain, thereby improving the security of identity authentication. BRIEF DESCRIPTION OF DRAWINGS
[0037] To make the technical solutions in the embodiments or the prior art clearer, the accompanying drawings needed in the embodiments or the prior art description will be briefly introduced. Obviously, the accompanying drawings in the following description are only some embodiments of the application, and other accompanying drawings can be obtained by those skilled in the art without any creative effort on the basis of the accompanying drawings.
[0038] Figure 1 A system framework schematic diagram related to an application scenario in the embodiment of the application;
[0039] Figure 2 A method flowchart of a mailbox-based identity authentication method provided by the embodiment of the application;
[0040] Figure 3 A method flowchart of another mailbox-based identity authentication method provided by the embodiment of the application;
[0041] Figure 4 A structure schematic diagram of a mailbox-based identity authentication device provided by the embodiment of the application. DETAILED DESCRIPTION
[0042] In the following, the technical solutions in the embodiments of the present application will be described clearly and completely in combination with the drawings in the embodiments of the present application, so that those skilled in the art can better understand the solutions in the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present application.
[0043] The existing blockchain adopts a public key and private key system and a certificate system based on the public key and private key system. In the public key and private key system, the public key and the private key are exposed and have no binding relationship with the identity information. If the private key of the blockchain is forgotten, there is no way to operate the blockchain. If it is necessary to attach identity information, other auxiliary modules are needed, and the standards of various blockchains are different, making the identity information more fragmented and lacking security.
[0044] Therefore, in order to solve the above problems, in the embodiments of the present application, first, the blockchain node receives an identity verification request sent by a user terminal, and generates an identity verification identifier through a smart contract according to the identity verification request. Then, the blockchain node sends the identity verification identifier to the user terminal, for notifying the user terminal to send a target email including the identity verification identifier to a target mailbox through a user mailbox, wherein the target email is signed by a domain name key identification email standard DKIM protocol. Finally, the blockchain node receives the target email and signature information of the target email sent by the user terminal, and performs identity verification on the target email and the signature information through a smart contract to obtain an identity verification result of the user terminal.
[0045] The blockchain node generates an identity verification identifier through a smart contract in response to an identity verification request sent by a user terminal and returns the identity verification identifier to the user terminal, so that the user terminal sends a target email with the identity verification identifier to a target mailbox through a user mailbox, and the target email is signed by a domain name key identification email standard DKIM protocol. Based on this, the blockchain node performs identity verification on the target email and the signature information of the target email sent by the user terminal through a smart contract. This method provides a user terminal identity information verification method based on the blockchain, thereby improving the security of identity verification.
[0046] For example, one of the scenarios of the embodiments of the present application can be applied to, for example, Figure 1The scenario shown. The scenario includes a blockchain node 101 and a user terminal 102, and the blockchain node 101 interacts with the user terminal 102. First, the blockchain node 101 generates an identity verification identifier through a smart contract in response to an identity verification request sent by the user terminal 102 and returns it to the user terminal 102, the user terminal 102 sends a target email including the identity verification identifier to a target mailbox through a user mailbox, and the target email is signed by a domain name key identification email standard DKIM protocol, and finally, the blockchain node 101 verifies the target email sent by the user terminal 102 and the signature information of the target email through a smart contract.
[0047] First, in the above application scenario, although the action description of the embodiment provided by the present application is executed by the blockchain node 101; however, the present application is not limited in terms of execution subject, as long as the action disclosed by the embodiment provided by the present application is executed.
[0048] Second, the above scenario is only one scenario example provided by the present application, and the present application is not limited to this scenario.
[0049] The specific implementation of the mailbox-based identity verification method and device in the present application will be described in detail below with reference to the accompanying drawings and embodiments.
[0050] Figure 2 The method flow chart of the mailbox-based identity verification method provided by the present application. According to the mailbox-based identity verification method provided by the present application, the blockchain node can include: Figure 2
[0051] S201: Receive the identity verification request sent by the user terminal.
[0052] The blockchain node receives the identity verification request sent by the user terminal. As an example, the identity verification request can be a request for a lost private key, or a request to reset the private key information. Of course, the present application does not specifically limit the content of the identity verification request, and does not affect the implementation of the present application.
[0053] S202: According to the identity verification request, generate an identity verification identifier through a smart contract.
[0054] A smart contract is a piece of code on a blockchain that can automatically execute tasks. Smart contracts are deployed on blockchain nodes, and the blockchain nodes generate a unique authentication identifier based on the authentication request sent by the user terminal. This authentication identifier can be a one-time random number, a Universally Unique Identifier (UUID), or an auto-incrementing sequence number. Of course, this application does not specifically limit the authentication identifier, and this does not affect the implementation of the embodiments of this application.
[0055] S203: Send an authentication identifier to the user terminal. The authentication identifier is used to notify the user terminal to send a target email containing the authentication identifier to the target email address through the user's email address. The target email is signed by the Domain Key Identifier Mail Standard (DKIM) protocol.
[0056] DomainKeys Identified Mail (DKIM) is an encrypted email verification system. It involves registering one or more public key certificates with a domain name registry. When delivering emails, the mail server adds a signature, allowing the recipient to verify that the email originated from the mail server based on the signature and the certificate obtained from the domain name registry. DKIM can be used to prevent online fraud by ensuring that signed emails are not tampered with before reaching the target email address, thus guaranteeing email security.
[0057] Blockchain nodes send an authentication identifier to the user terminal. This identifier notifies the user terminal to send a target email containing the authentication identifier to a target email address via the user's email address. The target email is signed using the DKIM protocol. As an example, the content of the target email could be: "Private key lost, password needs to be reset, verification code 1234," where the authentication identifier is verification code 1234. However, this application does not specifically limit the content of the target email, nor does it affect the implementation of the embodiments of this application.
[0058] The target email address can be a black hole email address; for example, the target email address could be no-reply@block.chain.
[0059] S204: Receive the target email and the signature information of the target email sent by the user terminal.
[0060] The blockchain node receives the target email sent by the user terminal and the signature information of the target email signed by the DKIM protocol.
[0061] S205: Verify the identity of the target email and signature information through a smart contract to obtain the identity verification result of the user terminal.
[0062] The blockchain node authenticates the identity authentication identifier in the target email and the signature information of the target email through the smart contract to obtain an identity authentication result of the user terminal. The identity authentication result can be a pass or a fail.
[0063] The above is a mailbox-based identity authentication method provided by the embodiment of the application. The blockchain node receives an identity authentication request sent by a user terminal, generates an identity authentication identifier through a smart contract according to the identity authentication request, sends the identity authentication identifier to the user terminal, and notifies the user terminal to send a target email including the identity authentication identifier to a target mailbox through a user mailbox. The target email is signed by a domain name key identification email standard DKIM protocol. Finally, the blockchain node receives the target email and the signature information of the target email sent by the user terminal, authenticates the target email and the signature information through the smart contract, and obtains an identity authentication result of the user terminal.
[0064] The blockchain node generates an identity authentication identifier through a smart contract in response to an identity authentication request sent by a user terminal and returns the identity authentication identifier to the user terminal, so that the user terminal sends a target email with the identity authentication identifier to a target mailbox through a user mailbox. The target email is signed by a domain name key identification email standard DKIM protocol. Based on this, the blockchain node authenticates the target email and the signature information of the target email sent by the user terminal through the smart contract. This method provides a user terminal identity information authentication method based on a blockchain, thereby improving the security of identity authentication.
[0065] For ease of understanding, the mailbox-based identity authentication method provided by the embodiment of the application is described in detail below. Referring to Figure 3 The figure is a method flowchart of another mailbox-based identity authentication method provided by the embodiment of the application, executed by a blockchain node. The specific steps of the mailbox-based identity authentication method can include:
[0066] S301: The blockchain node receives an identity authentication request of a lost private key sent by a user terminal.
[0067] S302: The blockchain node generates a verification code through a smart contract according to the identity authentication request of the lost private key.
[0068] S303: The blockchain node sends the verification code to the user terminal. The verification code is used to notify the user terminal to send a target email including the verification code to a target mailbox through a user mailbox. The target email is signed by a domain name key identification email standard DKIM protocol.
[0069] As an example, the blockchain node sends a one-time random verification code 123456 to the user terminal, the validity duration can be 5 minutes, the verification code can be used to inform the user terminal to send a target email with the content ResetAccount123456 to the target email no-reply@block.chain through the user email jack@some.where, the target email is signed by the domain name key identification email standard DKIM protocol.
[0070] In a possible implementation, the email content needs to be normalized and formatted, the target email can be hex encoded by the mailbox node, the blockchain node sends the verification code 123456 to the user, the verification code can be used to inform the user terminal to send a target email with the content ==ResetAccount123456== to the target email no-reply@block.chain through the user email jack@some.where, the hex encoded data can be 3D3D52657365744163636F756E743132333435363D3D, the target email is signed by the domain name key identification email standard DKIM protocol. The target email signed by the DKIM protocol can be read by the user terminal through the interactive mail access protocol (English: Internet Mail Access Protocol, IMAP) protocol to obtain the information of the target email and the DKIM signature information of the target email.
[0071] S304: The blockchain node receives the target email and the signature information of the target email sent by the user terminal.
[0072] S305: The blockchain node verifies the verification code and the signature information of the target email through the smart contract to obtain the identity verification result of the user terminal.
[0073] S306: The blockchain node sends the corresponding identity verification information to the user terminal according to the identity verification result of the user terminal.
[0074] When the identity verification result of the user terminal is identity verification passed, the blockchain node allows the user terminal to send a new identity information change request, including adding the public key and the corresponding blockchain address recognized by the user, modifying the public key and the corresponding blockchain address recognized by the user, and deleting the public key and the corresponding blockchain address recognized by the user. Of course, the specific content of the identity information change request is not specifically limited in the present application, and does not affect the implementation of the embodiments of the present application;
[0075] When the identity verification result of the user terminal is identity verification failed, the blockchain node sends the identity verification failure information to the user terminal.
[0076] The above is another mailbox-based identity verification method provided by the embodiment of the application. In response to a login request for a lost private key sent by a user terminal, a blockchain node generates a verification code through a smart contract and returns the verification code to the user terminal, so that the user terminal sends a target email with an identity verification identifier to a target mailbox through a user mailbox, and the target email is signed by a domain name key identification email standard DKIM protocol. Based on this, the blockchain node verifies the target email sent by the user terminal and the signature information of the target email through the smart contract. When the identity verification is passed, the blockchain node allows the user terminal to send a new identity information change request. When the identity verification is not passed, the blockchain node sends identity verification failure information to the user terminal. This method provides a user terminal identity information verification method based on a blockchain, thereby improving the security of identity verification.
[0077] The above is some specific implementation manners of the mailbox-based identity verification method provided by the embodiment of the application. Based on this, the application also provides a corresponding device. The device provided by the embodiment of the application will be introduced from the perspective of functional modularization.
[0078] Referring to Figure 4 The mailbox-based identity verification device 400 includes a first receiving module 401, a generating module 402, a first sending module 403, a second receiving module 404, and an identity verification module 405.
[0079] The first receiving module 401 is configured to receive an identity verification request sent by a user terminal.
[0080] The generating module 402 is configured to generate an identity verification identifier through a smart contract according to the identity verification request.
[0081] The first sending module 403 is configured to send the identity verification identifier to the user terminal. The identity verification identifier is used to inform the user terminal to send a target email including the identity verification identifier to a target mailbox through a user mailbox. The target email is signed by a domain name key identification email standard DKIM protocol.
[0082] The second receiving module 404 is configured to receive a target email sent by the user terminal and signature information of the target email.
[0083] The identity verification module 405 is configured to verify the target email and the signature information through the smart contract to obtain an identity verification result of the user terminal.
[0084] In the embodiment of the present application, through cooperation of the first receiving module 401, the generating module 402, the first sending module 403, the second receiving module 404 and the identity authentication module 405, the blockchain node returns an identity authentication identifier generated by the smart contract to the user terminal in response to the identity authentication request sent by the user terminal, so that the user terminal sends a target email with the identity authentication identifier to the target mailbox through the user mailbox, and the target email is signed by the domain name key identification email standard DKIM protocol. Based on this, the blockchain node performs identity authentication on the target email sent by the user terminal and the signature information of the target email through the smart contract. The method provides a user terminal identity information verification method based on the blockchain, thereby improving the security of identity authentication.
[0085] As an implementation manner, the identity authentication identifier includes a random number, a universally unique identifier UUID and / or a self-incrementing serial number.
[0086] As an implementation manner, the identity authentication module 405 can specifically include:
[0087] The verification unit is specifically configured to perform identity authentication on the identity authentication identifier and the signature information in the target email through the smart contract, and obtain an identity authentication result of the user terminal.
[0088] As an implementation manner, the mailbox-based identity authentication apparatus 400 further includes:
[0089] The second sending module is configured to allow the user terminal to send an identity information change request when the identity authentication result is identity authentication passed, the identity information change request including adding a public key, modifying a public key and deleting a public key; and send identity authentication failure information to the user terminal when the identity authentication result is identity authentication not passed.
[0090] As an implementation manner, the target mailbox includes a black hole mailbox.
[0091] The embodiment of the present application also provides a corresponding device and a computer readable storage medium for implementing the scheme provided by the embodiment of the present application.
[0092] The device includes a memory and a processor, the memory is configured to store a computer program, and the processor is configured to execute the computer program to enable the device to perform the mailbox-based identity authentication method described in any embodiment of the present application.
[0093] The computer readable storage medium stores a computer program, and when the computer program is executed, the device executing the computer program implements the mailbox-based identity authentication method described in any embodiment of the present application.
[0094] The "first", "second" in the names of the "first", "second" mentioned in the embodiments of the present application are only used for name identification, and do not represent the first, second in order.
[0095] From the description of the above embodiments, those skilled in the art can clearly understand that all or part of the steps in the above-mentioned embodiment methods can be implemented by means of software plus a general hardware platform. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product. The computer software product can be stored in a storage medium, such as a read-only memory (English: read-only memory, ROM) / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for causing a computer device (which can be a personal computer, a node, or a network communication device such as a router) to execute the methods described in various embodiments or some parts of the embodiments of the present application.
[0096] Each of the embodiments in the specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other. Each embodiment focuses on the difference from other embodiments. In particular, for the device embodiments, since they are basically similar to the method embodiments, they are described more simply, and the relevant parts refer to the part of the method embodiments. According to the actual needs, some or all of the modules can be selected to achieve the purpose of the embodiment scheme. Those skilled in the art can understand and implement without creative labor.
[0097] The above is only an exemplary embodiment of the present application, and is not intended to limit the protection scope of the present application.
Claims
1. An email-based authentication method, characterized in that, The method, executed by a blockchain node, includes: Receive authentication requests sent by user terminals; Based on the authentication request, an authentication identifier is generated via a smart contract; The authentication identifier is sent to the user terminal. The authentication identifier is used to notify the user terminal to send a target email containing the authentication identifier to the target email address through the user's email address. The target email is signed by the Domain Key Identifier Mail Standard (DKIM) protocol. Receive the target email and the signature information of the target email sent by the user terminal; The target email and the signature information are authenticated through a smart contract to obtain the authentication result of the user terminal. After obtaining the authentication result of the user terminal, the method further includes: When the authentication result is successful, the user terminal is allowed to send an identity information change request, which includes adding a public key, modifying a public key, or deleting a public key; When the authentication result is that the authentication fails, an authentication failure message is sent to the user terminal.
2. The method according to claim 1, characterized in that, The authentication identifier includes a random number, a universally unique identifier (UUID), and / or an auto-incrementing serial number.
3. The method according to claim 1, characterized in that, The step of verifying the target email and the signature information through a smart contract to obtain the authentication result of the user terminal includes: The authentication result of the user terminal is obtained by verifying the authentication identifier and signature information in the target email through a smart contract.
4. The method according to any one of claims 1 to 3, characterized in that, The target email address includes the Blackhole email address.
5. An email-based identity verification device, characterized in that, Deployed on a blockchain node, the device includes: The first receiving module is used to receive authentication requests sent by user terminals; The generation module is used to generate an authentication identifier through a smart contract based on the authentication request; The first sending module is used to send the authentication identifier to the user terminal. The authentication identifier is used to notify the user terminal to send a target email containing the authentication identifier to a target email address through the user's email address. The target email is signed by the Domain Key Identifier Mail Standard (DKIM) protocol. The second receiving module is used to receive the target email and the signature information of the target email sent by the user terminal; An authentication module is used to authenticate the target email and the signature information through a smart contract to obtain the authentication result of the user terminal. The device further includes: The second sending module is configured to allow the user terminal to send an identity information change request when the authentication result is successful, the identity information change request including adding a public key, modifying a public key, or deleting a public key; and to send an authentication failure message to the user terminal when the authentication result is unsuccessful.
6. The apparatus according to claim 5, characterized in that, The authentication module includes: The verification unit is specifically used to verify the identity verification identifier and the signature information in the target email through a smart contract, and to obtain the identity verification result of the user terminal.
7. An email-based authentication device, characterized in that, The device includes: Memory, used to store computer programs; A processor, configured to implement the steps of the email-based authentication method as described in any one of claims 1 to 4 when executing the computer program.
8. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the email-based authentication method as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Block chain-based identity authentication methods, authentication server and user terminal
CN106533696A
Blockchain-based account management method, device, server and storage medium
CN108712395A