A federated model aggregation encryption method and system

By adopting a dual-server architecture and proxy re-encryption algorithm in federated learning, processing and converting model parameters, the problem of model update data security in federated learning is solved, and the security of client privacy data and model availability is improved.

CN118842654BActive Publication Date: 2024-11-26HARBIN INSTITUTE OF TECHNOLOGY (SHENZHEN) (INSTITUTE OF SCIENCE AND TECHNOLOGY INNOVATION HARBIN INSTITUTE OF TECHNOLOGY SHENZHEN) +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411315697.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-09-20
Publication Date
2024-11-26
Estimated Expiration
2044-09-20

AI Technical Summary

Technical Problem

During the federated learning process, publicly propagated model updates have the risk of extracting private training data. How to improve data security is a problem that needs to be solved.

Method used

Using a dual-server architecture of aggregation server and an auxiliary server, the client and the auxiliary server determine the shared key through key exchange, use the shared key generation blind factor to blind the local model parameters, and then encrypt it and send it to the aggregation server. The proxy re-encryption algorithm converts the ciphertext model parameters under the client's public key to the ciphertext model parameters under the aggregation server's public key. The aggregation server and the auxiliary server cooperate to perform ciphertext conversion processing, eliminate blind factors, and generate deblind aggregation. Model parameters.

Benefits of technology

Without increasing system communication and computing overhead, ensure the security of client private data, improve the availability of the model, and prevent private data leakage.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118842654B_ABST
    Figure CN118842654B_ABST
Patent Text Reader

Abstract

This application provides a federated model aggregation encryption method and system, including: a client blinding local model parameters using a blinding factor, encrypting the local model parameters, and sending the encrypted local model parameters to an aggregation server; the aggregation server converting the parameters into encrypted model parameters under its public key using a proxy re-encryption method, aggregating to generate aggregated encrypted model parameters, decrypting the aggregated encrypted model parameters using the aggregation server's private key to obtain the aggregated model parameters, encrypting the aggregated model parameters using the client's public key to obtain the aggregated model parameters under the client's public key; an auxiliary server encrypting the calculated aggregation blinding factor using the client's public key, sending the encrypted aggregated blinding factor to the aggregation server; the aggregation server determining the deblinded aggregated model parameters based on the aggregated model parameters and the encrypted aggregated blinding factor, and the client decrypting the aggregated model parameters using its private key to obtain the aggregated model parameters. This method ensures the security of private data without increasing resource overhead.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of data security technology, and in particular to a federated model aggregate encryption method and system. Background Art

[0002] Federated learning (FL) is a groundbreaking paradigm in machine learning. It allows multiple clients (such as smartphones and IoT devices) to collaboratively train a global model without sharing their local data. This approach addresses the privacy and data security requirements of the data-centric application era. However, there is still a risk of extracting private training data from publicly disseminated model updates. Therefore, improving data security during federated model training is a challenge in this field. Summary of the Invention

[0003] In view of this, the purpose of the embodiments of the present application is to propose a federated model aggregate encryption method and system.

[0004] Based on the above objectives, the present invention provides a federated model aggregation encryption method, including:

[0005] The client uses the generated blinding factor to blind the local model parameters, encrypts the blinded local model parameters using the client's public key to generate ciphertext local model parameters, and sends the ciphertext local model parameters to the aggregation server;

[0006] The aggregation server receives the encrypted local model parameters, converts the encrypted local model parameters into encrypted model parameters under the aggregation server public key based on the proxy re-encryption method, and sends the client set participating in the aggregation to the auxiliary server;

[0007] The aggregation server aggregates and generates the aggregated ciphertext model parameters under the aggregation server public key based on the ciphertext model parameters under the aggregation server public key;

[0008] The aggregation server uses the private key of the aggregation server to decrypt the aggregation ciphertext model parameters to obtain the aggregation model parameters, and uses the public key of the client to encrypt the aggregation model parameters to obtain the aggregation model parameters under the client public key;

[0009] The auxiliary server calculates the aggregation blinding factor based on the set of clients participating in the aggregation, encrypts the aggregation blinding factor using the client's public key, obtains the ciphertext aggregation blinding factor, and sends the ciphertext aggregation blinding factor to the aggregation server;

[0010] The aggregation server determines the unblinded aggregation model parameters based on the aggregation model parameters under the client public key and the ciphertext aggregation blinding factor, and sends the unblinded aggregation model parameters to the client;

