Anonymous identity authentication method and device, electronic equipment, and storage medium

CN120474719BActive Publication Date: 2026-09-11TRAVELSKY TECHNOLOGY LIMITED
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510675726.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-05-23
Publication Date
2026-09-11
Estimated Expiration
2045-05-23

AI Technical Summary

Technical Problem

[0005]本发明实施例提供了一种匿名身份认证方法及装置、电子设备、存储介质,以至少解决相关技术中身份认证过程容易遭遇安全攻击,造成信息泄露以及认证不可靠,从而导致身份认证失败的技术问题

Benefits of technology

[0139] 1. To achieve anonymity for logged-in users, a ring signature algorithm is used to enable users to prove they are members of a legitimate user group without revealing their specific identity. At the same time, a non-interactive zero-knowledge proof method is introduced to ensure the legitimacy of the user's identity, that is, to prove that the user does indeed possess a specific private key and that the signature was legally generated. Through the above methods, the privacy, legitimacy of the identity, and security of the authentication of the users to be logged in are guaranteed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120474719B_ABST
    Figure CN120474719B_ABST
Patent Text Reader

Abstract

The application discloses an anonymous identity authentication method and device, electronic equipment and a storage medium, relates to the technical field of anonymous identity authentication or other related fields, and the method comprises the steps of obtaining a public key set containing a trusted user public key, and extracting a local private key of a target anonymous user; generating a ring signature based on the public key set and the private key, and generating proof information based on the private key and the ring signature, wherein the ring signature is used to prove that the target anonymous user belongs to one of the trusted users, and the proof information is used to prove that the ring signature is legal; encapsulating the ring signature, the proof information and a timestamp identifier into an authentication request, submitting the authentication request to an authentication system, and returning an authentication result; obtaining an identity authentication token indicating that the authentication is passed in the authentication result, and logging in to the authentication system based on the identity authentication token. The application solves the technical problem that the identity authentication process is prone to security attacks, information leakage and unreliable authentication in the related art, thereby causing identity authentication failure.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of anonymous identity authentication technology, and more specifically, to an anonymous identity authentication method and apparatus, electronic device, and storage medium. Background Technology

[0002] In the digital age, internet services are deeply integrated into our lives, but this has also increased the risk of identity and privacy leaks. Personal information submitted when registering and logging in on online platforms—including sensitive data such as ID numbers, names, phone numbers, and email addresses—is easily intercepted during transmission, leading to privacy breaches and security threats.

[0003] Despite rapid technological advancements, identity authentication still faces two core challenges: information leakage due to security attacks and the unreliability of the authentication mechanism itself. These two factors together constitute the key reasons for authentication failure. Given the serious consequences of privacy data breaches and users' growing demand for privacy protection, the limitations of existing identity authentication technologies are becoming increasingly apparent. The authentication process is vulnerable to security attacks, leading to information leakage and unreliable authentication, ultimately resulting in authentication failure.

[0004] There is currently no effective solution to the above problems. Summary of the Invention

[0005] This invention provides an anonymous identity authentication method, apparatus, electronic device, and storage medium to at least solve the technical problems in related technologies where the identity authentication process is susceptible to security attacks, resulting in information leakage and unreliable authentication, thus leading to identity authentication failure.

[0006] According to one aspect of the present invention, an anonymous identity authentication method is provided, wherein a user terminal for a target anonymous user includes: obtaining a public key set containing public keys of N trusted users authorized by an authentication system, and extracting a private key locally stored by the target anonymous user, wherein N is a positive integer greater than or equal to 2; generating a ring signature based on the public key set and the private key, and generating proof information based on the private key and the ring signature, wherein the ring signature is used to prove that the target anonymous user belongs to one of the N trusted users, and the proof information is used to prove the validity of the ring signature; encapsulating the ring signature, the proof information, and a timestamp identifier into an authentication request initiated by the target anonymous user, and submitting the authentication request to the authentication system, wherein the authentication system performs identity authentication based on the ring signature, the proof information, and the timestamp identifier to generate and return an authentication result; obtaining an identity authentication token indicating successful authentication in the authentication result, and logging into the authentication system based on the identity authentication token.

[0007] Further, the step of generating a ring signature based on the public key set and the private key includes: obtaining challenge string information, wherein the challenge string information is a random challenge value generated by the authentication system based on a random timestamp within the current time period; obtaining, according to elliptic curve cryptography, a unique random number generated by a random number generator for the target anonymous user, and a set of random numbers generated for N-1 other trusted users besides the target anonymous user, wherein the set of random numbers contains N-1 random numbers corresponding one-to-one with the other N-1 trusted users, and each of the random numbers conforms to a preset elliptic curve. The specified value range is defined; the true intermediate value corresponding to the target anonymous user is calculated based on the unique random number, and N-1 fake intermediate values ​​corresponding to other N-1 trusted users are constructed based on the random number set and the public key set; N hash values ​​are calculated based on the true intermediate value and the N-1 fake intermediate values, and the unique fake random number corresponding to the target anonymous user is calculated based on the principle that the N hash values ​​can form a closed hash chain; the unique fake random number is placed into the random number set, and the new random number set and the closed hash chain are arranged according to a preset structure to obtain the ring signature.

[0008] Further, the step of generating proof information based on the private key and the ring signature includes: hashing the private key to obtain an anonymous user commitment, wherein the anonymous user commitment is a public commitment value used to prove that a user holds the private key but does not disclose the private key value; hashing the challenge string information, the public key set, the ring signature, and the anonymous user commitment to obtain a challenge value; encrypting the challenge value using the private key to obtain a response value; and encapsulating the challenge value and the response value to obtain the proof information.

[0009] Furthermore, the authentication system, upon receiving the authentication request, performs the following steps to authenticate the ring signature: extracting the ring signature from the authentication request, and calculating N verification intermediate values ​​based on N random numbers and corresponding N hash values ​​in the ring signature; verifying whether the N hash values ​​can form a closed hash chain based on the N verification intermediate values ​​and challenge string information, and obtaining a verification result; if the hash chain is verified to be closed, determining that the ring signature is authentic, and that the target anonymous user is one of the trusted users.

[0010] Furthermore, the authentication system, upon receiving the authentication request, performs the following steps to authenticate the proof information: performing a hash calculation using the challenge string information, the public key set, the closed hash chain, and the publicly disclosed anonymous user commitment to obtain a verification challenge value; extracting the proof information from the authentication request; and determining that the challenge value submitted by the target anonymous user is genuine if the verification challenge value matches the challenge value in the proof information.

[0011] Furthermore, the authentication system, upon receiving the authentication request, further includes the following steps for authenticating the proof information: if the challenge value submitted by the target anonymous user is deemed genuine, performing a mathematical relationship verification between the verification challenge value and the response value in the proof information to obtain a verification result; if the verification result indicates that the verification challenge value and the response value conform to a preset mathematical relationship, determining that the proof information is reliable and that the ring signature is valid.

[0012] Further, the authentication system, upon receiving the authentication request, performs the following steps to authenticate the timestamp identifier: querying the system identifier database using the timestamp identifier as a query identifier to obtain a query result; if the query result indicates that the query identifier does not duplicate any historical identifier, the timestamp authentication is deemed successful; if the ring signature, the proof information, and the timestamp identifier are all successfully authenticated, an identity authentication token for the target anonymous user is generated, wherein the identity authentication token is used to log in to the authentication system; if any one of the ring signature, the proof information, and the timestamp identifier fails authentication, the authentication request for the target anonymous user is rejected, and the timestamp identifier is marked as invalid.

[0013] According to another aspect of the present invention, an anonymous identity authentication device is also provided, wherein it is disposed on the user terminal of a target anonymous user, comprising: an acquisition unit, configured to acquire a public key set containing public keys of N trusted users authorized by the authentication system, and extract a private key stored locally by the target anonymous user, wherein N is a positive integer greater than or equal to 2; a generation unit, configured to generate a ring signature based on the public key set and the private key, and generate proof information based on the private key and the ring signature, wherein the ring signature is used to prove that the target anonymous user belongs to one of the N trusted users, and the proof information is used to prove that the ring signature is valid; a submission unit, configured to encapsulate the ring signature, the proof information, and a timestamp identifier into an authentication request initiated by the target anonymous user, and submit the authentication request to the authentication system, wherein the authentication system performs identity authentication based on the ring signature, the proof information, and the timestamp identifier to generate and return an authentication result; and a login unit, configured to acquire an identity authentication token indicating successful authentication in the authentication result, and log in to the authentication system based on the identity authentication token.

