Joint graph processing method and device, computer equipment and program product

By using privacy-protected arrangement algorithms and homomorphic encryption technology in multi-party joint graph processing, the weight ciphertext sequence is constructed and updated, and the problem of efficiently realizing graph iterative updates while protecting private data is solved, and safe and efficient graph data processing is achieved.

CN119646836AActive Publication Date: 2025-03-18ALIPAY (HANGZHOU) INFORMATION TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411488935.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-23
Publication Date
2025-03-18
Estimated Expiration
2044-10-23

AI Technical Summary

Technical Problem

In the multi-party joint graph processing process, how to efficiently realize iterative update of graphs while protecting the privacy data of all parties, especially when the graph data contains highly sensitive privacy information.

Method used

By jointly implementing the privacy protection arrangement algorithm with the second party, the sequence number values ​​of each vertex in the first graph are obtained, and the weight sequence is constructed for homomorphic encryption, so as to realize the construction and update of the weight ciphertext sequence, and finally the updated vertex weight is obtained through decryption.

Benefits of technology

Without revealing vertex identification and weight plaintext, joint processing and iterative update of graph data between multiple parties is realized, reducing traffic and ensuring data privacy and security.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119646836A_ABST
    Figure CN119646836A_ABST
Patent Text Reader

Abstract

The invention provides a combined graph processing method, a first party and a second party respectively hold a first graph and a second graph, and the first party obtains a sequence number value of mapping of each first vertex of the first graph through a privacy protection arrangement algorithm jointly executed by the first party and the second party; the vertex serial number values representing different objects in the first graph and the second graph are different, and the vertex serial number values representing the same object are the same. Furthermore, a first weight sequence is constructed according to the serial number value and the weight of each first vertex, and a first joint operation is executed based on a second weight sequence constructed by the first participant and a second participant to obtain a first weight ciphertext sequence and a homomorphic ciphertext of the ith position corresponding to the weight of the vertex of the serial number value i in the first weight ciphertext sequence. And the first graph and the second party jointly execute a plurality of rounds of graph iteration by utilizing the edge of the first graph, the first weight ciphertext sequence is updated, and finally, the updated first weight ciphertext sequence is decrypted to obtain the updated weight of the first vertex.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] One or more embodiments of the present specification relate to the field of privacy computing technology, and in particular, to a method, apparatus, computer device, and program product for joint graph processing. Background Art

[0002] A graph is a data structure consisting of vertices and edges, and is widely used in social network analysis, financial transaction risk analysis, biochemistry, and other fields. In some scenarios, each vertex has a weight, and each edge connects two vertices on the graph. The edges in the graph may or may not have weights. For such graph data, the weights of the vertices in the graph can generally be updated according to the connection relationship and weights of the edges in the graph to analyze the graph.

[0003] In some technical scenarios, in order to obtain more comprehensive analysis results, multiple participants need to jointly use the locally held graph to participate in the process of iteratively updating vertex weights. However, the graph data held locally by each participant often contains private information. For example, many graph data use users or accounts as nodes, and the node weight represents a certain attribute or indicator data of the user. Among them, which user nodes are included in the graph, the connection relationship between user nodes, and the weight of user nodes (attribute value or indicator value) are all private data. In this case, different participants cannot send the information in the graph to other participants in plain text.

[0004] It is hoped that there will be an improved solution that can efficiently implement multi-party joint graph processing while protecting the privacy data of all parties. Summary of the invention

[0005] In view of this, one or more embodiments of the present specification provide a method, apparatus, computer device, and program product for jointly performing graph processing.

[0006] According to a first aspect of one or more embodiments of the present specification, a method for jointly performing graph processing is provided, involving a first party and a second party, each of which holds a first graph and a second graph as private data, and the method is applied to the first party, and the method includes:

[0007] By jointly executing a privacy-preserving permutation algorithm with the second party, a sequence number value obtained by mapping each first vertex in the first graph to the N sequence positions is obtained; the permutation algorithm makes the sequence number values ​​of vertices representing the same object in the first graph and the second graph the same, and the sequence number values ​​of vertices representing different objects different;

[0008] According to the sequence number value and weight of each first vertex, an N-bit first weight sequence is constructed;

[0009] Using the first weight sequence and the second weight sequence obtained by the second party, a first joint operation is performed to obtain an N-bit first weight ciphertext sequence, wherein the i-th bit corresponds to the homomorphic ciphertext of the weight of the vertex with sequence value i;

[0010] Using the edges in the first graph, jointly with the second party, perform several rounds of graph iterations to update the first weighted ciphertext sequence;

[0011] The updated first weight ciphertext sequence is decrypted to obtain the updated weight of the first vertex.

[0012] According to a second aspect of one or more embodiments of the present specification, a device for jointly performing graph processing is provided, involving a first party and a second party, each of which holds a first graph and a second graph as private data, and the device is applied to the first party, and the device includes:

[0013] a permutation module, configured to obtain, by jointly executing with the second party, a sequence number value obtained by mapping each first vertex in the first graph to the N sequence positions; the permutation algorithm ensures that the sequence number values ​​of vertices representing the same object in the first graph and the second graph are the same, and the sequence number values ​​of vertices representing different objects are different;

[0014] A sequence construction module, used to construct an N-bit first weight sequence according to the sequence number value and weight of each first vertex;

[0015] A first joint operation module, configured to perform a first joint operation using the first weight sequence and a second weight sequence obtained corresponding to the second party, to obtain an N-bit first weight ciphertext sequence, wherein the i-th bit corresponds to the homomorphic ciphertext of the weight of the vertex with sequence number i;

[0016] A sequence updating module, configured to utilize the edges in the first graph and jointly perform several rounds of graph iterations with the second party to update the first weighted ciphertext sequence;

[0017] The sequence decryption module is used to decrypt the updated first weight ciphertext sequence to obtain the updated weight of the first vertex.

[0018] According to a third aspect of the embodiments of this specification, a computer-readable storage medium is provided, on which computer instructions are stored. When the instructions are executed by a processor, the method for joint graph processing as described in the first aspect of the embodiments of this specification is implemented.

[0019] According to a fourth aspect of an embodiment of this specification, a computer device is provided, the computer device comprising:

[0020] processor;

[0021] a memory for storing processor-executable instructions;

[0022] The processor executes the executable instructions to implement the method for joint graph processing as described in the first aspect of the embodiment of this specification.

[0023] According to a fifth aspect of the embodiments of this specification, a computer program product is provided, which, when executed by a processor, implements the method for joint graph processing as described in the first aspect of the embodiments of this specification.