[0011] The client receives the deblinded aggregation model parameters, decrypts the deblinded aggregation model parameters using the client's private key, and obtains the aggregation model parameters.

[0012] Optionally, the client blinds the local model parameters using the generated blinding factor, including:

[0013] The client and the auxiliary server determine a shared key through key exchange, use the shared key as a seed of a pseudo-random generator, use the pseudo-random generator to generate a blinding factor, and use the blinding factor to blind the local model parameters.

[0014] Optionally, the aggregation server receives the encrypted local model parameters, and converts the encrypted local model parameters into encrypted model parameters under the aggregation server public key based on a proxy re-encryption method, including:

[0015] The aggregation server Ciphered local model parameters for each client , based on the proxy re-encryption method, using the re-encryption key The first The ciphertext local model parameters of each client are converted into the ciphertext model parameters under the public key of the aggregation server ; Among them, the re-encryption key It is generated during the client initialization phase and sent to the aggregation server. It is The local model parameters of each client, It is A client-generated blinding factor, is the public key of the aggregation server, It is The client's public key.

[0016] Optionally, the method for aggregating and generating the aggregate ciphertext model parameters under the aggregation server public key is:

[0017]

[0018] in, is the aggregate ciphertext model parameter, is the number of clients participating in the aggregation.

[0019] Optionally, the aggregation server decrypts the aggregated ciphertext model parameters using the private key of the aggregation server to obtain the aggregated model parameters, and encrypts the aggregated model parameters using the public key of the client to obtain the aggregated model parameters under the public key of the client, including:

[0020] The aggregation server uses the private key of the aggregation server to aggregate the ciphertext model parameters Decrypt and get the aggregation model parameter w+r, using the The aggregate model parameters are encrypted with the public key of each client to obtain the aggregate model parameters under the client public key. .

[0021] Optionally, the aggregation server calculates the unblinded aggregation model parameters using homomorphic addition according to the aggregation model parameters under the client public key and the ciphertext aggregation blinding factor, which is expressed as:

[0022]

[0023] in, For the The aggregate model parameters for the unblinded client, For the secondary server, use The ciphertext aggregate blinding factor is obtained by encrypting the aggregate blinding factor with the public key of each client, and r is the aggregate blinding factor.

[0024] Optionally, the auxiliary server calculates an aggregation blinding factor based on a set of clients participating in the aggregation, including:

[0025] The auxiliary server determines, from a pre-generated blinding factor set, a blinding factor corresponding to each client in the set of clients participating in the aggregation; wherein the blinding factor set is a set of blinding factors of all clients participating in the federated learning;

[0026] The blinding factor corresponding to each client in the set of clients participating in the aggregation is summed to obtain the aggregate blinding factor.

[0027] The present application also provides a federated model aggregate encryption system, including:

[0028] The client is configured to blind the local model parameters using the generated blinding factors, encrypt the blinded local model parameters using the client's public key to generate ciphertext local model parameters, and send the ciphertext local model parameters to the aggregation server; and receive the unblinded aggregated model parameters, decrypt the unblinded aggregated model parameters using the client's private key to obtain the aggregated model parameters.

[0029] The auxiliary server is used to calculate the aggregation blinding factor based on the set of clients participating in the aggregation, encrypt the aggregation blinding factor using the client's public key to obtain the ciphertext aggregation blinding factor, and send the ciphertext aggregation blinding factor to the aggregation server;

[0030] The aggregation server is used to receive the ciphertext local model parameters, convert the ciphertext local model parameters into ciphertext model parameters under the public key of the aggregation server based on the proxy re-encryption method, and send the set of clients participating in the aggregation to the auxiliary server; based on the ciphertext model parameters under the public key of the aggregation server, aggregate and generate the aggregated ciphertext model parameters under the public key of the aggregation server; use the private key of the aggregation server to decrypt the aggregated ciphertext model parameters to obtain the aggregated model parameters, use the public key of the client to encrypt the aggregated model parameters to obtain the aggregated model parameters under the public key of the client; determine the deblinded aggregated model parameters based on the aggregated model parameters under the public key of the client and the ciphertext aggregation blinding factor, and send the deblinded aggregated model parameters to the client.

