Ciphertext feature matching method and system based on fully homomorphic encryption and composite polynomial
By using composite polynomials to iteratively calculate the difference between the Euclidean distance and the threshold in fully homomorphic encryption, the problems of low computational efficiency and data leakage in ciphertext feature vector matching are solved, and efficient and secure ciphertext feature vector matching is achieved. The privacy information of both parties is protected.
Patent Information
- Application Number
- CN202410812547.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-22
- Publication Date
- 2024-08-30
- Estimated Expiration
- 2044-06-22
AI Technical Summary
The existing technology has low computational efficiency in ciphertext comparison, is difficult to achieve efficient ciphertext feature vector-threshold matching, and has the risk of data leakage. In particular, it is difficult to avoid data leakage caused by the number of iterations under monotonic polynomial function processing.
Using a method based on fully homomorphic encryption and composite polynomials, the difference between the Euclidean distance and the threshold is calculated through three or five polynomial iterations, and the polynomial coefficients are dynamically adjusted to ensure the convergence and security of the iteration results, avoid information leakage, and Addition and multiplication calculations are performed in a fully homomorphic encryption scheme.
It achieves efficient and secure ciphertext feature vector matching, protects the private information of the client and server, avoids data leakage, and has low computational cost, making it suitable for a variety of security feature vector matching scenarios.
Smart Images