[0024] This specification proposes a method for joint graph processing, in which the first party and the second party hold the first graph and the second graph respectively, and the method is applied to the first party. The first party obtains the mapped serial values ​​of each first vertex of the first graph through a privacy-preserving permutation algorithm jointly executed with the second party, the size of all serial values ​​does not exceed N, and the serial values ​​of vertices representing different objects in the first graph and the second graph are different, and the serial values ​​of vertices representing the same object are the same. Further, a first weight sequence is constructed according to the serial values ​​and weights of each first vertex, and based on this, a second weight sequence constructed with the second participant is executed to perform a first joint operation to obtain a first weight ciphertext sequence, and the i-th position in the first weight ciphertext sequence corresponds to the homomorphic ciphertext of the weight of the vertex with serial value i. And using the edges of the first graph, several rounds of graph iterations are jointly executed with the second party to update the first weight ciphertext sequence, and finally the updated first weight ciphertext sequence is decrypted to obtain the updated weight of the first vertex.

[0025] In each iteration of this specification, there is no need to send edge information, only the weight ciphertext sequence needs to be communicated, which reduces the communication volume compared with the solutions in the related art. Moreover, the sequence number value obtained based on vertex mapping facilitates the construction of the weight ciphertext sequence. The sequence number value allows the two parties to determine which vertex each weight in the weight ciphertext sequence corresponds to, facilitating communication between the two parties. Moreover, by homomorphically encrypting the weights, the two parties cannot know any intermediate results during the communication process, thus ensuring security.

[0026] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present specification. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the specification and, together with the description, serve to explain the principles of the specification.

[0028] Figure 1 It is an application scenario diagram of this specification shown in accordance with an exemplary embodiment of this specification.

[0029] Figure 2It is a flowchart of a method for joint graph processing according to an exemplary embodiment of the present specification.

[0030] Figure 3 It is a schematic diagram of an arrangement algorithm shown in this specification according to an exemplary embodiment.

[0031] Figure 4 It is a block diagram of a device for jointly performing graph processing according to an exemplary embodiment of the present specification.

[0032] Figure 5 It is a hardware structure diagram of a computer device shown in this specification according to an exemplary embodiment. DETAILED DESCRIPTION

[0033] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with one or more embodiments of this specification. Instead, they are merely examples of devices and methods consistent with some aspects of one or more embodiments of this specification as detailed in the appended claims.

[0034] It should be noted that: in other embodiments, the steps of the corresponding method are not necessarily performed in the order shown and described in this specification. In some other embodiments, the steps included in the method may be more or less than those described in this specification. In addition, a single step described in this specification may be decomposed into multiple steps for description in other embodiments; and multiple steps described in this specification may be combined into a single step for description in other embodiments.

[0035] In the scenario where two parties jointly conduct graph analysis, both parties have their own graphs, and some vertices in the two graphs overlap, and some vertices may not overlap. For overlapping vertices, the weights and connection relationships of these vertices in the two graphs will be different. When two parties conduct graph analysis, the vertex weights, edge information, number of vertices, and number of overlapping vertices of each party's graph are all private information that cannot be known by the other party.

[0036] For example, in the field of financial transaction risk analysis, the two participants may be different transaction data holders (such as banks, financial institutions, etc.), vertices can represent different accounts, and edges can represent transfers between two accounts. The weight of the vertex can represent the transaction risk information of the account. The two participants jointly iterate the vertex weights, and can combine the information of the two graphs to obtain more accurate vertex weights, so as to better analyze the user's transaction risks.

[0037] In the process of two parties jointly processing the graph, highly sensitive information such as transaction information cannot be directly transferred between different parties in plain text. In order to ensure the security of private information, the two parties usually jointly perform private computing to complete the graph processing.

[0038] Privacy computing is a computation performed by multiple parties. Each party provides certain input data, and the two parties jointly calculate the output data through the privacy computing algorithm. During the calculation process, cryptography and other means are used to ensure that each party cannot obtain the privacy information of other parties. Through privacy computing, two parties can process and calculate on the merged graph data while ensuring that the input privacy data and intermediate results will not be leaked.

[0039] When applying privacy computing methods in the process of joint analysis and processing of graphs, it is necessary to ensure that the vertex weights of the graph, the connection relationships and weights of the edges, the total number of vertices, and the overlapping vertices between the two participants are not leaked.

[0040] In order to realize the joint iterative update of the graph while ensuring the security of the above data, the following methods exist in the related art:

[0041] First, we implement two-party privacy graph analysis based on obfuscated circuits, and implement two bitonic sorts and two parallel scans in each iteration. Although the security of privacy information can be guaranteed in the above process, the computational complexity of each iteration communication is high due to the two bitonic sorts.

[0042] The second is to achieve it through secret sharing, propagating the secret sharing shards of edges and vertices in each iteration, and completing the iterative update based on this. However, although the above method is better than the first method, its complexity is still high.

[0043] Based on this, this specification proposes a method for joint graph processing, in which the first party and the second party hold the first graph and the second graph respectively, and the method is applied to the first party. The first party obtains the mapped serial values ​​of each first vertex of the first graph through a privacy-preserving permutation algorithm jointly executed with the second party, the size of all serial values ​​does not exceed N, and the serial values ​​of vertices representing different objects in the first graph and the second graph are different, and the serial values ​​of vertices representing the same object are the same. Further, a first weight sequence is constructed according to the serial values ​​and weights of each first vertex, and based on this, a second weight sequence constructed with the second participant is executed to perform a first joint operation to obtain a first weight ciphertext sequence, and the i-th position in the first weight ciphertext sequence corresponds to the homomorphic ciphertext of the weight of the vertex with serial value i. And using the edges of the first graph, several rounds of graph iterations are jointly executed with the second party to update the first weight ciphertext sequence, and finally the updated first weight ciphertext sequence is decrypted to obtain the updated weight of the first vertex.

[0044] In each iteration of this specification, there is no need to send edge information, only the weight ciphertext sequence needs to be communicated, which reduces the communication volume compared with the solutions in the related art. Moreover, the sequence number value obtained based on vertex mapping facilitates the construction of the weight ciphertext sequence. The sequence number value allows the two parties to determine which vertex each weight in the weight ciphertext sequence corresponds to, facilitating communication between the two parties. Moreover, by homomorphically encrypting the weights, the two parties cannot know any intermediate results during the communication process, thus ensuring security.

[0045] Next, a method for joint graph processing shown in this specification will be described.

[0046] The application scenarios of this method are as follows Figure 1 As shown, the method involves a first party and a second party, the first party and the second party respectively holding a first graph and a second graph as private data. Figure 1 In the example, the first graph of the first party includes four vertices: b, c, r, and y, and the second graph of the second party includes three vertices: b, j, and y. The weights of each vertex in the first and second graphs, the connection relationship and weights of the edges between the vertices, etc. are all private data. The first graph and the second graph include at least one overlapping vertex, and correspondingly, the two parties may include non-overlapping vertices. The two parties jointly perform graph processing, that is, update the weights of the vertices in the graphs in combination with the graphs of the two parties.