[0031] From the above description, it can be seen that the federated model aggregation encryption method and system provided by the embodiment of the present application adopts a dual-server architecture of an aggregation server and an auxiliary server. The client and the auxiliary server determine the shared key through key exchange, use the shared key to generate a blinding factor, use the blinding factor to blind the local model parameters, and send them to the aggregation server after encryption, which can ensure the security of the client's private data; the ciphertext local model parameters under the client's public key are converted into ciphertext model parameters under the aggregation server's public key through a proxy re-encryption algorithm, which can ensure the correct execution of homomorphic aggregation operations; in order to enable the client to use its private key to decrypt, the aggregation server decrypts the aggregated ciphertext model parameters, and encrypts them based on the client's public key to obtain the aggregated model parameters based on the public key of each client. The aggregation server and the auxiliary server collaborate to perform ciphertext conversion processing, eliminate the blinding factor, generate deblinded aggregated model parameters, and send them to each client. The method of the present application can ensure the security of client privacy data and improve the availability of the model without adding additional system communication overhead and computing overhead. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0033] Figure 1 A schematic diagram of a method flow chart of an embodiment of the present application;

[0034] Figure 2 A schematic diagram of the system architecture of an embodiment of the present application;

[0035] Figure 3 A schematic diagram comparing experimental results of the embodiments of the present application;

[0036] Figure 4This is a structural block diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0037] In order to make the objectives, technical solutions and advantages of the present disclosure more clearly understood, the present disclosure is further described in detail below in conjunction with specific embodiments and with reference to the accompanying drawings.

[0038] It should be noted that, unless otherwise defined, the technical terms or scientific terms used in the embodiments of the present application should have the usual meanings understood by people with ordinary skills in the field to which this disclosure belongs. The "first", "second" and similar words used in the embodiments of the present application do not indicate any order, quantity or importance, but are only used to distinguish different components. "Include" or "comprise" and similar words mean that the elements or objects appearing before the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects. "Connect" or "connected" and similar words are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. "Up", "down", "left", "right" and the like are only used to indicate relative positional relationships. When the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0039] Federated learning is a distributed machine learning method in which multiple clients collaborate to complete the training of a federated model under the coordination of a central server. The client has a local dataset. The client uses the local dataset to train the initial global model to obtain a local model. The client only needs to upload the model parameters (for example, weights) of the local model to the central server. The central server aggregates and distributes the model parameters based on the local models of each client. Since the local data of the client is not shared, the security of the user's private data can be guaranteed. Among them, the algorithm process of federated learning is generally as follows: the central server initializes the global model according to a specific goal , and send the global model to each client. Client The initial global model is trained based on the local data set to obtain the local model, and the model parameters of the local model are Upload to the central server; the central server will upload the model parameters of each client's local model Aggregation to obtain the aggregate model ,in .

[0040] Proxy re-encryption (PRE) is a technique that allows for secure transformation of ciphertext. The principle is as follows: Consider a proxy re-encryption scheme involving three participants: Alice, Bob, and a semi-trusted third-party proxy. The third-party proxy uses a re-encryption key to transform ciphertext encrypted with Alice's public key into ciphertext encrypted with Bob's public key. Importantly, during this transformation, the third-party proxy cannot obtain any useful information about the ciphertext.

[0041] EC-AFGH is a variant of PRE, which defines the system parameters as The EC-AFGH proxy re-encryption algorithm process is as follows: In the key generation phase, Alice selects two random numbers As its private key , whose public key is ; Bob's private key is , the public key is During the re-encryption key generation phase, if Alice wants to entrust Bob to decrypt the ciphertext, Alice needs to use her private key and Bob's public key Calculate the re-encryption key , then Alice will Send to a third-party agent to perform ciphertext conversion. In the first level encryption stage, if Alice does not want to share the ciphertext, that is, she can only decrypt the ciphertext by herself, then she needs to convert the plaintext Encrypted in first-level ciphertext form In the secondary encryption phase, if Alice wants herself and her clients to be able to decrypt using her public key Encrypted ciphertext, she needs to convert the plaintext Encrypted in secondary ciphertext form ,in It is from E1() is the first-level encryption operation, E2() is the second-level encryption operation, rk is the abbreviation of the proxy re-encryption key, and b1 and b2 are random numbers selected by Bob.

[0042] During the proxy re-encryption phase, the third-party proxy can use the re-encryption key , by calculating , Alice's secondary ciphertext Convert to Bob's first-level ciphertext and get the ciphertext under Bob's public key .

[0043] In the decryption phase, Alice's private key is used Decrypting the first-level ciphertext The method is:

[0044]

[0045] Using a private key Decrypting secondary ciphertext The method is:

[0046]

[0047] Among them, D1() is the first-level decryption operation, and D2() is the second-level decryption operation.

[0048] Diffie-Hellman (DH) key exchange is a cryptographic protocol used to securely exchange keys over an insecure communication channel. It allows two parties to establish a shared key over a public channel and use the shared key for encrypted communication. Generally speaking, DH key exchange can be divided into three steps: generating public parameters, such as a large prime number p and a generator of the modulus p. ; Generate the user's key pair, Alice chooses one in Random numbers in As her private key , calculate the public key based on the private key , and broadcast the public key , Alice's key pair is ; Alice uses her private key and Bob's public key Calculate the shared secret key .

[0049] To address the potential leakage of publicly disseminated model parameters during federated model training, related technologies such as secret sharing, differential privacy, and homomorphic encryption can be employed to improve security. Secret sharing requires distributing model parameters across multiple shares. However, federated learning requires multiple rounds of iterations between devices, increasing communication overhead and making it impractical in practical applications. Differential privacy balances model availability and privacy by introducing noise into local or global models. This noise is often irreversible and degrades model accuracy, making it a significant issue in high-precision applications such as medical diagnosis. Homomorphic encryption offers the potential to reduce communication costs and provide provable security. However, traditional homomorphic encryption requires all clients to use the same public-private key pair, potentially leading to information leakage between clients and posing a significant threat to private data. Multi-key homomorphic encryption schemes can address this issue, but typically require additional interaction between clients, increasing the communication burden of federated learning.

[0050] In view of this, an embodiment of the present application provides a federated model aggregation encryption method, which adopts a dual-server architecture of an aggregation server and an auxiliary server, and uses a proxy re-encryption algorithm, homomorphic addition of homomorphic encryption, and a key interaction protocol to realize the ciphertext conversion and aggregation process in the federated learning process. It does not increase resource overhead and can ensure the efficiency of federated learning and the security of privacy data.

[0051] like Figure 1 As shown, the embodiment of the present application provides a federated model aggregate encryption method, including:

[0052] S101: The client blinds the local model parameters using the generated blinding factors, encrypts the blinded local model parameters using the client's public key to generate ciphertext local model parameters, and sends the ciphertext local model parameters to the aggregation server;

[0053] Combine Figure 2 As shown, this embodiment trains a federated model based on a federated learning approach, employing a dual-server architecture of an aggregation server and auxiliary servers. The aggregation server aggregates and distributes the global model, while the auxiliary servers assist in providing ciphertext conversion and key exchange functions. To improve the security of model parameters, the client and the auxiliary server determine a shared key through key exchange. The shared key is used as the seed for a pseudo-random generator, which is then used to generate a blinding factor. This blinding factor is then used to blind the local model parameters, enhancing the security of the model parameters during transmission.

[0054] Specifically, during the initialization phase, the aggregation server Determine the client set participating in federated learning , and Clients Corresponding identity information ; The aggregation server sends the initialized global model to each client. Client According to its private key and the aggregation server's public key Calculate the re-encryption key The re-encryption key is sent to the aggregation server. With the secondary server Obtain the other party's public key and determine the shared key through the DH key exchange protocol as well as .

[0055] Client The initial global model is trained based on the local data set, and the local model is obtained after training The client uses the shared key as the seed of the pseudo-random generator and uses the pseudo-random generator to generate the blinding factor. , based on the blinding factor, the model parameters of the local model (referred to as local model parameters) are blinded to generate the blinded local model parameters, and the client's public key is used to Encrypt the blinded local model parameters to generate the ciphertext local model parameters in the secondary ciphertext form , the encrypted local model parameters and client identity information Sent to the aggregation server.

[0056] S102: The aggregation server receives the encrypted local model parameters, converts the encrypted local model parameters of the client into encrypted model parameters under the aggregation server's public key based on the proxy re-encryption method, and sends the set of clients participating in the aggregation to the auxiliary server;

[0057] In this embodiment, during the proxy re-encryption phase, the aggregation server receives the encrypted local model parameters and identity information of each client, and determines the client set participating in the aggregation in this round based on the identity information of each client. ,in , , the client collection Sent to the secondary server.

[0058] The aggregation server uses the EC-AFGH proxy re-encryption algorithm to convert the client's ciphertext local model parameters into ciphertext model parameters under the aggregation server's public key, that is, the aggregation server converts the ciphertext local model parameters based on the client's public key into Convert to ciphertext model parameters based on the aggregate server public key .