Figure CN118381598B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of ciphertext data processing, and in particular to a ciphertext feature matching method and system based on fully homomorphic encryption and composite polynomials. Background Art
[0002] Feature vector-threshold matching is a common pattern recognition technology that performs classification or recognition by comparing the size relationship between feature vectors and preset thresholds. It has a wide range of applications in many fields, such as image matching, voiceprint recognition, biometrics, target tracking, and object recognition. In image matching, a threshold is usually set. By comparing the feature vector of the input image with the feature vector of a known object in the database, if the Euclidean distance between the two feature vectors is less than the threshold, the two feature vectors are considered to match. It can be used in applications such as face recognition and real-time object recognition. It can also be used in combination with other technologies such as machine learning algorithm recognition. It is simple and intuitive, has high computational efficiency, and is suitable for real-time applications.
[0003] However, with the enhancement of privacy awareness and the country's requirements for data security, plaintext data processing can no longer meet the requirements of data security laws and regulations. Therefore, technical means are needed to avoid the leakage of private information of both parties. Homomorphic encryption is one of the important technologies of privacy computing, which is applied in finance, medicine and genomics. It allows unlimited addition and multiplication operations to be performed on encrypted data, and the results corresponding to the plaintext operations are obtained after decryption. Therefore, it is widely used in the field of data protection. In 2009, Gentry created a fully homomorphic encryption (FullyHomomorphic Encryption / FHE) scheme, but its performance is poor and remains in the theoretical stage. Although many FHE schemes have been developed, these FHE support high-speed arithmetic operations between messages, including addition and multiplication. However, in the comparison of ciphertext, it cannot be directly processed by calculation. Although ciphertext comparison can be achieved by outsourcing to a trusted third party, using Boolean circuits, and using oblivious transmission, these methods have low computational efficiency and it is difficult to find a trusted third party, which makes ciphertext comparison difficult to achieve efficiently. Therefore, it is difficult to put the feature vector-threshold matching technology under ciphertext into practical use. The specific problems are as follows:
[0004] In ciphertext comparison, the Boolean circuit-based method will double the amount of calculation due to the circuit depth problem and the Boolean circuit implementation is complicated.
[0005] Based on semi-homomorphic encryption and oblivious transfer schemes, only addition or multiplication operations can be performed, the application scenarios are greatly limited, and the oblivious transfer overhead is extremely high, so the overall efficiency is poor.
[0006] If a monotone polynomial function is used to process the ciphertext, the result can only be approximated in one direction. The attacker will infer the threshold data interval based on the number of ciphertext iterations and the result, causing data leakage.
[0007] Therefore, how to provide a ciphertext feature vector matching method that can effectively protect the privacy information of the client and the server and has the characteristics of low computational cost is a technical problem that needs to be solved urgently by those skilled in the art. Summary of the invention
[0008] In view of the above research status, the present invention provides a ciphertext feature matching method and system based on fully homomorphic encryption and composite polynomials. The data of both parties are encrypted using the fully homomorphic encryption scheme CKKS to avoid the use of plaintext data. The Euclidean distance and the threshold are iterated using a cubic polynomial, so that the comparison result can be obtained and the leakage of relevant information can be avoided in the intermediate iteration process. Because high-precision iteration is not required, the computational cost is relatively small.
[0009] The present invention provides a ciphertext feature matching method based on fully homomorphic encryption and composite polynomial, comprising the following steps:
[0010] S1: The server receives the ciphertext a of the feature vector to be matched sent by the client, where the ciphertext a is obtained by encrypting the feature vector to be matched using a fully homomorphic encryption algorithm;
[0011] S2: Encrypt the target feature vector on the server side using a fully homomorphic encryption algorithm to obtain ciphertext b;
[0012] S3: Calculate the Euclidean distance between ciphertext a and ciphertext b, and calculate the difference between the Euclidean distance and the preset threshold fully homomorphic ciphertext;
[0013] S4: normalize the difference, use the normalized result as the independent variable of the high-order polynomial for multiple iterative calculations, and dynamically adjust the polynomial coefficients to obtain the dependent variable of the high-order polynomial outputted by the final iteration as the iterative result;
[0014] S5: Return the iteration result to the client, so that the client can use the private key corresponding to the fully homomorphic encryption algorithm to decrypt the iteration result and obtain the comparison result in plain text.
[0015] Preferably, the method further includes the step of acquiring the feature vector to be matched and the target feature vector:
[0016] The feature vector to be matched is obtained by the client through feature extraction based on user data;
[0017] The target feature vector is obtained by the server side through feature extraction based on the target data;
[0018] The user data and the target data have the same data type and use the same feature extraction method.
[0019] Preferably, the server is based on the target feature vector (w1, w2, ..., w i ,...,w n )Use G(x) as the normalization function:
[0020] ;
[0021] Wherein, x is the difference.
[0022] Preferably, normalization is performed before iterative multiplication is performed, and rescaling and mode switching are performed after each iterative multiplication, and then multiple iterative calculations are performed as independent variables of a high-order polynomial.
[0023] Preferably, the iterative calculation is performed within a specified range of iteration times, and the conditions for determining the range of iteration times include: the iterative result converges to two values (-1, 1) after decryption.
[0024] Preferably, the high-order polynomial includes a cubic polynomial and a quintic polynomial.
[0025] The present invention also provides a ciphertext feature vector matching system according to the ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomial, comprising:
[0026] Ciphertext receiving module: used to receive the ciphertext a of the feature vector to be matched sent by the client, where the ciphertext a is obtained by encrypting the feature vector to be matched using a fully homomorphic encryption algorithm;
[0027] Fully homomorphic encryption module: used to encrypt the target feature vector located on the server side using a fully homomorphic encryption algorithm to obtain the ciphertext b;
[0028] Difference calculation module: used to calculate the Euclidean distance between ciphertext a and ciphertext b, and calculate the difference between the Euclidean distance and the preset threshold fully homomorphic ciphertext;
[0029] High-order polynomial iteration module: used to normalize the difference, use the normalized result as the independent variable of the high-order polynomial for multiple iterative calculations, and dynamically adjust the polynomial coefficients to obtain the dependent variable of the high-order polynomial output of the final iteration as the iteration result;
[0030] Ciphertext sending module: used to return the iteration result to the client, so that the client can use the private key corresponding to the fully homomorphic encryption algorithm to decrypt the iteration result and obtain the plaintext comparison result.
[0031] Preferably, the high-order polynomial iteration module is based on the target feature vector (w1, w2, ..., w i ,...,w n )Use G(x) as the normalization function:
[0032] ;
[0033] Wherein, x is the difference.
[0034] Preferably, after the high-order polynomial iteration module executes the multiplication of the normalized processing function, it performs multiple iterative calculations as the independent variable of the high-order polynomial. During iteration, rescaling and module switching are required after each multiplication.
[0035] Preferably, the high-order polynomial iteration module performs the iterative calculation within a specified range of iteration times, and the conditions for determining the range of iteration times include: the iterative result converges to two values (-1, 1) after decryption.
[0036] The ciphertext feature matching method and system based on fully homomorphic encryption and composite polynomial proposed in the present invention have the following beneficial effects compared with the prior art:
[0037] The present invention provides a secure computation feature vector-threshold comparison solution based on fully homomorphic encryption, which can be applied to a variety of secure feature vector matching.
[0038] The present invention combines high-order polynomials with homomorphic encryption, performs iterative calculations on ciphertexts, and replaces the symbolic function to compare the size of data under the ciphertext. It can make comparisons securely without leaking any information, fully protect the privacy information of the client and server, and make the data available but invisible.
[0039] In the comparison between the Euclidean distance and the threshold, the present invention adopts a polynomial iteration method, and can adopt methods such as cubic and quintic polynomials to ensure that the iterative value is a jitter approximation convergence value rather than a monotonic approximation, thereby avoiding data leakage caused by the number of iterations.
[0040] The present invention uses a fully homomorphic encryption scheme to securely calculate the Euclidean distance, can perform multiplication and addition calculations at the same time, and is easy to use and easy to promote. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention, and for ordinary technicians in this field, other drawings can be obtained based on the provided drawings without creative work.
[0042] Figure 1It is a flow chart of a ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomial provided by an embodiment of the present invention;
[0043] Figure 2 A graph showing the plaintext convergence results of the iterative calculation of the cubic polynomial provided by the embodiment of the present invention;
[0044] Figure 3 A schematic diagram of the effect of the intermediate result of each iteration in the ten iterations of a cubic polynomial provided in an embodiment of the present invention;
[0045] Figure 4 An organizational chart of a ciphertext feature vector matching system based on fully homomorphic encryption and composite polynomials provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0046] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0047] like Figure 1 As shown, the first aspect of an embodiment of the present invention provides a ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomials. This scheme can also be used in the comparison of various types of feature vectors-thresholds, such as image matching, voiceprint recognition, fingerprint recognition, biometrics, target tracking and object recognition.
[0048] The ciphertext feature matching method based on fully homomorphic encryption and composite polynomials includes the following steps:
[0049] S1: The server receives the ciphertext a of the feature vector to be matched sent by the client. The ciphertext a is the feature vector to be matched encrypted by a fully homomorphic encryption algorithm.
[0050] S2: Encrypt the target feature vector on the server side using a fully homomorphic encryption algorithm to obtain ciphertext b;
[0051] S3: Calculate the Euclidean distance between ciphertext a and ciphertext b, and calculate the difference between the Euclidean distance and the preset threshold fully homomorphic ciphertext;
[0052] S4: Normalize the difference to ensure that the plaintext data falls within the interval (-2, 2), use the normalized result as the independent variable of the high-order polynomial for multiple iterative calculations, and dynamically adjust the polynomial coefficients to obtain the dependent variable of the high-order polynomial output of the final iteration as the iteration result;
[0053] S5: Return the iteration result to the client, so that the client can use the private key corresponding to the fully homomorphic encryption algorithm to decrypt the iteration result and obtain values close to -1 and 1, thereby determining the plaintext of the comparison result and obtaining the matching result.
[0054] It should be noted that this embodiment does not limit the feature vector extraction method used, including: feature extraction methods such as SIFT, which are selected as needed according to the specific application scenario. This embodiment focuses on the security feature matching of vectors, and the data security processing steps of the client and the server in each step of the matching. Therefore, the focus of this embodiment is to describe the secure calculation of the Euclidean distance and polynomial iterative calculation of the feature vector-threshold model, so that the client cannot infer the relevant information of the server based on the number of iterations.
[0055] The following uses a client's data to be matched as an example to illustrate each embodiment one by one:
[0056] In one embodiment, the method further includes the following steps of obtaining the feature vector to be matched and the target feature vector:
[0057] The server extracts features of all its target data in advance and calculates all feature vectors (w1, w2, ..., w n ) and the corresponding threshold homomorphic ciphertext (d1,d2,...,d i ,...,d n ), and store it in its own database.
[0058] The client also extracts features from its own user data to be matched and obtains a feature vector v=(v 1 ,v 2 ,...,v n ).
[0059] The data type of user data and target data is the same, and the same feature extraction method is used.
[0060] This embodiment can be used for feature extraction of data such as images and genomes that need to be matched.
[0061] In one embodiment, two sets of feature vectors (w i =(w 1 ,w 2 ,...,w n ),v=(v 1 ,v 2 ,...v n ))After fully homomorphic encryption, the Euclidean distance is calculated; comprising the following steps:
[0062] The client uses the fully homomorphic encryption CKKS scheme to encrypt the feature vector v to obtain the ciphertext vector a and sends it to the server.
[0063] The server uses the fully homomorphic encryption CKKS scheme to compare a feature vector w i Encrypt to get b.
[0064] In one embodiment, the Euclidean distance is calculated in S3, and the formula of the safe Euclidean distance is as follows:
[0065] ;
[0066] The obtained Euclidean distance is compared with the ciphertext d of the threshold i Subtract and get the homomorphic ciphertext, where the homomorphic addition is processed as follows:
[0067] .
[0068] In one embodiment, the difference is normalized to ensure that the plaintext data falls within the interval (-2, 2), and a cubic polynomial is used to dynamically adjust the polynomial coefficients for iteration; the following steps are included:
[0069] The server calculates the plaintext w according to its own direction i , estimate the size, convert the division into homomorphic multiplication, and use G(x) as the normalization (non-strict normalization) processing function:
[0070] ;
[0071] Here, x is the difference.
[0072] In a fully homomorphic encryption scheme, the operation on the ciphertext is equivalent to the operation on the plaintext. Therefore, the purpose of using the normalization function for processing is to facilitate iteration of the plaintext value of the difference in a fixed interval. The cubic polynomial selected in this embodiment is;
[0073]
[0074] The shape can be dynamically selected according to accuracy and efficiency. Figure 2 The polynomial of the dynamic adjustment iteration coefficient is set as:
[0075] coefficients = [
[0076] [-0.648130810654374, 2.587469610350580],
[0077] [-0.645946504882452, 2.570794502956270],
[0078] [-0.640461560005760, 2.528996359271780],
[0079] [-0.627392628179869, 2.429839534983810],
[0080] [-0.599954150574302, 2.223732581490930],
[0081] [-0.556379869538908, 1.902644587584910],
[0082] [-0.516021146910677, 1.612820594787540],
[0083] [-0.501189482451817, 1.508330145167520],
[0084] [-0.500006380415569, 1.500044663017540],
[0085] [-0.500000000183196, 1.500000001282370] ]
[0087] like Figure 2 As shown in the figure, it is a cubic polynomial during iteration. The server calculates the ciphertext value based on the coefficients of the pre-calculated cubic polynomial, and then iterates the result. Experiments show that when the iteration is more than seven times, the decrypted plaintext can converge to around 1. Therefore, the number of iterations can be randomly set to (7, 12) times, taking into account both efficiency and security.
[0088] In this embodiment, during calculation, since multiple homomorphic multiplications may cause ciphertext overflow, normalization is performed before executing iterative multiplication. After each iterative multiplication, rescaling and module switching are performed, and then multiple iterative calculations are performed as independent variables of the high-order polynomial.
[0089] In one embodiment, the high-order polynomial further includes a quintic polynomial.
[0090] In one embodiment, the iterative calculation is performed within a specified range of iteration times. The conditions for determining the range of iteration times include: the iterative result converges to two values (-1, 1) after decryption, such as Figure 3 As shown, the function result is not monotonic, and its shape is similar to the sign function, but it shows a jitter effect, so the number of iterations cannot be reversed based on the size of the decrypted plaintext value.
[0091] In this embodiment, the obtained ciphertext result is decrypted using the private key to determine the plaintext of the comparison result. The following steps are included:
[0092] The client decrypts the received iteration value. Due to the accuracy of CKKS itself, it is approximately obtained:
[0093]
[0094] When the value is iterated 7 times, it has converged. Taking a single iteration as an example, assuming that the server-side 128-dimensional vector w1=(0.18, 0.34,....., 0.64, 0.81, 0.91), the corresponding threshold is d1=0.8. The client-side 128-dimensional vector v =(0.06, 0.6, ..., 0.15, 0.31, 0.3), the difference between the plaintext Euclidean distance and the threshold is 0.69.
[0095] The following table shows the decrypted data values after eight iterations of the ciphertext using the above cubic polynomial (the ciphertext on the server side cannot be decrypted during the iteration process, but it is decrypted for intuitive display effect). Through polynomial iteration, the wave-like approximation can be achieved, such as Figure 3 As shown, for the decrypted result y=0.9798207232797659 after iteration, the client cannot distinguish which iteration value [0.9798207232797659] corresponds to on the x-axis (non-monotonic approximation), so it is impossible to infer the threshold information of the server based on the iteration value.
[0096] X = [
[0097] Decrypted Result: [1.5547813793433813]
[0098] Decrypted Result: [1.472291347894896]
[0099] Decrypted Result: [1.4788434575470588]
[0100] Decrypted Result: [1.1833122378671523]
[0101] Decrypted Result: [1.1846878849842022]
[0102] Decrypted Result: [0.9798207232797659]
[0103] Decrypted Result: [1.0008040081340708]
[0104] Decrypted Result: [0.9992122929964331] ]
[0106] In the above-mentioned embodiment steps, the operation is always carried out under fully homomorphic ciphertext, and the server cannot crack the homomorphic ciphertext value of the client, so the vector value of the client is safe. During the operation, the server cannot decrypt any value, and the calculation is completed by the server, and the client can only obtain the final calculation result. When the server calculates a cubic polynomial, the polynomial and coefficients are kept confidential to the client, and the number of iterations is also random. At the same time, the result of the iteration is a fluctuating convergence. In other words, the client cannot infer the number of times (the approximate threshold of the server) and other information based on the convergence value. Therefore, the client cannot obtain any valid information, and can only finally decrypt the ciphertext to obtain two values (-1, 1). In this process, the privacy of the data of both parties is guaranteed.
[0107] The above embodiments S1-S5 describe a feature matching process. When the client processes m data vectors, for the vector data {w1, w2, ..., w n}, repeat the above steps for each i={1,2,...,n}, and perform m*n comparisons. You can also combine the vectors into matrices for parallel processing.
[0108] like Figure 4 As shown, the second aspect of the embodiment of the present invention further provides a ciphertext feature vector matching system according to the first aspect of the embodiment, which is deployed on the server side and includes:
[0109] Fully homomorphic encryption module: used to encrypt the target feature vector located on the server side using a fully homomorphic encryption algorithm to obtain the ciphertext b;
[0110] Ciphertext receiving module: used to receive the ciphertext a of the feature vector to be matched sent by the client, where the ciphertext a is obtained by encrypting the feature vector to be matched using a fully homomorphic encryption algorithm;
[0111] Difference calculation module: used to calculate the Euclidean distance between ciphertext a and ciphertext b, and calculate the difference between the Euclidean distance and the preset threshold fully homomorphic ciphertext;
[0112] High-order polynomial iteration module: used to normalize the difference, use the normalized result as the independent variable of the high-order polynomial for multiple iterative calculations, and dynamically adjust the polynomial coefficients to obtain the dependent variable of the high-order polynomial output of the final iteration as the iteration result;
[0113] Ciphertext sending module: used to return the iteration results to the client, so that the client can use the private key corresponding to the fully homomorphic encryption algorithm to decrypt the iteration results and obtain the plaintext comparison results.
[0114] In this embodiment, the client deployment includes:
[0115] Fully homomorphic encryption module: used to encrypt the matching feature vector using a fully homomorphic encryption algorithm to obtain the ciphertext a;
[0116] Ciphertext sending module: used for sending the ciphertext a of the feature vector to be matched to the ciphertext receiving module on the server side in the first aspect of the embodiment;
[0117] A ciphertext receiving module: used to receive the iteration result returned by the ciphertext sending module on the server side in the first aspect of the embodiment;
[0118] Decryption module: used to decrypt the iteration result using the private key corresponding to the fully homomorphic encryption algorithm to obtain the plaintext of the comparison result.
[0119] In one embodiment, the high-order polynomial iteration module is based on the target feature vector (w1, w2, ..., w i ,...,w n )Use G(x) as the normalization function:
[0120] ;
[0121] Here, x is the difference.
[0122] In one embodiment, after the high-order polynomial iteration module executes the normalization processing function, the result is used as the independent variable of the high-order polynomial to perform multiple iterative calculations, wherein rescaling and mode switching are required after each multiplication.
[0123] In one embodiment, the high-order polynomial iteration module performs iterative calculation within a specified range of iteration times, and the conditions for determining the range of iteration times include: the iteration result converges to two values (-1, 1) after decryption. According to experimental experience, when the number of iterations is generally more than five, the iteration result converges to two values (-1, 1) after decryption. The number of iterations in this embodiment is set to seven times.
[0124] The ciphertext feature vector matching system provided in the second aspect of this embodiment can be used to execute all steps of the ciphertext feature matching method based on fully homomorphic encryption and composite polynomials in the first aspect of the embodiment.
[0125] The above is a detailed introduction to the ciphertext feature matching method and system based on fully homomorphic encryption and composite polynomials provided by the present invention. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for general technical personnel in this field, according to the idea of the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
[0126] In this article, relational terms such as first and second, etc. are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article 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, article or device. In the absence of further restrictions, the elements defined by the statement "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
Claims
1. A ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomials, characterized by: The steps include: S1: The server receives the ciphertext a of the feature vector to be matched sent by the client, where the ciphertext a is obtained by encrypting the feature vector to be matched using a fully homomorphic encryption algorithm; S2: Encrypt the target feature vector on the server side using a fully homomorphic encryption algorithm to obtain ciphertext b; S3: Calculate the Euclidean distance between ciphertext a and ciphertext b, and calculate the difference between the Euclidean distance and the preset threshold fully homomorphic ciphertext; S4: normalize the difference, use the normalized result as the independent variable of the high-order polynomial for multiple iterative calculations, and dynamically adjust the polynomial coefficients to obtain the dependent variable of the high-order polynomial outputted by the final iteration as the iterative result; S5: Return the iteration result to the client, so that the client can use the private key corresponding to the fully homomorphic encryption algorithm to decrypt the iteration result and obtain the comparison result in plain text.
2. According to claim 1, a ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomials is characterized in that: The method also includes the steps of obtaining the feature vector to be matched and the target feature vector: The feature vector to be matched is obtained by the client through feature extraction based on user data; The target feature vector is obtained by the server side through feature extraction based on the target data; The user data and the target data have the same data type and use the same feature extraction method.
3. According to claim 1, a ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomials is characterized in that: The server is based on the target feature vector (w1, w2, ..., w i ,...,w n )Use G(x) as the normalization function: ; Wherein, x is the difference.
4. According to claim 1, a ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomials is characterized in that: Normalization is performed before iterative multiplication is performed, and rescaling and mode switching are performed after each iterative multiplication, and then multiple iterative calculations are performed as independent variables of a high-order polynomial.
5. According to claim 1, a ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomials is characterized in that: The iterative calculation is performed within a specified range of iteration times, and the conditions for determining the range of iteration times include: the iterative result converges to two values (-1, 1) after decryption.
6. According to claim 1, a ciphertext feature vector matching method based on fully homomorphic encryption and composite polynomials is characterized in that: The high-order polynomial includes a cubic polynomial and a quintic polynomial.
7. A ciphertext feature vector matching system according to any one of claims 1 to 6, characterized in that: include: Ciphertext receiving module: used to receive the ciphertext a of the feature vector to be matched sent by the client, where the ciphertext a is obtained by encrypting the feature vector to be matched using a fully homomorphic encryption algorithm; Fully homomorphic encryption module: used to encrypt the target feature vector located on the server side using a fully homomorphic encryption algorithm to obtain the ciphertext b; Difference calculation module: used to calculate the Euclidean distance between ciphertext a and ciphertext b, and calculate the difference between the Euclidean distance and the preset threshold fully homomorphic ciphertext; High-order polynomial iteration module: used to normalize the difference, use the normalized result as the independent variable of the high-order polynomial for multiple iterative calculations, and dynamically adjust the polynomial coefficients to obtain the dependent variable of the high-order polynomial output of the final iteration as the iteration result; Ciphertext sending module: used to return the iteration result to the client, so that the client can use the private key corresponding to the fully homomorphic encryption algorithm to decrypt the iteration result and obtain the plaintext comparison result.
8. The ciphertext feature vector matching system according to claim 7, characterized in that: The high-order polynomial iteration module is based on the target feature vector (w1, w2, ..., w i ,...,w n )Use G(x) as the normalization function: ; Wherein, x is the difference.
9. The ciphertext feature vector matching system according to claim 7, characterized in that: The high-order polynomial iteration module is normalized before execution, and after each iterative multiplication, it is rescaled and module switched, and then used as an independent variable of the high-order polynomial for multiple iterative calculations.
10. The ciphertext feature vector matching system according to claim 7, characterized in that: The high-order polynomial iteration module performs the iterative calculation within a specified range of iteration times, and the conditions for determining the range of iteration times include: the iterative result converges to two values (-1, 1) after decryption.
Citation Information
Patent Citations
Medical data sharing privacy protection method based on fully homomorphic encryption
CN114978467A
Image comparison method and device based on privacy protection
CN115001652A