[0014] Further, the generation unit includes: a first acquisition module, used to acquire challenge string information, wherein the challenge string information is a random challenge value generated by the authentication system based on a random timestamp within the current time period; a second acquisition module, used to acquire, based on elliptic curve cryptography, a unique random number generated by a random number generator for the target anonymous user, and a set of random numbers generated for N-1 other trusted users besides the target anonymous user, wherein the set of random numbers contains N-1 random numbers corresponding one-to-one with the other N-1 trusted users, and each random number conforms to the value range specified by a preset elliptic curve; and a first calculation. The first module is used to calculate the real intermediate value corresponding to the target anonymous user based on the unique random number, and construct N-1 fake intermediate values ​​corresponding to other N-1 trusted users based on the random number set and the public key set; the second calculation module is used to calculate N hash values ​​based on the real intermediate value and the N-1 fake intermediate values, and calculate the unique fake random number corresponding to the target anonymous user based on the principle that the N hash values ​​can form a closed hash chain; the third module is used to place the unique fake random number into the random number set, and arrange the new random number set and the closed hash chain according to a preset structure to obtain the ring signature.

[0015] Furthermore, the generation unit further includes: a third calculation module, used to perform hash calculation on the private key to obtain an anonymous user commitment, wherein the anonymous user commitment is a public commitment value used to prove that a user holds a private key but does not disclose the private key value; a fourth calculation module, used to perform hash calculation on the challenge string information, the public key set, the ring signature, and the anonymous user commitment to obtain a challenge value; an encryption module, used to encrypt the challenge value using the private key to obtain a response value; and an encapsulation module, used to encapsulate the challenge value and the response value to obtain the proof information.

[0016] Furthermore, the anonymous identity authentication device also includes a first authentication unit in the authentication system, used to perform the step of authenticating the ring signature after the authentication system receives the authentication request. The first authentication unit includes: a fifth calculation module, used to extract the ring signature from the authentication request and calculate N verification intermediate values ​​based on N random numbers and corresponding N hash values ​​in the ring signature; a verification module, used to verify whether the N hash values ​​can form a closed hash chain based on the N verification intermediate values ​​and challenge string information, and obtain a verification result; and a first identification module, used to identify the ring signature as genuine and the target anonymous user as one of the trusted users if the hash chain is verified to be closed.

[0017] Furthermore, the anonymous identity authentication device also includes a second authentication unit in the authentication system, used to perform the step of authenticating the proof information after the authentication system receives the authentication request. The second authentication unit includes: a sixth calculation module, used to perform hash calculation using the challenge string information, the public key set, the closed hash chain, and the publicly disclosed anonymous user commitment to obtain a verification challenge value; and a second determination module, used to extract the proof information in the authentication request, and determine that the challenge value submitted by the target anonymous user is genuine if the verification challenge value matches the challenge value in the proof information.

[0018] Furthermore, the second authentication unit further includes: a verification module, used to perform a mathematical relationship verification between the verification challenge value and the response value in the proof information when the challenge value submitted by the target anonymous user is deemed to be genuine, and to obtain a verification result; and a third determination module, used to determine that the proof information is reliable and the ring signature is valid when the verification result indicates that the verification challenge value and the response value conform to a preset mathematical relationship.

[0019] Furthermore, the anonymous identity authentication device also includes a third authentication unit in the authentication system, used to perform the step of authenticating the timestamp identifier after the authentication system receives the authentication request. The third authentication unit includes: a query module, used to query the system identifier library using the timestamp identifier as the query identifier to obtain a query result; a fourth determination module, used to determine that the timestamp authentication is successful if the query result indicates that the query identifier does not duplicate any historical identifier; a generation module, used to generate an identity authentication token for the target anonymous user if the ring signature, the proof information, and the timestamp identifier are all successfully authenticated, wherein the identity authentication token is used to log in to the authentication system; and a rejection module, used to reject the authentication request of the target anonymous user and mark the timestamp identifier as invalid if any one of the ring signature, the proof information, and the timestamp identifier fails authentication.

[0020] According to another aspect of the present invention, a computer-readable storage medium is also provided, the computer-readable storage medium including a stored computer program, wherein, when the computer program is executed, it controls the device where the computer-readable storage medium is located to perform any of the above-described anonymous identity authentication methods.

[0021] According to another aspect of the present invention, an electronic device is also provided, including one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors cause the one or more processors to implement any of the above-described anonymous identity authentication methods.

[0022] This invention proposes an anonymous identity authentication method for a target anonymous user's client. First, a public key set containing the public keys of N trusted users authorized by the authentication system is obtained, and the private key stored locally by the target anonymous user is extracted, where N is a positive integer greater than or equal to 2. Then, a ring signature is generated based on the public key set and the private key, and proof information is generated based on the private key and the ring signature. The ring signature proves that the target anonymous user belongs to one of the N trusted users, and the proof information proves the validity of the ring signature. Next, the ring signature, proof information, and timestamp identifier are encapsulated into an authentication request initiated by the target anonymous user, and the authentication request is submitted to the authentication system. The authentication system performs identity authentication based on the ring signature, proof information, and timestamp identifier to generate and return an authentication result. Finally, an identity authentication token indicating successful authentication is obtained from the authentication result, and the user logs into the authentication system based on this identity authentication token.

[0023] In this invention, an identity verification mechanism that combines ring signatures and non-interactive zero-knowledge proofs is adopted. Through cryptographic operations, it achieves efficient anonymous identity authentication without exposing the user's specific identity information, thereby realizing the technical effect of ensuring high security and reliability of identity authentication while protecting user privacy.

[0024] Specifically, the anonymous user first obtains a public key set authorized by the authentication system, containing public keys from multiple trusted users. This set, combined with a locally stored private key, generates a ring signature to prove the user belongs to a trusted user group, rather than directly revealing their identity. Next, proof information is generated based on the private key and ring signature to verify the ring signature's legitimacy, ensuring the signature was indeed generated by the user's private key. This proves the user's identity is genuine and valid even in an anonymous state. Subsequently, a timestamp identifier is introduced to ensure the immediate uniqueness of each authentication request, preventing replay attacks. The ring signature, proof information, and timestamp identifier are encapsulated in the authentication request, which is submitted to the authentication system by the anonymous user. Upon receiving the request, the authentication system performs a comprehensive evaluation based on the above information to generate an authentication result. Finally, after successful authentication, the user receives an identity authentication token, allowing them to log in to the authentication system without disclosing any sensitive information and enjoy secure, anonymous online services.

[0025] This invention thoroughly improves the vulnerability of identity verification in related technologies through the above-mentioned means, effectively avoids security attacks during the authentication process, reduces the risk of information leakage, enhances the reliability of authentication, significantly improves the level of user privacy protection and the user experience of online services, and thus solves the technical problem that the identity authentication process in related technologies is prone to security attacks, resulting in information leakage and unreliable authentication, which leads to identity authentication failure. Attached Figure Description

[0026] The accompanying drawings, which are included to provide a further understanding of the invention and form part of this application, illustrate exemplary embodiments of the invention and, together with their description, serve to explain the invention and do not constitute an undue limitation thereof. In the drawings:

[0027] Figure 1 This is a flowchart of an optional anonymous identity authentication method according to an embodiment of the present invention;

[0028] Figure 2 This is a model diagram of an optional anonymous authentication system according to an embodiment of the present invention;

[0029] Figure 3 This is a flowchart of an optional anonymous authentication and anonymous login method according to an embodiment of the present invention;

[0030] Figure 4 This is a schematic diagram of an optional anonymous identity authentication device according to an embodiment of the present invention;

[0031] Figure 5 This is a structural block diagram of an electronic device that performs an anonymous identity authentication method according to an embodiment of the present invention. Detailed Implementation

[0032] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.

[0033] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0034] To facilitate understanding of the present invention by those skilled in the art, some terms or nouns involved in the various embodiments of the present invention are explained below:

[0035] Ring signature is a special digital signature scheme that allows the signer of a message to conceal their identity from a group of signers (i.e., a "ring"). The generation of a ring signature relies on the public keys of all members in the ring and the signer's own private key. When verifying a signature, the verifier only knows that the signer is a member of the ring, but cannot determine which specific member. This feature protects user privacy while ensuring the authenticity and legitimacy of the authentication.

[0036] NIZK, Non-interactive Zero-Knowledge Proof, is a proof mechanism that allows a prover (i.e., a user) to prove the correctness of a statement or knowledge without direct interaction with a verifier (such as an authentication system). In this invention, a user proves the legitimacy of their private key using NIZK and is able to generate a valid ring signature, without revealing any specific information about the private key.

