A homomorphic encryption privacy protection method for distributed digital identity
By using the Paillier semi-homomorphic encryption algorithm and the additive homomorphism verification of smart contracts on the blockchain, the problems of low security and low efficiency in the distributed digital identity system are solved, and efficient privacy protection of user identity information is achieved. , to prevent information leakage.
Patent Information
- Application Number
- CN202210595421.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-29
- Publication Date
- 2024-09-20
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing distributed digital identity system has problems of low security and low efficiency, especially in terms of privacy information protection, which is difficult to effectively solve, causing user identity information to be easily over-exposed.
The Paillier semi-homomorphic encryption algorithm is used to encrypt distributed digital identities. By establishing a key pair on the blockchain and using the additive homomorphism of smart contracts for identity attribute verification, it ensures that information remains private during transmission and storage. .
It effectively protects users' identity data, prevents unauthorized information leakage, and maximizes the security and privacy protection efficiency of the distributed digital identity system.
Smart Images

Figure CN115174091B
Abstract
Description
Technical Field
[0001] The present invention relates to a homomorphic encryption privacy protection method based on distributed digital identity, and belongs to the technical field of blockchain privacy protection. Background Art
[0002] With the popularization and application of blockchain, its good development prospects have quickly attracted widespread attention from scholars from all over the world. As a completely decentralized system, blockchain can not only be used for digital transactions, but its potential for trusted value transfer is almost unlimited. At present, blockchain, as the basic technical support for many industries, has brought far-reaching impacts to various industries such as finance, law, and the Internet of Things, and has great application value and research significance.
[0003] The solid trust built by blockchain between different centers comes from third-party endorsement, such as consensus mechanism, node co-governance, and account sharing. As an autonomous system, blockchain deploys nodes in the form of smart contracts. Through strong logical relationships and unified specifications, it ensures the verifiable honesty of nodes and meets the security requirements of transactions. All nodes can exchange data safely in a trustless environment, and users can establish trust with trading parties even in an anonymous manner. In addition, the immutable nature of blockchain allows the data on the chain to be permanently stored, and the information on it is highly stable.
[0004] As network technology matures, more and more digital services are gradually emerging. Digital identity, as the identity of users on the Internet, has received widespread attention. Digital identity has gone through three stages, the first is centralized digital identity, the second is federalized digital identity, and the last is the integration of blockchain technology and digital identity into distributed digital identity, which has also made it an emerging hot spot.
[0005] Distributed digital identity not only has the decentralized advantages of blockchain technology, but also extends the transaction data of the ledger to verifiable credentials. Compared with other forms of digital identity, distributed digital identity not only has basic functions such as self-registration, update, and revocation, but also allows the same user to have different distributed digital identities (DIDs) according to different purposes. Multiple DIDs are not related to each other, thus effectively avoiding the collection of private information.
[0006] However, blockchain technology is not absolutely safe. Its biggest feature, the public ledger, still poses security risks. Whether the user's verification of identity attributes on the blockchain will affect other unauthorized identity attributes, thereby over-exposing the user's identity information, is still a technical defect that needs to be resolved.
[0007] At present, most of the research stays on the application models and identity authentication of distributed digital identities in different fields, and pays less attention to the protection of privacy information in its credentials. For example, He Changhui et al. proposed a multi-PKI fusion certificate service system, which solved the distributed certificate verification between multiple domains, but it lacked integration with the trust model. Wang Jiahe et al. proposed a collaborative identity authentication scheme to solve the problem of key leakage in authentication, but it is difficult to cope with complex scenarios and still needs to find a balance between efficiency and security. Bi Danyang et al. proposed an application model of distributed digital identity in the industrial Internet, but there are still security issues. Privacy protection of distributed identities has become an important bottleneck in the development of distributed digital identities.
[0008] In 2009, Gentry created the first fully homomorphic encryption scheme, which attracted widespread attention and flourished. Homomorphic encryption technology can complete the processing of ciphertext without leaking the data content. It can effectively solve the privacy leakage risk problem faced by user identity information after it is uploaded to the blockchain network, while being able to perform appropriate operations on the encrypted data on the ledger. It can be said that homomorphic encryption technology provides good security for data and greatly protects user privacy. Therefore, homomorphic encryption technology is widely used in cloud computing security, multi-party computing and other fields. Its successful practice on cloud platforms has brought the protection of private data to a new level.
[0009] At present, although fully homomorphic encryption technology supports both addition and multiplication homomorphism, its computational complexity and low efficiency also make it not very practical. In contrast, semi-homomorphic encryption technology has a wider range of application scenarios due to its high algorithm performance. Summary of the invention
[0010] The purpose of the present invention is to creatively propose a homomorphic encryption privacy protection method for distributed digital identity in response to the technical defects of the existing distributed digital identity system such as low security and low efficiency.
[0011] The innovation of this invention is that it adopts Paillier, a semi-homomorphic encryption algorithm that can satisfy additive homomorphism, and applies it to distributed digital identities to achieve homomorphic encryption privacy protection for distributed digital identities. It is built on the Hyperledger and aims to protect the privacy of identity information on the blockchain through Paillier homomorphic encryption technology.
[0012] In order to achieve the above object, the present invention adopts the following technical scheme.
[0013] First, the concept of the present invention is explained.
[0014] 1. Holder. It refers to the owner of a digital identity. By registering a decentralized identity (DID) with the identity chain, the holder becomes a member of the distributed digital identity system. The holder can apply for relevant verifiable credentials from the institution that issued the credential, and the credential will be bound to the holder's DID.
[0015] 2. Issuer. The issuer has certain user data. When the holder needs a certificate for the corresponding data, the issuer provides the holder with the information required to verify the certificate through the corresponding service. For different businesses, the same issuer can provide multiple services. For the information of the holder in different fields, different verifiable certificates can be issued to the same DID by multiple issuers.
[0016] 3. Verifier. The verifier receives the data and verifiable credentials provided by the holder, and applies to the identity chain for credential verification, thereby confirming the holder's identity information. During this period, the verifier can only apply to the identity chain for verification of the identity attribute credentials provided by the holder to the verifier, and cannot attempt to illegally obtain other information of the holder;
[0017] 4. Blockchain network node refers to the node that processes related matters in the network of the distributed digital identity system, including credential upload, credential download, credential verification, etc.
[0018] 5. Smart contract. A computer protocol designed to disseminate, verify or execute contracts in an information-based manner. Smart contracts accept user requests and provide corresponding services through different algorithms in the contract according to different parameters.
[0019] A homomorphic encryption privacy protection method for distributed digital identity, comprising the following steps:
[0020] Step 1: Identity hiding.
[0021] The holder submits a credential application to the issuer; the issuer accepts the request and obtains the holder's identity attributes based on the user information, and generates a verifiable credential with the corresponding identity attributes.
[0022] Specifically, step 1 includes the following steps:
[0023] Step 1.1: The identity chain generates a key pair through Paillier homomorphic encryption. The public key in the key pair will be made public for homomorphic encryption. The private key in the key pair is stored by the identity chain itself and used during verification.
[0024] Step 1.2: The holder applies for the issuance of a verifiable credential. After the issuer confirms that the holder's identity information is accurate, the issuer uses the public key to encrypt and sign the user's digital identity attributes.
[0025] In steps 1.1 to 1.2, the specific implementation method of calculating the value based on Paillier homomorphic encryption technology is as follows:
[0026] Suppose the public key of the identity chain is pk0, the private key of the issuer is sk1, E(x,y) is the encryption algorithm, Sign(x,y) is the signature algorithm, x represents the plaintext information, and y represents the encryption key / signer private key.
[0027] The verifier first encrypts the user identity attribute m with the identity chain public key pk0 to obtain a verifiable certificate F, F = E (m, pk0). After that, the summary of the encrypted data is obtained through the hash function, and then the summary is signed to obtain Sign (h (E (m, pk0)), pk1), and finally submitted to the identity chain with the verifiable certificate F, where h represents the hash function and pk1 represents the identity chain public key.
[0028] Step 1.3: The issuer uploads the identity information certificate to the blockchain ledger.
[0029] Step 2: Encrypt credential transmission.
[0030] The holder downloads the identity attribute certificate from the identity chain and sends it to the verifier together with the signed partial identity information.
[0031] Specifically, step 2 includes the following steps:
[0032] Step 2.1: The holder downloads the identity attribute certificate signed by the issuer from the identity chain and encrypts it through Paillier homomorphic encryption, which includes the identity attributes that the verifier needs to know and other private information of the holder.
[0033] Step 2.2: The holder first signs part of his or her identity information with his or her private key, and then encrypts it with the public key of the verifier. This part of the encrypted information needs to be provided to the verifier in plain text.
[0034] Step 3: Identity attribute verification.
[0035] The verifier encrypts part of the user's identity attributes and initiates a verification request to the identity chain. The smart contract receives the request and calls the verifiable credentials in the ledger for verification.
[0036] Specifically, step 3 includes the following steps:
[0037] Step 3.1 The verifier encrypts part of the user's identity attributes using the public key of the identity chain and initiates a verification request to the identity chain.
[0038] Step 3.2: The smart contract receives the request and calls the ledger to which the holder's DID belongs and the related encrypted identity attributes stored in it to verify the credentials.
[0039] Step 3.3: The smart contract uses additive homomorphism to verify by comparing the verifier’s data with the ledger data, and returns the result to the verifier.
[0040] The implementation method based on additive homomorphism verification is as follows:
[0041] The input ciphertext includes: the identity attribute c1 encrypted by the verifier, the random number r1 encrypted by the issuer, the random number r2 encrypted by the verifier, and the user's digital identity did.
[0042] The output is: True if the verification is successful, or False if the verification fails.
[0043] The verifier encrypts the identity attribute sent by the user as c1, and initiates a verification request to the identity chain on the same channel, so that the accounting node with the chain code calls the smart contract to verify the data.
[0044] During verification, first, the random number used by the issuer for encryption is added to the random number used by the verifier for encryption to obtain the random number used for verification. That is, r3 = r1 + r2.
[0045] Afterwards, the credentials of the user's related identity attribute information are obtained from the blockchain account book, that is, c2 = getPing (did).
[0046] Then, the result of adding the attributes is obtained. That is, c3 = En(De(2*c2, sk1), pk1, r3). En() represents the encryption algorithm, which requires the input of plain text and key.
[0047] Finally, the received identity attributes are verified for additive homomorphism, and the results after the operation are compared to determine whether the data of both parties are consistent. Since the random number r3=r1+r2, if the plaintext data on both sides of the equation are exactly the same, the encrypted data should also be exactly the same. If the two results are equal, that is, c1c2=c3, the verification is successful, otherwise it returns verification failure. After processing the request, regardless of whether the verification is successful or not, the identity chain will return the result to the verifier.
[0048] Beneficial Effects
[0049] Compared with the prior art, the present invention has the following advantages:
[0050] 1. The present invention uses Paillier semi-homomorphic encryption technology to encrypt digital identity attributes. Since the Paillier algorithm is a probabilistic encryption scheme, the existence of the random number r makes the encryption result of the same ciphertext different each time. After the attacker obtains the ciphertext in data transmission or blockchain ledger, it is impossible to determine whether the two ciphertexts are the same by comparison, which effectively protects the identity data of the holder.
[0051] 2. In addition to hiding the identity attributes of the holder, the present invention uses the homomorphic encryption properties of the blockchain smart contract to keep the identity attributes that can be accessed and verified within an authorized and controllable range when the verifier verifies the data.
[0052] 3. On the basis of ensuring the security of the holder's privacy data, the present invention overcomes to the greatest extent the technical problems of low security and easy leakage in the existing distributed digital identity system in hiding digital identity information. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Figure 1 It is a schematic diagram of the process of the present invention. DETAILED DESCRIPTION
[0054] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the accompanying drawings. The described embodiments are only part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0055] like Figure 1 As shown in the figure, a homomorphic encryption privacy protection method for distributed digital identity is presented.
[0056] This embodiment elaborates on privacy protection in the identity management scenario enabled by blockchain. For example, in the student job search scenario, students, schools, and enterprises have service requirements such as academic qualifications, certificate chaining, and credential verification. In response to student academic qualification certificate requests, schools in the blockchain network will generate verifiable academic qualifications certificates based on their databases and credential templates, and enterprises will verify academic qualifications information by requesting credential verification from the identity chain. Its service capabilities are reflected by the time and economic cost of executing services.
[0057] This embodiment describes the use of the method of the present invention to allocate services in the above-mentioned distributed digital identity system, including the following process:
[0058] Step 1: The student submits a credential application to the school. The school accepts the request, obtains the student's identity attributes based on the student information in the database, and generates a verifiable credential with the corresponding identity attributes.
[0059] Homomorphic encryption technology based on a probabilistic encryption system can generate different ciphertexts for the same information and protect similar data that may be involved. In addition, when an enterprise applies for verification services, the enterprise's verifiable attributes can be kept within a controllable range, effectively preventing the leakage of other identity information of students.
[0060] Step 1 includes the following steps:
[0061] Step 1.1: The identity chain generates a key pair through Paillier homomorphic encryption. The public key will be made public for homomorphic encryption, while the private key will be stored by the identity chain itself and used during verification.
[0062] Step 1.2: The student applies for a verifiable credential through the blockchain. After the school confirms that the student’s identity information is accurate, the school uses the public key to encrypt and sign the user’s digital identity attributes.
[0063] Among them, the value is calculated based on Paillier homomorphic encryption technology to protect the privacy of student data.
[0064] Suppose the public key of the identity chain is pk0, the private key of the school is sk1, E(x,y) is the encryption algorithm, Sign(x,y) is the signature algorithm, x represents the plaintext information, and y represents the encryption key / signer private key.
[0065] The school first encrypts the student identity attribute m through the identity chain public key pk0 to obtain a verifiable certificate F, F = E (m, pk0). After that, the encrypted data summary is obtained through the hash function, and then the summary is signed to obtain Sign (h (E (m, pk0)), pk1), and finally submitted to the identity chain with the verifiable certificate F, where h represents the hash function.
[0066] Step 1.3: The school uploads the identity information credentials to the blockchain ledger.
[0067] Step 2: The student downloads the identity attribute certificate from the identity chain and sends it to the enterprise together with the signed partial identity information.
[0068] Step 2 includes the following steps:
[0069] Step 2.1: The student downloads the identity attribute certificate signed by the issuer from the identity chain and encrypts it through Paillier homomorphic encryption, which includes the identity attributes that the enterprise needs to know and other private information of the student;
[0070] Step 2.2: The student signs the holder's identity attributes and encrypts them with the enterprise's public key. This encrypted information needs to be provided to the enterprise in plain text.
[0071] Step 3: The verifier encrypts part of the user's identity attributes and initiates a verification request to the identity chain. The smart contract receives the request and calls the verifiable credentials in the ledger for verification.
[0072] Step 3 includes the following steps:
[0073] Step 3.1: The verifier encrypts part of the user's identity attributes using the public key of the identity chain and initiates a verification request to the identity chain;
[0074] Step 3.2: The smart contract receives the request and calls the ledger to which the holder’s DID belongs and the related encrypted identity attributes stored in the ledger to verify the credentials;
[0075] Step 3.3: The smart contract uses additive homomorphism to verify by comparing the verifier’s data with the ledger data, and returns the result to the verifier.
[0076] The characters involved in this embodiment are shown in Table 1:
[0077] Table 1 Description of characters involved in the method in this embodiment
[0078]
[0079] The method based on addition homomorphism verification in step 3 is as follows:
[0080] The input ciphertext includes: the identity attribute c1 encrypted by the enterprise, the random number r1 encrypted by the school, the random number r2 encrypted by the enterprise, and the digital identity did of the student.
[0081] The output is: True if the verification is successful, or False if the verification fails.
[0082] The enterprise encrypts the identity attribute sent by the student as c1, initiates a verification request to the identity chain on the same channel, and enables the accounting node with the chain code to call the smart contract to verify the data.
[0083] During verification, first, the random number used for school encryption is added to the random number used for enterprise encryption to obtain the random number used for verification, that is, r3 = r1 + r2.
[0084] Afterwards, the certificate of the student's relevant identity attribute information is obtained from the blockchain account book, that is, c2 = getPing (did).
[0085] Then, the result obtained by adding the attributes is obtained, that is, c3=En(De(2*c2, sk1), pk1, r3).
[0086] Finally, the received identity attributes are verified for additive homomorphism, and the results after the operation are compared to determine whether the data of both parties are consistent. Since the random number r3=r1+r2, if the plaintext data on both sides of the equation are exactly the same, the encrypted data should also be exactly the same. If the two results are equal, that is, c1c2=c3, the verification is successful, otherwise the verification is failed. After the request is processed, the identity chain will return the result to the enterprise regardless of whether the verification is successful.
[0087] The above is only a preferred embodiment of the present invention, and the present invention should not be limited to the contents disclosed in the embodiment and the drawings. Any equivalent or modification completed without departing from the spirit disclosed in the present invention shall fall within the scope of protection of the present invention.
Claims
1. A homomorphic encryption privacy protection method for distributed digital identity, characterized in that: The following steps are involved: Step 1: Identity information hiding; The holder submits a certificate application to the issuer; the issuer accepts the request, obtains the holder's identity attributes based on the user information, and generates a verifiable certificate with the corresponding identity attributes; including the following steps: Step 1.1: The identity chain generates a key pair through Paillier homomorphic encryption. The public key in the key pair will be made public for homomorphic encryption; the private key in the key pair is stored by the identity chain itself and used during verification; Among them, Paillier homomorphic encryption generates a key pair using the following method: Assume that the public key of the identity chain is pk0, the private key of the issuer is sk1, E(x,y) is the encryption algorithm, Sign(x,y) is the signature algorithm, x represents the plaintext information, and y represents the encryption key / signer private key; The verifier first encrypts the user identity attribute m through the identity chain public key pk0 to obtain a verifiable credential F, F = E(m, pk0); After that, the summary of the encrypted data is obtained through the hash function, and then the summary is signed to obtain Sign(h(E(m,pk0)),pk1), and finally submitted to the identity chain with the verifiable certificate F, where h represents the hash function and pk1 represents the identity chain public key; Step 1.2: The holder applies for the issuance of a verifiable credential; after the issuer confirms that the holder's identity information is accurate, the issuer uses the public key to encrypt and sign the user's digital identity attributes; Step 1.3: The issuer uploads the identity information certificate to the blockchain ledger; Step 2: Encrypted credential transmission; The holder downloads the identity attribute certificate from the identity chain and sends it together with the signed part of the identity information to the verifier, including the following steps: Step 2.1: The holder downloads the identity attribute certificate signed by the issuer from the identity chain and encrypts it through Paillier homomorphic encryption, which includes the identity attributes that the verifier needs to know and other private information of the holder; Step 2.2: The holder first uses his private key to sign part of his identity information, and then encrypts it using the public key of the verifier. This part of the encrypted information needs to be provided to the verifier in plain text. Step 3: Identity attribute verification; The verifier encrypts part of the user's identity attributes and initiates a verification request to the identity chain. Upon receiving the request, the smart contract calls the verifiable credentials in the ledger for verification, including the following steps: Step 3.1 The verifier encrypts part of the user's identity attributes using the public key of the identity chain and initiates a verification request to the identity chain; Step 3.2: The smart contract receives the request and calls the ledger to which the holder’s DID belongs and the related encrypted identity attributes stored in it to verify the credentials; Step 3.3: The smart contract uses additive homomorphism to verify by comparing the verifier’s data with the ledger data, and returns the result to the verifier; The input ciphertext includes: the identity attribute c1 encrypted by the verifier, the random number r1 encrypted by the issuer, the random number r2 encrypted by the verifier, and the user's digital identity did; The output is: True if the verification is successful, or False if the verification fails; The verifier encrypts the identity attribute sent by the user as c1, and initiates a verification request to the identity chain in the same channel, so that the accounting node with the chain code calls the smart contract to verify the data; During verification, first, the random number used by the issuer for encryption is added to the random number used by the verifier for encryption to obtain the random number used for verification; that is, r3 = r1 + r2; Afterwards, the credentials of the user's relevant identity attribute information are obtained from the blockchain account book; that is, c2 = getPing (did); Then, the result of adding the attributes is obtained; that is, c3 = En(De(2*c2, sk1), pk1, r3); En() represents the encryption algorithm, which requires the input of plain text and key; Finally, the received identity attributes are verified for additive homomorphism, and the results after the operation are compared to determine whether the data of both parties are consistent. Since the random number r3=r1+r2, if the plaintext data on both sides of the equation are exactly the same, the encrypted data should also be exactly the same. If the two results are equal, that is, c1c2=c3, the verification is successful, otherwise it is returned as a verification failure. After the request is processed, regardless of whether the verification is successful or not, the identity chain will return the result to the verifier.