[0059] S103: The aggregation server aggregates and generates aggregated ciphertext model parameters under the aggregation server public key based on the ciphertext model parameters under the aggregation server public key;

[0060] In this embodiment, during the model aggregation phase, the aggregation server converts the ciphertext local model parameters of each client into ciphertext model parameters under the aggregation server's public key, and then aggregates them to generate aggregated ciphertext model parameters under the aggregation server's public key using the homomorphic addition property. The aggregation method is:

[0061]

[0062] in, is the aggregate ciphertext model parameter, is the number of clients that actually participate in the aggregation.

[0063] S104: The aggregation server decrypts the aggregation ciphertext model parameters using the private key of the aggregation server to obtain the aggregation model parameters, and encrypts the aggregation model parameters using the public key of the client to obtain the aggregation model parameters under the public key of the client;

[0064] In this embodiment, during the ciphertext conversion phase, the aggregation server first uses its private key to aggregate the ciphertext model parameters Decrypt it to get the aggregate model parameters w+r, and then encrypt the aggregate model parameters with the client's public key to get the aggregate model parameters under the client's public key .

[0065] S105: The auxiliary server calculates an aggregation blinding factor based on the set of clients participating in the aggregation, encrypts the aggregation blinding factor using the public key of the client, obtains a ciphertext aggregation blinding factor, and sends the ciphertext aggregation blinding factor to the aggregation server;

[0066] In this embodiment, the auxiliary server receives the client set in the proxy re-encryption phase. , generating the aggregate blinding factor , and use the client The public key is encrypted to obtain the ciphertext aggregation blind factor , send the ciphertext aggregation blinding factor to the aggregation server.

[0067] In some embodiments, the auxiliary server calculates the aggregation blinding factor based on the set of clients participating in the aggregation, including: the auxiliary server determines the set of clients participating in the aggregation from a pre-generated blinding factor set The blinding factors corresponding to each client in the federated learning are: The blinding factors corresponding to each client in are summed up to get the aggregate blinding factor.

[0068] In this embodiment, in order to reduce time overhead, the auxiliary server pre-generates the blinding factors of all clients in the client set C participating in federated learning, and the blinding factors of all clients in the client set C constitute a blinding factor set; when receiving the client set participating in the aggregation in this round, When , the client set is determined from the pre-generated blinding factor set The blinding factor corresponding to each client in the client set The blinding factors corresponding to each client in the sum are added to generate the aggregate blinding factor. The method for the auxiliary server to generate the blinding factor of any client is: for the client , will be with the client The shared key between them is used as the seed of the pseudo-random generator, and the blinding factor is generated by the pseudo-random generator. .

[0069] S106: The aggregation server determines the unblinded aggregation model parameters according to the aggregation model parameters under the client public key and the ciphertext aggregation blinding factor, and sends the unblinded aggregation model parameters to the client;

[0070] In this embodiment, the aggregation server calculates the aggregation model parameters under the client public key and obtains the ciphertext aggregation blinding factor from the auxiliary server. Afterwards, the client is obtained by homomorphic addition. The unblinded aggregation model , the method is:

[0071]

[0072] S107: The client receives the deblinded aggregation model parameters, and decrypts the deblinded aggregation model parameters using the client's private key to obtain the aggregation model parameters.

[0073] In this embodiment, during the global model delivery phase, the client receives the deblinded aggregated model. Finally, the client's private key is used to decrypt the deblinded aggregation model to obtain the aggregation model parameters .

[0074] The technical effects of this application are described below with reference to specific embodiments and experimental data.

[0075] The experimental environment was set up and run on an Intel(R) Xeon(R) Gold 6128 CPU @ 3.40 GHz, 64 GB of memory, and Ubuntu 18.04.3 LTS 64-bit. The system was implemented in Python using pypbc version 0.5.14. To verify the effectiveness, a comparative analysis was conducted using two existing methods, MKAgg and PTK, in the same experimental environment.

[0076] In terms of communication overhead, the method of this application is compared with the MKAgg and PTK methods, and the comparison results are shown in Table 1. The security aggregation stage includes the proxy re-encryption stage, the model aggregation stage, and the ciphertext conversion stage. n represents the number of clients, and d represents the dimension of the model parameters. Indicates the length of the EC-AFGH scheme ciphertext, As shown in Table 1, the method of this application reduces the communication overhead in the security aggregation stage compared with the MKAgg method. Since the communication overhead of the PTK scheme in the model aggregation stage is linearly related to the number of clients and the dimensions of the model parameters, while the method of the present application is only linearly related to the dimensions of the model parameters, the method of the present application reduces the communication overhead more than the PTK method.

