Government affair data sharing and information retrieval encryption chain method based on proxy re-encryption

By adopting proxy re-encryption and blockchain technology solutions in government data sharing, the problem of insufficient efficiency and security in government data sharing is solved, and efficient and secure data sharing and operation traceability are achieved.

CN120110668APending Publication Date: 2025-06-06JIANGSU UNIV
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202510277127.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-10
Publication Date
2025-06-06

AI Technical Summary

Technical Problem

The prior art has problems of insufficient efficiency and security in government data sharing, especially in social security and medical insurance data involving sensitive privacy information, which is difficult to ensure the safe and efficient sharing of data.

Method used

The government data sharing and information retrieval encryption chain system scheme is adopted based on proxy re-encryption. Public-private key pairs are generated through proxy servers, producers encrypt data and upload them to proxy servers, requestors interact with producers, proxy servers query keywords and perform proxy re-encryption, operation metadata is chained, and their untamperability and transparency are ensured through consensus mechanisms.

Benefits of technology

It greatly improves the security and trust of data sharing, ensures data privacy protection and operation traceability, and makes the data sharing process more efficient and reliable.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120110668A_ABST
    Figure CN120110668A_ABST
Patent Text Reader

Abstract

The invention provides a government affair data sharing and information retrieval encryption chain method based on proxy re-encryption. The method is suitable for an NTRU lattice public key cryptosystem. In the system, a proxy server generates corresponding public and private key pairs for producers, requesters and themselves, and links operation metadata to ensure the traceability of the operation. A producer encrypts data by using a public key of the producer, and a generated keyword index table is uploaded to a proxy server. The requester interacts with the producer, generates a trapdoor by using the keyword and a private key of the requester, and submits the trapdoor to the proxy server; and the proxy server matches the keyword through a query function, and performs proxy re-encryption processing on the ciphertext. And after re-encryption is completed, the proxy server uploads the ciphertext and the operation record to the private chain, and the credibility and non-tampering property of the information are ensured by using a consensus mechanism of the block chain. And the proxy server transmits the re-encrypted ciphertext to the requester, and the requester decrypts the ciphertext by using a private key of the requester so as to obtain the required data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of NTRU lattice public key cryptography system, and specifically relates to a government data sharing and information retrieval encryption chain system solution based on proxy re-encryption. Background Art

[0002] With the rapid development of e-government, the need for cross-departmental information sharing has become more urgent. At present, data docking between departments or data exchange through the e-government extranet is a common method, but information security issues become more complicated due to the involvement of multiple departments and systems. For example, in some areas, the medical insurance and social security systems operate independently, and there is an urgent need for a mechanism that can ensure data security and efficient sharing to achieve data flow between different systems. Existing solutions still have deficiencies in the efficiency and security of data sharing, especially the sensitive privacy information involved in social security and medical insurance data (such as user name, ID number, home address and health status), which makes security particularly important. Therefore, developing a data sharing mechanism that is both efficient and secure has important practical significance and innovative value.

[0003] Public key cryptography is a cryptographic technology that uses different keys for encryption and decryption. The public key is used for encryption, and the private key is responsible for decryption. The NTRU public key cryptography system has the advantages of convenient key generation and fast encryption and decryption speed because it relies on simple modular operations and inverse operations. It effectively solves the bottleneck of traditional public key cryptography in encryption and decryption efficiency, and provides technical support for secure and efficient data sharing between government systems. In addition, combined with blockchain technology, operation metadata (such as operation time, operator information, encrypted file name, and requesting party unit) are recorded on the chain to ensure its transparency and non-tamperability. This technology further improves the security of the data sharing process, ensures the traceability of operations and the non-tamperability of data, and provides a more secure and reliable technical solution for government data sharing. Summary of the invention

[0004] The algorithm for proxy re-encryption and metadata upload to the chain not only involves producers, requesters, and proxy servers, but also relies on blockchain technology to ensure the security and traceability of data. As the only party with complete data, the producer uploads the encrypted ciphertext and keywords to the proxy server. Before accessing the data, the requester must first communicate with the producer to obtain the keywords. After receiving the keywords provided by the requester, the proxy server searches and performs proxy re-encryption after matching the target data. The re-encrypted ciphertext is then sent to the requester, and the proxy server will upload the metadata of each operation (including operation time, data file information, etc.) to the chain and generate blocks through the consensus mechanism. The immutability and transparency of the blockchain ensure the traceability of all operations, so that each step of the data processing process is traceable, thereby greatly improving the security and trust of the entire system. The requester finally uses his own private key to decrypt the re-encrypted ciphertext and complete the data acquisition.