[0047] The following description will take the method performed by the first party as an example. It is easy to understand that the method performed by the first party and the second party during the update process is the same. Here, either party can perform the following method as the first party, that is, the second party also performs the same method accordingly. Figure 2 As shown, the following steps are included:

[0048] Step 101 , by jointly executing a privacy-preserving permutation algorithm with a second party, obtain the sequence number value obtained by mapping each first vertex in the first graph to N sequence positions.

[0049] The arrangement algorithm ensures that the serial number values ​​of the vertices representing the same object in the first graph and the second graph are the same, and the serial number values ​​of the vertices representing different objects are different.

[0050] Correspondingly, the second party also obtains the sequence number value mapped to the N sequence positions of each second vertex in the second graph by jointly executing the privacy-preserving permutation algorithm with the first party.

[0051] Specifically, vertex mapping is achieved through this step, and vertex mapping enables each participant to only obtain the serial number value of the vertex in its own graph, and for the serial number value, the serial number value corresponding to each object is unique (that is, the serial number value of the vertex representing the same object in the first graph and the second graph is the same, and the serial number values ​​representing different vertices are different), and the serial number value of each vertex does not exceed N. This makes it convenient to construct the weighted ciphertext sequence later. Specifically, the length of the weighted ciphertext sequence is N, and the i-th bit is the weight of the vertex with serial number value i.

[0052] The two parties can easily determine the weights of their own vertices through the weight ciphertext sequence and the serial number values ​​of their own vertices without revealing the vertex identifiers. Moreover, since the serial number values ​​of the other party's vertices are unknown and the weight ciphertext sequence is encrypted, it is also impossible to know which vertices the other party has and the weights of each vertex through the weight ciphertext sequence.

[0053] In addition, since the sequence number value is only obtained by mapping according to the permutation algorithm and has nothing to do with the specific weight, it is also impossible to know any private information, such as the weight of the vertex, through the sequence number value alone.

[0054] The length of N needs to be greater than the total number of objects represented by the vertices in the first graph and the second graph. As for the method of obtaining the number of N, N can be a relatively large number generated randomly.

[0055] In addition, since the weighted ciphertext sequence needs to be communicated in the subsequent iteration step, the communication volume can be reduced by reducing the size of N. For example, the N is determined according to the number of vertices of the first party and the second party, and is linearly positively correlated with the maximum number of vertices of the first party and the second party.

[0056] Furthermore, in some scenarios, the number of vertices owned by each participant is also private data. Therefore, N can be determined based on the maximum value of the logarithmic values ​​of the number of vertices of the first party and the second party rounded up. Since the logarithmic values ​​are rounded up, only a rough range of the number of vertices of the first party and the second party can be known, and the specific size of the number of vertices cannot be known, thus ensuring data privacy.

[0057] Under the above implementation ideas, the specific size of N can be determined according to formula (1):

[0058] In the above formula (1), |V0| represents the number of vertices on the first side, and |V1| represents the number of vertices on the second side. Represents the value obtained by taking the logarithm of the number of vertices of the first party to the base 2 and rounding it up. Correspondingly, Represents the value obtained by taking the base 2 logarithm of the number of vertices of the second party and rounding it up. Representative and The maximum value in .

[0059] In the above formula, N is greater than or equal to twice max(|V0|,|V1|), which ensures that N is greater than the sum of the number of vertices in the first graph and the second graph, and greater than the sum of the number of objects represented by the vertices in the first graph and the second graph. and This ensures that the number of vertices on the first and second sides is not leaked during the calculation.

[0060] As for the specific implementation of step 101, the vertex mapping can be achieved by using an oblivious mapping structure method, or by executing a joint sorting protocol based on a private intersection PSI protocol.

[0061] In addition, this specification also provides a vertex mapping method with lower complexity.

[0062] Specifically, step 101 may include: obtaining a first vertex array containing vertex identifiers corresponding to the first graph; performing a joint merge with a second vertex array held by a second participant to obtain a third vertex array; for the third vertex array, generating a sequence of serial number values ​​corresponding one-to-one to the elements of the third vertex array by jointly executing a privacy-preserving random permutation generation algorithm with the second participant; and determining the serial number values ​​of each first vertex in N sequence positions based on the serial number value sequence.

[0063] Specifically, through the Secure Multi-Party Computation (MPC) method, the first vertex array and the second vertex array corresponding to the two parties are merged to obtain a third vertex array including all vertices of the first party and the second party. Then, a random permutation generation algorithm is performed on the third vertex array to generate serial number values ​​corresponding to each vertex.

[0064] It should be noted that when generating random permutations, it is necessary to ensure that the serial number values ​​of vertices with the same vertex identifier are the same in the final serial number values ​​obtained by the first party and the second party. To achieve this goal, it is possible to check whether there are identical vertex identifiers while generating random permutations, and assign the same serial number value to the identical vertex identifiers.

[0065] In addition, the above objectives can also be achieved through the following methods.

[0066] Specifically, first, the first vertex array and the second vertex array each include N elements, each element includes a vertex identifier and a number value selected from binary values, and each vertex corresponds to two adjacent elements with the same vertex identifier and different number values.

[0067] like Figure 3 As shown, the first vertex array is shown as A0, and the second vertex array is shown as A1. One element corresponds to a vertical column. The upper row of the vertical column represents the vertex identifier, and the lower row represents the number value. Figure 1 It can be seen that each vertex corresponds to two adjacent elements, and the vertex identifiers of the two elements are the same, but the number values ​​are different.

[0068] The binary values ​​can be 0 and 1. Figure 3 That is, the binary values ​​are 0 and 1.

[0069] In addition, in some cases, the number of vertices in the first or second party is less than N / 2. In this case, the missing elements can be filled with random vertex information. Figure 3 In the example, the vertex z of the second party is the randomly generated vertex information.

