A decentralized multi-party privacy intersection method, device, equipment and medium
The centerless multi-party privacy interception method solves the high cost and leakage risk in data interception query through joint data mapping tables and ciphertext numerical comparisons, and realizes safe and efficient data commonality query.
Patent Information
- Application Number
- CN202210511480.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-10
- Publication Date
- 2025-09-02
- Estimated Expiration
- 2042-05-10
AI Technical Summary
In the prior art, there are high costs and data leakage risks in the process of data submission query, and a third-party trusted query server is required to increase additional costs and data leakage risks.
The centerless multi-party privacy interception method is adopted. By obtaining the joint data mapping table corresponding to all the data being queried, the ciphertext value of the target data is compared with the joint mapping value to determine whether the target data is the shared data of all terminals in the terminal cluster, and avoiding the transmission of original data and the participation of third parties.
It reduces the risk of data leakage and query costs, and realizes efficient data submission query while ensuring data privacy and security.
Smart Images

Figure CN114925392B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of privacy computing technology, and in particular to a decentralized multi-party privacy intersection method, device, electronic device, and computer-readable storage medium. Background Art
[0002] With the continuous improvement of people's awareness of privacy protection and the continuous improvement of relevant laws and regulations, society has increasingly stringent requirements for the security of data during circulation and use. How to perform intersection queries on data while ensuring data privacy has become a key research topic in the industry.
[0003] In related technologies, when performing data queries, in order to ensure the security of data from all parties, the data of the querying and queried parties must not be leaked to each other. This typically requires the establishment of a trusted third-party query server to process the intermediate calculation results and desensitized data from the querying and queried parties. The data intersection process can be summarized as follows: the querying party can send its target data to the query server, which then matches the target data with the acquired dataset from the queried party. If a match is successful, it indicates that the target data is shared by both the querying and queried parties. The query server then returns the query results for the target data to the querying party, allowing the querying party to determine whether the target data it holds is shared by multiple parties.
[0004] However, in the above solution, the data of the querying end and the queried end need to be sent to a third-party query server, which increases the risk of data leakage. In addition, setting up a third-party query server requires additional costs, resulting in a higher cost for the overall query process. Summary of the Invention
[0005] The embodiments of the present application provide a decentralized multi-party privacy intersection method, device, electronic device, and computer-readable storage medium to address the problems of high intersection query costs and data leakage risks in related technologies.
[0006] In a first aspect, embodiments of the present application provide a decentralized multi-party privacy intersection method, which is applied to a querying end in a terminal cluster, wherein the terminal cluster includes one querying end and N queried ends. The method includes:
[0007] Obtaining a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal;
[0008] determining a joint mapping value from the joint data mapping table according to a first mapping position set corresponding to the target data;
[0009] When the N-times target ciphertext value is the same as the joint mapping value, the target data is determined to be common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data.
[0010] In an optional embodiment, the method further includes:
[0011] Sending a target public key to each queried end so that each queried end encrypts the data mapping table of each queried end according to the target public key to obtain an encrypted data mapping table corresponding to each queried end; wherein the data mapping table of the queried end is obtained by the queried end mapping the ciphertext value stored in the queried end according to a mapping function set, and the ciphertext value is obtained by the queried end encrypting the data of the queried end according to the target function.
[0012] In an optional implementation manner, obtaining a joint data mapping table corresponding to data of all queried terminals includes:
[0013] Sending a query request to a target queried end, so that the target queried end accumulates the encrypted data mapping tables corresponding to the respective queried ends to obtain a joint data mapping table;
[0014] Receive the joint data mapping table sent by the target queried end.
[0015] In an optional implementation manner, determining the joint mapping value from the joint data mapping table according to the first mapping position set corresponding to the target data includes:
[0016] Determine a first mapping position set corresponding to the target data according to the mapping function set;
[0017] Based on the first mapping location set, obtaining a target mapping data set from the joint data mapping table;
[0018] Accumulating each target mapping data in the target mapping data set to obtain joint ciphertext mapping data;
[0019] The joint ciphertext mapping data is decrypted using the target private key corresponding to the target public key to obtain a joint mapping value.
[0020] In an optional embodiment, the method further includes:
[0021] The target data is encrypted using a target function to obtain a target ciphertext value corresponding to the target data.
[0022] In a second aspect, an embodiment of the present application provides a decentralized multi-party privacy intersection method, which is applied to the queried end. The method includes:
[0023] Generate a data mapping table for the queried end based on the data set of the queried end;
[0024] Generate a joint data mapping table according to the data mapping table of the queried end;
[0025] The joint data mapping table is sent to the query end, so that the query end queries the target data of the query end according to the joint data mapping table.
[0026] In an optional implementation manner, generating a data mapping table of the queried end according to the data set of the queried end includes:
[0027] Encrypt the data of the queried end in the data set of the queried end through the target function to obtain a ciphertext value set;
[0028] Determine, based on the mapping function set, a second mapping position set corresponding to the data of each queried end in the data set of the queried end;
[0029] A random number is stored at the empty value second mapping position of the data mapping table of the queried end, so that the cumulative value of the random numbers stored at all second mapping positions of the data mapping table of the queried end is equal to the ciphertext value corresponding to the second mapping position set.
[0030] In an optional implementation manner, generating a joint data mapping table according to the data mapping table of the queried end includes:
[0031] Receiving the target public key sent by the querying end, encrypting the data mapping table of the queried end according to the target public key, and obtaining the data mapping table of the queried end;
[0032] The encrypted data mapping tables of the respective queried terminals in the terminal cluster are obtained, and the encrypted data mapping tables of the respective queried terminals in the terminal cluster are summed to obtain a joint data mapping table.
[0033] In a third aspect, an embodiment of the present application provides a decentralized multi-party privacy intersection device, which is applied to a querying end in a terminal cluster, wherein the terminal cluster includes one querying end and N queried ends, and the device includes:
[0034] An acquisition module, configured to acquire a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of the respective queried terminals;
[0035] a determination module, configured to determine a joint mapping value from the joint data mapping table according to a first mapping position set corresponding to the target data;
[0036] A query module is used to determine that the target data is common data of all terminals in the terminal cluster when the N-fold target ciphertext value is the same as the joint mapping value; wherein the target ciphertext value is obtained by encrypting the target data.
[0037] In an optional embodiment, the device further includes:
[0038] A sending module is used to send a target public key to each queried end, so that each queried end encrypts the data mapping table of each queried end according to the target public key to obtain an encrypted data mapping table corresponding to each queried end; wherein the data mapping table of the queried end is obtained by the queried end mapping the ciphertext value stored in the queried end according to a mapping function set, and the ciphertext value is obtained by the queried end encrypting the data of the queried end according to the target function.
[0039] In an optional implementation, the acquisition module includes:
[0040] a request submodule, configured to send a query request to a target queried end, so that the target queried end accumulates the encrypted data mapping tables corresponding to the respective queried ends to obtain a joint data mapping table;
[0041] The receiving submodule is configured to receive the joint data mapping table sent by the target queried end.
[0042] In an optional implementation, the determining module includes:
[0043] A position submodule, configured to determine a first mapping position set corresponding to the target data according to the mapping function set;
[0044] a first mapping submodule, configured to obtain a target mapping data set from the joint data mapping table based on the first mapping position set;
[0045] A first accumulation submodule, configured to accumulate each target mapping data in the target mapping data set to obtain joint ciphertext mapping data;
[0046] The mapping value submodule is used to decrypt the joint ciphertext mapping data using the target private key corresponding to the target public key to obtain a joint mapping value.
[0047] In an optional embodiment, the device further includes:
[0048] The encryption module is used to encrypt the target data through a target function to obtain a target ciphertext value corresponding to the target data.
[0049] In a fourth aspect, an embodiment of the present application provides a decentralized multi-party privacy intersection device, which is applied to a queried end, and includes:
[0050] A first generating module, configured to generate a data mapping table of the queried end according to the data set of the queried end;
[0051] A second generating module, configured to generate a joint data mapping table according to the data mapping table of the queried end;
[0052] The mapping table sending module is used to send the joint data mapping table to the query end, so that the query end can query the target data of the query end according to the joint data mapping table.
[0053] In an optional implementation, the first generating module includes:
[0054] The ciphertext value set submodule is used to encrypt the data of the queried end in the data set of the queried end through the target function to obtain a ciphertext value set;
[0055] A second mapping submodule, configured to determine, based on the mapping function set, a second mapping position set corresponding to the data of each queried end in the data set of the queried end;
[0056] The second accumulation submodule is used to store random numbers at the empty value second mapping position of the data mapping table of the queried end, so that the cumulative value of the random numbers stored at all second mapping positions of the data mapping table of the queried end is equal to the ciphertext value corresponding to the second mapping position set.
[0057] In an optional implementation, the second generating module includes:
[0058] The public key receiving submodule is used to receive the target public key sent by the querying end, and encrypt the data mapping table of the queried end by using the target public key to obtain an encrypted data mapping table;
[0059] The summing submodule is configured to obtain the encrypted data mapping table of each queried terminal in the terminal cluster, and sum the encrypted data mapping tables of each queried terminal in the terminal cluster to obtain a joint data mapping table.
[0060] In a fifth aspect, an embodiment of the present application further provides an electronic device comprising: a processor; a memory for storing instructions executable by the processor; wherein the processor is configured to execute the instructions to implement the decentralized multi-party privacy intersection method.
[0061] In a sixth aspect, an embodiment of the present application further provides a computer-readable storage medium, which, when the instructions in the computer-readable storage medium are executed by a processor of an electronic device, enables the electronic device to execute the decentralized multi-party privacy intersection method.
[0062] In an embodiment of the present application, a joint data mapping table corresponding to the data of all queried terminals is obtained; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal; according to the first mapping position set corresponding to the target data, a joint mapping value is determined from the joint data mapping table; when the N-fold target ciphertext value is the same as the joint mapping value, the target data is determined to be the common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data. The query terminal of the present application can obtain the joint data mapping table of the queried terminal, and determine whether the target data it holds is the common data of this terminal and all queried terminals based on the joint data mapping table. During the query process, neither the query terminal nor the queried terminal needs to transmit the original data they hold, and no third party needs to participate in the entire query process, which not only reduces the risk of data leakage but also reduces costs.
[0063] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0064] Various other advantages and benefits will become apparent to those skilled in the art upon reading the detailed description of the preferred embodiment below. The accompanying drawings are for illustration purposes only and are not to be considered as limiting the present application. The same reference symbols are used throughout the drawings to represent the same components. In the drawings:
[0065] Figure 1 This is a flowchart of the steps of a decentralized multi-party privacy intersection method provided by an embodiment of the present application;
[0066] Figure 2 This is a cluster architecture diagram provided by an embodiment of the present application;
[0067] Figure 3 This is a flowchart of another decentralized multi-party privacy intersection method provided by an embodiment of the present application;
[0068] Figure 4 This is a flowchart of the steps of another decentralized multi-party privacy intersection method provided by an embodiment of the present application;
[0069] Figure 5This is a flowchart of the steps of a decentralized multi-party privacy intersection method provided in an embodiment of the present application;
[0070] Figure 6 This is a data query model structure diagram provided by an embodiment of the present application;
[0071] Figure 7 This is another data query model structure diagram provided by an embodiment of the present application;
[0072] Figure 8 This is a logic block diagram of an electronic device according to an embodiment of the present application;
[0073] Figure 9 It is a logic block diagram of an electronic device according to another embodiment of the present application. DETAILED DESCRIPTION
[0074] The following describes exemplary embodiments of the present application in more detail with reference to the accompanying drawings. Although exemplary embodiments of the present application are shown in the accompanying drawings, it should be understood that the present application can be implemented in various forms and should not be limited by the embodiments set forth herein. Rather, these embodiments are provided to enable a more thorough understanding of the present application and to fully convey the scope of the present application to those skilled in the art.
[0075] Figure 1 This is a flowchart of a decentralized multi-party privacy intersection method provided by an embodiment of the present application. Figure 1 As shown, the method includes:
[0076] Step 101: Acquire a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of the respective queried terminals.
[0077] The embodiments of the present application are applied to a querying end in a terminal cluster. The terminal cluster includes one querying end and N queried ends, where N is an integer greater than or equal to 1. It should be noted that in the embodiments of the present application, each terminal in the terminal cluster can serve as either a querying end or a queried end. When a terminal in the terminal cluster initiates a query, it becomes the querying end, and the other terminals in the terminal cluster become the queried ends.
[0078] Reference Figure 2 , Figure 2 A cluster architecture diagram provided by an embodiment of the present application is shown in FIG. Figure 2As shown, a cluster contains three terminals. If the second terminal in the cluster is the querying terminal, the queried terminals include the first and third terminals. If the third terminal in the cluster is the querying terminal, the queried terminals include the first and second terminals. Querying terminals and queried terminals can be collectively referred to as participants. The number of participants is N+1, the number of querying terminals is 1, and the number of queried terminals is N.
[0079] Each participant holds its own data set, which may include certain data information, such as mobile phone number, identity identification code, and file name and identification code corresponding to the file. Can hold datasets:
[0080] .
[0081] Before performing a query, all participants map each data point in their own dataset to a data mapping table. It should be noted that to facilitate subsequent queries based on the data mapping table, all participants' data mapping tables contain the same number of mapping locations. For example, each data mapping table can contain 10,000 mapping locations.
[0082] Specifically, each participant can determine the mapping position corresponding to each data item in its own data set based on the same mapping function set, generate a mapping value corresponding to each mapping position, and then store the mapping value corresponding to the data item at the mapping position corresponding to the data item in the data mapping table. The sum of the mapping values in all mapping positions corresponding to the data item is equal to the data item itself.
[0083] For example, the data set of participant 1 contains two phone numbers: 12345678910 and 11223344556. The data mapping table corresponding to participant 1 may include the structure shown in Table 1, which includes four mapping locations for storing mapped values:
[0084]
[0085] Table 1
[0086] Assuming that the mapping function set contains two mapping functions, each number in the data set of participant 1 is substituted into the two mapping functions respectively, and the mapping positions corresponding to "12345678910" are calculated to be 1 and 2, and the mapping positions corresponding to "11223344556" are calculated to be 3 and 4. Then, the mapping values can be written into mapping positions 1 and 2 of the above data mapping table so that the sum of the mapping values in mapping positions 1 and 2 is "12345678910". At the same time, the mapping values can be written into mapping positions 3 and 4 of the above data mapping table so that the sum of the mapping values in mapping positions 3 and 4 is "11223344556". The data mapping table shown in Table 2 is obtained:
[0087]
[0088] Table 2
[0089] Among them, the cumulative value of the mapping values in mapping position 1 and mapping position 2 in Table 2 is "12345678910", and the cumulative value of the mapping values in mapping position 3 and mapping position 4 in Table 2 is "11223344556".
[0090] Furthermore, when higher security is required, or when the data in the dataset is non-numeric, each participant can encrypt the data in the dataset according to a unified encryption rule, converting it into ciphertext values, and then generate a data mapping table based on these ciphertext values, so that the cumulative value of the mapping values corresponding to each data item equals the ciphertext value corresponding to the data item. For example, the unified encryption rule can be a hash function.
[0091] After each participant generates a corresponding data mapping table, in one embodiment, the querying end can send a request to the queried end in the cluster to obtain the data mapping table of each queried end, and then accumulate the data mapping tables of each queried end to obtain a joint data mapping table. In another embodiment, the querying end can send a request to only one of the queried ends, and then the queried end obtains the data mapping tables of the other queried ends, accumulates its own queried end mapping table and the data mapping tables of the other queried ends to obtain a joint data mapping table, and finally feeds this joint data mapping table back to the querying end.
[0092] It should be noted that, if any terminal in a terminal cluster can serve as a query terminal, all terminals in the terminal cluster need to generate their own data mapping tables. However, in another case, if the query terminal in the terminal cluster is fixed, the query terminal itself may not generate a corresponding data mapping table.
[0093] Step 102: Determine a joint mapping value from the joint data mapping table according to a first mapping position set corresponding to the target data.
[0094] In the embodiment of the present application, after the query end obtains the joint data mapping table, it can query through the joint data mapping table whether the target data in its own data set is the common data of all terminals in the terminal cluster.
[0095] Specifically, the querying end can input the target data into each mapping function in the mapping function set, determine the first mapping position set corresponding to the target function, and obtain the mapping values at the corresponding positions from the joint data mapping table based on the first mapping position set. These mapping values are then summed to obtain the joint mapping value. It should be noted that the mapping function set used to determine the first mapping position set is the same mapping function set used by each queried end to generate the data mapping table in the above steps.
[0096] Step 103 : When the N-fold target ciphertext value is the same as the joint mapping value, determine that the target data is common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data.
[0097] The query end can encrypt the target data using the encryption rules used when encrypting the data of each queried end in the above steps to obtain a target encrypted value, and compare the target encrypted value with the joint mapping value. Based on the comparison result, it is determined whether the target data corresponding to the target encrypted value is the data commonly held by all terminals in the terminal cluster.
[0098] Specifically, since the joint data mapping table is obtained by accumulating the data mapping tables of all queried terminals, the data stored in each mapping position in the joint data mapping table is the accumulated value of the mapping values at the corresponding position in the data mapping tables of each queried terminal.
[0099] Because each terminal uses the same encryption rules to encrypt its own data, obtaining the corresponding ciphertext value, and uses the same set of mapping functions to determine the mapping location corresponding to its own data, and the cumulative value of the values in the mapping location corresponding to any data is equal to the ciphertext value corresponding to that data, if each terminal simultaneously stores the target data, the joint mapping value determined from the joint data mapping table based on the first mapping location set corresponding to the target data of the querying terminal should be equal to the target ciphertext value corresponding to the target data times the number of queried terminals in the cluster.
[0100] For example, the terminal cluster contains three terminals: query terminal 1, queried terminal 2, and queried terminal 3. Each terminal's data set contains two data. Query terminal 2 uses the mapping function set to determine that one data in the data set corresponds to mapping positions 2 and 3, and the other data corresponds to mapping positions 1 and 4. It then generates a data mapping table based on hash function A, as shown in Table 3:
[0101]
[0102] Table 3
[0103] The queried end 3 determines through the mapping function set that the mapping positions corresponding to one data in the data set are 2 and 3, and the mapping positions corresponding to the other data are 1 and 4, and generates a data mapping table according to the hash function A as shown in Table 4:
[0104]
[0105] Table 4
[0106] The joint data mapping table obtained by accumulating the data mapping tables corresponding to all queried ends is shown in Table 5:
[0107]
[0108] Table 5
[0109] After calculating the target data according to the mapping function set, it is determined that the mapping positions corresponding to the target data include mapping position 2 and mapping position 3. The mapping values in mapping position 2 and mapping position 3 of the joint data mapping table are obtained as A2+B2 and A3+B3 respectively, and the combined values are added to obtain the joint mapping value A2+B2+A3+B3.
[0110] Since the mapping position set corresponding to the same data in the queried end is the same, and the cumulative value of the data at each mapping position in the mapping position set is equal to the ciphertext value corresponding to the same data, if the target ciphertext value corresponding to twice the target data is equal to A2+B2+A3+B3, it means that the target data is the common data of the querying end and all queried ends. In other words, it can be determined that the target data is the common data of all participants, thereby completing the privacy intersection of multiple participants.
[0111] In summary, a decentralized multi-party privacy intersection method is provided for the embodiment of the present application. In the embodiment of the present application, a joint data mapping table corresponding to the data of all queried ends is obtained; wherein, the joint data mapping table is obtained by summing the data mapping tables of each queried end; according to the first mapping position set corresponding to the target data, the joint mapping value is determined from the joint data mapping table; when the N times target ciphertext value is the same as the joint mapping value, the target data is determined to be the common data of all terminals in the terminal cluster; wherein, the target ciphertext value is obtained by encrypting the target data. The query end of the present application can obtain the joint data mapping table of the queried end, and determine whether the target data it holds is the common data of this end and all queried ends based on the joint data mapping table. During the query process, neither the query end nor the queried end needs to send the original data they hold, and no third party needs to participate in the entire query process, which not only reduces the risk of data leakage but also reduces costs.
[0112] Figure 3 This is a flowchart of another decentralized multi-party privacy intersection method provided by an embodiment of the present application. Figure 3 As shown, the method includes:
[0113] Step 201: Acquire a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of the respective queried terminals.
[0114] This step can be referred to as step 101 and will not be described in detail in this embodiment of the present application.
[0115] Step 202: Send the target public key to each queried end, so that each queried end encrypts the data mapping table of each queried end according to the target public key to obtain the encrypted data mapping table corresponding to each queried end; wherein, the data mapping table of the queried end is obtained by the queried end mapping the ciphertext value stored in the queried end according to the mapping function set, and the ciphertext value is obtained by the queried end encrypting the data of the queried end according to the target function.
[0116] In the embodiment of the present application, when querying data, the querying end needs to obtain a joint data mapping table obtained by summing the data mapping tables of all the queried ends. Therefore, the data mapping tables of each queried end can be aggregated into one queried end, and the queried end generates the joint data mapping table.
[0117] Furthermore, to ensure the security of the data mapping table of the queried end, the queried end can generate a target public key and a corresponding target private key and send the target public key to each queried end. Each queried end then encrypts its own data mapping table using the target public key to obtain an encrypted data mapping table, which is then sent to the other queried ends, avoiding the need to directly send unencrypted data mapping tables to other queried ends.
[0118] Specifically, when the queried end encrypts its own queried end data mapping table using the target public key, a homomorphic encryption algorithm (such as the CKKS encryption algorithm) may be used to obtain the encrypted data mapping table.
[0119] CKKS is a special encryption algorithm that encrypts raw data into corresponding homomorphic ciphertext, which can then be directly used in calculations without being decrypted back to the original data. Furthermore, CKKS can simultaneously encrypt a group of data, resulting in high encryption efficiency. CKKS's plaintext and ciphertext also have a one-to-many nature. Even when encrypting multiple identical plaintexts with the same target public key, different ciphertexts can be obtained. This effectively prevents subsequent target query endpoints from aggregating and accumulating the encrypted data mapping tables and obtaining the data of each query endpoint based on the intersection of the encrypted data mapping tables.
[0120] Step 203: Send a query request to the target queried end, so that the target queried end accumulates the encrypted data mapping tables corresponding to the respective queried ends to obtain a joint data mapping table.
[0121] The query end can determine a target queried end among the queried ends and send a query request to the target queried end, so that the target queried end summarizes the encrypted data mapping tables of all queried ends and accumulates all the encrypted data mapping tables to obtain a joint data mapping table.
[0122] Step 204: Receive the joint data mapping table sent by the target queried end.
[0123] After the target queried end generates the joint data mapping table, it may send the joint data mapping table to the query end, and the query end receives the joint data mapping table.
[0124] In an embodiment of the present application, the querying end can send the target public key to the queried end, so that the queried end encrypts the data mapping table it holds according to the target public key, and then sends the encrypted data mapping table to other queried ends. Since the target queried end does not hold the target private key corresponding to the target public key, the target queried end cannot decrypt the encrypted data mapping tables of other queried ends. Moreover, since the joint data mapping table obtained by the querying end is obtained by accumulating the encrypted data mapping tables of all queried ends, the data mapping table of any queried end cannot be obtained by decrypting the joint data mapping table using the target private key corresponding to the target public key, so that the data mapping table of any queried end cannot be obtained by other terminals in the cluster, thereby enhancing the security of the data of the queried end.
[0125] Step 205: Determine a first mapping position set corresponding to the target data according to the mapping function set.
[0126] In an embodiment of the present application, the mapping function set is used to determine a mapping position set corresponding to data in a data set of each terminal, and the mapping position set is used to indicate a mapping position of the corresponding data in a data mapping table.
[0127] A mapping function set contains multiple mapping functions that map data to the mapping locations within the data mapping table. For example, if the data mapping table corresponding to all terminals in the cluster contains 10,000 mapping locations, you can set mapping function A. The input of mapping function A is the data of the data set of each terminal, and the output is any integer in the range [1, 10,000]. The mapping function can be a hash function.
[0128] In the embodiment of the present application, the number of first mapping positions in the first mapping position set is the same as the number of mapping functions in the mapping function set. Each first mapping position corresponds to a mapping function.
[0129] Step 206: Based on the first mapping location set, obtain a target mapping data set from the joint data mapping table.
[0130] After determining the first mapping position set, the target mapping data stored in each first mapping position in the first mapping position set can be obtained from the joint data mapping table based on each first mapping position in the first mapping position set. There is a one-to-one correspondence between the target mapping data and the first mapping position, and the number of first mapping positions in the first mapping position set is the same as the number of target mapping data in the target mapping data set.
[0131] For example, the first mapping position set includes three first mapping positions [1, 3, 5], and the joint data mapping table is shown in Table 6 below:
[0132]
[0133] Table 6
[0134] Based on the first mapping position set [1, 3, 5], the target mapping data set that can be obtained from the joint data mapping table shown in Table 6 is [value 1, value 3, value 5].
[0135] Step 207: Accumulate each target mapping data in the target mapping data set to obtain joint ciphertext mapping data.
[0136] After the target mapping data set is obtained, each target mapping data in the target mapping data set may be accumulated to obtain joint ciphertext mapping data.
[0137] For example, in Table 6 above, assuming that the value 1 is 38274, the value 3 is 34847, and the value 5 is 48239, the target mapping data set can be expressed as [38274, 34847, 48239]. After accumulating all the target mapping data in the target mapping data set, the joint ciphertext mapping data 121360 is obtained.
[0138] Step 208: Decrypt the joint ciphertext mapping data using the target private key corresponding to the target public key to obtain a joint mapping value.
[0139] In an embodiment of the present application, the query end can generate a target private key corresponding to the target public key while generating the target public key. The target private key can be used to decrypt data encrypted by the target public key.
[0140] Since the joint ciphertext mapping data is obtained by accumulating data encrypted by the target public key, the joint ciphertext mapping data can be decrypted by the target private key corresponding to the target public key to obtain the joint mapping value.
[0141] In addition, considering that in some cases, the order of accumulating public key encrypted data and decrypting it with a private key will affect the final result, therefore, in another embodiment, all target mapping data in the target mapping data set can be first decrypted using the target private key to obtain the target mapping data set, and then each target mapping data set in the target mapping data set can be accumulated to obtain a joint mapping value.
[0142] In an embodiment of the present application, the query end determines the joint mapping value corresponding to the target data through the joint data mapping table. Even if the query end has the target private key and can decrypt the joint data mapping table, it can only obtain the joint data mapping table and cannot obtain the data mapping table of any queried end, thereby ensuring the security of the data of the queried end.
[0143] Step 209: encrypt the target data using a target function to obtain a target ciphertext value corresponding to the target data.
[0144] In an embodiment of the present application, the step of encrypting the target data through the target function to obtain the target ciphertext value corresponding to the target data can be performed after obtaining the joint mapping value corresponding to the target data, or it can be performed when generating the data mapping table corresponding to the query end.
[0145] Since the joint mapping value is obtained by summing the mapping data of the mapping positions corresponding to the target data in the data mapping tables of each queried terminal, and the mapping data of all terminals in the cluster are determined by the objective function, in order to determine whether the target data is shared by multiple terminals through the joint mapping value corresponding to the target data, the target data can be first processed through the objective function to obtain the target ciphertext value corresponding to the target data.
[0146] Step 210 : When the N-times target ciphertext value is the same as the joint mapping value, determine that the target data is common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data.
[0147] This step can be referred to as step 103 and will not be described in detail in this embodiment of the present application.
[0148] In summary, another decentralized multi-party privacy intersection method provided for the embodiment of the present application includes: obtaining a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal; determining a joint mapping value from the joint data mapping table according to the first mapping position set corresponding to the target data; when the N times target ciphertext value is the same as the joint mapping value, determining that the target data is the common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data. The querying terminal of the present application can obtain the joint data mapping table of the queried terminal, and determine whether the target data it holds is the common data of this terminal and all queried terminals based on the joint data mapping table. During the query process, neither the querying terminal nor the queried terminal needs to send the original data they hold, and no third party needs to participate in the entire query process, which not only reduces the risk of data leakage but also reduces costs.
[0149] Figure 4 This is a flowchart of the steps of another decentralized multi-party privacy intersection method provided by the embodiment of the present application, which is applied to the queried end, such as Figure 4 As shown, the method includes:
[0150] Step 301: Generate a data mapping table of the queried end according to the data set of the queried end.
[0151] In an embodiment of the present application, any terminal in the terminal cluster can serve as a query end or a queried end. When a terminal needs to query whether the data in its own data set is common data of all terminals in the terminal cluster, the terminal serves as the query end, and the other terminals in the terminal cluster serve as the queried ends.
[0152] Therefore, in the embodiment of the present application, a preparation phase and a query phase may be included. In the preparation phase, each terminal in the terminal cluster generates a data mapping table corresponding to its own data set.
[0153] Optionally, step 301 may further include:
[0154] Sub-step 3011: encrypt the data of the queried end in the data set of the queried end through the target function to obtain a ciphertext value set.
[0155] To ensure data security and facilitate subsequent operations, the data in the queried dataset can be processed using an objective function to obtain a corresponding ciphertext value set. The objective function converts the data in the dataset into a ciphertext value. The ciphertext values in the ciphertext value set correspond one-to-one to the data in the dataset.
[0156] Specifically, each terminal in the terminal cluster can jointly generate an objective function to ensure the security of the objective function. Each queried terminal in the terminal cluster converts its own data set through the same objective function to obtain a corresponding ciphertext value set.
[0157] Sub-step 3012: determining, based on the mapping function set, a second mapping position set corresponding to the data of each queried end in the data set of the queried end.
[0158] A mapping function set can also be generated jointly by all terminals in a terminal cluster. For example, if a mapping function set contains 60 mapping functions and the terminal cluster includes 10 terminals, each terminal can generate 6 mapping functions. The mapping functions generated by all terminals are aggregated to form the mapping function set. This prevents any terminal from fully controlling the mapping function set, reducing the possibility of data theft through manipulation of the mapping function set. Based on the input ciphertext value, the mapping function output indicates the mapping location of a storage unit in the data mapping table.
[0159] Specifically, each queried end can input each data item in its own data set into each mapping function in the mapping function set to obtain a second mapping position set corresponding to each data item. Based on the second mapping position set, the mapping value corresponding to the data item on the queried end is then stored in the corresponding position of the data mapping table. After performing the above operation on each data item, a data mapping table for the queried end can be obtained.
[0160] Sub-step 3013, stores a random number at the empty value second mapping position of the data mapping table of the queried end, so that the cumulative value of the random numbers stored at all second mapping positions of the data mapping table of the queried end is equal to the ciphertext value corresponding to the second mapping position set.
[0161] Specifically, the queried end can first construct a data mapping table containing a target number of mapping positions. In the initial state, the value of each mapping position in the data mapping table of the queried end is empty or 0. The target number can be preset by the system, specified by a technician, or determined based on the amount of data contained in the data sets of each terminal in the cluster. For example, the target number can be set to 60 times the amount of data contained in the data set with the largest amount of data in the data set of all terminals. It should be noted that the data mapping tables of all terminals in the cluster contain the same number of mapping positions.
[0162] In one case, if all mapping positions of a mapping position set of a data in the data mapping table of the queried end are null values or 0, a random number is generated for each mapping position of the mapping position set, and the sum of the random numbers corresponding to these mapping positions is equal to the ciphertext value corresponding to the data.
[0163] For example, the data mapping table of a queried end is shown in Table 7 below:
[0164]
[0165] Table 7
[0166] All mapping positions of the data mapping table of the queried end shown in Table 7 are empty values. If the mapping position set corresponding to a data of the queried end is [1, 3, 5], and the ciphertext value corresponding to the data is 99, then three random numbers R1, R2, and R3 can be generated, and R1+R2+R3=99. In one solution, R1=22, R2=54, and R3=23. Then R1, R2, and R3 can be written into mapping positions 1, 3, and 5 of the data mapping table shown in Table 7 above, resulting in the data mapping table shown in Table 8 below:
[0167]
[0168] Table 8
[0169] In another case, if the mapping values stored in some mapping positions of a mapping position set of a data in the data mapping table of the queried end are empty or 0, then only a random number is generated as a new mapping value for each mapping position in the mapping position set whose mapping value is empty or 0, and the sum of the random numbers corresponding to the mapping positions whose mapping values are empty or 0 and the mapping values corresponding to the mapping positions whose mapping values are not empty or 0 is equal to the ciphertext value corresponding to the data.
[0170] For example, based on the data mapping table shown in Table 8, if the mapping position set corresponding to a piece of data on the queried end is [1, 2, 3], and the ciphertext value corresponding to the data is 88, then a random number R1 corresponding to mapping position 2 can be generated, and the sum of the random number R1 corresponding to mapping position 2, the mapping value stored in mapping position 1, and the mapping value stored in mapping position 3 is the ciphertext value 88 corresponding to the data. The equation R1+22+54=88 can be obtained, and the solution is R1=12. R1 can then be written into mapping position 2 of the data mapping table shown in Table 7 above, resulting in the data mapping table shown in Table 9 below:
[0171]
[0172] Table 9
[0173] In an embodiment of the present application, the queried end can determine the data mapping table corresponding to its own data set based on the target function and the mapping function set. Even if the data mapping table is leaked, the data in the data set of the queried end cannot be restored from the data mapping table, thereby ensuring the security of the data.
[0174] Step 302: Generate a joint data mapping table according to the data mapping table of the queried end.
[0175] Optionally, step 302 may further include:
[0176] Sub-step 3021: receiving the target public key sent by the querying end, and encrypting the data mapping table of the queried end using the target public key to obtain an encrypted data mapping table.
[0177] This step can be referred to as step 202 and will not be described in detail in this embodiment of the present application.
[0178] It should be noted that the data mapping table of the queried end is encrypted according to the target public key, and the mapping value in each mapping position in the data mapping table of the queried end is encrypted by the target public key, and the mapping position in the encrypted data mapping table corresponds one-to-one to the mapping position in the data mapping table of the queried end.
[0179] Sub-step 3022: obtaining the encrypted data mapping table of each queried terminal in the terminal cluster, and summing the encrypted data mapping tables of each queried terminal in the terminal cluster to obtain a joint data mapping table.
[0180] Any queried end in the terminal cluster can receive the query request from the query end. After receiving the query request, the queried end can send a request to other queried ends in the terminal cluster to obtain the encrypted data mapping tables of other queried ends, and sum the encrypted data mapping tables of all other queried ends with the encrypted data mapping table of this end to obtain a joint data mapping table.
[0181] Specifically, since the encrypted data mapping tables of all queried ends contain the same number of mapping positions, the mapping data in the same mapping position of all encrypted data mapping tables can be accumulated, and the accumulated results can be written into the corresponding mapping positions of the joint data mapping table. After performing the same operation on all mapping positions, the final joint data mapping table can be obtained.
[0182] For example, if the terminal cluster contains two queried terminals, the encrypted data mapping table of one of the queried terminals is shown in Table 10 below, and the encrypted data mapping table of the other queried terminal is shown in Table 11 below:
[0183]
[0184] Table 10
[0185]
[0186] Table 11
[0187] After accumulating the encrypted data mapping tables represented by Table 10 and Table 11, the joint data mapping table shown in Table 12 can be obtained:
[0188]
[0189] Table 12
[0190] Step 303: Send the joint data mapping table to the query end, so that the query end queries the target data of the query end according to the joint data mapping table.
[0191] This step can refer to the above steps 201 to 210, and will not be repeated in this embodiment of the application.
[0192] In summary, another decentralized multi-party privacy intersection method is provided for the embodiment of the present application. In the embodiment of the present application, a joint data mapping table corresponding to the data of all queried ends is obtained; wherein, the joint data mapping table is obtained by summing the data mapping tables of each queried end; according to the first mapping position set corresponding to the target data, the joint mapping value is determined from the joint data mapping table; when the N times target ciphertext value is the same as the joint mapping value, the target data is determined to be the common data of all terminals in the terminal cluster; wherein, the target ciphertext value is obtained by encrypting the target data. The query end of the present application can obtain the joint data mapping table of the queried end, and determine whether the target data it holds is the common data of this end and all queried ends based on the joint data mapping table. During the query process, neither the query end nor the queried end needs to send the original data they hold, and no third party needs to participate in the entire query process, which not only reduces the risk of data leakage but also reduces costs.
[0193] Figure 5 This is a flowchart of a decentralized multi-party privacy intersection method provided by an embodiment of the present application. Figure 5 As shown, the method includes:
[0194] In step 401, the queried end encrypts the data in the data set of the queried end through the target function to obtain a ciphertext value set.
[0195] Step 402: The queried end determines, based on the mapping function set, a second mapping position set corresponding to each queried end's data in the queried end's data set.
[0196] In step 403, the queried end stores a random number at the empty value second mapping position of the data mapping table of the queried end, so that the cumulative value of the random numbers stored at all second mapping positions of the data mapping table of the queried end is equal to the ciphertext value corresponding to the second mapping position set.
[0197] In step 404, the querying end sends the target public key to each queried end, so that each queried end encrypts the data mapping table of each queried end according to the target public key to obtain the encrypted data mapping table corresponding to each queried end.
[0198] Step 405: The queried end receives the target public key sent by the querying end, and encrypts the data mapping table of the queried end using the target public key to obtain an encrypted data mapping table.
[0199] In step 406, the querying end sends a query request to the target queried end, so that the target queried end accumulates the encrypted data mapping tables corresponding to the respective queried ends to obtain a joint data mapping table.
[0200] In step 407 , the queried end obtains the encrypted data mapping table of each queried end in the terminal cluster, and sums the encrypted data mapping tables of each queried end in the terminal cluster to obtain a joint data mapping table.
[0201] Step 408: The query end receives the joint data mapping table sent by the target queried end.
[0202] Step 409: The query end determines a first mapping position set corresponding to the target data according to the mapping function set.
[0203] Step 410: The query end obtains a target mapping data set from the joint data mapping table based on the first mapping location set.
[0204] In step 411 , the query end accumulates each target mapping data in the target mapping data set to obtain joint ciphertext mapping data.
[0205] In step 412, the query end decrypts the joint ciphertext mapping data using the target private key corresponding to the target public key to obtain a joint mapping value.
[0206] In step 413, the query end encrypts the target data using a target function to obtain a target ciphertext value corresponding to the target data.
[0207] In step 414 , when the N-times target ciphertext value is the same as the joint mapping value, the query end determines that the target data is the common data of all the terminals in the terminal cluster.
[0208] In summary, the embodiment of the present application also provides a decentralized multi-party privacy intersection method, including: obtaining a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal; determining a joint mapping value from the joint data mapping table according to the first mapping position set corresponding to the target data; when the N times target ciphertext value is the same as the joint mapping value, determining that the target data is the common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data. The querying terminal of the present application can obtain the joint data mapping table of the queried terminal, and determine whether the target data it holds is the common data of this terminal and all queried terminals based on the joint data mapping table. During the query process, neither the querying terminal nor the queried terminal needs to send the original data they hold, and no third party needs to participate in the entire query process, which not only reduces the risk of data leakage but also reduces costs.
[0209] Corresponding to the method provided by the embodiment of the decentralized multi-party privacy intersection method of the present invention, see Figure 6The present invention also provides a structure diagram of a decentralized multi-party privacy intersection device. In this embodiment, the device is applied to a querying end in a terminal cluster. The terminal cluster includes one querying end and N queried ends. The device includes:
[0210] An acquisition module 501 is configured to acquire a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal;
[0211] a determination module 502 for determining a joint mapping value from the joint data mapping table according to a first mapping position set corresponding to the target data;
[0212] The query module 503 is configured to determine that the target data is common data of all terminals in the terminal cluster when the N-times target ciphertext value is the same as the joint mapping value; wherein the target ciphertext value is obtained by encrypting the target data.
[0213] In an optional embodiment, the device further includes:
[0214] A sending module is used to send a target public key to each queried end, so that each queried end encrypts the data mapping table of each queried end according to the target public key to obtain an encrypted data mapping table corresponding to each queried end; wherein the data mapping table of the queried end is obtained by the queried end mapping the ciphertext value stored in the queried end according to a mapping function set, and the ciphertext value is obtained by the queried end encrypting the data of the queried end according to the target function.
[0215] In an optional implementation, the acquisition module includes:
[0216] a request submodule, configured to send a query request to a target queried end, so that the target queried end accumulates the encrypted data mapping tables corresponding to the respective queried ends to obtain a joint data mapping table;
[0217] The receiving submodule is configured to receive the joint data mapping table sent by the target queried end.
[0218] In an optional implementation, the determining module includes:
[0219] A position submodule, configured to determine a first mapping position set corresponding to the target data according to the mapping function set;
[0220] a first mapping submodule, configured to obtain a target mapping data set from the joint data mapping table based on the first mapping position set;
[0221] A first accumulation submodule, configured to accumulate each target mapping data in the target mapping data set to obtain joint ciphertext mapping data;
[0222] The mapping value submodule is used to decrypt the joint ciphertext mapping data using the target private key corresponding to the target public key to obtain a joint mapping value.
[0223] In an optional embodiment, the device further includes:
[0224] The encryption module is used to encrypt the target data through a target function to obtain a target ciphertext value corresponding to the target data.
[0225] In summary, the embodiment of the present application provides a data query model generation device, including: obtaining a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal; determining a joint mapping value from the joint data mapping table according to the first mapping position set corresponding to the target data; when the N times target ciphertext value is the same as the joint mapping value, determining that the target data is the common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data. The query terminal of the present application can obtain the joint data mapping table of the queried terminal, and determine whether the target data it holds is the common data of this terminal and all queried terminals based on the joint data mapping table. During the query process, neither the query terminal nor the queried terminal needs to send the original data they hold, and no third party needs to participate in the entire query process, which not only reduces the risk of data leakage but also reduces costs.
[0226] Corresponding to the method provided by the embodiment of the decentralized multi-party privacy intersection method of the present invention, see Figure 7 The present invention also provides another decentralized multi-party privacy intersection device structure diagram. In this embodiment, the device is applied to the query end and includes:
[0227] The first generating module 801 is used to generate a data mapping table of the queried end according to the data set of the queried end;
[0228] A second generating module 802 is configured to generate a joint data mapping table according to the data mapping table of the queried end;
[0229] The mapping table sending module 803 is configured to send the joint data mapping table to the query end, so that the query end can query the target data of the query end according to the joint data mapping table.
[0230] In an optional implementation, the first generating module includes:
[0231] The ciphertext value set submodule is used to encrypt the data of the queried end in the data set of the queried end through the target function to obtain a ciphertext value set;
[0232] A second mapping submodule, configured to determine, based on the mapping function set, a second mapping position set corresponding to the data of each queried end in the data set of the queried end;
[0233] The second accumulation submodule is used to store random numbers at the empty value second mapping position of the data mapping table of the queried end, so that the cumulative value of the random numbers stored at all second mapping positions of the data mapping table of the queried end is equal to the ciphertext value corresponding to the second mapping position set.
[0234] In an optional implementation, the second generating module includes:
[0235] The public key receiving submodule is used to receive the target public key sent by the querying end, and encrypt the data mapping table of the queried end by using the target public key to obtain an encrypted data mapping table;
[0236] The summing submodule is configured to obtain the encrypted data mapping table of each queried terminal in the terminal cluster, and sum the encrypted data mapping tables of each queried terminal in the terminal cluster to obtain a joint data mapping table.
[0237] In summary, another data query model generation device provided by an embodiment of the present application includes: obtaining a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal; determining a joint mapping value from the joint data mapping table according to the first mapping position set corresponding to the target data; when the N times target ciphertext value is the same as the joint mapping value, determining that the target data is the common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data. The query terminal of the present application can obtain the joint data mapping table of the queried terminal, and determine whether the target data it holds is the common data of this terminal and all queried terminals based on the joint data mapping table. During the query process, neither the query terminal nor the queried terminal needs to send the original data they hold, and no third party needs to participate in the entire query process, which not only reduces the risk of data leakage but also reduces costs.
[0238] Figure 8 6 is a logical block diagram of an electronic device 600 according to an embodiment of the present application. For example, the electronic device 600 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0239] Reference Figure 8, the electronic device 600 may include one or more of the following components: a processing component 602 , a memory 604 , a power component 606 , a multimedia component 608 , an audio component 610 , an input / output (I / O) interface 612 , a sensor component 614 , and a communication component 616 .
[0240] The processing component 602 generally controls the overall operation of the electronic device 600, such as operations associated with display, phone calls, data communications, camera operation, and recording operations. The processing component 602 may include one or more processors 620 to execute instructions to perform all or part of the steps of the above-described method. In addition, the processing component 602 may include one or more modules to facilitate interaction between the processing component 602 and other components. For example, the processing component 602 may include a multimedia module to facilitate interaction between the multimedia component 608 and the processing component 602.
[0241] The memory 604 is used to store various types of data to support operations on the electronic device 600. Examples of such data include instructions for any application or method operating on the electronic device 600, contact data, phone book data, messages, pictures, videos, etc. The memory 604 can be implemented by any type of volatile or non-volatile storage device, or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, or optical disk.
[0242] The power supply assembly 606 provides power to the various components of the electronic device 600. The power supply assembly 606 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 600.
[0243] The multimedia component 608 includes a screen that provides an output interface between the electronic device 600 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, slides, and gestures on the touch panel. The touch sensors can not only sense the boundaries of a touch or slide action, but also detect the duration and pressure associated with the touch or slide action. In some embodiments, the multimedia component 608 includes a front-facing camera and / or a rear-facing camera. When the electronic device 600 is in an operating mode, such as a capture mode or a video mode, the front-facing camera and / or the rear-facing camera can receive external multimedia data. Each front-facing camera and the rear-facing camera can have a fixed optical lens system or have focal length and optical zoom capabilities.
[0244] The audio component 610 is used to output and / or input audio signals. For example, the audio component 610 includes a microphone (MIC) that is used to receive external audio signals when the electronic device 600 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals can be further stored in the memory 604 or transmitted via the communication component 616. In some embodiments, the audio component 610 also includes a speaker for outputting audio signals.
[0245] I / O interface 612 provides an interface between processing component 602 and peripheral interface modules, such as a keyboard, click wheel, buttons, etc. These buttons may include but are not limited to: a home button, volume buttons, a start button, and a lock button.
[0246] The sensor assembly 614 includes one or more sensors for providing various aspects of status assessment for the electronic device 600. For example, the sensor assembly 614 can detect the open / closed state of the electronic device 600, the relative positioning of components, such as the display and keypad of the electronic device 600. The sensor assembly 614 can also detect changes in the position of the electronic device 600 or a component of the electronic device 600, the presence or absence of user contact with the electronic device 600, the orientation or acceleration / deceleration of the electronic device 600, and temperature changes of the electronic device 600. The sensor assembly 614 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 614 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 614 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
[0247] The communication component 616 is used to facilitate wired or wireless communication between the electronic device 600 and other devices. The electronic device 600 can access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G or 5G), or a combination thereof. In an exemplary embodiment, the communication component 616 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 616 also includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
[0248] In an exemplary embodiment, the electronic device 600 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to implement a decentralized multi-party privacy intersection method provided in an embodiment of the present application.
[0249] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 604 including instructions. The instructions can be executed by the processor 620 of the electronic device 600 to perform the above method. For example, the non-transitory storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0250] Figure 9 7 is a logic block diagram of an electronic device 700 according to an embodiment of the present application. For example, the electronic device 700 may be provided as a server. Figure 9 The electronic device 700 includes a processing component 722, which further includes one or more processors, and a memory resource represented by a memory 732 for storing instructions executable by the processing component 722, such as an application. The application stored in the memory 732 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 722 is configured to execute instructions to perform a decentralized multi-party privacy intersection method provided in an embodiment of the present application.
[0251] The electronic device 700 may further include a power supply component 726 configured to perform power management of the electronic device 700, a wired or wireless network interface 750 configured to connect the electronic device 700 to a network, and an input / output (I / O) interface 758. The electronic device 700 may operate based on an operating system stored in the memory 732, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or the like.
[0252] An embodiment of the present application also provides a computer program product, including a computer program, which implements the decentralized multi-party privacy intersection method when executed by a processor.
[0253] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the application disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present application that follow the general principles of the present application and include common knowledge or customary techniques in the art not disclosed herein. The description and examples are to be considered as exemplary only, and the true scope and spirit of the present application are indicated by the following claims.
[0254] It should be understood that the present application is not limited to the exact structures described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.
Claims
1. A decentralized multi-party privacy intersection method, characterized in that: Applied to a querying end in a terminal cluster, the terminal cluster includes one querying end and N queried ends, the method comprising: Obtaining a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of each queried terminal; determining a joint mapping value from the joint data mapping table according to a first mapping position set corresponding to the target data; When the N-times target ciphertext value is the same as the joint mapping value, determining that the target data is common data of all terminals in the terminal cluster; wherein the target ciphertext value is obtained by encrypting the target data; The sum of the mapping values in the data mapping table of each queried terminal is equal to the data corresponding to each queried terminal; Sending a target public key to each queried end, so that each queried end encrypts its data mapping table according to the target public key, thereby obtaining an encrypted data mapping table corresponding to each queried end; wherein the data mapping table of the queried end is obtained by the queried end mapping the ciphertext value stored by the queried end according to the mapping function set, and the ciphertext value is obtained by the queried end encrypting the queried end's data according to the target function; The step of obtaining the joint data mapping table corresponding to the data of all queried terminals includes: Sending a query request to a target queried end, so that the target queried end accumulates the encrypted data mapping tables corresponding to the respective queried ends to obtain a joint data mapping table; Receive the joint data mapping table sent by the target queried end.
2. The method according to claim 1, characterized in that The determining, from the joint data mapping table according to the first mapping position set corresponding to the target data, a joint mapping value includes: Determine a first mapping position set corresponding to the target data according to the mapping function set; Based on the first mapping location set, obtaining a target mapping data set from the joint data mapping table; Accumulating each target mapping data in the target mapping data set to obtain joint ciphertext mapping data; The joint ciphertext mapping data is decrypted using the target private key corresponding to the target public key to obtain a joint mapping value.
3. The method according to claim 1, characterized in that The method further comprises: The target data is encrypted using a target function to obtain a target ciphertext value corresponding to the target data.
4. A decentralized multi-party privacy intersection method, characterized in that: Applied to the queried end, the method includes: Generate a data mapping table for the queried end based on the data set of the queried end; Generate a joint data mapping table according to the data mapping table of the queried end; Sending the joint data mapping table to the query end, so that the query end queries the target data of the query end according to the joint data mapping table; The sum of the mapping values in the data mapping table of the queried end is equal to the data corresponding to the queried end; The generating of the joint data mapping table according to the data mapping table of the queried end includes: Receiving the target public key sent by the querying end, and encrypting the data mapping table of the queried end by using the target public key to obtain an encrypted data mapping table; The encrypted data mapping tables of the respective queried terminals in the terminal cluster are obtained, and the encrypted data mapping tables of the respective queried terminals in the terminal cluster are summed to obtain a joint data mapping table.
5. The method according to claim 4, characterized in that Generating a data mapping table of the queried end according to the data set of the queried end includes: Encrypt the data in the data set of the queried end through the target function to obtain a ciphertext value set; Determine, based on the mapping function set, a second mapping position set corresponding to the data of each queried end in the data set of the queried end; A random number is stored at the empty value second mapping position of the data mapping table of the queried end, so that the cumulative value of the random numbers stored at all second mapping positions of the data mapping table of the queried end is equal to the ciphertext value corresponding to the second mapping position set.
6. A decentralized multi-party privacy intersection device, characterized in that: Applied to a querying end in a terminal cluster, the terminal cluster includes one querying end and N queried ends, the device includes: An acquisition module, configured to acquire a joint data mapping table corresponding to the data of all queried terminals; wherein the joint data mapping table is obtained by summing the data mapping tables of the respective queried terminals; a determination module, configured to determine a joint mapping value from the joint data mapping table according to a first mapping position set corresponding to the target data; a query module, configured to determine that the target data is common data of all terminals in the terminal cluster when the N-times target ciphertext value is the same as the joint mapping value; wherein the target ciphertext value is obtained by encrypting the target data; The sum of the mapping values in the data mapping table of each queried terminal is equal to the data corresponding to each queried terminal; The device is further configured to send a target public key to each queried end, so that each queried end encrypts the data mapping table of each queried end according to the target public key to obtain an encrypted data mapping table corresponding to each queried end; wherein the data mapping table of the queried end is obtained by the queried end mapping the ciphertext value stored by the queried end according to a mapping function set, and the ciphertext value is obtained by the queried end encrypting the queried end data according to the target function; The step of obtaining the joint data mapping table corresponding to the data of all queried terminals includes: Sending a query request to a target queried end, so that the target queried end accumulates the encrypted data mapping tables corresponding to the respective queried ends to obtain a joint data mapping table; Receive the joint data mapping table sent by the target queried end.
7. A decentralized multi-party privacy intersection device, characterized in that: Applied to the queried end, the device includes: A first generating module, configured to generate a data mapping table of the queried end according to the data set of the queried end; A second generating module, configured to generate a joint data mapping table according to the data mapping table of the queried end; a mapping table sending module, configured to send the joint data mapping table to a query end, so that the query end queries the target data of the query end according to the joint data mapping table; The sum of the mapping values in the data mapping table of the queried end is equal to the data corresponding to the queried end; The generating of the joint data mapping table according to the data mapping table of the queried end includes: Receiving the target public key sent by the querying end, and encrypting the data mapping table of the queried end by using the target public key to obtain an encrypted data mapping table; The encrypted data mapping tables of the respective queried terminals in the terminal cluster are obtained, and the encrypted data mapping tables of the respective queried terminals in the terminal cluster are summed to obtain a joint data mapping table.
8. An electronic device, characterized in that: include: processor; a memory for storing instructions executable by the processor; The processor is configured to execute the instructions to implement the method according to any one of claims 1 to 5.
9. A computer-readable storage medium, characterized in that When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to perform the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Multi-party safe intersection solving method and device, storage medium and equipment
CN113901425A