[0005] In order to achieve the above object, the technical solution of the present invention is: a government data sharing and information retrieval encryption chain method based on proxy re-encryption, comprising the following steps:

[0006] (1) The proxy server generates public and private key pairs for the producer, requester, and proxy server itself;

[0007] (2) The producer uses its public key to encrypt the data and extract the keywords from the data file; the producer encrypts the keywords using its own private key and the server public key, generates an index table, and uploads it to the proxy server together with the encrypted data;

[0008] (3) The requester communicates with the producer to determine the content of the query; the producer provides the keyword to the requester; the requester generates a trapdoor based on the keyword and its own private key, and submits it to the proxy server, which performs a keyword search through the query function;

[0009] (4) After querying the corresponding data, the proxy server performs the proxy re-encryption operation and sends the re-encrypted ciphertext to the requester; at the same time, the proxy server uploads metadata including operation time, operator, encrypted file name, request unit and other information to the private chain, and ensures the credibility and immutability of this information through a consensus mechanism;

[0010] (5) The requester uses its own private key to decrypt the received re-encrypted ciphertext.

[0011] Furthermore, the following process is also included before step (1):

[0012] In the initial stage, the Build function is used to generate {x, y, params, δ sk},Build(m,n)→{x,y,params,δ sk}: By receiving security parameters m, n, select the finite field F x , where x is a large prime number; define the set of all points on the plaintext space M as (F x ) 2 , and y is a small prime number; parameter Where V A ,V B ,V C is a cyclic group of prime order t, is the third type of bilinear pairing, and the generators are V A u and V B v; in addition v:V C ×{0,1} * →V A , J 1 :{0,1} * →V A , J 2 : {0,1} * →V B , J 1 , J 2 is a cryptographic hash function, {0,1} * For all possible binary strings, a master key δ is selected by a random algorithm sk =θ∈Z t , Z t represents the congruence class of the integer set modulo t, θ is represented by Z t an element of , and calculate δ pk =u θ ∈V A ; That is, the θ-th power of the cyclic group element u. Finally, the output parameters are {x, y, params, δ sk}.

[0013] Further, the specific steps of step (1) are as follows:

[0014] Step 1.1: Encryption key generation algorithm KeyGenerate(x,y): From the finite field F x Randomly and uniformly select random numbers B∈F x , the decimal u∈F x , u must meet the following two conditions: x ·u≡1(mod x),u≡1(mod y),u x and u need to satisfy the multiplicative inverse element, and u modulo y is 1. If u does not meet the conditions, it is necessary to reselect; from F x Randomly select a number e′ and calculate the public key pk as v=ux B+e′(mod x), the private key sk is u; a pair of keys (pk p ,sk p )=(v p ,u p ), generate a pair of keys (pk q ,sk q )=(v q ,u q ), and finally generate a pair of keys (pk pro ,sk pro );

[0015] Step 1.2: The proxy server securely shares the public-private key pair (pk, sk) with the user through a secure communication channel.

[0016] Further, the specific steps of step (2) are as follows:

[0017] Step 2.1: Encryption algorithm Encrypt(v p ,δ): Input the public key v of producer p p and plaintext δ, from F x Select a random number R u , e p ∈F x , e p Belongs to the set domain F x An element of , calculate the ciphertext E p = x(R u v p +e p )+δ(mod x);

[0018] Step 2.2: Encryption keyword algorithm function Enckeys(params,w,Pk pro ,Sk Keyp ) where each parameter is a preset symbol, Pk pro is the producer public key, Sk Keyp is the producer keyword secret key, selected by random algorithm s∈Z t , is a random element in the large prime field F, performs calculations and returns the ciphertext E w,p,q =(E1,E2,E3), where E2=u s ,E3=v s ,and u s With v s are the encrypted ciphertexts of the corresponding public and private key plaintexts respectively, and w is the keyword;