[0077] Table 1. Communication overhead comparison

[0078]

[0079] In terms of computational overhead, we first evaluate the computational overhead of the method of this application as the parameter dimension changes, such as Figure 3 As shown in Table 2, when the parameter dimension is 5000, the encryption time (Enc) of this application's method is less than 2 seconds, and the decryption time (Dec) is only 1 second. This application's method is compared with the MKAgg and PTK methods. The comparison results are shown in Table 2. Exp represents modular exponentiation, Mul represents multiplication, BM represents bilinear mapping, and Log represents logarithm. As shown in Table 2, compared with the MKAgg and PTK methods, this application's method can reduce computational overhead in data upload, security aggregation, and model delivery.

[0080] Table 2 Computational overhead comparison

[0081]

[0082] The federated model aggregation encryption method provided by the embodiment of the present application adopts a dual-server architecture of an aggregation server and an auxiliary server. The client and the auxiliary server determine a shared key through key exchange, generate a blinding factor using the shared key, blind the local model parameters using the blinding factor, and send them to the aggregation server after encryption, which can ensure the security of the client's private data; the ciphertext local model parameters under the client's public key are converted into ciphertext model parameters under the aggregation server's public key through a proxy re-encryption algorithm, which can ensure the correct execution of homomorphic aggregation operations; in order to enable the client to use its private key to decrypt, the aggregation server decrypts the aggregated ciphertext model parameters, and encrypts them based on the client's public key to obtain the aggregated model parameters based on the public key of each client. The aggregation server and the auxiliary server collaborate to perform ciphertext conversion processing, eliminate the blinding factor, generate deblinded aggregated model parameters, and send them to each client. The method of the present application can ensure the security of the client's private data and improve the availability of the model without adding additional system communication overhead and computing overhead.

[0083] It should be noted that the method of the embodiment of the present application can be performed by a single device, such as a computer or server. The method of this embodiment can also be applied in a distributed scenario and performed by multiple devices working together. In such a distributed scenario, one of the multiple devices may only perform one or more steps of the method of the embodiment of the present application, and the multiple devices will interact with each other to complete the method.

[0084] It should be noted that the foregoing description of this specification is based on specific embodiments. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims can be performed in an order different from that described in the embodiments and still achieve the desired results. Furthermore, the processes depicted in the accompanying drawings do not necessarily require the specific order shown or the sequential order to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0085] like Figure 2 As shown, the embodiment of the present application also provides a federated model aggregate encryption system, including:

[0086] The client is configured to blind the local model parameters using the generated blinding factors, encrypt the blinded local model parameters using the client's public key to generate ciphertext local model parameters, and send the ciphertext local model parameters to the aggregation server; and receive the unblinded aggregated model parameters, decrypt the unblinded aggregated model parameters using the client's private key to obtain the aggregated model parameters.

[0087] The auxiliary server is used to calculate the aggregation blinding factor based on the set of clients participating in the aggregation, encrypt the aggregation blinding factor using the client's public key to obtain the ciphertext aggregation blinding factor, and send the ciphertext aggregation blinding factor to the aggregation server;

[0088] The aggregation server is used to receive the ciphertext local model parameters, convert the ciphertext local model parameters of the client into ciphertext model parameters under the public key of the aggregation server based on the proxy re-encryption method, and send the set of clients participating in the aggregation to the auxiliary server; based on the ciphertext model parameters under the public key of the aggregation server, aggregate and generate the aggregated ciphertext model parameters under the public key of the aggregation server; use the private key of the aggregation server to decrypt the aggregated ciphertext model parameters to obtain the aggregated model parameters, use the public key of the client to encrypt the aggregated model parameters to obtain the aggregated model parameters under the public key of the client; determine the deblinded aggregated model parameters based on the aggregated model parameters under the public key of the client and the ciphertext aggregation blinding factor, and send the deblinded aggregated model parameters to the client.

[0089] The system of the above embodiment is used to implement the corresponding method in the above embodiment, and has the beneficial effects of the corresponding method embodiment, which will not be described in detail here.

[0090] Figure 4 A more specific hardware structure diagram of an electronic device provided in this embodiment is shown. 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 communicatively connected to each other within the device via the bus 1050.