[0070] The first vertex array and the second vertex array may be sorted according to vertex identifiers and number values ​​(for example, Figure 3 This makes it easier to sort the subsequent steps.

[0071] By setting the first vertex array and the second vertex array in the above-mentioned form, in the subsequent execution of the random arrangement generation algorithm, in conjunction with other processing flows, there is no need to detect whether there are two identical vertices, thereby ensuring that the serial number values ​​received by the first participant and the second participant are the same for vertices representing the same object.

[0072] Corresponding to the structure of the above-mentioned vertex array, the process of performing the joint merge can be: by jointly executing a privacy-preserving sorting algorithm with the second party, the first vertex array and the second vertex array are sorted according to vertex identifiers and number values ​​to obtain a third vertex array, wherein elements with the same vertex identifier and number value are arranged adjacent to each other.

[0073] That is, the first vertex array and the second vertex array are sorted and merged through the sorting algorithm. Figure 3 As shown, A is the third vertex array.

[0074] In the case where both the first vertex array and the second vertex array are sorted arrays, in order to speed up the sorting speed, the sorting algorithm may be an odd-even merge algorithm. That is, both parties may call the privacy-preserving odd-even merge process to merge the first vertex array and the second vertex array into a third vertex array in order.

[0075] Compared with other sorting algorithms, the odd-even merge algorithm does not need to sort all the third vertex arrays to be merged. It only needs to sort the two arrays that have been sorted, which can improve processing efficiency.

[0076] In the above case, for the third vertex array, both parties can call the privacy-preserving random permutation generation algorithm to generate a sequence of serial number values, where the values ​​of the 2i-th and 2i-1-th bits in the sequence are the same. The sequence of serial number values ​​can be as follows: Figure 3 As shown in L. Through the random permutation generation algorithm, it can be ensured that the sequence value of the generated random number does not exceed half of the length of A, that is, N, thereby ensuring that the sequence values ​​of all mappings are positive integers not exceeding N.

[0077] Correspondingly, the determining of the sequence value of each first vertex in the N sequence positions based on the sequence value sequence includes: for the sequence value sequence, jointly executing the inverse process of the sorting algorithm with the second party to obtain a first subsequence value sequence. The sequence value of a specific position in the first subsequence is used as the sequence value of each first vertex; the specific position is an odd position or an even position agreed with the second party.

[0078] By jointly invoking the inverse process of the privacy-preserving odd-even merge with the second party, the first subsequence number value sequence can be obtained, and correspondingly, the second party can obtain the second subsequence number value sequence. The first subsequence number value sequence and the second subsequence number value sequence can be as follows Figure 3 As shown in L0 and L1.

[0079] Then both parties convert the even-numbered elements of their sub-sequence value sequence into plain text, and obtain the sequence value of the vertex mapping held by their own party; or both parties convert the odd-numbered elements of their sub-sequence value sequence into plain text, and obtain the sequence value of each vertex mapping of their own party. Figure 3 As shown, Figure 3 Here v represents the vertex identifier, p(v) represents the sequence number value, the first party is P0, and the second party is P1. Both parties use the values ​​of the even positions in the sub-sequence number value sequence as mapping values.

[0080] pass Figure 3It can be seen that among the serial numbers obtained by each participant, the serial numbers of vertices with the same vertex identifier are the same, for example, the serial number value of vertex b obtained by both parties is 8. Moreover, the serial numbers of vertices representing different objects do not overlap.

[0081] Next, the rationality of the above method will be explained. In the above method, a sorting algorithm is used to arrange vertices with the same vertex identifiers in the third vertex array A together, and elements with the same number values ​​are arranged together. For example, the first party and the second party both have vertex b. In the third vertex array A, the elements corresponding to vertex b in the first vertex array A0 and the elements corresponding to vertex b in the second vertex array A1 are arranged together. And because the third vertex array A is also sorted according to the number value, the four elements corresponding to b in the third vertex array A belong to A0, A1, A0, A1 respectively.

[0082] When calling the random permutation generation algorithm, it is ensured that the serial number values ​​generated by two adjacent elements are the same. Although this causes the overlapping vertices of the two participants to generate two mapped serial number values, for example, b generates two serial number values ​​4 and 8. However, through the sorting algorithm above, each participant includes elements corresponding to the two serial number values. Further, through the inverse process of the odd-even merge algorithm, each participant has two serial number values ​​for vertex b. Finally, by both participants taking the odd positions in the sub-sequence value sequence, or both taking the even positions in the sub-sequence value sequence, it is ensured that the serial number values ​​of the two participants for the vertices representing the same object are the same.

[0083] Through the above algorithm, the serial number value corresponding to each vertex is generated with less complexity. In addition, there is no leakage of any information in the above process (such as which vertices of the two participants overlap), only the and Ensures data security.

[0084] Back to Figure 3 After both parties obtain the mapping sequence number values ​​of their own vertices through the above various vertex mapping methods, they can then proceed to the subsequent weight sequence construction and update processing. For the first party in the example, in step 103, an N-bit first weight sequence is constructed based on the sequence number values ​​and weights of each first vertex.

[0085] Step 105: Perform a first joint operation using the first weight sequence and the second weight sequence correspondingly obtained by the second party to obtain an N-bit first weight ciphertext sequence.

[0086] The i-th bit corresponds to the homomorphic ciphertext of the weight of the vertex with sequence value i.

[0087] Correspondingly, the second party also constructs a second weight sequence based on the serial number values ​​and weights of each second vertex. Similarly, the second weight sequence is used together with the first weight sequence obtained by the first party to perform a first joint operation to obtain an N-bit second weight ciphertext sequence.

[0088] Specifically, in step 103 and step 105, the initial weight of the joint interaction between the two parties is determined through the interaction between the two parties.

[0089] In order to protect privacy, the plaintext corresponding to the first weight ciphertext sequence and the second weight ciphertext sequence can be the same, but the encryption keys of the two are different. The first weight ciphertext sequence can be obtained by encrypting the public key of the second party, and the second weight ciphertext sequence can be obtained by encrypting the public key of the first party, so that it can be ensured that neither party can decrypt the weight ciphertext sequence held by itself and obtain the privacy data of the intermediate result.

[0090] As for the specific implementation method of step 103, when constructing the weight sequence, it can be constructed according to the sequence number value obtained above. A sequence structure or an empty sequence with a length of N bits can be constructed, and the i-th bit is filled with the weight of the vertex with the sequence number value i. For example Figure 3 As shown in the serial number value, in the first weight sequence constructed by the first party, the second position can be filled with the weight of vertex y, the fifth position can be filled with the weight of vertex c, the seventh position can be filled with the weight of vertex r, and the eighth position can be filled with the weight of vertex b.

[0091] In this way, the two parties construct the corresponding weight sequence through the sequence number value during the interaction, ensuring that the two parties can obtain the weight ciphertext sequence without leaking the intersection of the vertices of the first graph and the second graph.

[0092] The above process can be represented by formula (2):

[0093]

[0094] The above b represents the identifier of the participating party. For example, the identifier b corresponding to the first party is 0, and the identifier b corresponding to the second party is 1. represents the weight sequence constructed by the b-th party at the 0th iteration (i.e., the initial value), represent The p(v)th position of Represents the weight of the vertex identified as v in the b-th party at the 0th iteration (i.e., the initial value).

[0095] In addition, for other positions in the first weight ciphertext sequence, default values ​​can be used to fill them. In other words, step 103 includes: for any first vertex, its weight in the first graph is filled into the position corresponding to its serial number value in the N-bit sequence structure; after filling each first vertex, the unfilled positions in the sequence structure are filled with default values.

[0096] The default value may be a value that does not affect subsequent graph updates. Since the values ​​and edges in the weighted ciphertext sequence are needed to update the weighted ciphertext sequence in the subsequent local update process, the default value needs to not affect the update in order not to affect subsequent calculations. For example, the default value may be 0.

[0097] As for the specific implementation of step 105, step 105 needs to ensure that in this process, the two participants cannot obtain the plain text of the weight of any vertex. Here, the implementation of step 105 will be described through an embodiment, which does not limit this specification.

[0098] Specifically, the two parties can first obtain their respective total shards based on the obtained shards of the first weight sequence and the second weight sequence through a secret sharing protocol. The sum of the two total shards is the weight required for the two parties to update the graph, but in order to protect data privacy, the plaintext sum of the two total shards cannot be directly obtained. Therefore, the secret sharing to homomorphic ciphertext protocol can be used to obtain the first weight ciphertext sequence and the second weight ciphertext sequence held by the first party and the second party respectively through the two total shards.

[0099] In other words, the first party performs the following steps in the first join operation:

[0100] Splitting the first weight sequence into first-party shards and second-party shards through secret sharing;

[0101] sending the second party fragments of the first weight sequence to the second party, and receiving the first party fragments of the second weight sequence sent by the second party;

[0102] Determine a first total shard according to first party shards of each of the first weight sequence and the second weight sequence;

[0103] The first total shard and the second total shard held by the second party are used to jointly call a first conversion protocol of secret sharing to homomorphic encryption to obtain the first weighted ciphertext sequence.

[0104] The above method for determining the first total fragment can be determined according to the requirements of graph processing. For example, for the vertices that overlap between the first graph and the second graph, in some cases, the weight used for updating needs to be determined based on the sum of the weights of the two parties; in some cases, the weight of a certain participant needs to be used as the basis; in some cases, the maximum or minimum value of the two weights needs to be used as the basis.

[0105] The following will take the method of determining the first total slice as an example of determining the weight used for updating by the sum of the two weights. Specifically, determining the first total slice includes: calculating the sum of the first slices of the first weight sequence and the second weight sequence as the first total slice.

[0106] Correspondingly, the second participant also obtains the second total shard through the above method.

[0107] A specific example of the first conversion protocol will be shown below, but the following example does not limit the present specification.

[0108] Specifically, the process by which the first party obtains the first weighted ciphertext sequence through the first conversion protocol may include: performing homomorphic encryption on the first total shard using the public keys of the first party and the second party respectively to obtain a first ciphertext and a second ciphertext; sending the first ciphertext to the second party, and receiving a third ciphertext sent by the second party; the third ciphertext is obtained by the second party performing homomorphic encryption on the second total shard using the public key of the second party; and determining the first weighted ciphertext sequence based on the homomorphic sum of the second ciphertext and the third ciphertext.

[0109] Correspondingly, the second participant also uses the public keys of the first party and the second party to homomorphically encrypt the second total shard to obtain the fourth ciphertext and the third ciphertext. The third ciphertext is sent to the other party, and the first ciphertext sent by the other party is received. The second weighted ciphertext sequence is determined based on the homomorphic sum of the first ciphertext and the fourth ciphertext.

[0110] That is, the two parties use their public keys to homomorphically encrypt their respective total shards, and send the data encrypted with their own public keys to the other party, so that either party can use the homomorphic sum of the two total shards homomorphically encrypted with the other party's public key to determine the corresponding weighted ciphertext sequence.

[0111] Step 107: Utilize the edges in the first graph and jointly perform several rounds of graph iterations with the second party to update the first weighted ciphertext sequence.

[0112] Correspondingly, the second party also uses the edges in the second graph to jointly perform several rounds of graph iterations with the first party to update the second weighted ciphertext sequence.

[0113] Specifically, the two participants each use the edges of the graph held locally to locally update the weighted ciphertext sequence, and further cooperate with the other party based on the local weighted ciphertext sequence and the other party's locally updated weighted ciphertext sequence, combining the values ​​in the two weighted ciphertext sequences to obtain the weighted ciphertext sequence used for the next round of updates.

[0114] To perform step 107, each party may establish a local adjacency list. Specifically, the first party and the second party may respectively establish a local adjacency list for a known set of edges. The specific method for establishing an adjacency list is the same as that in the related art and will not be repeated here. The connection information between the edges can be represented by the adjacency list. The establishment of the adjacency list does not require interaction between multiple parties. Among them, the adjacency list can also be established before performing step 103, and this specification does not limit the timing of establishing the adjacency list.

[0115] After the adjacency table is established, the adjacency table can be used to update the weighted ciphertext sequence. After the update, the weighted ciphertext sequence can be integrated and updated using a similar approach as in step 105. For example, this can be achieved through secret sharing and homomorphic encryption.

[0116] Next, the specific implementation method of step 107 will be described by taking the first party as an example through a specific embodiment.

[0117] Step 107 may include: first, the first party locally updates the first weighted ciphertext sequence using the edges in the first graph to obtain a first incremental ciphertext sequence.

[0118] The local update process may be similar to the update method in the related art, and this specification does not limit the local update method.

[0119] An example of local update can be shown as formula (3):

[0120]

[0121] Represents the weight obtained by node v’s local update in the tth local update of participant b. b represents the adjacency list of party b, (u,v,w) represents the edge from vertex u to vertex v, and the weight of this edge is w, w t-1 (u) represents the weight of vertex u after the t-1th iteration. G and f S Represents the gather function and scatter function in the gather-apply-scatter (GAS) model. Can represent in f G The operation in formula (3) is a homomorphic operation performed in the form of homomorphic ciphertext. The weight update of each node obtained in this way constitutes the first / second incremental ciphertext sequence.

[0122] Then, the first party uses the above-mentioned first incremental ciphertext sequence and the second incremental ciphertext sequence corresponding to the second party to perform the second joint operation to obtain the first weighted ciphertext sequence after this round of update. The implementation ideas of the second joint operation are similar to those of the first joint operation, both of which realize the value of the weighted ciphertext sequence of the two parties while ensuring that the first party and the second party do not obtain any plaintext intermediate results.

[0123] In an optional implementation, the second join operation performed by the first party may include the following process.

[0124] 1) By calling the second conversion protocol of homomorphic encryption to secret sharing, the first incremental ciphertext sequence and the second incremental ciphertext sequence are obtained, each of which corresponds to the first party incremental fragmentation of the plaintext on the first party.