[0019] Step 2.3: Producer p will encrypt the ciphertext E p The encrypted keyword index table is uploaded to the proxy server through a secure communication channel.

[0020] Further, the specific steps of step (3) are as follows:

[0021] Step 3.1: Requester q uses the trapdoor function TD(params,w,Pk pro ,Sk IDj ,Key p ,Key q ), TD is a trapdoor function that accepts a series of parameters and generates a trapdoor output: s∈Z is selected by a random algorithm t , calculate and return a trapdoor TD w,p,q =(TD 1 , TD 2 ), where TD 1 =J(k,w)·u s , which is a value with a random number s, obtained by the function J(k,w) and the encryption public key u s The result of multiplication. TD 2 =v s ,This is another part of the output, which is the encrypted private key, related to the bilinear pairing, Sk IDj Key is the requester keyword key, p ,Key q Key for the producer and requester;

[0022] Step 3.2: Requester j sends the trapdoor function TD(params,w,Pk pro ,Sk IDj ,Key p ,Key q )Upload to the proxy server;

[0023] Step 3.3: The proxy server uses the query function Query(Key p ,Key q ,E w,p,q ,TD w,p,q ,params,Sk pro ), and verify whether the corresponding relationship is satisfied through the query function, where Key p ,Key q are the keywords of producers and requesters, E w,p,q is the ciphertext, TD w,p,q Trapdoor for calculation: Analyze E w,p,q For (E1 , E 2 , E 3 ) and Trapdoor TD w,p,q for (TD 1 , TD 2 );if It verifies whether the bilinear pairing results corresponding to the ciphertext and the gate value are equal. If they are equal, the result 1 is returned and the proxy server performs the proxy re-encryption operation.

[0024] Further, the specific steps of step (4) are as follows:

[0025] Step 4.1: Re-encryption key generation algorithm ReKeyGenerate(u p ,u q , x): According to the private key u of producer p and requester q p and u q , first the producer from F x Select random numbers f and e from the equation, and calculate f′=f·(u p +ye)(mod x) is sent to the requester q, and f is sent to the proxy server. After the requester q receives f′, it calculates is ′u for f q x power modulo x and send it to the proxy server. After receiving f″, the proxy calculates the re-encryption key rk p→q for: Further simplified to: rk p→q =u p u q x+yeu q x (mod x), which is the key that enables the proxy to convert encrypted data from producer p into a format that can be decrypted by requester q;

[0026] Step 4.2: Re-encryption algorithm ReEncrypt (E p , rk p→q ): The proxy server runs the re-encryption key generation algorithm and inputs the ciphertext E of producer p p and the re-encryption key rk p→q , calculate E q =E p rk p→q , the ciphertext E of producer p p Converted to the requester's ciphertext E q , and E q Send to requester q;

[0027] Step 4.3: The proxy server combines the operation time t, operator o, encrypted file name f and request unit r into metadata M = (t, o, f, r), each representing specific content. The proxy server uses the public key pk pro Encrypt metadataC pro =E pro (M), which is an encryption function, E pro (M) indicates the use of the producer p's public key pk pro Encrypt the metadata M, which includes the operation time t, operator o, encrypted file name f and request unit r; generate the encrypted metadata C pro As transaction T, it is transmitted to the private chain, generating the transaction data structure T pro =(C pro , σ s ), (C pro , σ s ) represents the T data structure of the generated transaction, T pro Includes the previously calculated encrypted data C pro And the signature function is used to ensure the integrity of the data, where σ s =Sign(pk pro ,C pro );

[0028] Sign is a signature function used to generate a digital signature; the producer p and the requester q use proof of work as a consensus mechanism to calculate the transaction hash value P p , P q :H(T, nonce)≤D, D is the difficulty coefficient, H is the hash function, T is the timestamp, and nonce is a random number to ensure that the hash value calculated each time is different. After consensus is achieved, block B=(T, nonce, h pre ),h pre It is the previous hash value, ensuring the connectivity and security of the blockchain.

[0029] Further, in step (5), through the decryption algorithm Dec: the requester q receives the encrypted ciphertext E transmitted by the proxy server q Then, use the private key u q , calculate m′=E q u q (mod x), simplify it and then modulo y to get the plain text. m = m'(mod y), where m is the plain text.

[0030] The beneficial effects of the solution proposed by the present invention include:

[0031] (1) The present invention protects the security of data. The producer is the only one who can access the original data. The proxy server stores encrypted data and uploads the operation metadata to the chain. By utilizing the immutability and transparency of blockchain, data privacy protection and operation traceability capabilities are greatly enhanced.

[0032] (2) The present invention uses blockchain technology to ensure the transparency and immutability of operation records, and improves the security of data sharing through decentralization and consensus mechanisms.

[0033] (2) The present invention allows the requester to generate a trapdoor using only the private key and the obtained keywords. The proxy server performs ciphertext index query and re-encryption, and then sends the decrypted ciphertext to the requester. This process relies on the security and traceability of the blockchain to ensure the security and reliability of the decryption process. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] Figure 1 The overall flow chart of the method for the specific implementation of the present invention is

[0035] Figure 2 The system model diagram of the solution in the present invention

[0036] Figure 3 The data and keyword index table in the present invention DETAILED DESCRIPTION

[0037] The present invention will be described in detail below in conjunction with the various embodiments shown in the accompanying drawings. However, these embodiments do not limit the present invention, and any structural, methodological, or functional changes made by a person skilled in the art based on these embodiments are all within the scope of protection of the present invention.

[0038] like Figure 1 As shown, the proxy re-encrypted government data sharing and information retrieval encryption chain system solution includes: the proxy server generates a public-private key pair, the producer encrypts the data and uploads the data keywords to the proxy server, the requester and the producer interact, the proxy server queries the keywords, the proxy server performs proxy re-encryption on the ciphertext, uploads the operation data to the chain, generates blocks using the consensus mechanism, sends the re-encrypted ciphertext to the requester, and the requester uses his own private key to decrypt and view the data.

[0039] The present invention mainly includes the following five parts:

[0040] 1. The proxy server generates a public and private key pair

[0041] The proxy server executes the encryption key generation algorithm to generate public and private key pairs for the producer, requester, and proxy server. The specific steps are as follows:

[0042] Encryption key generation algorithm KeyGenerate(x,y): from Fx Randomly and uniformly select random numbers B∈F x , the decimal u∈F x , u must meet the following two conditions: x u≡1(mod x), u≡1(mod y), if u does not meet the conditions, you need to reselect. x Randomly select a number e′∈Rx and calculate the public key pk as v=u x B+e′(mod x), the private key sk is u. Next, a pair of keys (pk p ,sk p )=(v p ,u p ), and generate a pair of keys (pk q ,sk q )=(v q ,u q ), and finally generate a pair of keys (pk pro ,sk pro );

[0043] 2. The producer uses its own public key to encrypt the data, extracts the keywords of the data file, encrypts it with its own private key and the server public key, generates an index table and uploads it to the proxy server together with the encrypted data

[0044] The producer runs the encryption algorithm based on its own public key and plaintext data to encrypt the data; then runs the keyword encryption algorithm based on the keyword, the proxy server public key, its own private key, its own ID, and the requester ID to form an encrypted keyword index table and upload it to the proxy server. The specific steps are as follows:

[0045] Step 2.1: Encryption algorithm Encrypt(v p ,δ): Input the public key v of producer p p and plaintext δ, from F x Select a random number R u , e i ∈F x , calculate the ciphertext E p = x(R u v p +e p )+δ(mod x);

[0046] Step 2.2: Encryption keyword algorithm Enckeys(params,w,Pk pro ,Sk Keyp ,Key p ,Key q ): Select s∈Z by random algorithm t , perform the calculation and return the ciphertext Ew,p,q =(E1,E2,E3), where E2=u s ,E3=v s ,and w is a keyword;

[0047] Step 2.3: Producer p sends the encrypted ciphertext E through a secure communication channel p The encrypted keyword index table is uploaded to the proxy server.

[0048] 3. Requester and producer interaction, proxy server query keywords

[0049] If the requester wants to access a piece of data, he needs to interact with the producer through a communication channel, and the producer provides the keyword of the data to the requester. The requester generates a trapdoor through the trapdoor function based on the keyword, the public key of the proxy server, his own private key, and the keys of himself and the producer, and uploads it to the proxy server. The proxy server uses its own private key, the ID of the producer and requester, the keyword ciphertext and the trapdoor to find the matching keyword through the query function Query. The steps are as follows:

[0050] Step 3.1: Requester q uses the trapdoor function TD(params,w,Pk pro ,Sk IDj ,Key p ,Key q ): Select s∈Z by random algorithm t , calculate and return a trapdoor TD w,p,q =(TD 1 , TD 2 ), where TD 1 =J(k,w)·u s , TD 2 =v s ,

[0051] Step 3.2: Requester j sends the trapdoor function TD(params,w,Pk pro ,Sk IDj ,Key p ,Key q ) to the proxy server.

[0052] Step 3.3: Proxy server uses query function

[0053] Query(Key p ,Key q ,E w,p,q ,TD w,p,q,params,Sk pro ): Parse E w,p,q For (E 1 , E 2 , E 3 ) and Trapdoor TD w,p,q for (TD 1 , TD 2 ).if If they are equal, the result 1 is returned and the proxy server performs the proxy re-encryption operation.

[0054] 4. The proxy server re-encrypts the ciphertext, uploads the operation data to the chain, and generates blocks using the consensus mechanism

[0055] In order to enable the requester to decrypt using his own private key and maintain the credibility of the system data, the proxy server runs the re-encryption key generation algorithm and the re-encryption algorithm to re-encrypt the ciphertext, and uploads metadata including operation time, operator, encrypted file name, request unit, etc. to the private chain, and ensures the credibility and non-tamperability of the chain information through the consensus mechanism. The specific steps are as follows:

[0056] Step 4.1: Re-encryption key generation algorithm ReKeyGenerate(u p ,u q , x): According to the private key u of producer p and requester q p and u q , first the producer from F x Select random numbers f and e from the equation, and calculate f′=f·(u p +xe)(mod y) is sent to the requester q, and f is sent to the proxy server. After the requester q receives f′, it calculates And send it to the proxy server. After receiving f″, the proxy calculates the re-encryption key rk p→q for:

[0057] Step 4.2: Re-encryption algorithm ReEncrypt (E p , rk p→q ): The proxy server runs the re-encryption key generation algorithm and inputs the ciphertext E of producer p p and the re-encryption key rk p→q , calculate E q =E p rk p→q , the ciphertext E of producer p p Converted to the requester's ciphertext E q , and E q Send to requester q;

[0058] Step 4.3: The proxy server combines the operation time, operator, encrypted file name and request unit into metadata M = (t, o, f, r), each representing specific content. The proxy server uses the public key pk pro Encrypt metadataC pro =E pro (M), the generated encrypted metadata C pro As transaction T is transmitted to the private chain, T pro =(C pro , σ s ), σ s =Sign(pk pro ,C pro ) ; Producer p and requester q use proof of work as a consensus mechanism to calculate the transaction hash value P p , P q :H(T, nonce)≤D, D is the difficulty coefficient, after consensus is achieved, block B=(T, nonce, h pre ),h pre It is the previous hash value, ensuring the connectivity and security of the blockchain;

[0059] 5. The requester uses his own private key to decrypt and view the data

[0060] The requester q receives the encrypted ciphertext E from the proxy server q Then, use the private key u q , calculate m′=E q u q (mod x), we can get the plain text as m=m′(mod y).

[0061] In summary, the method of the present invention includes the following steps: (1) The proxy server generates a public-private key pair for the producer, the requester, and the proxy server itself; (2) The producer uses its public key to encrypt the data and extract the keywords of the data file. The producer encrypts the keywords using its own private key and the server public key, generates an index table, and uploads it to the proxy server together with the encrypted data; (3) The requester communicates with the producer to determine the content to be queried. The producer provides the keyword to the requester. The requester generates a trapdoor based on the keyword and its own private key, and submits it to the proxy server, which performs a keyword search through a query function; (4) After querying the corresponding data, the proxy server performs a proxy re-encryption operation and sends the re-encrypted ciphertext to the requester. At the same time, the proxy server uploads metadata including information such as operation time, operator, encrypted file name, and request unit to the private chain, and ensures the credibility and immutability of this information through a consensus mechanism; (5) The requester uses its own private key to decrypt the received re-encrypted ciphertext.

Claims