[0037] The following embodiments of the present invention can be applied to various systems / applications / devices that require anonymous authentication and secure login, enabling users to perform efficient and secure identity authentication and login functions without exposing their personal privacy. The present invention uses a ring signature algorithm for anonymous identity verification, and then generates proof information based on non-interactive zero-knowledge proofs, which better ensures the legitimacy of the ring signature while protecting the privacy of the user's private key and preventing information leakage and replay attacks.

[0038] This innovative anonymous identity verification process enables users to successfully complete identity verification and access the services they need, even in highly sensitive environments such as financial transactions, online government affairs, or personal data management platforms, while ensuring their privacy and security. This significantly improves the security of user data and the convenience of the authentication process.

[0039] The present invention will now be described in detail with reference to various embodiments.

[0040] Example 1

[0041] According to an embodiment of the present invention, an anonymous identity authentication method embodiment is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0042] Examples of embodiments of the present invention Figure 1 The anonymous identity authentication method shown can be implemented by the client of the target anonymous user interacting with the authentication system. Combining ring signature and non-interactive zero-knowledge proof technology, it is used for anonymous identity authentication scenarios, especially for the problems of user privacy leakage and identity forgery. The anonymous identity authentication process includes the following steps: obtaining a public key set, generating a ring signature and proof information, encapsulating the authentication request, verifying the validity of the ring signature and proof information, and generating and returning an identity authentication token. This ensures high security and reliability of identity authentication while protecting user privacy.

[0043] Figure 1 This is a flowchart of an optional anonymous identity authentication method according to an embodiment of the present invention, such as... Figure 1 As shown, the method includes the following steps:

[0044] Step S101: Obtain a public key set containing the public keys of N trusted users authorized by the authentication system, and extract the private key stored locally by the target anonymous user, where N is a positive integer greater than or equal to 2.

[0045] It should be noted that the authentication system is the central hub responsible for managing, verifying, and authorizing user identities. Its main responsibilities include, but are not limited to, user management, key management, identity verification, and authentication token issuance. A trusted user is a user who has registered and passed the verification process in the authentication system, whose identity is recognized by the system, and who possesses a corresponding public-private key pair. The public key is public, while the private key is kept by the user.

[0046] In this system, the public keys of all trusted users form a public key set. This set can participate in generating ring signatures to allow users to prove their membership in the set without revealing their personal identity information. The private key, stored locally on each user's device, is a pair with a specific public key in the public key set. It directly relates to the user's identity security and privacy; any disclosure could increase the risk of identity spoofing. In this embodiment, only users with the correct private key can generate a valid ring signature to prove they are a member of the trusted user set authorized by the authentication system.

[0047] In this embodiment of the invention, the target anonymous user refers to a user who wishes to verify their identity through an authentication system without disclosing their personal identity information. For example, in scenarios such as financial services, online shopping, and social media, users may wish to enjoy services while avoiding the leakage of their personal information.

[0048] Another point to note is that the key pairs are pre-generated during the registration phase. The registration method includes: the authentication system generating a public-private key pair for each successfully registered user; the private key being kept privately by the registered user; and the public key being made public. The registration phase is the foundation of the anonymous identity authentication system. Generating a public-private key pair for each user ensures that each user has a unique and secure identity. For example, during system registration, the SM2 algorithm (Elliptic Curve Public Key Algorithm) is used to generate public-private key pairs for users. The private key is kept privately by the user, while the public key is made public, serving as the basis for ring signatures and ZKP (Zero-Knowledge Proof) generation.

[0049] In one specific embodiment, the public and private key generation process of SM2 relies on the basic operations of elliptic curves and the mathematical model of key generation, randomly selecting two multiplicative cyclic groups G1 and G2 of prime order q, and a bilinear mapping function e: G1×G1→G2, and selecting a generator g∈G1.

[0050] The private key generation process includes: randomly selecting a large integer sk as the user's private key, where the value of sk is in the range of 1≤sk≤q. The private key is kept secret and is generated by a random number generator in the key generation organization to ensure its randomness and unpredictability. At the same time, the private key is kept by the user alone.

[0051] Public key generation includes: calculating using the private key sk and the generator g multiplied by a factor, i.e.: pk = sk·g.