[0125] In a specific implementation of the second conversion protocol, the first party first homomorphically adds each value in the first incremental ciphertext sequence to a set of random numbers to obtain a ciphertext E1. The ciphertext E1 is sent to the second party, and the plaintext corresponding to the ciphertext E1 sent by the second party is received. The above set of random numbers is subtracted from the plaintext to obtain the plaintext of the first incremental ciphertext sequence, and two fragments of the plaintext of the first incremental ciphertext sequence are obtained through secret sharing. Similarly, the second party executes the above method to obtain two plaintext fragments corresponding to the second incremental ciphertext sequence.

[0126] 2) Determine the first party shard of the total weight of this round based on the first party shard of the total weight of the previous round and the first party incremental shard.

[0127] For example, the total weight W of the previous round can be t-1 The first-party shard [W t-1 ]0, the sum of the first incremental fragments corresponding to the first incremental ciphertext sequence and the second incremental ciphertext sequence is taken as the total weight W of this round t The first-party shard [W t ]0. The first-party shard storing the total weight of this round [W t ]0, for the next iteration.

[0128] 3) Using the first-party shard of the total weight of this round [W t ]0, and the second party's shard of the total weight of this round held by the second party [W t ]1. Jointly call the first conversion protocol of secret sharing to homomorphic encryption to obtain the first weighted ciphertext sequence after this round of update. The description of the first conversion protocol is detailed in the previous text and will not be repeated here.