1. A government data sharing and information retrieval encryption chain method based on proxy re-encryption, characterized by: The following steps are involved: (1) The proxy server generates public and private key pairs for the producer, requester, and proxy server itself; (2) The producer uses its public key to encrypt the data and extract the keywords from the data file; the producer encrypts the keywords using its own private key and the server public key, generates an index table, and uploads it to the proxy server together with the encrypted data; (3) The requester communicates with the producer to determine the content of the query; The producer provides the keyword to the requester; the requester generates a trapdoor based on the keyword and its own private key, and submits it to the proxy server, which performs a keyword search through a query function; (4) After querying the corresponding data, the proxy server performs the proxy re-encryption operation and sends the re-encrypted ciphertext to the requester; at the same time, the proxy server uploads metadata including operation time, operator, encrypted file name, request unit and other information to the private chain, and ensures the credibility and immutability of this information through a consensus mechanism; (5) The requester uses its own private key to decrypt the received re-encrypted ciphertext.

2. According to claim 1, a method for government data sharing and information retrieval encryption chain based on proxy re-encryption is characterized in that: The following process is also included before step (1): In the initial stage, the Build function is used to generate {x, y, params, δ sk },Build(m,n)→{x,y,params,δ sk }: By receiving security parameters m, n, select the finite field F x , where x is a large prime number; define the set of all points on the plaintext space M as (F x ) 2 , and y is a small prime number; parameter params = (V A ,V B ,V C , ,t,u∈V A ,v∈V B ,v,J1,J2,δ pk ), where V A ,V B ,V C is a cyclic group of prime order t, is the third type of bilinear pairing, and the generators are V A u and V B v; in addition v:V C ×{0,1} * →V A ,J1:{0,1} * →V A , J2: {0,1} * →V B , J1, J2 are cryptographic hash functions, {0,1} * For all possible binary strings, a master key δ is selected by a random algorithm sk =θ∈Z t , Z t represents the congruence class of the integer set modulo t, θ is represented by Z t an element in , and calculate δ pk =u θ ∈V A ; That is, the θ-th power of the cyclic group element u. Finally, the output parameters are {x, y, params, δ sk }.

3. According to claim 1, a method for government data sharing and information retrieval encryption chain based on proxy re-encryption is characterized in that: The specific steps of step (1) are as follows: Step 1.1: Encryption key generation algorithm KeyGenerate(x,y): From the finite field F x Randomly and uniformly select random numbers B∈F x , the decimal u∈F x , u must meet the following two conditions: x ·u≡1(mod x),u≡1(mod y),u x and u need to satisfy the multiplicative inverse element, and u modulo y is 1. If u does not meet the conditions, it is necessary to reselect; from F x Randomly select a number e′ and calculate the public key pk as v=u x B+e′(mod x), the private key sk is u; a pair of keys (pk p ,sk p )=(v p ,u p ), generate a pair of keys (pk q ,sk q )=(v q ,u q ), and finally generate a pair of keys (pk pro ,sk pro ); Step 1.2: The proxy server securely shares the public-private key pair (pk, sk) with the user through a secure communication channel.

4. According to claim 1, a method for government data sharing and information retrieval encryption chain based on proxy re-encryption is characterized in that: The specific steps of step (2) are as follows: Step 2.1: Encryption algorithm Encrypt(v p ,δ): Input producer p’s public key v p and plaintext δ, from F x Select a random number R u , e p ∈F x , e p Belongs to the set domain F x An element of , calculate the ciphertext E p = x(R u v p +e p )+δ(mod x); Step 2.2: Encryption keyword algorithm function Enckeys(params,w,Pk pro ,Sk Keyp ) where each parameter is a preset symbol, Pk pro is the producer public key, Sk Keyp is the producer keyword secret key, selected by random algorithm s∈Z t , is a random element in the large prime field F, performs calculations and returns the ciphertext E w,p,q =(E1,E2,E3), where u s With v s are the encrypted ciphertexts of the corresponding public and private key plaintexts respectively, and w is the keyword; Step 2.3: Producer p will encrypt the ciphertext E p The encrypted keyword index table is uploaded to the proxy server through a secure communication channel.