[0052] Furthermore, during the user registration phase, assume that the set of legitimate users of the service system consists of n legitimate users, represented as: {P1, P2, ..., P...} nThe authentication system registers all users in the legitimate user set and, through a key generation organization, generates a unique public-private key pair for each user in the legitimate user set using the SM2 algorithm, i.e.: {(pk1, sk1), (pk2, sk2), ..., (pk n ,sk n Each public-private key pair corresponds to a user. After generating a public-private key pair for a user in the set of legitimate users, the private key is given to a user in the set of legitimate users for safekeeping, while the public key is made public.

[0053] The authentication system provides challenge string information M to all users in the set of legitimate users within a fixed time period. The challenge string information M is a random challenge value randomly generated by the authentication system. Users use the challenge string information M to generate authentication requests to prevent replay attacks and prove the legitimacy of their identity in an anonymous manner.

[0054] In this embodiment of the invention, the challenge string information M can be a timestamp or a random number, or a value generated by combining a timestamp and a random number. When a user wants to log in to the authentication system anonymously, they need to authenticate their identity using ring signatures and zero-knowledge proofs.

[0055] Step S102: Generate a ring signature based on the public key set and the private key, and generate proof information based on the private key and the ring signature. The ring signature is used to prove that the target anonymous user belongs to one of N trusted users, and the proof information is used to prove that the ring signature is legitimate.

[0056] It's important to note that ring signatures are a type of digital signature scheme that allows a signer to anonymously prove their membership in a specified set of users (a set of trusted users) without revealing their exact identity. The set of public keys for this set of trusted users is called a "ring." For example, suppose a ring consists of the public keys of five trusted users. When one of these users signs anonymously, the recipient can only verify whether the signature was signed by one of these five trusted users through the ring signature, but cannot determine which specific trusted user signed it.

[0057] The proof information is data generated using non-interactive zero-knowledge proof technology to ensure the legitimacy of the ring signature and the actual ownership of the private key by the target anonymous user, ensuring that the legitimacy of the signature and the authenticity of the user's identity can be confirmed even in an anonymous state.

[0058] Optionally, the step of generating a ring signature based on the public key set and private key includes: obtaining challenge string information, wherein the challenge string information is a random challenge value generated by the authentication system based on a random timestamp within the current time period; obtaining, according to elliptic curve cryptography, a unique random number generated by a random number generator for the target anonymous user, and a set of random numbers generated for N-1 other trusted users besides the target anonymous user, wherein the random number set contains N-1 random numbers corresponding to the other N-1 trusted users, and each random number conforms to the value range specified by a preset elliptic curve; calculating the true intermediate value corresponding to the target anonymous user based on the unique random number, and constructing N-1 fake intermediate values ​​corresponding to the other N-1 trusted users based on the random number set and the public key set; calculating N hash values ​​based on the true intermediate value and the N-1 fake intermediate values, and calculating the unique fake random number corresponding to the target anonymous user based on the principle that the N hash values ​​can form a closed hash chain; placing the unique fake random number into the random number set, and arranging the new random number set and the closed hash chain according to a preset structure to obtain the ring signature.

[0059] In one specific embodiment, for n users in the set of legitimate users: {P1, P2, ..., P...} n Let user P be an example. s User P is a member of the legitimate user set and wants to log in to the authentication system anonymously while ensuring personal data privacy, where s is the index of the corresponding legitimate user in the set (1≤s≤n). s First, a random number k needs to be selected using a random number generator. Then, the random number k is used to calculate with the generator g to generate a number belonging to the legitimate user P. s The median value, i.e., the true median value: L s = k·g, where k∈Z q q is the order of the elliptic curve, Z q It is the set of integers modulo q, that is, all integers that satisfy 0≤k≤q. Since k represents the user number in this invention, it is not set to 0.

[0060] Next, the legitimate user P s Generate spoofed intermediate values ​​L for other legitimate users i (i≠s), used to obfuscate the signer's identity information, specifically as follows: A random number generator generates one-to-one random numbers for all users in the legitimate user set except themselves, i.e.: {r1, r2, ..., r s-1 ,r s+1 ,...,r n}, where r i ∈Z q (i≠s), and then generate their respective spoofed intermediate values ​​by using the public keys of other users, i.e.: Li =r i ·g+c i ·pk i , where c i This is the challenge value of the previous user;

[0061] Regarding the challenge value, it should be noted that the user P who actually signed the challenge value... s In generating the true intermediate value L s Then, the hash value obtained by combining the challenge string information M with the SM3 hash algorithm is used as the challenge value corresponding to the user, that is: c s =H(M||L s-1 For other users whose identities are obscured, the hash calculation formula for the challenge value is: c i+1 =H(M||L i Thus, we have obtained N challenge values ​​corresponding to N trusted users and N-1 random numbers corresponding to N-1 other users;

[0062] Based on the design requirement that ring signatures must be completely closed with their beginning and end connected, for user P s Calculate the uniquely disguised random number r s That is: r s =(kc s ·sk s mod q, insert {r1,r2,...,r} s-1 ,r s+1 ,...,r n In the set;

[0063] The final generated ring signature has the following form: σ=(c1,c2,...,c n ,r1,r2,...,r n ), where c1, c2, ..., c n Let r1, r2, ..., r be the challenge values ​​from N trusted users. n It is a random number from N trusted users.

[0064] Optionally, the step of generating proof information based on the private key and ring signature includes: hashing the private key to obtain an anonymous user commitment, wherein the anonymous user commitment is a public commitment value used to prove that the user holds the private key but does not disclose the private key value; hashing the challenge string information, the public key set, the ring signature, and the anonymous user commitment to obtain a challenge value; encrypting the challenge value using the private key to obtain a response value; and encapsulating the challenge value and the response value to obtain proof information.

[0065] In one specific embodiment, user P sAfter receiving the challenge string information M and generating a ring signature, in order to ensure the legitimacy of its identity and prevent malicious users from forging the ring signature, it is necessary to generate a zero-knowledge proof of the ring signature, thereby proving that it can generate a legitimate ring signature without exposing any private information about itself.

[0066] First, user P s By using your private key sk s A commitment is generated to ensure that the private key is not disclosed. The commitment is generated using the SM3 hash algorithm, i.e.: C = H(sk s The commitment value is public and does not reveal the private key itself; then, to ensure the non-interactive nature of zero-knowledge proofs, the challenge value needs to be passed through the publicly available challenge string information M and user P. s The public key, ring signature, and commitment are combined with the SM3 hash algorithm to generate the following: challenge = H(M, pk) s Next, using the encryption algorithm function f, the challenge value challenge, and its own private key sk, s Generate a proof that user P s A response from someone holding a valid private key is generated using the formula: response = f(sk) s Finally, the challenge value and response value are encapsulated to form a zero-knowledge proof, namely: π s = (challenge, response).

[0067] Step S103: Encapsulate the ring signature, proof information, and timestamp identifier into the authentication request initiated by the target anonymous user, and submit the authentication request to the authentication system. The authentication system performs identity authentication based on the ring signature, proof information, and timestamp identifier to generate and return the authentication result.

[0068] User P s Before sending the authentication request, a timestamp identifier (Timestamp) is generated using the current timestamp. This Timestamp, along with the ring signature, zero-knowledge proof, and unique identifier, is submitted to the authentication system as part of the authentication request. The authentication request can be represented as {σ,π} s ,Timestamp}.

[0069] It should be noted that appending a timestamp identifier to the authentication request can prevent replay attacks; after receiving the authentication request, the authentication system can detect duplicate use by comparing the timestamp with the timestamp list stored internally; and after successful authentication, the authentication system records the timestamp to ensure the uniqueness of the authentication credential, which can prevent double-spending attacks.

[0070] Upon receiving an authentication request, the authentication system will perform a series of verification processes based on the ring signature, proof information, and timestamp identifier to confirm the identity of the target anonymous user. The authentication result may include the following two scenarios.

[0071] 1. Authentication Successful: If the authentication system confirms that the ring signature is valid, the proof information is correct, and the timestamp identifier is appearing for the first time and within the valid range, then an authentication token or identity authorization is generated as a sign of successful authentication. The user who initiated the request can log in to the system with this authentication token and enjoy the relevant services or permissions.

[0072] 2. Authentication Failure: If any one or more of the ring signature, proof information, or timestamp identifier does not meet the expected verification criteria, the authentication system will reject the authentication request and record the failed timestamp identifier as invalid for comparison in future requests to prevent malicious retries or replay attacks.

[0073] Optionally, after receiving an authentication request, the authentication system performs the following steps to authenticate the ring signature: extracting the ring signature from the authentication request, and calculating N intermediate verification values ​​based on N random numbers and corresponding N hash values ​​in the ring signature; verifying whether the N hash values ​​can form a closed hash chain based on the N intermediate verification values ​​and challenge string information, and obtaining the verification result; if the hash chain is verified to be closed, determining that the ring signature is genuine, and that the target anonymous user is one of the trusted users.

[0074] Alternatively, if the hash chain is not closed, the ring signature is deemed authentic, and the target anonymous user is deemed an untrusted user.

[0075] In one specific embodiment, after receiving an authentication request from a target anonymous user, the authentication system first performs ring signature verification, calculating the value of each user P using the challenge value and a random number given in the submitted ring signature σ. i The intermediate value of (i = 1, 2, ..., n), i.e.: L i =r i ·g+c i ·pk i Then, the authentication system verifies whether each user meets the following conditions: c i+1 =H(M||L i Finally, verify whether c1 satisfies the condition for loop closure, i.e.: c1 = H(M||L) n ), where L n It is the median value of the last user.

[0076] If all the above conditions are met, it proves that the ring signature is valid, the anonymous user submitting the request is identified as a legitimate user without exposing personal information, and the ring signature does indeed come from a member of the key ring.

[0077] Optionally, after receiving an authentication request, the authentication system performs the following steps to authenticate the proof information: using the challenge string information, the public key set, the closed hash chain, and the publicly disclosed anonymous user commitment to perform a hash calculation to obtain a verification challenge value; extracting the proof information from the authentication request; and determining that the challenge value submitted by the target anonymous user is genuine if the verification challenge value matches the challenge value in the proof information.

[0078] Alternatively, if the challenge value submitted by the target anonymous user is inconsistent with the challenge value in the proof information, the challenge value submitted by the target anonymous user is deemed to be authentic.

[0079] In one specific embodiment, if the ring signature authentication passes, the authentication system continues with the non-interactive zero-knowledge proof π. s Verification is performed to ensure that the target anonymous user does indeed possess the correct private key and can legally generate the ring signature σ. The specific verification is as follows:

[0080] The authentication system administrator recalculates the challenge value using the same public information (public challenge string M, public key set, ring signature σ, commitment C), i.e., the verification challenge value is called "challenge". new =H((M,pk s If the verification challenge value is recalculated (σ,C), then... new If the challenge value matches the one submitted by the anonymous user, then the challenge value was generated correctly.

[0081] Optionally, the authentication process of the authentication system after receiving an authentication request further includes the following steps: if the challenge value submitted by the target anonymous user is deemed to be genuine, performing a mathematical relationship verification between the verification challenge value and the response value in the authentication information to obtain a verification result; if the verification result indicates that the verification challenge value and the response value conform to a preset mathematical relationship, then the authentication information is deemed reliable, and the ring signature is deemed valid.

[0082] Alternatively, if the verification result indicates that the verification challenge value and the response value do not conform to a preset mathematical relationship, the verification information is deemed unreliable, and the ring signature is deemed invalid.

[0083] In one specific embodiment, if the challenge value is generated correctly, the authentication system uses the calculated challenge value. newThe response value provided by the anonymous target user is checked against a predetermined encryption algorithm function to determine if the response conforms to the mathematical relationship: Verify(response, challenge). new ,pk s If the above equation holds, it can be verified that the anonymous target user legally generated the ring signature without revealing the private key.

[0084] Optionally, the authentication system, upon receiving an authentication request, performs the following steps to authenticate the timestamp identifier: using the timestamp identifier as a query identifier to query the system identifier database and obtain the query result; if the query result indicates that the query identifier does not duplicate any historical identifier, the timestamp authentication is deemed successful; if the query result indicates that there is a historical identifier that duplicates the query identifier, the timestamp authentication is deemed unsuccessful.

[0085] Furthermore, after authenticating the timestamp identifier, the process also includes: generating an identity authentication token for the target anonymous user if the ring signature, proof information, and timestamp identifier are all successfully authenticated, wherein the identity authentication token is used to log in to the authentication system; and rejecting the authentication request of the target anonymous user and marking the timestamp identifier as invalid if any one of the ring signature, proof information, or timestamp identifier fails authentication.

[0086] In one specific implementation, the authentication system records the unique identifier (Timestamp) sent by the target anonymous user in the authentication request and checks whether the authentication request has already been processed. If the same identifier has been found to have been processed, the duplicate request is rejected.

[0087] Furthermore, if the authentication system successfully verifies the ring signature, zero-knowledge proof, and unique identifier (Timestamp) sent to the target anonymous user, the authentication system will confirm the user's legitimacy and send a P to the user. s Return a valid authentication token, i.e.: AuthenticationResult(P) s =Authorized; If any one or more authentication steps fail, the authentication system rejects the authentication request and marks the currently sent unique identifier Timestamp as invalid in the database, never allowing any authentication request carrying that identifier to pass, i.e.: AuthenticationResult(P s = Unauthorized.

[0088] Step S104: Obtain the identity authentication token indicating successful authentication from the authentication result, and log in to the authentication system based on the identity authentication token.

[0089] In one alternative embodiment, the target is an anonymous user P. s After receiving the authentication token from the authentication system, user P uses this token to request login access to the authentication and service systems without disclosing any personal information. The authentication system, after verifying the token's accuracy, allows login. s Anonymous authentication and login successful.

[0090] Through steps S101 to S104 above, a public key set containing the public keys of N trusted users authorized by the authentication system can be obtained first, and the private key stored locally by the target anonymous user can be extracted, where N is a positive integer greater than or equal to 2. Then, a ring signature is generated based on the public key set and the private key, and proof information is generated based on the private key and the ring signature. The ring signature is used to prove that the target anonymous user belongs to one of the N trusted users, and the proof information is used to prove that the ring signature is valid. Then, the ring signature, proof information, and timestamp identifier are encapsulated into the authentication request initiated by the target anonymous user and submitted to the authentication system. The authentication system performs identity authentication based on the ring signature, proof information, and timestamp identifier to generate and return the authentication result. Finally, the identity authentication token indicating successful authentication in the authentication result is obtained, and the user logs into the authentication system based on the identity authentication token.

[0091] In this embodiment of the invention, an identity verification mechanism that combines ring signatures and non-interactive zero-knowledge proofs is adopted. Through cryptographic operations, the goal of efficient anonymous identity authentication is achieved without exposing the user's specific identity information. This achieves the technical effect of ensuring high security and reliability of identity authentication while protecting user privacy.

[0092] Specifically, the anonymous user first obtains a public key set authorized by the authentication system, containing public keys from multiple trusted users. This set, combined with a locally stored private key, generates a ring signature to prove the user belongs to a trusted user group, rather than directly revealing their identity. Next, proof information is generated based on the private key and ring signature to verify the ring signature's legitimacy, ensuring the signature was indeed generated by the user's private key. This proves the user's identity is genuine and valid even in an anonymous state. Subsequently, a timestamp identifier is introduced to ensure the immediate uniqueness of each authentication request, preventing replay attacks. The ring signature, proof information, and timestamp identifier are encapsulated in the authentication request, which is submitted to the authentication system by the anonymous user. Upon receiving the request, the authentication system performs a comprehensive evaluation based on the above information to generate an authentication result. Finally, after successful authentication, the user receives an identity authentication token, allowing them to log in to the authentication system without disclosing any sensitive information and enjoy secure, anonymous online services.

[0093] The embodiments of the present invention thoroughly improve the vulnerability of identity verification in related technologies through the above-mentioned means, effectively avoid security attacks during the authentication process, reduce the risk of information leakage, enhance the reliability of authentication, significantly improve the level of user privacy protection and the user experience of online services, and thus solve the technical problem that the identity authentication process in related technologies is prone to security attacks, resulting in information leakage and unreliable authentication, thereby leading to identity authentication failure.

[0094] The present invention will now be described in conjunction with another specific embodiment.

[0095] The application background involved in the embodiments of the present invention is as follows: In the scenario of anonymous identity authentication, the authentication system provides a set of legitimate users for the legitimate users of the website. Users in the set can log in, otherwise they are not allowed; if external users want to log in to the authentication system, they need to register and join the set of legitimate users before they can use it.

[0096] Figure 2 This is a model diagram of an optional anonymous authentication system according to an embodiment of the present invention, such as... Figure 2 As shown, the model works as follows:

[0097] First, the authentication system administrator submits a key request to the key management center based on all users in the legitimate user set. The key management center then generates a public-private key pair for each user using the SM2 algorithm and sends the generated public-private key pair to all users.

[0098] Suppose user U, a member of the legitimate user set, wants to log in to the authentication system without disclosing personal information. User U needs to generate a ring signature using their private key and all the public keys of users in the legitimate user set to prove that they are a legitimate user. Then, they need to generate a non-interactive zero-knowledge proof for the ring signature to prove that the private key does indeed belong to them and can generate a valid ring signature, preventing external attackers from tampering with the information. After generating the above information, user U submits the ring signature, the non-interactive zero-knowledge proof, and the unique identifier to the authentication system for verification by the authentication system administrator.

[0099] After receiving the information uploaded by user U, the authentication system administrator verifies the validity of the ring signature using the ring signature verification formula. If the verification passes, it proves that user U is a legitimate member of the legitimate user set; otherwise, it is considered illegitimate. Then, the authentication system administrator verifies the validity of the non-interactive zero-knowledge proof. If the verification passes, it proves that the ring signature generated by user U is legitimate and that user U does indeed possess the private key paired with its public key; otherwise, it is considered illegitimate.

[0100] If all ring signatures and zero-knowledge proofs verified by the authentication system administrator pass and the requests are unique, the authentication system confirms the user's legitimacy and sends an authentication token or authorization within a certain time. If verification fails, the authentication request is rejected. A legitimate user who successfully verifies their identity will then log in to the authentication system after receiving the authentication token or authorization.

[0101] Figure 3 This is a flowchart of an optional anonymous authentication and anonymous login method according to an embodiment of the present invention, such as... Figure 3 As shown, the method includes the following steps: system initialization, legitimate user registration, submission of anonymous authentication request, anonymous authentication by the authentication system, authentication return, and user login. The specific steps are described below.

[0102] Step 1: System initialization.

[0103] System model diagram as follows Figure 2 As shown, the model diagram contains four entities: key generation system, authentication system, legitimate user set, and authentication system administrator, which will be introduced one by one.

[0104] Key generation system: Generates public and private key pairs for users in the legitimate user set using SM2, and distributes the public and private key pairs to each user through the authentication system administrator;

[0105] The authentication system administrator acts as a bridge between the key generation system, the set of legitimate users, and the authentication system. They generate corresponding key pairs for the set of legitimate users by sending them to the key generation system. At the same time, they verify the information sent by users whose identity privacy is protected, proving the user's legitimacy, and return authentication tokens to legitimate users so that they can log in to the authentication system.

[0106] Legitimate User Set: A set of legitimate users who have successfully registered through the authentication system, but who wish to log in to the authentication system without revealing their personal identities.

[0107] Authentication system: Similar to online service platforms, these are websites with authentication systems that only allow registered users or members to enjoy related services and benefits.

[0108] During initialization, it's important to note that a bilinear mapping is a general mathematical structure, typically represented as: e: G1 × G1 → G2, where G1 and G2 are two multiplicative cyclic groups. A bilinear mapping must satisfy the following three properties: a) Bilinear: for any a, b ∈ Z q For R, S∈G1, we have e(R) a ,S b )=e(R,S) abb. Non-degeneracy: There exist R, S ∈ G1 such that e(R, S) ≠ 1; c. Computability: There exists an efficient algorithm that can compute the value of e(R, S) for any R, S ∈ G1.

[0109] The public and private key generation process of SM2 relies on the basic operations of elliptic curves and the mathematical model of key generation. Two cyclic groups G1 and G2 of prime order q are randomly selected, along with a bilinear mapping function e: G1×G1→G2, and a generator g∈G1 is selected.

[0110] Furthermore, private key generation: a large integer sk is randomly selected as the user's private key, where the value range of sk is: 1≤sk≤q. The private key is kept secret and is generated by the random number generator in the key generation organization to ensure its randomness and unpredictability. At the same time, the private key is kept by the user alone. Public key generation: the public key pk is obtained by calculating the private key sk and the generator g multiple times, that is, pk=sk·g.

[0111] Step 2, Register as a legitimate user.

[0112] Assume the service system has n valid users, represented as: {P1, P2, ..., P...} n The authentication system registers all users in the legitimate user set and, through a key generation organization, generates a unique public-private key pair for each user in the legitimate user set using the SM2 algorithm, i.e.: {(pk1, sk1), (pk2, sk2), ..., (pk n ,sk n In this system, each public-private key pair corresponds one-to-one with a user.

[0113] After generating public-private key pairs for users in the legitimate user set, the authentication system administrator entrusts the private keys to these users for private safekeeping, while making the public keys public. The authentication system then provides a challenge string M to all users in the legitimate user set within a fixed time interval. Users generate authentication information using the challenge string, proving their identity's legitimacy anonymously.

[0114] Step 3: Submit an anonymous authentication request.

[0115] When a user wants to log in to the authentication system to verify their identity, they need to use ring signatures and non-interactive zero-knowledge proofs to confirm the legitimacy of their identity.

[0116] 1. Ring signature generation:

[0117] For n users in the set of valid users: {P1, P2, ..., P...} n Let user P be an example. sUser P is a member of the legitimate user set and wants to log in to the authentication system anonymously while ensuring personal data privacy, where s is the index of the corresponding legitimate user in the set, and 1≤s≤n. s Choose a random number k, where k∈Z q q is the order of the elliptic curve, and a random number k is calculated with the generator g to generate a value belonging to the legitimate user P. s The median value, namely: L s = k·g; then, user P s Using the SM3 hash algorithm, the generated intermediate value L s The challenge string information M is hashed to generate a signature value, namely: c s =H(M||L s ).

[0118] Then, legitimate user P s Generate intermediate values ​​L for other legitimate users i (i≠s), used to obfuscate the signer's identity information; legitimate user P... s Generate random values ​​one-to-one for all users in the set of legal users except themselves, i.e., {r1, r2, ..., r...} s-1 ,r s+1 ,...,r n}, where r i ∈Z q (i≠s), and then an intermediate value for spoofing is generated by using the public keys of other users, i.e.: L i =r i ·g+c i ·pk i , where c i The challenge value of the previous user, i.e., c i+1 =H(M||L i Finally, regarding the legitimate user P... s Calculate the fake random number so that the entire ring signature can be completely closed, i.e.: r s =kc s ·sk s modq.

[0119] Finally, the generated ring signature is: σ=(c1,c2,...,c n ,r1,r2,...,r n ), where c1, c2, ..., c n These are the challenge values ​​for each user, r1, r2, ..., r n It is a random number for each user.

[0120] 2. Non-interactive zero-knowledge proof generation:

[0121] User P s After receiving the challenge string information M and generating a ring signature, in order to ensure the legitimacy of its own identity and prevent malicious users from forging the ring signature, it needs to generate a zero-knowledge proof of the ring signature, thereby proving that it can generate a legitimate ring signature without exposing any private information about itself.

[0122] First, user P s By using your private key sk s A commitment is generated to ensure that the private key is not disclosed. The commitment is generated using the SM3 national cryptographic hash algorithm, i.e.: C = H(sk s The commitment value is public and does not reveal the private key itself. Then, to ensure the non-interactive nature of zero-knowledge proofs, the challenge value needs to be passed through the publicly available challenge string information M and user P. s The public key, ring signature, and commitment are generated using the SM3 national cryptographic hash algorithm, i.e.: challenge = H(M, pk s ,σ,C).

[0123] User P s Based on the challenge value (challenge) and your private key (sk) s A response is generated using the encryption algorithm function f, which proves that the user possesses a legitimate private key. The formula for generating the response is: response = f(sk) s After generating a response, the user encapsulates the challenge value and response value to form a zero-knowledge proof, namely: π s = (challenge, response).

[0124] 3. Submit authentication request: User P s Before sending the request, a unique identifier (current timestamp) is generated. After generation, the ring signature, zero-knowledge proof, and unique identifier are submitted to the authentication system together, i.e.: {σ,π s ,Timestamp}.

[0125] Step 4: Anonymous authentication via the authentication system.

[0126] The authentication system administrator receives user P s After the authentication request is sent, ring signature verification is performed first, calculating P for each user using the submitted challenge value and a random number. i The intermediate value of (i = 1, 2, ..., n), i.e.: L i =r i ·g+c i ·pk iThen, for each user in the set of legitimate users, the authentication system administrator verifies whether the following condition is met: c i+1 =H(M||L i Finally, verify whether c1 satisfies the condition for loop closure, i.e.: c1 = H(M||L n ), where L n It is the median value of the last user.

[0127] If all the above conditions are met, then the signature is valid, and the legitimate user P is authorized. s The user is identified as a legitimate user without revealing personal information, and the ring signature does indeed originate from a member of the key ring.

[0128] Next, the authentication system administrator tested the non-interactive zero-knowledge proof π. s Verification is performed to ensure that user P s Indeed, the private key sk of Yonyou s And it can legally generate a ring signature σ. The specific verification is as follows: The authentication system administrator uses the same public information (public challenge string information M, user P) s The challenge value is recalculated using the public key, ring signature, and commitment. new =H((M,pk s If the recalculated challenge value matches the challenge value submitted by the user (σ,C), then the challenge value was generated correctly.

[0129] The authentication system administrator uses the calculated challenge value. new and user P s The provided response value is checked to see if the response conforms to the mathematical relationship of the predetermined encryption algorithm function, that is:

[0130] Verify(response, challenge) new ,pk s ,σ)=True;

[0131] If the above equation holds, then user P is guaranteed to... s It is possible to legally generate ring signatures without revealing the private key.

[0132] After verifying the above information, the authentication system administrator will record the unique identifier (Timestamp) sent by the requester and check whether the request has already been processed. If the same identifier has been found to have been processed, the duplicate request will be rejected.

[0133] Step 5, authentication returned.

[0134] If the authentication system administrator has permission for user P s Once the ring signature, zero-knowledge proof, and unique identifier (Timestamp) verifications all pass, the authentication system will confirm the user's legitimacy and issue a P to the user. s Send a valid authentication token, i.e.: AuthenticationResult(P) s =Authorized;

[0135] If the authentication system administrator has permission for user P s If the authentication request fails, the authentication request is rejected, and the currently sent unique identifier (Timestamp) is marked as invalid in the database, i.e.: AuthenticationResult(P s = Unauthorized.

[0136] Step 6: User login.

[0137] User P s After receiving a valid authentication token from the authentication system administrator, user P requests login to the authentication system without disclosing any personal information. The administrator verifies the authenticity of the authentication token and grants login access. s Login successful.

[0138] The embodiments of the present invention have the following beneficial effects:

[0139] 1. To achieve anonymity for logged-in users, a ring signature algorithm is used to enable users to prove they are members of a legitimate user group without revealing their specific identity. At the same time, a non-interactive zero-knowledge proof method is introduced to ensure the legitimacy of the user's identity, that is, to prove that the user does indeed possess a specific private key and that the signature was legally generated. Through the above methods, the privacy, legitimacy of the identity, and security of the authentication of the users to be logged in are guaranteed.

[0140] 2. To prevent malicious users from forging ring signatures to bypass the authentication system and log in, non-interactive zero-knowledge proofs are used to complete the authentication process without interaction between the user and the authentication system, making the authentication process more efficient and avoiding potential privacy leaks during the interaction process.

[0141] 3. Introduce a unique identifier during the user's request sending process and add the identifier to each authentication request to resist replay attacks; at the same time, after successful authentication, record the unique identifier of the received authentication request to ensure that each person's authentication credentials can only be used once, associate the unique identifier with the user's current authentication request and mark it as "authenticated" to prevent double-spending attacks.

[0142] 4. During the use of the ring signature algorithm, the SM2 and SM3 algorithms are used to perform symmetric encryption and hashing on the plaintext data used in the process, making it resistant to quantum attacks, effectively preventing the leakage of sensitive information, and effectively resisting malicious tampering and improper theft by external attackers, ensuring the security and privacy protection of user data.

[0143] The invention will now be described in conjunction with another alternative embodiment.

[0144] Example 2

[0145] The anonymous identity authentication device provided in this embodiment includes multiple implementation units, each of which corresponds to a specific implementation step in Embodiment 1 above.

[0146] Figure 4 This is a schematic diagram of an optional anonymous identity authentication device according to an embodiment of the present invention, such as... Figure 4 As shown, the device may include: an acquisition unit 41, a generation unit 42, a submission unit 43, and a login unit 44.

[0147] The acquisition unit 41 is used to acquire a public key set containing the public keys of N trusted users authorized by the authentication system, and to extract the private key stored locally by the target anonymous user, where N is a positive integer greater than or equal to 2.

[0148] The generation unit 42 is used to generate a ring signature based on the public key set and the private key, and to generate proof information based on the private key and the ring signature. The ring signature is used to prove that the target anonymous user belongs to one of N trusted users, and the proof information is used to prove that the ring signature is legitimate.

[0149] Submission unit 43 is used to encapsulate the ring signature, proof information and timestamp identifier into the authentication request initiated by the target anonymous user, and submit the authentication request to the authentication system. The authentication system performs identity authentication based on the ring signature, proof information and timestamp identifier to generate and return the authentication result.

[0150] Login unit 44 is used to obtain the identity authentication token indicating successful authentication from the authentication result, and log in to the authentication system based on the identity authentication token.

[0151] The aforementioned anonymous identity authentication device can first obtain a public key set containing the public keys of N trusted users authorized by the authentication system through the acquisition unit 41, and extract the private key stored locally by the target anonymous user, where N is a positive integer greater than or equal to 2. Then, the generation unit 42 generates a ring signature based on the public key set and the private key, and generates proof information based on the private key and the ring signature. The ring signature is used to prove that the target anonymous user belongs to one of the N trusted users, and the proof information is used to prove that the ring signature is valid. Then, the submission unit 43 encapsulates the ring signature, proof information, and timestamp identifier into the authentication request initiated by the target anonymous user and submits the authentication request to the authentication system. The authentication system performs identity authentication based on the ring signature, proof information, and timestamp identifier to generate and return the authentication result. Finally, the login unit 44 obtains the identity authentication token indicating successful authentication from the authentication result and logs in to the authentication system based on the identity authentication token.

[0152] In this embodiment of the invention, an identity verification mechanism that combines ring signatures and non-interactive zero-knowledge proofs is adopted. Through cryptographic operations, the goal of efficient anonymous identity authentication is achieved without exposing the user's specific identity information. This achieves the technical effect of ensuring high security and reliability of identity authentication while protecting user privacy.

[0153] Specifically, the anonymous user first obtains a public key set authorized by the authentication system, containing public keys from multiple trusted users. This set, combined with a locally stored private key, generates a ring signature to prove the user belongs to a trusted user group, rather than directly revealing their identity. Next, proof information is generated based on the private key and ring signature to verify the ring signature's legitimacy, ensuring the signature was indeed generated by the user's private key. This proves the user's identity is genuine and valid even in an anonymous state. Subsequently, a timestamp identifier is introduced to ensure the immediate uniqueness of each authentication request, preventing replay attacks. The ring signature, proof information, and timestamp identifier are encapsulated in the authentication request, which is submitted to the authentication system by the anonymous user. Upon receiving the request, the authentication system performs a comprehensive evaluation based on the above information to generate an authentication result. Finally, after successful authentication, the user receives an identity authentication token, allowing them to log in to the authentication system without disclosing any sensitive information and enjoy secure, anonymous online services.

[0154] The embodiments of the present invention thoroughly improve the vulnerability of identity verification in related technologies through the above-mentioned means, effectively avoid security attacks during the authentication process, reduce the risk of information leakage, enhance the reliability of authentication, significantly improve the level of user privacy protection and the user experience of online services, and thus solve the technical problem that the identity authentication process in related technologies is prone to security attacks, resulting in information leakage and unreliable authentication, thereby leading to identity authentication failure.

[0155] The aforementioned anonymous identity authentication device may also include a processor and a memory. The aforementioned acquisition unit 41, generation unit 42, submission unit 43, login unit 44, etc., are all stored in the memory as program units, and the processor executes the aforementioned program units stored in the memory to realize the corresponding functions.

[0156] Optionally, the generation unit includes: a first acquisition module for acquiring challenge string information, wherein the challenge string information is a random challenge value generated by the authentication system based on a random timestamp within the current time period; a second acquisition module for acquiring, based on elliptic curve cryptography, a unique random number generated by a random number generator for the target anonymous user, and a set of random numbers generated for N-1 other trusted users besides the target anonymous user, wherein the set of random numbers contains N-1 random numbers corresponding to the other N-1 trusted users, and each random number conforms to the value range specified by a preset elliptic curve; a first calculation module for calculating the real intermediate value corresponding to the target anonymous user based on the unique random number, and constructing N-1 fake intermediate values ​​corresponding to the other N-1 trusted users based on the set of random numbers and the set of public keys; a second calculation module for calculating N hash values ​​based on the real intermediate value and the N-1 fake intermediate values, and calculating the unique fake random number corresponding to the target anonymous user based on the principle that the N hash values ​​can form a closed hash chain; and an arrangement module for placing the unique fake random number into the random number set, and arranging the new random number set and the closed hash chain according to a preset structure to obtain a ring signature.

[0157] Optionally, the generation unit further includes: a third calculation module for hashing the private key to obtain an anonymous user commitment, wherein the anonymous user commitment is a public commitment value used to prove that the user holds the private key but does not disclose the private key value; a fourth calculation module for hashing the challenge string information, the public key set, the ring signature, and the anonymous user commitment to obtain a challenge value; an encryption module for encrypting the challenge value using the private key to obtain a response value; and an encapsulation module for encapsulating the challenge value and the response value to obtain proof information.

[0158] Optionally, the anonymous identity authentication device further includes a first authentication unit in the authentication system, used to perform the step of authenticating the ring signature after the authentication system receives the authentication request. The first authentication unit includes: a fifth calculation module, used to extract the ring signature from the authentication request and calculate N verification intermediate values ​​based on N random numbers and corresponding N hash values ​​in the ring signature; a verification module, used to verify whether the N hash values ​​can form a closed hash chain based on the N verification intermediate values ​​and challenge string information, and obtain the verification result; and a first identification module, used to identify the ring signature as genuine and the target anonymous user as one of the trusted users if the hash chain is verified to be closed.

[0159] Optionally, the anonymous identity authentication device further includes a second authentication unit in the authentication system, used to perform the step of authenticating the proof information after the authentication system receives the authentication request. The second authentication unit includes: a sixth calculation module, used to perform hash calculation using challenge string information, public key set, closed hash chain and public anonymous user commitment to obtain verification challenge value; and a second determination module, used to extract the proof information in the authentication request, and determine that the challenge value submitted by the target anonymous user is genuine if the verification challenge value is consistent with the challenge value in the proof information.

[0160] Optionally, the second authentication unit further includes: a verification module, used to verify the mathematical relationship between the verification challenge value and the response value in the proof information when the challenge value submitted by the target anonymous user is deemed to be true, and to obtain the verification result; and a third determination module, used to determine that the proof information is reliable and the ring signature is valid when the verification result indicates that the verification challenge value and the response value conform to a preset mathematical relationship.

[0161] Optionally, the anonymous identity authentication device further includes a third authentication unit in the authentication system, used to perform the step of authenticating the timestamp identifier after the authentication system receives an authentication request. The third authentication unit includes: a query module, used to query the system identifier database using the timestamp identifier as the query identifier to obtain the query result; a fourth verification module, used to verify that the timestamp authentication is successful if the query result indicates that the query identifier does not duplicate any historical identifier; a generation module, used to generate an identity authentication token for the target anonymous user if the ring signature, proof information, and timestamp identifier are all successfully authenticated, wherein the identity authentication token is used to log in to the authentication system; and a rejection module, used to reject the authentication request of the target anonymous user and mark the timestamp identifier as invalid if any one of the ring signature, proof information, and timestamp identifier fails authentication.

[0162] The aforementioned processor contains a kernel, which retrieves the corresponding program units from memory. One or more kernels can be configured to encapsulate the ring signature, proof information, and timestamp identifier into the authentication request initiated by the anonymous target user by adjusting kernel parameters. This authentication request is then submitted to the authentication system. The authentication system performs identity authentication based on the ring signature, proof information, and timestamp identifier to generate and return the authentication result. Finally, it obtains the authentication token indicating successful authentication from the result and logs into the authentication system using this token.

[0163] The aforementioned memory may include non-permanent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.

[0164] This application also provides a computer program product, which, when executed on a data processing device, is suitable for executing an initialization program with the following method steps: obtaining a public key set containing public keys of N trusted users authorized by the authentication system, and extracting the private key locally stored by the target anonymous user, where N is a positive integer greater than or equal to 2; generating a ring signature based on the public key set and the private key, and generating proof information based on the private key and the ring signature, wherein the ring signature is used to prove that the target anonymous user belongs to one of the N trusted users, and the proof information is used to prove the validity of the ring signature; encapsulating the ring signature, proof information, and timestamp identifier into an authentication request initiated by the target anonymous user, and submitting the authentication request to the authentication system, wherein the authentication system performs identity authentication based on the ring signature, proof information, and timestamp identifier to generate and return an authentication result; obtaining an identity authentication token indicating successful authentication from the authentication result, and logging into the authentication system based on the identity authentication token.

[0165] According to another aspect of the present invention, a computer-readable storage medium is also provided, the computer-readable storage medium including a stored computer program, wherein, when the computer program is executed, it controls the device where the computer-readable storage medium is located to execute the anonymous identity authentication method of any one of the above embodiments.

[0166] According to another aspect of the present invention, an electronic device is also provided, including one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors cause the one or more processors to implement the anonymous identity authentication method of any one of the above embodiments.

[0167] Figure 5 This is a structural block diagram of an electronic device that performs an anonymous authentication method according to an embodiment of the present invention, such as... Figure 5 As shown, the electronic device may include: one or more ( Figure 5 Only one of the components is shown: processor 502, memory 504, memory controller, and peripheral interface, wherein the peripheral interface is connected to the radio frequency module, audio module, and display.

[0168] The memory can be used to store software programs and modules, such as the program instructions / modules corresponding to the anonymous identity authentication method and apparatus in this application embodiment. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory, thereby implementing the aforementioned anonymous identity authentication method. The memory may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include memory remotely located relative to the processor, and these remote memories can be connected to the terminal via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0169] Those skilled in the art will understand that Figure 5 The structure shown is for illustrative purposes only. Electronic devices can also be smartphones, tablets, handheld computers, mobile internet devices (MIDs), PADs, and other terminal devices. Figure 5 This does not limit the structure of the aforementioned electronic device. For example, electronic devices may also include components that are more... Figure 5 The more or fewer components shown (such as network interfaces, display devices, etc.), or having the same Figure 5 The different configurations shown.

[0170] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.

[0171] In the above embodiments of the present invention, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0172] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units can be a logical functional division, and in actual implementation, there may be other division methods. For instance, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.

[0173] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0174] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0175] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, read-only memory (ROM), random access memory (RAM), portable hard drives, magnetic disks, or optical disks.

[0176] The above description is only a preferred embodiment of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.

Claims

1. An anonymous identity authentication method, characterized in that, The client-side software used for targeted anonymous users includes: Obtain a public key set containing the public keys of N trusted users authorized by the authentication system, and extract the private key stored locally by the target anonymous user, where N is a positive integer greater than or equal to 2; A ring signature is generated based on the public key set and the private key, and proof information is generated based on the private key and the ring signature. The ring signature is used to prove that the target anonymous user belongs to one of N trusted users, and the proof information is used to prove that the ring signature is legitimate. The proof information is data generated by non-interactive zero-knowledge proof technology and is used to prove that the ring signature is legitimate and that the target anonymous user has actual ownership of the private key. The ring signature, the proof information, and the timestamp identifier are encapsulated into an authentication request initiated by the target anonymous user, and the authentication request is submitted to the authentication system. The authentication system performs identity authentication based on the ring signature, the proof information, and the timestamp identifier to generate and return the authentication result. Obtain the authentication token indicating successful authentication from the authentication result, and log in to the authentication system based on the authentication token; The steps for generating proof information based on the private key and the ring signature include: The private key is hashed to obtain an anonymous user commitment, wherein the anonymous user commitment is a public commitment value used to prove that the user holds the private key but does not disclose the private key value; The challenge value is obtained by hashing the challenge string information, the public key set, the ring signature, and the anonymous user commitment. The challenge value is encrypted using the private key to obtain the response value; The challenge value and the response value are encapsulated to obtain the proof information.

2. The anonymous identity authentication method according to claim 1, characterized in that, The steps for generating a ring signature based on the public key set and the private key include: Obtain challenge string information, wherein the challenge string information is a random challenge value generated by the authentication system based on a random timestamp within the current time period; Based on elliptic curve cryptography, a unique random number generated by a random number generator for the target anonymous user is obtained, as well as a set of random numbers generated for N-1 other trusted users besides the target anonymous user. The set of random numbers contains N-1 random numbers corresponding to the other N-1 trusted users, and each random number conforms to the value range specified by a preset elliptic curve. Calculate the true intermediate value corresponding to the target anonymous user based on the unique random number, and construct N-1 fake intermediate values ​​corresponding to the other N-1 trusted users based on the set of random numbers and the set of public keys; Based on the real intermediate value and N-1 of the fake intermediate values, N hash values ​​are calculated, and a unique fake random number corresponding to the target anonymous user is calculated based on the principle that the N hash values ​​can form a closed hash chain. The unique fake random number is placed into the random number set, and the new random number set is arranged with the closed hash chain according to a preset structure to obtain the ring signature.

3. The anonymous identity authentication method according to claim 1, characterized in that, The authentication system, upon receiving the authentication request, performs the following steps to authenticate the ring signature: Extract the ring signature from the authentication request, and calculate N intermediate verification values ​​based on the N random numbers and corresponding N hash values ​​in the ring signature; Based on the N intermediate verification values ​​and challenge string information, verify whether the N hash values ​​can form a closed hash chain, and obtain the verification result; If the hash chain is verified to be closed, the ring signature is deemed authentic, and the target anonymous user is identified as one of the trusted users.

4. The anonymous identity authentication method according to claim 3, characterized in that, The authentication system, upon receiving the authentication request, performs the following steps to authenticate the proof information: The challenge string information, the public key set, the closed hash chain, and the publicly disclosed anonymous user commitment are used to perform hash calculations to obtain the verification challenge value; Extract the proof information from the authentication request. If the verification challenge value matches the challenge value in the proof information, the challenge value submitted by the target anonymous user is deemed to be genuine.

5. The anonymous identity authentication method according to claim 4, characterized in that, The authentication system, upon receiving the authentication request, further includes the following steps in authenticating the proof information: If the challenge value submitted by the target anonymous user is found to be genuine, the mathematical relationship between the verification challenge value and the response value in the proof information is verified to obtain the verification result. If the verification result indicates that the verification challenge value and the response value conform to a preset mathematical relationship, the proof information is deemed reliable, and the ring signature is deemed valid.

6. The anonymous identity authentication method according to claim 5, characterized in that, The authentication system, upon receiving the authentication request, performs the following steps to authenticate the timestamp identifier: The timestamp identifier is used as the query identifier to query the system identifier database and obtain the query result; If the query result indicates that the query identifier does not duplicate any historical identifier, the timestamp authentication is deemed successful. If the ring signature, the proof information, and the timestamp identifier are all successfully authenticated, an identity authentication token for the target anonymous user is generated, wherein the identity authentication token is used to log in to the authentication system; If any one of the ring signature, the proof information, and the timestamp identifier fails authentication, the authentication request of the target anonymous user is rejected, and the timestamp identifier is marked as invalid.

7. An anonymous identity authentication device, characterized in that, Settings on the target anonymous user's client include: The acquisition unit is used to acquire a public key set containing the public keys of N trusted users authorized by the authentication system, and to extract the private key stored locally by the target anonymous user, where N is a positive integer greater than or equal to 2; A generation unit is configured to generate a ring signature based on the public key set and the private key, and to generate proof information based on the private key and the ring signature. The ring signature is used to prove that the target anonymous user belongs to one of N trusted users, and the proof information is used to prove that the ring signature is legitimate. The proof information is data generated by non-interactive zero-knowledge proof technology and is used to prove that the ring signature is legitimate and that the target anonymous user has actual ownership of the private key. The submission unit is used to encapsulate the ring signature, the proof information, and the timestamp identifier into an authentication request initiated by the target anonymous user, and submit the authentication request to the authentication system, wherein the authentication system performs identity authentication based on the ring signature, the proof information, and the timestamp identifier to generate and return the authentication result; The login unit is used to obtain the identity authentication token indicating successful authentication from the authentication result, and log in to the authentication system based on the identity authentication token. The generation unit further includes: a third calculation module, used to perform hash calculation on the private key to obtain an anonymous user commitment, wherein the anonymous user commitment is a public commitment value used to prove that a user holds a private key but does not disclose the private key value; a fourth calculation module, used to perform hash calculation on the challenge string information, the public key set, the ring signature, and the anonymous user commitment to obtain a challenge value; an encryption module, used to encrypt the challenge value using the private key to obtain a response value; and an encapsulation module, used to encapsulate the challenge value and the response value to obtain the proof information.

8. A computer-readable storage medium, characterized in that, The computer-readable storage medium includes a stored computer program, wherein, when the computer program is executed, it controls the device on which the computer-readable storage medium is located to perform the anonymous identity authentication method according to any one of claims 1 to 6.

9. An electronic device, characterized in that, It includes one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors cause the one or more processors to implement the anonymous identity authentication method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • IOT identity authentication method based on non-interactive zero knowledge proof

    CN112636922A

  • Alliance chain cross-chain identity authentication method and system based on traceable ring signature

    CN117614634A