[0091] The processor 1010 can be implemented using 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.

[0092] The memory 1020 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage devices, dynamic storage devices, 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 through software or firmware, the relevant program code is stored in the memory 1020 and is called and executed by the processor 1010.

[0093] The input / output interface 1030 is used to connect to input / output modules to enable information input and output. The input / output modules can be configured as components within the device (not shown) or externally connected to the device to provide corresponding functions. Input devices may include a keyboard, mouse, touch screen, microphone, and various sensors. Output devices may include a display, speaker, vibrator, indicator light, and the like.

[0094] The communication interface 1040 is used to connect to a communication module (not shown) to enable communication between the device and other devices. The communication module can communicate via wired means (such as USB, network cable, etc.) or wireless means (such as mobile network, Wi-Fi, Bluetooth, etc.).

[0095] The bus 1050 comprises a pathway for transmitting information between various components of the device, such as the processor 1010 , the memory 1020 , the input / output interface 1030 , and the communication interface 1040 .

[0096] 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 a specific implementation, the device may also include other components necessary for normal operation. In addition, it will be understood by those skilled in the art that the above device may only include the components necessary to implement the embodiments of this specification, and does not necessarily include all the components shown in the figure.

[0097] The electronic devices of the above embodiments are used to implement the corresponding methods in the above embodiments and have the beneficial effects of the corresponding method embodiments, which will not be described in detail here.

[0098] The computer-readable media of this embodiment includes permanent and non-permanent, removable and non-removable media that can be used to store information by any method or technology. The 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 disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, tape 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.

[0099] Those skilled in the art should understand that the discussion of any of the above embodiments is merely illustrative and is not intended to imply that the scope of the present disclosure is limited to these examples. Based on the concept of the present disclosure, the technical features in the above embodiments or different embodiments may be combined, the steps may be implemented in any order, and there are many other variations of the different aspects of the embodiments of the present application as described above, which are not provided in detail for the sake of simplicity.

[0100] In addition, to simplify the description and discussion, and to avoid obscuring the embodiments of the present application, well-known power / ground connections to integrated circuit (IC) chips and other components may or may not be shown in the provided figures. Furthermore, devices may be shown in block diagram form to avoid obscuring the embodiments of the present application, and this also takes into account the fact that the details of the implementation of these block diagram devices are highly dependent on the platform on which the embodiments of the present application will be implemented (i.e., these details should be fully understood by those skilled in the art). Where specific details (e.g., circuits) are set forth to describe exemplary embodiments of the present disclosure, it will be apparent to those skilled in the art that the embodiments of the present application can be implemented without these specific details or with variations therefrom. Therefore, these descriptions should be considered illustrative rather than restrictive.

[0101] Although the present disclosure has been described in conjunction with specific embodiments thereof, many alternatives, modifications, and variations of these embodiments will be apparent to those skilled in the art in light of the foregoing description. For example, other memory architectures (e.g., dynamic RAM (DRAM)) may utilize the discussed embodiments.

[0102] The embodiments of the present application are intended to cover all such substitutions, modifications, and variations that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the embodiments of the present application should be included in the scope of protection of this disclosure.

Claims