[0129] That is, firstly, the second conversion protocol of homomorphic encryption to secret sharing is used to obtain the incremental sharding of the weight increment generated by the local update, and the sharding value of the total weight obtained by the incremental sharding and the sharding value of the total weight obtained by the previous round of update is used to obtain the sharding value of the total weight of this iteration). Then, the first conversion protocol mentioned in step 105 is used to obtain the first weight ciphertext sequence after the current round of update through the sharding of the total weight of the two parties in this round.

[0130] It should be understood that step 107 generally needs to be performed iteratively for multiple times. The number of iterations is usually related to the vertex aggregation order and can be a preset value.

[0131] After performing several iterations of updating, in step 109, the updated first weight ciphertext sequence is decrypted to obtain the updated weight of the first vertex.

[0132] Specifically, the final update result of the vertex can be obtained through multiple iterations in step 107. The updated first weight ciphertext sequence is decrypted to obtain the updated plaintext of the vertex at the corresponding position.

[0133] As mentioned above, in order to ensure security, the first weighted ciphertext sequence held by the first party during the update process is encrypted by the public key of the second party, so the first weighted ciphertext sequence needs to be decrypted using the second party's key. At the same time, the second party cannot know the plaintext corresponding to the first weighted ciphertext sequence during decryption.

[0134] Next, a method for achieving the above requirements will be described through an embodiment, which does not limit the present specification.

[0135] Specifically, step 109 may include: homomorphically adding the ciphertext values ​​in the local first weight ciphertext sequence and a set of random numbers to obtain a fifth ciphertext; sending the fifth ciphertext to the second party, and receiving the plaintext corresponding to the fifth ciphertext sent by the second party; subtracting the set of random numbers from the plaintext to obtain the updated weight.

[0136] This step 109 is similar to the decryption part in the second conversion protocol above. The second party can only obtain the plain text corresponding to the sum of the weight and the random number, but cannot obtain the weight itself, thus ensuring security.

[0137] In addition, in order to ensure security, the first weighted ciphertext sequence can be decrypted as a whole during decryption, or several ciphertext weights owned by the first party, as well as The first party sends the first party a random value encrypted with the second party's public key to the second party for decryption. This ensures that the number of vertices on the first party is not known to the second party.

[0138] Corresponding to the embodiment of the aforementioned method, this specification also provides an embodiment of an apparatus for jointly performing graph processing and a computer device used therein.

[0139] like Figure 4 As shown, Figure 4 This is a block diagram of a device for jointly performing graph processing according to an exemplary embodiment of the present specification, involving a first party and a second party, which respectively hold a first graph and a second graph as private data, and the device is applied to the first party, and the device includes:

[0140] The arrangement module 410 is used to obtain the sequence number value obtained by mapping each first vertex in the first graph to the N sequence positions by jointly executing a privacy-preserving arrangement algorithm with the second party; the arrangement algorithm makes the sequence number values ​​of the vertices representing the same object in the first graph and the second graph the same, and the sequence number values ​​of the vertices of different objects different;

[0141] A sequence construction module 420, configured to construct an N-bit first weight sequence according to the sequence number value and weight of each first vertex;

[0142] A first joint operation module 430 is used to perform a first joint operation using the first weight sequence and the second weight sequence obtained by the second party to obtain an N-bit first weight ciphertext sequence, wherein the i-th bit corresponds to the homomorphic ciphertext of the weight of the vertex with sequence value i;

[0143] A sequence updating module 440, configured to utilize the edges in the first graph and jointly perform several rounds of graph iterations with the second party to update the first weighted ciphertext sequence;

[0144] The sequence decryption module 450 is used to decrypt the updated first weight ciphertext sequence to obtain the updated weight of the first vertex.

[0145] In an optional implementation, the sequence construction module 420 is specifically used to fill, for any first vertex, its weight in the first graph into the position corresponding to its serial number value in the N-bit sequence structure; after filling each first vertex, fill the unfilled position in the sequence structure with a default value.

[0146] In an optional implementation, the first joint operation module 430 includes:

[0147] A secret sharing submodule 431 (not shown in the figure), configured to split the first weight sequence into first-party fragments and second-party fragments by secret sharing;

[0148] A fragment sending submodule 432 (not shown in the figure), configured to send the second party fragments of the first weight sequence to the second party, and receive the first party fragments of the second weight sequence sent by the second party;

[0149] A total shard determination submodule 433 (not shown in the figure), configured to determine a first total shard according to the first side shards of each of the first weight sequence and the second weight sequence;

[0150] The first conversion protocol calling submodule 434 (not shown in the figure) is used to use the first total shard and the second total shard held by the second party to jointly call the first conversion protocol of secret sharing to homomorphic encryption to obtain the first weight ciphertext sequence.

[0151] In an optional implementation manner, the total fragmentation determination submodule 433 is specifically configured to calculate the sum of the first party fragmentations of the first weight sequence and the second weight sequence as the first total fragmentation.

[0152] In an optional implementation, the first conversion protocol calls submodule 434, which is specifically used to homomorphically encrypt the first total shard using the public keys of the first party and the second party respectively to obtain a first ciphertext and a second ciphertext; send the first ciphertext to the second party, and receive a third ciphertext sent by the second party; the third ciphertext is obtained by the second party homomorphically encrypting the second total shard using the public key of the second party; determine the first weighted ciphertext sequence based on the homomorphic sum of the second ciphertext and the third ciphertext.

[0153] In an optional implementation, the arrangement module 410 includes:

[0154] A vertex array acquisition submodule 411 (not shown in the figure) is used to acquire a first vertex array including vertex identifiers corresponding to the first graph;