5. According to claim 1, a method for government data sharing and information retrieval encryption chain based on proxy re-encryption is characterized in that: The specific steps of step (3) are as follows: Step 3.1: Requester q uses the trapdoor function TD(params,w,Pk pro ,Sk IDj ,Key p ,Key q ), TD is a trapdoor function that accepts a series of parameters and generates a trapdoor output: s∈Z is selected by a random algorithm t , calculate and return a trapdoor TD w,p,q =(TD1, TD2), where TD1 = J(k, w)·u s , which is a value with a random number s, obtained by the function J(k,w) and the encryption public key u s The result of multiplication; TD2 = v s ,This is another part of the output, which is the encrypted private key, related to the bilinear pairing, Sk IDj Key is the requester keyword key, p ,Key q Key for the producer and requester; Step 3.2: Requester j sends the trapdoor function TD(params,w,Pk pro ,Sk IDj ,Key p ,Key q )Upload to the proxy server; Step 3.3: The proxy server uses the query function Query(Key p ,Key q ,E w,p,q ,TD w,p,q ,params,Sk pro ), and verify whether the corresponding relationship is satisfied through the query function, where Key p ,Key q are the keywords of producers and requesters, E w,p,q is the ciphertext, TD w,p,q Trapdoor for calculation: Analyze E w,p,q For (E1, E2, E3) and trapdoor TD w,p,q is (TD1, TD2); if It verifies whether the bilinear pairing results corresponding to the ciphertext and the gate value are equal. If they are equal, the result 1 is returned and the proxy server performs the proxy re-encryption operation.

6. According to claim 1, a method for government data sharing and information retrieval encryption chain based on proxy re-encryption is characterized in that: The specific steps of step (4) are as follows: Step 4.1: Re-encryption key generation algorithm ReKeyGenerate(u p ,u q , x): According to the private key u of producer p and requester q p and u q , first the producer from F x Select random numbers f and e from the equation, and calculate f′=f·(u p +ye)(mod x) is sent to the requester q, and f is sent to the proxy server. After the requester q receives f′, it calculates is ′u for f q x power modulo x and send it to the proxy server. After receiving f″, the proxy calculates the re-encryption key rk p→q for: Further simplified to: rk p→q =u p u q x+yeu q x (mod x), which is the key that enables the proxy to convert encrypted data from producer p into a format that can be decrypted by requester q; Step 4.2: Re-encryption algorithm ReEncrypt (E p , rk p→q ): The proxy server runs the re-encryption key generation algorithm and inputs the ciphertext E of producer p p and the re-encryption key rk p→q , calculate E q =E p rk p→q , the ciphertext E of producer p p Converted to the requester's ciphertext E q , and E q Send to requester q; Step 4.3: The proxy server combines the operation time t, operator o, encrypted file name f and request unit r into metadata M = (t, o, f, r), each representing specific content. The proxy server uses the public key pk pro Encrypt metadataC pro =E pro (M), which is an encryption function, E pro (M) indicates the use of the producer p's public key pk pro Encrypt the metadata M, which includes the operation time t, operator o, encrypted file name f and request unit r; generate the encrypted metadata C pro As transaction T, it is transmitted to the private chain and the transaction data structure T is generated. pro =(C pro , σ s ), (C pro , σ s ) represents the T data structure of the generated transaction, T pro Includes the previously calculated encrypted data C pro And the signature function is used to ensure the integrity of the data, where σ s =Sign(pk pro ,C pro ); Sign is a signature function used to generate a digital signature; the producer p and the requester q use proof of work as a consensus mechanism to calculate the transaction hash value P p , p q :H(T, nonce)≤D, D is the difficulty coefficient, H is the hash function, T is the timestamp, and nonce is a random number to ensure that the hash value calculated each time is different. After consensus is achieved, block B is generated = (T, nonce, h pre ),h pre It is the previous hash value, ensuring the connectivity and security of the blockchain.

7. According to claim 1, a method for government data sharing and information retrieval encryption chain based on proxy re-encryption is characterized in that: In step (5), through the decryption algorithm Dec: the requester q receives the encrypted ciphertext E transmitted by the proxy server q Then, use the private key u q , calculate m′=E q u q (mod x), and then simplify it modulo y to get the plain text, m = m'(mod y), where m is the plain text.

Citation Information

Cited By

  • Social security and medical insurance system data security sharing method based on proxy re-searchable encryption

    CN116886324A

  • Cloud chain collaborative medical data security sharing method based on PRE

    CN121907492A