A privacy computing method based on multivariate polynomials
Through the privacy calculation method of multivariate polynomial expression, the problems of low efficiency and low accuracy in the existing technology are solved, and efficient and accurate privacy calculation is realized, which is suitable for complex data operations.
Patent Information
- Application Number
- CN202210008022.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-01-06
- Publication Date
- 2024-09-17
- Estimated Expiration
- 2042-01-06
AI Technical Summary
Existing privacy computing technology has problems of low efficiency or low accuracy, especially the low execution efficiency of obfuscation circuits, low accuracy of homomorphic encryption and high cost of trusted hardware, making it difficult to promote and use it.
Using a privacy calculation method based on multivariate polynomials, the first party generates variables and assigns different variables to each privacy number to generate a polynomial expression. The second party establishes a polynomial fitting of the objective function and expresses the polynomial The formula expansion is sent to the first participant for privacy calculation.
It achieves high-efficiency privacy calculations, has controllable polynomial fitting errors, can complete complex operations, and has high operating efficiency and accuracy.
Smart Images

Figure CN114417404B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information technology, and in particular to a privacy computing method based on multivariate polynomials. Background Art
[0002] Privacy computing refers to a set of technologies that implement data analysis and computing while protecting the data from external disclosure, so as to achieve the goal of "available but invisible" data; and to achieve the transformation and release of data value while fully protecting data and privacy security. At present, the means of data security utilization, such as data desensitization or anonymization, must sacrifice some data dimensions, resulting in the ineffective use of data information. Privacy computing can maximize the value of data as much as possible while ensuring security. As data plays an increasingly important role in the economy, the demand for privacy computing is gradually increasing. The current privacy computing methods mainly include obfuscated circuits, homomorphic encryption, and trusted hardware computing. The execution efficiency of obfuscated circuits is low, and homomorphic encryption has the problem of low accuracy. The cost of using trusted hardware is high and it is difficult to promote its use. Therefore, new privacy computing technologies still need to be studied.
[0003] For example, Chinese patent CN113505395A, published on October 15, 2021, discloses a privacy computing method, including: a scheduler receives computing tasks and distributes computing tasks to a programming interface; the programming interface parses the computing instructions in the computing tasks, parses the computing instructions into plaintext instructions and / or ciphertext instructions, and sends the plaintext instructions to the plaintext engine of the corresponding data party, and sends the ciphertext instructions to the ciphertext engine; the plaintext engine executes the received plaintext instructions based on the plaintext data held and / or the plaintext data read from the plaintext cache corresponding to the plaintext engine; the ciphertext engine executes the received ciphertext instructions based on the ciphertext data read from the ciphertext cache. Its technical solution can execute ciphertext instructions and ciphertext instructions concurrently to improve computing efficiency. However, it still requires the use of trusted hardware, which is not conducive to the promotion and use of privacy computing. Summary of the invention
[0004] The technical problem to be solved by the present invention is that the current privacy computing technology has the problem of low efficiency or low accuracy. A privacy computing method based on multivariate polynomials is proposed, which can perform privacy computing efficiently with controllable accuracy.
[0005] To solve the above technical problems, the technical solution adopted by the present invention is: a privacy computing method based on multivariate polynomials, including: the first participant generates N variables and assigns values, assigns m variables to each privacy number, and the variables assigned to the privacy numbers are different; all participants generate a polynomial expression of m variables for each privacy number they own; the second participant establishes a polynomial fitting of the objective function; all participants submit the polynomial expression of the privacy number to the selected second participant; the second participant substitutes the polynomial expression of each privacy number into the polynomial fitting, obtains the second polynomial after expansion, and sends the second polynomial to the first participant; the first participant substitutes the variable value into the second polynomial to obtain the result of the objective function, which is the privacy computing result.
[0006] Preferably, the polynomial expression of the privacy number is a multivariate linear polynomial.
[0007] Preferably, the method for establishing a polynomial fitting of the objective function includes: generating a preset number of sample data according to the objective function; establishing a polynomial fitting of the sample data so that the polynomial fitting error is lower than a preset verification.
[0008] Preferably, the method for generating sample data includes: all participants report the value range of the privacy number to the second participant; the second participant generates a number of sampling values within the value range of each privacy number; the sampling values are substituted into the objective function, the value of the objective function is used as a label, and the sample data is obtained.
[0009] Preferably, the method for generating sample data includes: all participants divide their respective privacy number value ranges into several intervals, and respectively count the probability of their respective privacy numbers falling into each interval as the interval probability; all participants send the privacy number value range and interval probability to the second participant; the participants randomly generate the number of examples within the privacy number value range, so that the distribution probability of the example number in the interval is equal to the interval probability; randomly combine the number of examples of the privacy number into value groups, substitute the value groups into the objective function, and obtain the result of the objective function; and use the result as a label value to mark the value group as sample data.
[0010] Preferably, the method for establishing a polynomial fit for sample data includes: establishing a polynomial fit expression and assigning initial values to the coefficients of the polynomial fit terms; substituting the sample data into the polynomial fit expression to obtain a fit value, calculating the square of the difference between the fit value and the sample data label value and recording it as a loss value; constructing a loss function, wherein the loss function is equal to the sum of the loss values of all sample data; and using an optimization algorithm to obtain the optimal values of the coefficients of the polynomial fit terms so that the value of the loss function is minimized.
[0011] The substantial effects of the present invention are as follows: arbitrary functions can be fitted through polynomials, and privacy calculations of complex operations can be completed; the error of polynomial fitting is controllable, and the polynomial fitting result can be determined according to the accuracy requirements; the operation of polynomials is closed, and privacy calculations are performed through polynomials with high operating efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0012] Figure 1 This is a schematic diagram of a privacy computing method according to Embodiment 1.
[0013] Figure 2 This is a schematic diagram of a polynomial fitting method for establishing an objective function in Example 1.
[0014] Figure 3 This is a schematic diagram of a method for generating sample data according to the first embodiment.
[0015] Figure 4 This is a schematic diagram of a method for generating sample data in Embodiment 2. DETAILED DESCRIPTION
[0016] The specific implementation of the present invention will be further described below through specific examples in conjunction with the accompanying drawings.
[0017] Embodiment 1:
[0018] A privacy calculation method based on multivariate polynomials, see the attached Figure 1 , including: step A01) the first participant generates N variables and assigns values, assigning m variables to each privacy number, and the variables assigned to the privacy numbers are different; step A02) all participants generate a polynomial expression of m variables for each privacy number they own; step A03) the second participant establishes a polynomial fitting of the objective function; step A04) all participants submit the polynomial expression of the privacy number to the selected second participant; step A05) the second participant substitutes the polynomial expression of each privacy number into the polynomial fitting, expands it to obtain the second polynomial, and sends the second polynomial to the first participant; step A06) the first participant substitutes the variable value into the second polynomial to obtain the result of the objective function, which is the privacy calculation result.
[0019] The first participant generates N variables and assigns them values: {S1=12, S2=6, S3=2, S4=20, S5=9}. In this embodiment, m is 2. The first privacy value of participant A is 60, the second privacy value is 32, the privacy value of participant B is 120, and the privacy value of participant C is 90. The variables assigned to the first privacy number of participant A are S1 and S2, the variables assigned to the second privacy number are S1 and S3, the variables assigned to the privacy number of participant B are S1 and S4, and the variables assigned to the privacy number of participant C are S1 and S5. Participant A establishes a polynomial expression of the variable to represent the value 60, 60=4*S1+2*S2. Or it is established as: 60=2*S1+S2^2. The polynomial expression for the second privacy number is established as: 32=3*S1-2*S3. The polynomial expression established by Party B for the privacy number is: 120=5*S1+6*S4. The polynomial expression established by Party C for the privacy number is: 90=3*S1+6*S5. The recommended polynomial expression is a multivariate first-order polynomial, which can generate more similar terms after being substituted into the objective function, and can play a good role in protecting privacy after similar terms are merged. The objective function in this embodiment is f(x1,x2,x3,x4)=12*x1+16*x2+8*x3+6*x4, which means that there are Enterprise A, Enterprise B and Enterprise C in the industry. Enterprise A sells two products, and Enterprise B and Enterprise C sell one product. The objective function is to calculate the overall sales of the industry for the three companies to judge the market demand trend. However, each company is reluctant to disclose the specific product sales. When calculating using this embodiment, Enterprise A is selected as the first participant and Enterprise B is selected as the second participant. Enterprise A generates variables S1 to S5 and assigns them to Enterprise B and Enterprise C. The three companies each generate a polynomial expression of the private number and send it to Company B.
[0020] Company B substitutes x1=4*S1+2*S2, x2=S1^2-7*S2^4, x3=5*S1+6*S4 and x4=3*S1+6*S5 into the objective function f(x1,x2,x3,x4), and then expands the objective function to obtain the second polynomial, f(x1,x2,x3,x4)=12*(4*S1+2*S2)+16*(6*S1-5*S2)+8*(5*S1+6*S4)+6*(3*S1+6*S5)=154*S1+24*S2-32*S3+48*S4+36*S5. Company B only knows the values of S1 and S4, so it does not know the values of the privacy numbers of Company A and Company C. Company B sends the second polynomial to Company A. Although Company A knows the values of all variables, after receiving the second polynomial, it cannot determine the coefficient of S1 in the polynomial expression of each privacy number, and therefore cannot know the value of the privacy number. Company A substitutes the value of the variable into the second polynomial to obtain the result of the privacy calculation. That is, f(x1,x2,x3,x4)=154*S1+24*S2-32*S3+48*S4+36*S5=154*12+24*6-32*2+48*20+36*9=3212, and the result of the privacy calculation 3212 can be announced.
[0021] The method for establishing a polynomial fitting of the objective function includes: generating a preset number of sample data according to the objective function; establishing a polynomial fitting of the sample data so that the polynomial fitting error is lower than a preset verification. Figure 2 , the method for generating sample data includes: step B01) all participants report the value range of the privacy number to the second participant; step B02) the second participant generates a number of sample values within the value range of each privacy number; step B03) the sample values are substituted into the objective function, the value of the objective function is used as a label, and the sample data is obtained. In this scheme, the value of the privacy number is combined into a value group arbitrarily and randomly. For example, the value range of the privacy number x1 is [1,30], the value range of the privacy number x2 is [2,40], and the privacy numbers x1 and x2 are evenly selected from 3 numbers within their value ranges, then the values of x1 are {1,12,23}, and the values of x2 are {12,23,24}, and the value group can be either {{1,12}, {12,23}, {23,24}} or {{1,23}, {12,12}, {23,24}}. Substituting the value group into the objective function, the output of the objective function is used as the label of the value group. Using the label to label the value group, we can obtain sample data.
[0022] Please see attached Figure 3The method for establishing a polynomial fitting of sample data includes: step C01) establishing a polynomial fitting expression and assigning initial values of the coefficients of the polynomial fitting items; step C02) substituting the sample data into the polynomial fitting expression to obtain a fitting value, calculating the square of the difference between the fitting value and the sample data label value and recording it as a loss value; step C03) constructing a loss function, the loss function is equal to the sum of the loss values of all sample data; step C04) using an optimization algorithm to obtain the optimal value of the coefficients of the polynomial fitting items, so that the value of the loss function is minimized.
[0023] The beneficial technical effects of this embodiment are: arbitrary functions can be fitted through polynomials, and privacy calculations of complex operations can be completed; the error of polynomial fitting is controllable, and the polynomial fitting result can be determined according to the accuracy requirements; the operation of polynomials is closed, and privacy calculations are performed through polynomials with high operating efficiency.
[0024] Embodiment 2:
[0025] A privacy calculation method based on multivariate polynomials, see the attached Figure 4 , the method for generating sample data includes: step D01) all participants divide their privacy number value range into several intervals, and count the probability of their privacy numbers falling into each interval as the interval probability; step D02) all participants send the privacy number value range and interval probability to the second participant; step D03) the participants randomly generate examples within the privacy number value range, so that the distribution probability of the example number in the interval is equal to the interval probability; step D04) randomly combine the example numbers of the privacy number into a value group, substitute the value group into the objective function, and obtain the result of the objective function; step D05) use the result as a label value to mark the value group as sample data. The accuracy of the polynomial fitting objective function is directly related to the sample data. If the sample data is close to the privacy value of the final privacy calculation, the accuracy of the final privacy calculation result will be higher.
[0026] The above embodiment is only a preferred solution of the present invention and does not limit the present invention in any form. There are other variations and modifications without exceeding the technical solution described in the claims.
Claims
1. A privacy computing method based on multivariate polynomials, characterized in that: include: The first participant generates N variables and assigns values, assigning m variables to each private number, and the variables assigned to the private numbers are different; All participants generate a polynomial expression of m variables for each private number they have; The second participant establishes a polynomial fit of the objective function; All participants submit the polynomial expression of the private number to the selected second participant; The second participant substitutes the polynomial expression of each private number into the polynomial fitting, expands it to obtain the second polynomial, and sends the second polynomial to the first participant; The first participant substitutes the variable value into the second polynomial to obtain the result of the objective function, which is the privacy calculation result; Methods for establishing a polynomial fit of the objective function include: Generate a preset number of sample data according to the objective function; Establish a polynomial fit for the sample data so that the polynomial fit error is lower than the preset verification; Methods for building a polynomial fit to sample data include: Establish a polynomial fitting expression and assign initial values to the coefficients of the polynomial fitting items; Substitute the sample data into the polynomial fitting expression to obtain the fitting value, and calculate the square of the difference between the fitting value and the sample data label value as the loss value; Constructing a loss function, where the loss function is equal to the sum of the loss values of all sample data; The optimization algorithm is used to obtain the optimal value of the coefficients of the polynomial fitting term so that the value of the loss function is minimized.
2. A privacy computing method based on multivariate polynomials according to claim 1, characterized in that: The polynomial expression of the privacy number is a multivariate linear polynomial.
3. The privacy computing method based on multivariate polynomial according to claim 1, characterized in that: Methods for generating sample data include: All participants report the value range of the privacy number to the second participant; The second participant generates several sample values within the value range of each privacy number; Substitute the sampled value into the objective function, use the value of the objective function as the label, and obtain the sample data.
4. The privacy computing method based on multivariate polynomial according to claim 1, characterized in that: Methods for generating sample data include: All participants divide their privacy number value range into several intervals, and calculate the probability of their privacy numbers falling into each interval as the interval probability; All participants send the value range and interval probability of the privacy number to the second participant; The participants randomly generate the number of examples within the range of the privacy number, so that the distribution probability of the number of examples in the interval is equal to the interval probability; Randomly combine the examples of privacy numbers into value groups, substitute the value groups into the objective function, and obtain the result of the objective function; The result is used as a label value to mark the value group as sample data.