[0155] A joint merging submodule 412 (not shown in the figure) is used to perform a joint merging with the second vertex array held by the second participant to obtain a third vertex array;

[0156] A sequence value sequence generation submodule 413 (not shown in the figure), for generating a sequence of sequence values ​​corresponding to the elements of the third vertex array one by one by jointly executing a privacy-preserving random permutation generation algorithm with the second participant for the third vertex array;

[0157] The sequence number determination submodule 414 (not shown in the figure) is used to determine the sequence number value of each first vertex in the N sequence positions based on the sequence number value sequence.

[0158] In an optional implementation, the first vertex array and the second vertex array each include N elements, each element includes a vertex identifier and a number value selected from binary values, and each vertex corresponds to two adjacent elements with the same vertex identifier and different number values;

[0159] Correspondingly, the joint merging submodule 412 is specifically used to: jointly execute a privacy-preserving sorting algorithm with the second party to sort the first vertex array and the second vertex array according to vertex identifiers and number values ​​to obtain a third vertex array, wherein elements with the same vertex identifiers and number values ​​are arranged adjacently;

[0160] Correspondingly, the serial number value determination submodule 414 is specifically used for: for the serial number value sequence, obtaining a first sub-sequence number value sequence by jointly executing the inverse process of the sorting algorithm with the second party; using the serial number value of a specific position in the first sub-sequence as the serial number value of each first vertex; the specific position is an odd position or an even position agreed with the second party; the values ​​of the 2ith bit and the 2i-1th bit in the serial number value sequence are the same.

[0161] In an optional implementation, the binary value is 0 and 1, and the sorting algorithm is an odd-even merge algorithm.

[0162] In an optional implementation, N is determined according to the number of vertices of the first party and the second party, and is linearly positively correlated with the maximum value of the number of vertices of the first party and the second party.

[0163] In an optional implementation, N is determined according to the maximum value of the logarithmic values ​​of the numbers of vertices of the first side and the second side rounded upwards.

[0164] In an optional implementation, the sequence updating module 440 includes:

[0165] A local update submodule 441 (not shown in the figure), configured to locally update the first weighted ciphertext sequence using the edges in the first graph to obtain a first incremental ciphertext sequence;

[0166] The second joint operation submodule 442 (not shown in the figure) is used to use the first incremental ciphertext sequence and the second incremental ciphertext sequence corresponding to the second party to perform a second joint operation to obtain the first weighted ciphertext sequence after this round of update.

[0167] In an optional implementation, the second joint operation submodule 442 is specifically used to obtain the first incremental ciphertext sequence and the second incremental ciphertext sequence, each corresponding to the first party incremental shard of the plaintext on the first party, by calling the second conversion protocol from homomorphic encryption to secret sharing; determine the first party shard of the total weight of this round according to the first party shard of the total weight of the previous round and the first party incremental shard; use the first party shard of the total weight of this round and the second party shard of the total weight of this round held by the second party to jointly call the first conversion protocol from secret sharing to homomorphic encryption to obtain the first weight ciphertext sequence after update in this round.

[0168] In an optional implementation, the sequence decryption module 450 is specifically used to: homomorphically add the ciphertext values ​​in the local first weight ciphertext sequence and a group of random numbers to obtain a fifth ciphertext; send the fifth ciphertext to the second party, and receive the plaintext corresponding to the fifth ciphertext sent by the second party; subtract the group of random numbers from the plaintext to obtain the updated weight.

[0169] The implementation process of the functions and effects of each module in the above-mentioned device is specifically described in the implementation process of the corresponding steps in the above-mentioned method, which will not be repeated here.

[0170] For the device embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The device embodiment described above is only schematic, wherein the modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical modules, that is, they may be located in one place, or they may be distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this specification. A person of ordinary skill in the art can understand and implement it without paying creative labor.

[0171] like Figure 5 As shown, Figure 5 A hardware structure diagram of a computer device in which an apparatus for jointly performing graph processing in an embodiment is located is shown, and the device may include: a processor 1010, a memory 1020, an input / output interface 1030, a communication interface 1040, and a bus 1050. The processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040 are connected to each other in communication within the device through the bus 1050.

[0172] The processor 1010 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification. The processor implements the above method by running executable instructions.

[0173] The memory 1020 for storing processor executable instructions can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 1020 can store an operating system and other application programs. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program codes are stored in the memory 1020.

[0174] The input / output interface 1030 is used to connect the input / output module to realize information input and output. The input / output module can be configured in the device as a component (not shown in the figure), or it can be externally connected to the device to provide corresponding functions. The input device may include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output device may include a display, a speaker, a vibrator, an indicator light, etc.

[0175] The communication interface 1040 is used to connect a communication module (not shown) to realize communication interaction between the device and other devices. The communication module can realize communication through a wired mode (such as USB, network cable, etc.) or a wireless mode (such as mobile network, WIFI, Bluetooth, etc.).

[0176] The bus 1050 includes a path that transmits information between the various components of the device (eg, the processor 1010, the memory 1020, the input / output interface 1030, and the communication interface 1040).

[0177] It should be noted that, although the above device only shows the processor 1010, the memory 1020, the input / output interface 1030, the communication interface 1040 and the bus 1050, in the specific implementation process, the device may also include other components necessary for normal operation. In addition, it can be understood by those skilled in the art that the above device may also only include the components necessary for implementing the embodiments of the present specification, and does not necessarily include all the components shown in the figure.

[0178] The embodiments of this specification also provide a computer program product, which implements the above-mentioned method of joint graph processing when executed by a processor.

[0179] The embodiments of the present specification also provide a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the above-mentioned method of joint graph processing is implemented.

[0180] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.

[0181] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.

[0182] The above is a description of a specific embodiment of the specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0183] The user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.

Claims

1. A method for joint graph processing, involving a first party and a second party, each of which holds a first graph and a second graph as private data, the method being applied to the first party, the method comprising: By jointly executing a privacy-preserving permutation algorithm with the second party, a sequence number value obtained by mapping each first vertex in the first graph to the N sequence positions is obtained; The arrangement algorithm is such that the serial number values ​​of the vertices representing the same object in the first graph and the second graph are the same, and the serial number values ​​of the vertices representing different objects are different; According to the sequence number value and weight of each first vertex, an N-bit first weight sequence is constructed; Using the first weight sequence and the second weight sequence obtained by the second party, a first joint operation is performed to obtain an N-bit first weight ciphertext sequence, wherein the i-th bit corresponds to the homomorphic ciphertext of the weight of the vertex with sequence value i; Using the edges in the first graph, jointly with the second party, perform several rounds of graph iterations to update the first weighted ciphertext sequence; The updated first weight ciphertext sequence is decrypted to obtain the updated weight of the first vertex.