1. A federated model aggregate encryption method, characterized in that: include: The client uses the generated blinding factor to blind the local model parameters, encrypts the blinded local model parameters using the client's public key to generate ciphertext local model parameters, and sends the ciphertext local model parameters to the aggregation server; The aggregation server receives the encrypted local model parameters, converts the encrypted local model parameters into encrypted model parameters under the public key of the aggregation server based on the proxy re-encryption method, and sends the client set participating in the aggregation to the auxiliary server, including: the aggregation server The encrypted local model parameters of each client , based on the proxy re-encryption method, using the re-encryption key The first The ciphertext local model parameters of each client are converted into the ciphertext model parameters under the public key of the aggregation server ; Among them, the re-encryption key It is generated during the client initialization phase and sent to the aggregation server. It is The local model parameters of each client, It is A client-generated blinding factor, is the public key of the aggregation server, It is The public key of the client; The aggregation server aggregates and generates the aggregated ciphertext model parameters under the public key of the aggregation server based on the ciphertext model parameters under the public key of the aggregation server; wherein the method for aggregating and generating the aggregated ciphertext model parameters under the public key of the aggregation server is: in, is the aggregate ciphertext model parameter, is the number of clients participating in the aggregation; The aggregation server uses the private key of the aggregation server to decrypt the aggregation ciphertext model parameters to obtain the aggregation model parameters, and uses the public key of the client to encrypt the aggregation model parameters to obtain the aggregation model parameters under the client public key, including: The aggregation server uses the private key of the aggregation server to aggregate the ciphertext model parameters Decrypt and get the aggregate model parameter w+r. The aggregate model parameters are encrypted with the public key of each client to obtain the aggregate model parameters under the client public key. ; The auxiliary server calculates the aggregation blind factor according to the set of clients participating in the aggregation, encrypts the aggregation blind factor using the public key of the client, obtains the ciphertext aggregation blind factor, and sends the ciphertext aggregation blind factor to the aggregation server; The aggregation server determines the deblinded aggregation model parameters according to the aggregation model parameters under the client public key and the ciphertext aggregation blinding factor, and sends the deblinded aggregation model parameters to the client, including: The aggregation server calculates the deblinded aggregation model parameters using homomorphic addition according to the aggregation model parameters under the client public key and the ciphertext aggregation blind factor, which is expressed as: in, For the The aggregate model parameters for the unblinded client, For the secondary server, use The ciphertext aggregate blinding factor is obtained by encrypting the aggregate blinding factor with the public key of each client, where r is the aggregate blinding factor; The client receives the deblinded aggregation model parameters, and decrypts the deblinded aggregation model parameters using the client's private key to obtain the aggregation model parameters.

2. The method according to claim 1, characterized in that The client uses the generated blinding factor to blind the local model parameters, including: The client and the auxiliary server determine a shared key through key exchange, use the shared key as a seed of a pseudo-random generator, use the pseudo-random generator to generate a blinding factor, and use the blinding factor to blind the local model parameters.

3. The method according to claim 1, characterized in that The auxiliary server calculates the aggregation blinding factor according to the set of clients participating in the aggregation, including: The auxiliary server determines the blinding factor corresponding to each client in the client set participating in the aggregation from a pre-generated blinding factor set; wherein the blinding factor set is a set of blinding factors of all clients participating in the federated learning; The blinding factor corresponding to each client in the set of clients participating in the aggregation is added up to obtain the aggregation blinding factor.

4. A federated model aggregate encryption system, characterized in that: For implementing the federated model aggregate encryption method as claimed in claim 1, the system comprises: The client is used to blind the local model parameters using the generated blinding factors, encrypt the blinded local model parameters using the public key of the client, generate ciphertext local model parameters, and send the ciphertext local model parameters to the aggregation server; and receive the unblinded aggregation model parameters, decrypt the unblinded aggregation model parameters using the private key of the client, and obtain the aggregation model parameters; The auxiliary server is used to calculate the aggregation blind factor according to the set of clients participating in the aggregation, encrypt the aggregation blind factor using the public key of the client, obtain the ciphertext aggregation blind factor, and send the ciphertext aggregation blind factor to the aggregation server; The aggregation server is used to receive the ciphertext local model parameters, convert the ciphertext local model parameters into ciphertext model parameters under the public key of the aggregation server based on the proxy re-encryption method, and send the client set participating in the aggregation to the auxiliary server; based on the ciphertext model parameters under the public key of the aggregation server, aggregate and generate the aggregated ciphertext model parameters under the public key of the aggregation server; use the private key of the aggregation server to decrypt the aggregated ciphertext model parameters to obtain the aggregated model parameters, use the public key of the client to encrypt the aggregated model parameters to obtain the aggregated model parameters under the public key of the client; determine the de-blinded aggregated model parameters according to the aggregated model parameters under the public key of the client and the ciphertext aggregation blind factor, and send the de-blinded aggregated model parameters to the client.

5. The system according to claim 4, characterized in that The client is used to determine a shared key through key exchange with the auxiliary server, use the shared key as a seed of a pseudo-random generator, generate a blinding factor using the pseudo-random generator, and use the blinding factor to blind the local model parameters.

6. The system according to claim 4, characterized in that The aggregation server is used to The encrypted local model parameters of each client , based on the proxy re-encryption method, using the re-encryption key The first The ciphertext local model parameters of each client are converted into the ciphertext model parameters under the public key of the aggregation server ; Among them, the re-encryption key It is generated during the client initialization phase and sent to the aggregation server. It is The local model parameters of each client, It is A client-generated blinding factor, is the public key of the aggregation server, It is The client's public key.