A method and system for non-equilibrium private set intersection
By combining a cuckoo filter and batch OT extended transmission on the blockchain, privacy-preserving set intersection is achieved under imbalanced dataset size conditions. This solves the problems of high communication overhead and unreliable results in existing technologies, ensuring the security and verifiability of the intersection process.
Patent Information
- Application Number
- CN202310055036.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-03
- Publication Date
- 2026-01-02
- Estimated Expiration
- 2043-02-03
AI Technical Summary
Existing privacy set intersection techniques suffer from high communication overhead and difficulty in guaranteeing the reliability and security of intersection results when the dataset size is imbalanced, especially in malicious models where there is a lack of effective verification mechanisms.
A blockchain-based unbalanced privacy set intersection method is adopted. The cuckoo filter is used for pre-intersection, and the dataset size is adjusted to balance. Then, the precise intersection result is obtained by combining batch OT extended transmission and OPRF calculation. The reliability of the intersection result is verified by using a verification dataset. The entire process is notarized through smart contracts.
In scenarios with imbalanced datasets, it reduces communication overhead, improves the reliability and security of intersection results, ensures the immutability and traceability of information, and enhances protection against malicious behavior.
Smart Images

Figure CN116108482B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of blockchain and privacy security technology, and in particular to a method and system for non-balance private set intersection. BACKGROUND
[0002] The blockchain technology is a new distributed infrastructure and computing paradigm, which uses block chain data structure to verify and store data, uses distributed consensus algorithm to generate and update data, uses cryptography to ensure the security of data transmission and access, and uses smart contract composed of automatic script code to program and operate data. It has the characteristics of decentralization, openness, autonomy, anonymity and information non-tamperability.
[0003] Private Set Intersection (PSI) is a cryptographic technology in secure multi-party computation (MPC), which allows both parties participating in the calculation to perform joint operations on the data set while protecting privacy. Without obtaining additional information (other than the intersection) from the other party, the intersection of the data of both parties is calculated. With the rise of big data, cloud computing and other technologies, enterprises and individuals pay more and more attention to the protection of private data. As a key technology in secure multi-party computation, private set intersection has received widespread attention.
[0004] There are currently three kinds of private set intersection technologies:
[0005] (1) Hash-based PSI, which uses a public hash function to compare hash results to achieve this. Although this method is efficient, it is not secure. A malicious participant can collide the hash value transmitted by the other party within a certain period of time through hash collision, thereby stealing additional information;
[0006] (2) Public key encryption-based PSI. The communication overhead of this protocol is small, but the calculation complexity of public key encryption is high, so the calculation overhead is large. The number of public key calculations in the protocol increases linearly with the increase of data volume, which will cause performance problems when the data volume is large, so it is more suitable for small-scale data sets;
[0007] (3) Oblivious Transfer (OT) based PSI, Kolesnikov in 2016 extended the transmission and cuckoo hash using batch OT to achieve a more efficient private set intersection scheme, although the scheme still uses asymmetric encryption technology, but the Oblivious Transfer uses limited times of asymmetric encryption to complete any number of secure data transmission, and the private set intersection based on OT becomes the private set intersection scheme closest to the performance of the hash intersection technology. Although the private set intersection based on OT has the best running performance for large-scale data, its communication overhead is large, and the private intersection scheme based on OT assumes that the size of the two sets is almost the same, and in the case of small set intersection large set, the communication and computing overhead also changes with the size of the large set, and it is not suitable for the intersection scene of unbalanced data set size.
[0008] It can be seen that various PSI schemes have their own obvious advantages and disadvantages, and most of the PSI protocols consider the case that the sizes of the two data sets are basically equal, but in some scenarios, the sizes of the intersection data sets of the two parties are quite different, such as black list query, contact search, etc. In addition, the above PSI schemes are mostly based on the semi-honest model, and in the malicious model, the protocol needs to use additional means to prevent the possibility of the above attacks, so the complexity and overhead of the secure protocol in the malicious model are usually much larger than that in the semi-honest model. SUMMARY
[0009] The purpose of the present application is to overcome the defects of the prior art and provide a non-balanced private set intersection method and system. For the scenario of unbalanced data set size, a scheme with communication overhead changing with the small set is designed, a verification step is added to ensure the verifiability of the intersection result, and the blockchain technology is combined to ensure the information is tamper-proof and traceable. In the case that the adversary may have malicious behavior, the security and reliability of the data are improved.
[0010] The purpose of the present application can be achieved by the following technical solutions:
[0011] A non-balanced private set intersection method, which is implemented on a blockchain, and data interaction and process and result evidence are performed through a smart contract on the blockchain, including the following steps:
[0012] Determine the sender's original data set and the receiver's original data set; the sender's original data set and the receiver's original data set are different in size;
[0013] Insert a verification data set into the receiver's original data set to obtain an intersection data set;
[0014] Pre-intersection of the sender original data set and the intersection data set based on the cuckoo filter to obtain a rough intersection;
[0015] Parameter transmission and OPRF calculation of the rough intersection based on the privacy intersection scheme of batch OT extended transmission to obtain an accurate intersection result;
[0016] Verify the obtained accurate intersection result using the verification data set to determine whether the intersection result is reliable.
[0017] Further, the verification data set is generated by the receiver, and the verification data set does not become the intersection of the sender original data set and the receiver original data set.
[0018] Further, let P1 be the receiver, the receiver original data set be X0, the size of the X0 set be n0; the verification data set be X1, the size of the X1 set be n; the intersection data set after adding the verification data set X1 be The size of the X set be n1, n1=n0+n;
[0019] Let P2 be the sender, the sender original data set be The size of the Y set be n2, and n1<<n2;
[0020] Let the fingerprint function in the cuckoo filter be fingerprint(x), and the hash function in the cuckoo filter be Hash1(x);
[0021] Let the three hash functions in the cuckoo hash be Hash2(x), Hash3(x), and Hash4(x), the length of the elements generated by the hash function be k, and the size of the stash be s;
[0022] Let the random encoding function common to the sender and the receiver be C, the encoding length of C be k, and C:{0,1} * →{0,1} k ;
[0023] Let the hash function common to the sender and the receiver be H:[m]×{0,1} k →{0,1} l , that is, randomly map a bit string of length k to a bit string of length l;
[0024] Pre-intersection of the sender original data set and the intersection data set based on the cuckoo filter to obtain a rough intersection, including the following steps:
[0025] The sender and the receiver interact to deliver a common parameter, and the common parameter includes the fingerprint function fingerprint(x) and the hash function Hash1(x) of the cuckoo filter;
[0026] The receiver generates a cuckoo filter CF for the intersection dataset X f = fingerprint(x), h1 = Hash1(x),
[0027] The receiver generates a cuckoo filter CF for the intersection dataset X and the cuckoo filter CF X Generates a hash and uploads to the blockchain for notarization;
[0028] The receiver sends the cuckoo filter CF to the sender through the smart contract on the blockchain; X
[0029] The sender looks for elements in the sender's original dataset Y in the cuckoo filter CF, obtaining a rough intersection X n3≥n1;
[0030] The sender generates a hash for the sender's original dataset Y and the rough intersection Z and uploads it to the blockchain for notarization.
[0031] Further, based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection to obtain the accurate intersection result, including the following steps:
[0032] The sender and the receiver pass public parameters through the smart contract on the blockchain, including three hash functions Hash2(x), Hash3(x), Hash4(x) of the cuckoo hash, the size s of the stash and its corresponding hash function;
[0033] The receiver maps the intersection dataset X into the cuckoo hash to obtain an element set r of m = 1.2n1 + s, r i ∈{0,1} * ;
[0034] The sender maps the rough intersection Z into each hash function of the cuckoo hash to obtain an element set r' of (3 + s)n3, r' ∈{0,1} * ;
[0035] The receiver initializes an m × k random bit matrix T to construct a matrix U,
[0036] The sender randomly initializes k bits of v;
[0037] The sender and the receiver execute The sender inputs v, and the receiver calculates each bit value v i The sender is sent each column of T and U in turn (t i , u i );When v i =0, the sender gets t i , when v i =1, the sender gets u i , and the sender combines all the columns received to form an m×k matrix, denoted as Q,
[0038] The receiver generates a hash for the matrices T and U and uploads it to the blockchain for notarization.
[0039] The sender generates a hash for v and Q and uploads it to the blockchain for notarization.
[0040] The receiver performs 1.2n1+s times of OPRF: for 1≤j≤1.2n1+s, the receiver outputs H(j,t j ), obtaining the set
[0041] The receiver generates a hash for and uploads it to the blockchain for notarization.
[0042] The sender performs (3+s)n3 times of OPRF: for 1≤j≤(3+s)n3, the sender outputs obtaining the set
[0043] The sender generates a hash for and uploads it to the blockchain for notarization.
[0044] The sender sends the set to the receiver.
[0045] The receiver finds the same elements in and , obtaining the intersection X∩Y of X and Y, which is the exact intersection result.
[0046] The receiver generates a hash for the obtained intersection X∩Y and uploads it to the blockchain for notarization.
[0047] Further, the exact intersection result obtained is verified using the verification data set to determine whether the intersection result is reliable, including the following steps:
[0048] The receiver verifies the exact intersection result X∩Y, checks whether the exact intersection result contains elements in X1, if yes, it means that the sender has dishonest behavior, and the obtained intersection result is not reliable, and the intersection is determined to fail and the result is uploaded to the blockchain for notarization; otherwise, it is considered that the result is reliable, and the intersection is determined to be successful and the result is uploaded to the blockchain for notarization.
[0049] A system for non-equilibrium private set intersection, comprising a data processing module, a pre-intersection module, an accurate solution module, a verification module and an interactive evidence module;
[0050] The data processing module is used to determine a sender original data set and a receiver original data set; the sender original data set and the receiver original data set are different in size; and a verification data set is inserted into the receiver original data set to obtain an intersection data set;
[0051] The pre-intersection module performs pre-intersection on the sender original data set and the intersection data set based on a cuckoo filter to obtain a rough intersection set;
[0052] The accurate intersection module performs parameter transmission and OPRF calculation on the rough intersection set based on a batch OT extended transmission privacy intersection scheme to obtain an accurate intersection result;
[0053] The interactive evidence module is used to perform data interaction and process and result evidence through a smart contract on a block chain;
[0054] The verification module is used to verify the obtained accurate intersection result by using the verification data set to determine whether the intersection result is reliable.
[0055] Further, the verification data set is generated by the receiver, and the verification data set cannot become an intersection of the sender original data set and the receiver original data set.
[0056] Further, let P1 be a receiver, a receiver original data set be X0, the size of the X0 set be n0; a verification data set be X1, the size of the X1 set be n; and the intersection data set after adding the verification data set X1 be The size of the X set be n1, and n1=n0+n;
[0057] Let P2 be a sender, a sender original data set be The size of the Y set be n2, and n1<<n2;
[0058] Let a fingerprint function in a cuckoo filter be fingerprint(x), and a hash function in the cuckoo filter be Hash1(x);
[0059] Let three hash functions in a cuckoo hash be Hash2(x), Hash3(x) and Hash4(x), the length of an element generated by the hash functions be k, and the size of a stash be s;
[0060] Let a random encoding function common to the sender and the receiver be C, the encoding length of C be k, and C:{0,1} * →{0,1}k ;
[0061] Let H: [m] x {0,1} k → {0,1} l be a hash function common to both the sender and the receiver, i.e., a random mapping of bit strings of length k to bit strings of length l;
[0062] The pre-intersection module pre-intersects the sender original data set and the intersection data set based on the cuckoo filter to obtain a rough intersection, including the following steps:
[0063] The sender and the receiver interact to deliver a common parameter, which includes a fingerprint function fingergprint(x) of the cuckoo filter and a hash function Hash1(x);
[0064] The receiver generates a cuckoo filter CF X for the intersection data set, f = fingergprint(x), h1 = Hash1(x),
[0065] The receiver generates a hash for the intersection data set X and the cuckoo filter CF X and uploads it to the blockchain for notarization;
[0066] The receiver sends the cuckoo filter CF X to the sender through a smart contract on the blockchain;
[0067] The sender looks up elements in the cuckoo filter CF X in the sender original data set Y to obtain a rough intersection n3 ≥ n1;
[0068] The sender generates a hash for the sender original data set Y and the rough intersection Z and uploads it to the blockchain for notarization.
[0069] Further, the accurate intersection module performs parameter transmission and OPRF calculation on the rough intersection based on a batch OT extended transmission privacy intersection scheme to obtain an accurate intersection result, including the following steps:
[0070] The sender and the receiver deliver a common parameter through a smart contract on the blockchain, which includes three hash functions Hash2(x), Hash3(x), and Hash4(x) of the cuckoo hash, the size s of the stash, and the corresponding hash function thereof;
[0071] The receiver maps the intersection data set X to the cuckoo hash to obtain an element set r of m = 1.2n1 + s, r i ∈ {0,1}* ;
[0072] The sender maps the rough intersection Z to each hash function in the cuckoo hash, obtaining a set r' of (3+s)n3 elements, r' e {0,1} * ;
[0073] The receiver initializes an m x k random bit matrix T to construct a matrix U,
[0074] The sender randomly initializes k bits of v;
[0075] The sender and the receiver execute The sender inputs v, and the receiver outputs the j-th column of T according to each bit value v i of v; the sender sends each column (t i , u i ) of T and U to the receiver in turn; when v i = 0, the sender obtains t i , and when v i = 1, the sender obtains u i ; the sender combines all the columns received to form an m x k matrix, denoted as Q,
[0076] The receiver generates a hash for the matrices T and U and uploads it to the blockchain for notarization;
[0077] The sender generates a hash for v and Q and uploads it to the blockchain for notarization;
[0078] The receiver executes 1.2n1+s times of OPRF: for 1≤j≤1.2n1+s, the receiver outputs H(j, t j ), obtaining a set
[0079] The receiver generates a hash for and uploads it to the blockchain for notarization;
[0080] The sender executes (3+s)n3 times of OPRF: for 1≤j≤(3+s)n3, the sender outputs obtaining a set
[0081] The sender generates a hash for and uploads it to the blockchain for notarization;
[0082] The sender sends the set to the receiver;
[0083] The receiver looks up and The same elements are obtained, and the intersection X intersection Y of X and Y is the accurate intersection result;
[0084] The receiving party generates a hash for the obtained intersection X intersection Y and uploads it to the blockchain for notarization.
[0085] Further, the verification module verifies the obtained accurate intersection result by using the verification data set, to determine whether the intersection result is reliable, including the following steps:
[0086] The receiving party verifies the obtained accurate intersection result X intersection Y, checks whether the accurate intersection result contains elements in X1, if yes, it indicates that the sender has dishonest behavior, and the obtained intersection result is not reliable, and the intersection is determined to fail and the result is uploaded to the blockchain for notarization; otherwise, it is considered that the result is reliable, and the intersection is determined to be successful and the result is uploaded to the blockchain for notarization.
[0087] Compared with the prior art, the present application has the following beneficial effects:
[0088] (1) Suitable for non-balance set intersection scene
[0089] Compared with the existing privacy set intersection scheme, the present application adds a pre-intersection step, in the case that the data sets of both parties are greatly different, first, the PSI based on the cuckoo filter is used to convert the PSI with unbalanced data set size into the PSI with balanced data set size, and then the PSI based on batch OT extended transmission is used for accurate intersection, compared with directly using the PSI based on batch OT extended transmission, the communication overhead is reduced, and the communication overhead is related to the small set, rather than changing with the large set.
[0090] (2) Combined with blockchain technology to ensure the safety of the intersection process
[0091] The present application combines the blockchain technology, and the process of privacy set intersection is constructed on the blockchain, and the data transmission is performed by using the smart contract, since the smart contract is automatically executed on the chain, fairness is realized, and each process is chained and notarized, so that the traceability and non-tamperability of the transaction data are ensured, and the safety of the privacy intersection process is ensured.
[0092] (3) Intersection result is verifiable
[0093] The present application designs a step of adding a verifiable set in the data set by the receiving party, so that the verifiability of the intersection result can be ensured in the case that the other party has malicious behavior. DETAILED DESCRIPTION
[0094] Figure 1 The flowchart of the method of the present application;
[0095] Figure 2 The system architecture diagram of the present application. DETAILED DESCRIPTION
[0096] The present application will be described in detail below with reference to the drawings and specific embodiments. The embodiments are implemented on the premise of the technical solutions of the present application, and detailed implementation modes and specific operation processes are given, but the protection scope of the present application is not limited to the following embodiments.
[0097] Embodiment 1
[0098] In order to solve the problems in the prior art, the present application provides a method and system for non-balanced private set intersection based on blockchain technology and cuckoo filter. The present application designs a scheme with communication overhead varying with small sets for the scenario of unbalanced data set size, adds a verification step to ensure the verifiability of the intersection result, and combines blockchain technology to ensure the non-tamperability and traceability of information, thereby improving the security and reliability of data in the case of possible malicious behavior of the opponent.
[0099] As shown in Figure 1 , 2 , the method comprises the following steps:
[0100] The sender and the receiver who have data sets with large size difference want to obtain the intersection of the data of both parties. The receiver first inserts a verifiable data set into its own original data set and inputs it as the intersection data set in the subsequent intersection process.
[0101] The sender and the receiver first perform pre-intersection through the private intersection scheme based on the cuckoo filter. Since the private intersection scheme based on the cuckoo filter has a certain error rate, part of the data in the final result may not be the real intersection data, so only the rough intersection is obtained. However, after pre-intersection through the scheme, the data sets of both parties will be matched to the same order of magnitude in size, i.e. the private intersection of unbalanced data set size is converted to the private intersection of balanced data set size.
[0102] Next, the private intersection scheme based on batch OT extended transmission is used by both parties to perform parameter transmission and OPRF (Oblivious Pseudorandom Function, OPRF) calculation to obtain the accurate private data intersection result, and the intersection result is verified to determine whether the other party has malicious behavior.
[0103] The whole process is built on the blockchain, and data interaction, process and result notarization are performed through the smart contract on the blockchain.
[0104] The verifiable data set will not intersect with the original data set of the sender, and the generation method comprises:
[0105] 1. Generate data with the same length and format as the data in the original data set of the receiver, but the data does not exist (for example, if the element in the original data set is an ID number, a string of random numbers that does not meet the format requirements of the ID number is generated as an element in the verification data set);
[0106] 2. Generate data with different length or format from the data in the original data set of the receiver;
[0107] Proper nouns and symbol explanation:
[0108] P1 is the receiver, and its original data set is denoted as X0, and the size of the set is n0; a certain data set generated by P1 that does not intersect with the data of P2 is denoted as X1, and the size of the set is n; the data set after adding the verification data set X1 is The size of the set is n1, and n1=n0+n;
[0109] P2 is the sender, and the data set is The size of the set is n2, and n1<<n2;
[0110] Cuckoo filter parameters: fingerprint(x) is a fingerprint function, and the hash function in the cuckoo filter is denoted as Hash1(x);
[0111] Cuckoo hash parameters: three hash functions are denoted as Hash2(x), Hash3(x), and Hash4(x), respectively, the length of the element generated by the hash function is k, and the size of the stash is s;
[0112] The random encoding function C common to the sender and the receiver, the encoding length of C is k, and C:{0,1} * →{0,1} k ;
[0113] The hash function H common to the sender and the receiver: [m]x{0,1} k →{0,1} l , that is, a bit string with a length of k is randomly mapped to a bit string with a length of l.
[0114] The method for non-balance private set intersection proposed by the application includes the following steps in specific implementation:
[0115] P1 generates a random data set X1 that will not become an intersection set, and merges it with the original data set X0 to obtain the intersection data set X;
[0116] P1 and P2 interact to transmit common parameters such as the fingerprint function fingerprint(x) and the hash function Hash1(x) of the cuckoo filter;
[0117] P1 generates a cuckoo filter CF for elements of its dataset X X , f = fingerprint(x), h1 = Hash1(x),
[0118] P1 generates a cuckoo filter CF for X X Generates hashes and uploads to the blockchain for notarization;
[0119] P1 sends CF to P2 through a smart contract on the blockchain; X
[0120] P2 looks up elements y in CF i in CF X , gets a rough intersection n3 ≥ n1;
[0121] P2 generates hashes for Y, Z and uploads to the blockchain for notarization;
[0122] P1 and P2 pass public parameters through a smart contract on the blockchain: three hash functions of the cuckoo hash Hash2(x), Hash3(x), Hash4(x), the size of the stash s and its corresponding hash function;
[0123] P1 maps the data set X into the cuckoo hash, gets a set of elements r, r i ∈{0,1} * ;
[0124] P2 maps the data set Z into each hash function of the cuckoo hash, gets a set of elements r', r' ∈{0,1} * ;
[0125] P1 initializes a random bit matrix T of m x k, constructs a matrix U,
[0126] P2 randomly initializes v of k bits;
[0127] P1 and P2 execute P2 inputs v, P1 sends each column (t i , u i ) of T and U to P2 in turn according to each bit value v i of v. When v i = 0, P2 gets t i , when v i = 1, P2 gets u i , combines all the columns received by P2 into a matrix of m x k, called Q,
[0128] P1 generates a hash for T and uploads it to the blockchain for notarization;
[0129] P2 generates a hash for Q and uploads it to the blockchain for notarization;
[0130] P1 performs 1.2n1+s OPRFs: for 1≤j≤1.2n1+s, P1 outputs H(j, t j ), obtaining the set
[0131] P1 generates a hash for and uploads it to the blockchain for notarization;
[0132] P2 performs (3+s)n3 OPRFs: for 1≤j≤(3+s)n3, P2 outputs obtaining the set
[0133] P2 generates a hash for and uploads it to the blockchain for notarization;
[0134] P2 sends the set to P1;
[0135] P1 finds the same elements in and , obtaining the intersection X∩Y of X and Y;
[0136] P1 generates a hash for the obtained intersection X∩Y and uploads it to the blockchain for notarization;
[0137] P1 verifies the obtained intersection X∩Y, checking whether there are elements in X1 in it. If there are, it means that the other party has dishonest behavior, the obtained intersection result is not trustworthy, and it is determined that the intersection fails and the result is uploaded to the blockchain for notarization. If not, it is considered that the result is trustworthy, and it is determined that the intersection is successful and the result is uploaded to the blockchain for notarization.
[0138] Embodiment 2
[0139] The embodiment provides a non-balanced private set intersection system for implementing the non-balanced private set intersection method as proposed in Embodiment 1, which includes a data processing module, a pre-intersection module, an accurate solution module, a verification module, and an interactive notarization module.
[0140] The data processing module is configured to determine a sender original data set and a receiver original data set, the sender original data set and the receiver original data set are different in size, and insert a verification data set into the receiver original data set to obtain an intersection data set; the verification data set is generated by the receiver, and the verification data set is not an intersection of the sender original data set and the receiver original data set.
[0141] The pre-intersection module performs a pre-intersection on the sender original data set and the intersection data set based on a cuckoo filter to obtain a rough intersection.
[0142] The precise intersection module performs parameter transmission and OPRF calculation on the rough intersection based on a batch OT extended transmission privacy intersection scheme to obtain a precise intersection result.
[0143] The interactive evidence module is configured to perform data interaction and process and result evidence through a smart contract on a block chain.
[0144] The verification module is configured to verify the precise intersection result obtained by using the verification data set to determine whether the intersection result is reliable.
[0145] In the embodiment, the verification data set in the data processing module will not intersect with the sender original data set, and the generation method includes:
[0146] 1. generating data that is the same in length and format as the data in the receiver original data set, but the data does not actually exist (for example, if the elements in the original data set are ID numbers, a string of numbers that does not meet the ID number format requirements is randomly generated as an element in the verification data set);
[0147] 2. generating data that is different in length or format from the data in the receiver original data set;
[0148] In the embodiment, P1 is the receiver, the receiver original data set is denoted as X0, the size of the X0 set is n0, the verification data set is denoted as X1, the size of the X1 set is n, and the intersection data set after adding the verification data set X1 is denoted as X. The size of the X set is n1, and n1=n0+n.
[0149] P2 is the sender, and the sender original data set is denoted as Y. The size of the Y set is n2, and n1<<n2.
[0150] The fingerprint function in the cuckoo filter is denoted as fingerprint(x), and the hash function in the cuckoo filter is denoted as Hash1(x).
[0151] Let the three hash functions of the cuckoo hash be Hash2(x), Hash3(x), and Hash4(x), and the length of the elements generated by the hash functions be k, and the size of the stash be s;
[0152] Let the random encoding function common to the sender and the receiver be C, and the encoding length of C be k, C:{0,1} * →{0,1} k ;
[0153] Let the hash function common to the sender and the receiver be H:[m]×{0,1} k →{0,1} l , that is, a bit string of length k is randomly mapped to a bit string of length l;
[0154] The pre-intersection module based on the cuckoo filter performs pre-intersection on the sender's original data set and the intersection data set to obtain a rough intersection, including the following steps:
[0155] The sender and the receiver interact to pass the common parameters, which include the fingerprint function fingerprint(x) and the hash function Hash1(x) of the cuckoo filter;
[0156] The receiver generates a cuckoo filter CF X for the intersection data set, f = fingerprint(x), h1 = Hash1(x),
[0157] The receiver generates a hash for the intersection data set X and the cuckoo filter CF X and uploads it to the blockchain for notarization;
[0158] The receiver sends the cuckoo filter CF X to the sender through the smart contract on the blockchain;
[0159] The sender searches for elements in the sender's original data set Y in the cuckoo filter CF X to obtain a rough intersection Z n3≥n1;
[0160] The sender generates a hash for the sender's original data set Y and the rough intersection Z and uploads it to the blockchain for notarization.
[0161] The precise intersection module based on the batch OT extended transmission privacy intersection scheme performs parameter transmission and OPRF calculation on the rough intersection to obtain a precise intersection result, including the following steps:
[0162] The sender and the receiver pass a public parameter including three hash functions Hash2(x), Hash3(x), Hash4(x) of the cuckoo hash, the size s of the stash and the corresponding hash function through the smart contract on the blockchain;
[0163] The receiver maps the intersection data set X to the cuckoo hash to obtain a set r of m = 1.2n1 + s elements, r i ∈{0,1} * ;
[0164] The sender maps the rough intersection Z to each hash function of the cuckoo hash to obtain a set r' of (3 + s)n3 elements, r'∈{0,1} * ;
[0165] The receiver initializes an m x k random bit matrix T to construct a matrix U,
[0166] The sender randomly initializes k bits of v;
[0167] The sender and the receiver execute The sender inputs v, and the receiver obtains each column (t i ,u i ) of T and U according to each bit value v i of v; when v i = 0, the sender obtains t i , and when v i = 1, the sender obtains u i , and the sender combines all the columns received to form an m x k matrix, denoted as Q,
[0168] The receiver generates a hash for the matrices T and U and uploads it to the blockchain for notarization;
[0169] The sender generates a hash for v and Q and uploads it to the blockchain for notarization;
[0170] The receiver executes 1.2n1 + s times of OPRF: for 1≤j≤1.2n1 + s, the receiver outputs H(j, t j ) to obtain a set
[0171] The receiver generates a hash for and uploads it to the blockchain for notarization;
[0172] The sender executes (3 + s)n3 times of OPRF: for 1≤j≤(3 + s)n3, the sender outputs to obtain a set
[0173] The sender is generates a hash and uploads it to the blockchain for storage;
[0174] The sender sends the set to the receiver;
[0175] The receiver finds and the same elements, and the intersection X∩Y of X and Y is the exact intersection result;
[0176] The receiver generates a hash for the intersection X∩Y and uploads it to the blockchain for storage.
[0177] The verification module verifies the exact intersection result obtained using the verification data set to determine whether the intersection result is reliable, including the following steps:
[0178] The receiver verifies the exact intersection result X∩Y to determine whether it contains elements in X1. If it does, it indicates that the sender has dishonest behavior, and the intersection result obtained is not reliable, and the intersection is deemed to have failed and the result is uploaded to the blockchain for storage. Otherwise, the result is deemed to be reliable, and the intersection is deemed to be successful and the result is uploaded to the blockchain for storage.
[0179] The above detailed the preferred embodiments of the present application. It should be understood that those skilled in the art can make many modifications and changes without creative labor based on the concept of the present application. Therefore, any technical solution obtained by logical analysis, reasoning or limited experiment based on the existing technology within the scope of the present application should be within the scope of protection determined by the claims.
Claims
1. A method for non-equilibrium private set intersection, characterized in that, The method is performed on a blockchain, data interaction and process and result storage are performed through a smart contract on the blockchain, and the method includes the following steps: Determine a sender original data set and a receiver original data set; the sender original data set and the receiver original data set are different in size; Insert a verification data set into the receiver original data set to obtain an intersection data set; Based on the cuckoo filter, the sender original data set and the intersection data set are pre-intersected to obtain a rough intersection set; Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result; The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set. Recall For the receiver, the original data set is denoted as , The size of the set is ; the verification data set is denoted as , The size of the set is ; the intersection data set after adding the verification data set is denoted as , The size of the set is , ; Recall For the sender, the sender's original data set is , The set size is , set ; The fingerprint function in the cuckoo filter is denoted as , and the hash function in the cuckoo filter is denoted as ; The three hash functions for cuckoo hashing are denoted as The length of the elements produced by the hash functions is The size of the stash is ; The random encoding function common to the sender and the receiver is denoted as , The encoding length of the random encoding function is , ; Let H be a hash function common to the sender and the receiver i.e., a random mapping of bit strings of length to bit strings of length Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result, including the following steps: The sender and the receiver interact to transfer a common parameter, which includes a fingerprint function of the cuckoo filter and a hash function ; The receiver generates a cuckoo filter for the intersection dataset , ; Recipient for intersection dataset And a cuckoo filter Generate hash and upload to blockchain for notarization; The receiver sends the cuckoo filter to the sender via a smart contract on the blockchain to the sender; The sender looks up the sender's original data set in the cuckoo filter ; The sender is the sender original data set And rough intersection Generate a hash and upload to the blockchain for notarization.
2. The method for non-equilibrium private set intersection of claim 1, wherein, The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set.
3. The method for non-equilibrium private set intersection of claim 1, wherein, Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result, including the following steps: The sender and the recipient communicate a public parameter over a smart contract on the blockchain, the public parameter including three hash functions of a cuckoo hash , a size s of a stash and its corresponding hash function; The receiver will intersect the data sets mapped into a cuckoo hash, resulting in a set of elements , ; The sender will coarse intersection Mapping to each hash function in the cuckoo hash, get A set of elements , ; The receiver initializes a random bit matrix of size ; constructs a matrix , ; Sender random initialization One bit of ; The sender and receiver execute through a smart contract on the blockchain. Sender input The recipient, according to Each bit value Send to the sender in sequence and Each column ( );when At that time, the sender received ,when When =1, the sender receives Combine all columns received by the sender into one The matrix is denoted as , ; Receiver is a matrix Generate a hash and upload to the blockchain for notarization; The sender is A hash is generated and uploaded to the blockchain for notarization; Receiver performs Sub-OPRF: For , receiver outputs , resulting in set ; The receiver is Generate a hash and upload to the blockchain for notarization; Sender performs Sub-OPRF: for , the sender outputs , obtaining the set ; The sender is Generate a hash and upload it to the blockchain for notarization; Sender sends set To receiver; Receiver lookup And The same elements in And The intersection of Is the exact intersection result; The receiver gets the intersection Generate a hash and upload to the blockchain for notarization.
4. The method for non-equilibrium private set intersection of claim 3, wherein, The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set. The receiving party gets the accurate intersection result The verification is performed to check whether the elements in the accurate intersection result are contained in If yes, it means that the sending party has dishonest behavior and the obtained intersection result is not trustworthy, and the intersection is determined to fail and the result is uploaded to the blockchain for notarization; otherwise, it is considered that the result is trustworthy, and the intersection is determined to succeed and the result is uploaded to the blockchain for notarization.
5. A system for non-equilibrium private set intersection, characterized in that, Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result, including the following steps: The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set. Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result, including the following steps: The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set. Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result, including the following steps: The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set. Recall For the receiver, the original data set is denoted as , The size of the set is ; the verification data set is denoted as , The size of the set is ; the intersection data set after adding the verification data set is denoted as , The size of the set is , ; Recall For the sender, the sender's original data set is , The set size is , set ; The fingerprint function in the cuckoo filter is denoted as , and the hash function in the cuckoo filter is denoted as ; The three hash functions for cuckoo hashing are denoted as The length of the elements produced by the hash functions is The size of the stash is ; The random encoding function common to the sender and the receiver is denoted as , The encoding length of the random encoding function is , ; Let H be a hash function common to the sender and the receiver i.e., a random mapping of bit strings of length to bit strings of length Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result, including the following steps: The sender and the receiver interact to transfer a common parameter, which includes a fingerprint function of the cuckoo filter and a hash function ; The receiver generates a cuckoo filter for the intersection dataset , ; Recipient for intersection dataset And a cuckoo filter Generate hash and upload to blockchain for notarization; The receiver sends the cuckoo filter to the sender via a smart contract on the blockchain to the sender; The sender looks up the sender's original data set in the cuckoo filter and gets the coarse intersection , , ; The sender is the sender original data set And rough intersection Generate a hash and upload to the blockchain for notarization.
6. The system for non-equilibrium private set intersection of claim 5, wherein, The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set.
7. The system for non-equilibrium private set intersection of claim 6, wherein, Based on the privacy intersection scheme of batch OT extended transmission, parameter transmission and OPRF calculation are performed on the rough intersection set to obtain an accurate intersection result, including the following steps: The sender and the recipient communicate a public parameter over a smart contract on the blockchain, the public parameter including three hash functions of a cuckoo hash , a size s of a stash and its corresponding hash function; The receiver will intersect the data sets to get a set of , ; The sender will send the rough intersection Mapping to each hash function in the cuckoo hash, get A set of elements , ; The receiver initializes a random bit matrix of size n x n , constructs the matrix , ; Sender random initialization One bit of ; The sender and receiver execute through a smart contract on the blockchain. Sender input The recipient, according to Each bit value Send to the sender in sequence and Each column ( );when At that time, the sender received ,when When =1, the sender receives Combine all columns received by the sender into one The matrix is denoted as , ; Receiver is a matrix Generate a hash and upload to the blockchain for notarization; The sender is Generate a hash and upload it to the blockchain for notarization; Receiver performs Next OPRF: For , receiver outputs , resulting in set ; The receiver is Generate a hash and upload to the blockchain for notarization; Sender performs Next OPRF: For , the sender outputs , resulting in a set ; The sender is Generate a hash and upload it to the blockchain for notarization; Sender sends set To receiver; Receiver lookup And The same elements of And The intersection of Is the exact intersection result; The receiver gets the intersection Generate a hash and upload to the blockchain for notarization.
8. The system for non-equilibrium private set intersection of claim 7, wherein, The verification data set is generated by the receiver, and the verification data set cannot become the intersection of the sender original data set and the receiver original data set. The receiver checks the accurate intersection result The receiver checks whether the elements in the accurate intersection result are included in If yes, it means that the sender has dishonest behavior and the intersection result is not reliable, and the intersection is determined to fail and the result is uploaded to the blockchain for evidence; otherwise, the result is considered reliable, and the intersection is determined to succeed and the result is uploaded to the blockchain for evidence.
Citation Information
Patent Citations
Privacy set intersection method and system
CN114401080A
Decentralization privacy intersection method and device based on block chain, and electronic equipment
CN114978493A