2. The method according to claim 1, wherein: Construct an N-bit first weight sequence, including: For any first vertex, fill its weight in the first graph into the position corresponding to its sequence number value in the N-bit sequence structure; After filling each first vertex, the unfilled positions in the sequence structure are filled with default values.

3. The method according to claim 1, wherein: The first joint operation includes: Splitting the first weight sequence into first-party shards and second-party shards through secret sharing; sending the second party fragments of the first weight sequence to the second party, and receiving the first party fragments of the second weight sequence sent by the second party; Determine a first total shard according to first party shards of each of the first weight sequence and the second weight sequence; The first total shard and the second total shard held by the second party are used to jointly call a first conversion protocol of secret sharing to homomorphic encryption to obtain the first weighted ciphertext sequence.

4. The method according to claim 3, wherein: Determine the first total shard, including: The sum of the first side fragments of the first weight sequence and the second weight sequence is calculated as the first total fragment.

5. The method according to claim 3, wherein: The jointly calling the first conversion protocol of secret sharing to homomorphic encryption to obtain the first weighted ciphertext sequence includes: Homomorphically encrypt the first total shard using the public keys of the first party and the second party respectively to obtain a first ciphertext and a second ciphertext; Sending a first ciphertext to the second party, and receiving a third ciphertext sent by the second party; the third ciphertext is obtained by the second party performing homomorphic encryption on the second total shard using the second party's public key; The first weighted ciphertext sequence is determined according to a homomorphic sum of the second ciphertext and the third ciphertext.

6. The method according to claim 1, wherein: The step of obtaining the sequence number value of each first vertex in the first graph in the N sequence positions by jointly executing the privacy-preserving arrangement algorithm with the second party includes: Get a first vertex array containing vertex identifiers corresponding to the first graph; Performing a joint merge with the second vertex array held by the second participant to obtain a third vertex array; For the third vertex array, jointly executing a privacy-preserving random permutation generation algorithm with the second participant, a sequence of serial number values ​​corresponding one-to-one to elements of the third vertex array is generated; The sequence number value of each first vertex in the N sequence positions is determined based on the sequence number value sequence.

7. The method according to claim 6, wherein: The first vertex array and the second vertex array each include N elements, each element includes a vertex identifier and a number value selected from binary values, and each vertex corresponds to two adjacent elements with the same vertex identifier and different number values; The execution of the joint merger includes: By jointly executing a privacy-preserving sorting algorithm with the second party, the first vertex array and the second vertex array are sorted according to vertex identifiers and number values ​​to obtain a third vertex array, wherein elements having the same vertex identifier and number value are arranged adjacently; The determining, based on the sequence of sequence values, the sequence number values ​​of each first vertex in the N sequence positions includes: For the sequence of serial number values, the inverse process of the sorting algorithm is jointly executed with the second party to obtain a first subsequence of serial number values; the serial number value of a specific position in the first subsequence is used as the serial number value of each first vertex; the specific position is an odd position or an even position agreed with the second party; the values ​​of the 2ith bit and the 2i-1th bit in the sequence of serial number values ​​are the same.

8. The method according to claim 7, wherein: The binary value is 0 and 1, and the sorting algorithm is an odd-even merge algorithm.

9. The method according to claim 1, wherein: The N is determined according to the number of vertices of the first party and the second party, and is linearly positively correlated with the maximum value of the number of vertices of the first party and the second party.

10. The method according to claim 9, wherein: The N is determined based on the maximum value of the logarithmic values ​​of the numbers of vertices of the first side and the second side rounded upward.

11. The method according to claim 1, wherein: Any one of the several rounds of graph iterations comprises: Using the edges in the first graph, locally updating the first weighted ciphertext sequence to obtain a first incremental ciphertext sequence; A second joint operation is performed using the first incremental ciphertext sequence and the second incremental ciphertext sequence corresponding to the second party to obtain the first weighted ciphertext sequence after this round of update.

12. The method according to claim 11, wherein: The second joint operation includes: By calling the second conversion protocol of homomorphic encryption to secret sharing, the first incremental ciphertext sequence and the second incremental ciphertext sequence are obtained, each corresponding to the first incremental fragment of the plaintext on the first party; Determine the first-party shard of the total weight of this round based on the first-party shard of the total weight of the previous round and the first-party incremental shard; The first-party shard of the total weight of this round and the second-party shard of the total weight of this round held by the second party are used to jointly call the first conversion protocol of secret sharing to homomorphic encryption to obtain the first weight ciphertext sequence after this round of update.

13. The method according to claim 1, wherein: Decrypting the updated first weight ciphertext sequence to obtain the updated weight of the first vertex includes: Homomorphically add the ciphertext values ​​in the local first weight ciphertext sequence and a set of random numbers to obtain the fifth ciphertext; sending the fifth ciphertext to the second party, and receiving a plaintext corresponding to the fifth ciphertext sent by the second party; The set of random numbers is subtracted from the plaintext to obtain the updated weight.

14. An apparatus for jointly performing graph processing, involving a first party and a second party, each of which holds a first graph and a second graph as private data, the apparatus being applied to the first party, the apparatus comprising: a permutation module, configured to obtain, by jointly executing with the second party, a sequence number value obtained by mapping each first vertex in the first graph to the N sequence positions; the permutation algorithm ensures that the sequence number values ​​of vertices representing the same object in the first graph and the second graph are the same, and the sequence number values ​​of vertices representing different objects are different; A sequence construction module, used to construct an N-bit first weight sequence according to the sequence number value and weight of each first vertex; A first joint operation module, configured to perform a first joint operation using the first weight sequence and a second weight sequence obtained corresponding to the second party, to obtain an N-bit first weight ciphertext sequence, wherein the i-th bit corresponds to the homomorphic ciphertext of the weight of the vertex with sequence number i; A sequence updating module, configured to utilize the edges in the first graph and jointly perform several rounds of graph iterations with the second party to update the first weighted ciphertext sequence; The sequence decryption module is used to decrypt the updated first weight ciphertext sequence to obtain the updated weight of the first vertex.

15. A computer program product, wherein when the computer program product is executed by a processor, the method according to any one of claims 1 to 13 is implemented.

16. A computer device comprising: processor; a memory for storing processor-executable instructions; The processor implements the method according to any one of claims 1 to 13 by running the executable instructions.

Citation Information

Patent Citations

  • Joint deep learning method capable of resisting generative adversarial network attacks

    CN110460600A

  • Ultra-dense wireless network power distribution method combining graph signal and reinforcement learning

    CN110972309A

  • Distributed graph data feature decomposition method and system for privacy protection

    CN114692200A

  • Industrial protocol software source code vulnerability detection and positioning method based on association diagram

    CN117744085A

  • Joint prediction method and device, storage medium, equipment and program product

    CN118573471A