Privacy protection federated learning training method, system and device based on homomorphic proxy re-encryption and medium

Through homomorphic proxy re-encryption technology, the mask is generated and encrypted in the preprocessing stage, and the edge server selects participants for local aggregation, solving the problems of excessive computing burden and protocol complexity in federated learning, realizing lightweight gradient encryption and flexible participant selection, and improving the privacy protection and stability of model training.

CN120474748APending Publication Date: 2025-08-12ENG UNIV OF THE CHINESE PEOPLES ARMED POLICE FORCE
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510545777.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-28
Publication Date
2025-08-12

AI Technical Summary

Technical Problem

In the industrial Internet of Things, existing federated learning methods have problems with excessive computing burden and protocol complexity in the data sharing process, especially on resource-constrained devices, making it difficult to achieve flexible participant selection and lightweight gradient encryption.

Method used

Using homomorphic proxy re-encryption technology, by generating and encrypting masks in the preprocessing stage, the edge server selects participants for local aggregation, and uses proxy re-encryption technology to remove masks, providing correct gradient aggregation results, reducing computational overhead and supporting flexible participant selection.

Benefits of technology

It realizes the protection of data privacy, reduces computing load during the joint modeling process of multiple participants, supports flexible participant selection, optimizes data aggregation, improves model generalization capabilities and training stability, and reduces network traffic and computing resource requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120474748A_ABST
    Figure CN120474748A_ABST
Patent Text Reader

Abstract

The invention provides a privacy protection federated learning training method, system and device based on homomorphic proxy re-encryption and a medium, participants can generate a large number of masks in advance and encrypt the masks in a preprocessing stage, and the encrypted masks are stored on an edge server; when the local training gradient is uploaded, a participant only needs to perform simple addition operation on the gradient and the mask, so that the minimum calculation overhead is realized; the edge server firstly selects a plurality of participants to carry out local aggregation, and a correct gradient aggregation result can be provided by removing a mask through a proxy re-encryption technology. The neural network model training framework provided by the invention has the characteristics of client selection and lightweight encryption, aims to protect the privacy of data in the joint modeling process of a plurality of participants, and has the characteristics of flexible participant selection, lightweight gradient encryption and the like.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of data encryption and privacy protection, and relates to a privacy-preserving federated learning training method, system, device and medium based on homomorphic proxy re-encryption. Background Art

[0002] With the increasing maturity of IoT technology, the Industrial Internet of Things (IIoT) has been widely applied in various fields, including smart manufacturing and smart factories, significantly improving production efficiency and achieving efficient management. Data collection and processing by intelligent devices, combined with deep learning algorithms for analysis and optimization, has provided a new direction for the development of smart industry. However, data owners have limited data resources, making it difficult to independently train high-quality models. Furthermore, data security and user privacy issues restrict data sharing, leading to the phenomenon of data silos.

[0003] To solve this problem, federated learning, as an emerging deep learning training method, allows each individual data owner to keep the data locally and only upload the model gradient to the server for collaborative training, thereby achieving the purpose of privacy protection.

[0004] Although federated learning training methods effectively break down data silos, external attackers or semi-trusted servers may still be able to infer users' private information through model gradients. Currently, data aggregation, which uses cryptographic techniques to protect gradient privacy, can provide strong protection for user data privacy. Mainstream data aggregation technologies include homomorphic encryption and masking. While homomorphic encryption-based gradient aggregation protocols can ensure privacy, they impose a heavy computational burden on resource-constrained devices such as smart devices. In contrast, masked gradient aggregation protocols offer advantages in terms of local computational overhead, but they significantly increase protocol complexity when faced with uncertain participants. Therefore, in federated learning for industrial intelligent systems, designing data aggregation methods that support flexible participant selection and lightweight gradient encryption is a pressing issue in the industrial Internet of Things (IIoT). Summary of the Invention

[0005] In response to the problems existing in the prior art, the present invention provides a privacy-preserving federated learning training method, system, device and medium based on homomorphic proxy re-encryption, thereby protecting the privacy of data in the joint modeling process of multiple participants, while combining features such as flexible participant selection and lightweight gradient encryption, reducing computational effort, streamlining the complexity of the protocol, and optimizing the data aggregation method.

[0006] The present invention is achieved through the following technical solutions:

[0007] A privacy-preserving federated learning training method based on homomorphic proxy re-encryption, including:

[0008] Based on the cloud server CS and each participant P i Generate their respective public and private key pairs; Participant P i Create re-encryption key RK i , and sent to the edge server ES;

[0009] Participants randomly generate mask E locally i , and encrypt the mask E with its own public key i Get the first ciphertext C i , sent to the edge server ES;

[0010] The edge server ES uses the re-encryption key RK i For the first ciphertext C i After re-encryption, the second ciphertext is obtained and store;

[0011] Participant P i The neural network model is trained locally and the mask E is used i Encrypt the gradient D generated by this round of training i , get the ciphertext gradient Send to edge server ES;

[0012] The edge server ES selects several participants and sends the ciphertext gradient generated by the selected participants in this round of training Second ciphertext with the selected participants Add and aggregate them to obtain the encrypted aggregate gradient T, which is sent to the cloud server CS;

[0013] The encrypted aggregate gradient T is decrypted using the private key through the cloud server CS to obtain the aggregated gradient to update the global neural network model, and then distributed to participants for the next round of training until the neural network model converges.

[0014] Preferably, based on the cloud server CS and each participant P i Generate their respective public and private key pairs; Participant P i Create re-encryption key RK i , and sent to the edge server ES, specifically:

[0015] The cloud server CS calls KeyGen to generate its own public and private key pair (PK c ,SK c ), each participant P i (1≤i≤N) call KeyGen to generate their respective public and private key pairs (PK i ,SK i ), where 1≤i≤N, the integer N is the number of participants; each participant P i(1≤i≤N) Call ReKeyGen to create the re-encryption key RK i Participant P i (1≤i≤N) the obtained re-encryption key RK i Sent to the edge server ES.

[0016] Preferably, the participant randomly generates the mask E locally i , and encrypt the mask E with its own public key i Get the first ciphertext C i , sent to the edge server ES, specifically:

[0017] Each participant P i (1≤i≤N) Generate a random mask locally The integer n represents the dimension, and the integer q is used to limit the value space to [0,q-1]. Each participant P i (1≤i≤N) Encrypt the mask E using your own public key i , get the first ciphertext C i , namely Enc(PK i ,E i )→C i , then the first ciphertext C i Sent to the edge server ES, where 1≤i≤N, the integer N represents the number of participants;

[0018] The mask E i Expressed in the form of a vector, the mask E i The vector size of is the same as the gradient size, both are vectors of length n.

[0019] Preferably, the second ciphertext Stored in the tuple list List established by the edge server ES.

[0020] Preferably, the edge server ES selects several participants and generates the ciphertext gradient generated by the selected participants in this round of training. Second ciphertext with the selected participants Add and aggregate them to obtain the encrypted aggregate gradient T, which is sent to the cloud server CS. Specifically:

[0021] The edge server ES collects the ciphertext gradients of all participants After that, a number of participants are selected according to the preset rules, and these selected participants form a set For all participants belonging to the set The ciphertext gradient generated by this round of training With selected participants Add them together to calculate the encrypted aggregate gradient T. The number of elements in the set is marked as And the encrypted aggregate gradient T and Forwarded to the cloud server CS.

[0022] Preferably, the encrypted aggregate gradient T is calculated as follows:

[0023]

[0024] Where: is the second ciphertext, is the ciphertext gradient.

[0025] Preferably, the edge server ES receives the ciphertext gradient provided by each participant The federated averaging algorithm is used to aggregate multiple gradients into a single gradient; the aggregated gradient is sent to the cloud server CS.

[0026] A privacy-preserving federated learning training system based on homomorphic proxy re-encryption, including:

[0027] Key generation module, based on cloud server CS and each participant P i Generate their respective public and private key pairs; Participant P i Create re-encryption key RK i , and sent to the edge server ES;

[0028] Mask generation and encryption module, used by participants to randomly generate mask E locally i , and encrypt the mask E with its own public key i Get the first ciphertext C i , sent to the edge server ES;

[0029] Re-encryption module, used for edge server ES through re-encryption key RK i For the first ciphertext C i After re-encryption, the second ciphertext is obtained and store,

[0030] Ciphertext gradient acquisition module for participant P i The neural network model is trained locally and the mask E is used i Encrypt the gradient D generated by this round of training i , get the ciphertext gradient Send to edge server ES;

[0031] Aggregation module, used by edge server ES to select several participants and generate the ciphertext gradient generated by the selected participants in this round of training Second ciphertext with the selected participants Add and aggregate them to obtain the encrypted aggregate gradient T, which is sent to the cloud server CS;

[0032] The decryption module is used to decrypt the encrypted aggregate gradient T using the private key through the cloud server CS, obtain the aggregated gradient to update the global neural network model, and then distribute it to participants for the next round of training until the neural network model converges.

[0033] A computer device comprises a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of a privacy-preserving federated learning training method based on homomorphic proxy re-encryption are implemented.

[0034] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of a privacy-preserving federated learning training method based on homomorphic proxy re-encryption.

[0035] Compared with the prior art, the present invention has the following beneficial technical effects:

[0036] This paper proposes a privacy-preserving federated learning training method based on homomorphic proxy re-encryption. During the preprocessing phase, participants can pre-generate a large number of masks and encrypt them. These encrypted masks are then stored on edge servers. When uploading local training gradients, participants only need to perform a simple addition operation on the gradients and masks, minimizing computational overhead. The edge server first selects several participants for local aggregation and then, using proxy re-encryption, removes the masks to provide the correct gradient aggregation results. Therefore, the proposed neural network model training framework features client selection and lightweight encryption, aiming to protect data privacy during the joint modeling process among multiple participants while also offering flexible participant selection and lightweight gradient encryption. The method utilizes homomorphic proxy re-encryption, ensuring that participant gradients remain encrypted throughout the aggregation process, protecting the privacy of participant data during model training. Furthermore, the process of participants uploading encrypted gradients and edge server aggregation of these gradients involves only addition and modulo operations, resulting in very low computational overhead. Therefore, the encryption algorithm employed in this paper is lightweight and suitable for resource-constrained participants. In addition, even if the edge server arbitrarily selects participants, it will not affect the correctness of the aggregation result, because only the gradients contributed by participants who survive both the preprocessing and gradient aggregation stages will be correctly counted into the final aggregation result.

[0037] Furthermore, the advantages of flexible participant selection in federated learning are significant. First, it ensures data quality and diversity. Different client data distributions vary. For example, combining data from comprehensive and specialized medical hospitals can improve model generalization. Second, it optimizes communication costs and computing resources. Selecting highly representative and contributing clients reduces network traffic and conserves computing power. Third, it improves training stability and fairness by screening out problematic clients and accommodating clients from various institutions, ensuring steady model optimization and fair results.

[0038] Furthermore, lightweight encryption in federated learning can effectively reduce the computational burden on participants: compared to traditional, high-strength encryption algorithms, lightweight encryption requires significantly fewer client-side computing resources. Many IoT devices, such as smart bracelets and home sensors, that serve as clients of federated learning have limited computing power. Using lightweight encryption can meet privacy protection requirements while preventing device lag and slowdowns caused by complex cryptographic operations, ensuring smooth data collection and transmission. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] Figure 1 This is a flowchart of the steps of a privacy-preserving federated learning method based on homomorphic proxy re-encryption of the present invention.

[0040] Figure 2 It is a structural diagram of the neural network system training model of the present invention. DETAILED DESCRIPTION

[0041] The present invention will be further described in detail below with reference to specific embodiments, which are intended to explain the present invention rather than to limit it.

[0042] In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the embodiments described 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 making creative efforts should fall within the scope of protection of the present invention.

[0043] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below with reference to the accompanying drawings and embodiments. In addition, the technical features involved in the various embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other.

[0044] See also Figure 1 ,This invention provides a privacy-preserving federated learning method based on homomorphic proxy re-encryption,

[0045] The following steps are involved:

[0046] Step 1: Construct a neural network system training model containing three types of entities, including: N participants P i (1≤i≤N), edge server ES and cloud server CS.

[0047] The implementation process is divided into system initialization, preprocessing and gradient aggregation. The following are the detailed steps and logic of the algorithm:

[0048] Step 2: System initialization phase

[0049] (1) Key generation: The cloud server ES and the i-th participant generate their own public-private key pair (PK c ,SK c ) and (PK i ,SK i );

[0050] (2) Generation and distribution of re-encryption keys: The i-th participant creates a re-encryption key PK i And send it to the edge server ES.

[0051] (3) Generate a random prime number q and make q public.

[0052] Step 3: Preprocessing stage

[0053] (1) Mask generation and encryption: The i-th participant generates a random mask E locally i , and use your own public key PK i Encrypt this mask to get the first ciphertext C i , then C i Sent to the edge server ES.

[0054] (2) Re-encryption: The edge server ES creates a two-tuple list List to store the received ciphertext. For example, the user receives the first ciphertext C of the i-th user. i When the edge server ES first uses the re-encryption key RK i For the first ciphertext C i Re-encrypt to get the second ciphertext Then Add to the two-tuple list List.

[0055] Step 4: Gradient aggregation stage

[0056] (1) Gradient encryption: Participant P i The neural network model is trained locally and the mask E is used i Encrypt the gradient D generated by this round of training i , get the ciphertext gradient Send to edge server ES;

[0057] (2) Gradient aggregation: The edge server ES collects the encrypted ciphertext gradients of all participants According to certain rules, a number of participants are selected, and these selected participants form a set For all Compute encrypted aggregate gradients And forward the encrypted aggregate gradient T to the cloud server CS;

[0058] (3) Decryption: The cloud server CS uses the private key to decrypt the encrypted aggregated gradient T to obtain the aggregated gradient, and uses the aggregated gradient to update the global neural network model, which is then distributed to participants for subsequent training.

[0059] Specifically, the following is a further explanation in conjunction with the implementation steps:

[0060] (1) System model such as Figure 2 As shown, it contains 3 types of entities, whose functions are:

[0061] ① Participant P i (1≤i≤N): Participants have sufficient training samples and run neural network system model training locally using their own data. Training is divided into multiple rounds. After each round, participants encrypt their gradients and upload them to the edge server ES for aggregation.

[0062] ②Edge Server (ES): The edge server has sufficient computing and storage capabilities to receive encrypted gradients from each participant. It aggregates multiple gradients into a single gradient using a federated averaging algorithm. The aggregated gradient is then sent to the cloud server (CS).

[0063] ③ Cloud Server CS: The cloud server updates the global neural network model based on the aggregated gradients sent by the edge server. The updated global neural network model is distributed to participants for the next round of training. This process is repeated until the global neural network model is stable.

[0064] (2) Step 2: System initialization phase.

[0065] According to the security requirements of the system, the mainstream homomorphic proxy re-encryption scheme HPRE (Homomorphic Proxy Re-encryption) can be selected, including algorithms such as (KeyGen, ReKeyGen, Enc, ReEnc, EvalAdd, Dec). During the key generation process, the cloud server CS calls KeyGen to generate its own public and private key pair (PK c ,SK c ), each participant Pi (1≤i≤N) also calls KeyGen to generate their own public and private key pairs (PK i ,SK i ), where 1≤i≤N, the integer N is the number of participants; in the process of generating the re-encryption key, each participant P i (1≤i≤N) Call ReKeyGen to create a re-encryption key RK i Participant P i (1≤i≤N) the re-encryption key RK i Sent to the edge server ES.

[0066] Below we assume that the current model has been trained to round l, and each round includes a preprocessing stage and a gradient aggregation stage.

[0067] (3) Step 3: Preprocessing

[0068] ① Mask generation and encryption: Each participant P i (1≤i≤N) Generate a random mask locally The size of this mask vector is the same as that of the gradient, both are vectors of length n. i (1≤i≤N) Use your own public key to encrypt this mask, that is, Enc(PK i ,E i )→C i , then C i Sent to the edge server ES.

[0069] ② Re-encryption: The edge server ES uses the re-encryption key RK i (1≤i≤N) for the ciphertext C i Re-encryption, that is The edge server ES stores all the tuples In the List.

[0070] Step 4: Gradient aggregation stage

[0071] (1) Gradient encryption: After the local training of this round is completed, the participant P i (1≤i≤N) The gradient generated in this round of training is (Assume that the gradient has been transformed into an integer not exceeding q by linear transformation.) i (1≤i≤N) using mask E i Encryption D i Gradient, that is Finally, Sent to the edge server ES.

[0072] (2) Gradient aggregation: After the edge server ES collects the encrypted gradients of all participants, it selects a number of participants according to certain rules. These selected participants form a set For all calculate The number of elements in the set is marked as And T and Forwarded to the cloud server CS.

[0073] (4) Decryption: The cloud server CS uses the private key SK c Decryption, that is The aggregated gradient is G, which can be used to update the global neural network model of this round. The correctness of the gradient aggregation is verified as follows:

[0074]

[0075]

[0076] The correctness of the third equation comes from the property of proxy re-encryption. In federated learning, proxy re-encryption allows a semi-trusted edge server ES to transform the encrypted mask of the participant without decrypting it, that is, from the ciphertext C corresponding to the public key of the participant Pi i Convert to the ciphertext corresponding to the cloud server CS public key Therefore, the cloud server CS can also decrypt the final ciphertext T.

[0077] ES can select any collection And all the masks introduced will be completely eliminated. This is because during the preprocessing phase, the set The mask E of the participant j is encrypted and sent to the edge server; in the gradient aggregation stage, the collection The users in encrypt the gradients using these masks. In the two processes of preprocessing and gradient aggregation, these common masks E j They will cancel each other out, thus ensuring that the final aggregated gradient is correct.

[0078] However, after the global neural network model is updated in the first round, the latest global neural network model will be distributed to the participants for a new round of training until the model becomes stable.

[0079] Advantages of the present invention:

[0080] (1) Privacy protection: Due to the use of homomorphic proxy re-encryption, the gradients of participants remain encrypted throughout the aggregation process, protecting the privacy of participants' data during model training.

[0081] (2) Lightweight encryption: The process of participants uploading encrypted gradients and edge servers aggregating these gradients involves only addition and modular operations, resulting in very low computational overhead. Therefore, the encryption algorithm used in this invention is lightweight and suitable for participants with limited resources.

[0082] (3) Support flexible selection of participants: Even if the edge server arbitrarily selects participants, it will not affect the correctness of the aggregation result, because only the gradients contributed by participants who survive both the preprocessing and gradient aggregation stages will be correctly counted into the final aggregation result.

[0083] A privacy-preserving federated learning training system based on homomorphic proxy re-encryption, characterized by including:

[0084] Key generation module, based on cloud server CS and each participant P i Generate their respective public and private key pairs; Participant P i Create re-encryption key RK i , and sent to the edge server ES;

[0085] Mask generation and encryption module, used by participants to randomly generate mask E locally i , and encrypt the mask E with its own public key i Get the first ciphertext C i , sent to the edge server ES;

[0086] Re-encryption module, used for edge server ES through re-encryption key RK i For the first ciphertext C i After re-encryption, the second ciphertext is obtained and store,

[0087] Ciphertext gradient acquisition module for participant P i The neural network model is trained locally and the mask E is used i Encrypt the gradient D generated by this round of training i , get the ciphertext gradient Send to edge server ES;

[0088] Aggregation module, used by edge server ES to select several participants and generate the ciphertext gradient generated by the selected participants in this round of training Second ciphertext with the selected participants Add and aggregate them to obtain the encrypted aggregate gradient T, which is sent to the cloud server CS;

[0089] The decryption module is used to decrypt the encrypted aggregate gradient T using the private key through the cloud server CS, obtain the aggregated gradient to update the global neural network model, and then distribute it to participants for the next round of training until the neural model converges.

[0090] In another embodiment of the present invention, a computer device is provided, which includes a processor and a memory, wherein the memory is used to store a computer program, the computer program includes program instructions, and the processor is used to execute the program instructions stored in the computer storage medium. The processor may be a central processing unit (CPU), or may be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc., which is the computing core and control core of the terminal, which is suitable for implementing one or more instructions, specifically suitable for loading and executing one or more instructions to implement the corresponding method flow or corresponding function; the processor described in the embodiment of the present invention can be based on the operation of the privacy-preserving federated learning method of homomorphic proxy re-encryption.

[0091] In another embodiment of the present invention, the present invention further provides a storage medium, specifically a computer-readable storage medium (Memory), which is a memory device in a computer device for storing programs and data. It is understandable that the computer-readable storage medium here can include both built-in storage media in the computer device and, of course, extended storage media supported by the computer device. The computer-readable storage medium provides a storage space that stores the operating system of the terminal. In addition, one or more instructions suitable for being loaded and executed by the processor are also stored in the storage space. These instructions can be one or more computer programs (including program codes). It should be noted that the computer-readable storage medium here can be a high-speed RAM memory or a non-volatile memory, such as at least one disk memory. The processor can load and execute one or more instructions stored in the computer-readable storage medium to implement the corresponding steps of the privacy-preserving federated learning method based on homomorphic proxy re-encryption in the above embodiment.

[0092] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.

[0093] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0094] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.

[0095] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0096] It should be noted that the terms "including" and "having" and any variations thereof in the specification and claims of the present invention and the above-mentioned drawings are intended to cover non-exclusive inclusions. For example, a process, method, system, product or apparatus comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or are inherent to these processes, methods, products or apparatuses.

[0097] It will be understood that when used in this specification and the appended claims, the terms “comprises” and “comprising” indicate the presence of described features, integers, steps, operations, elements and / or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof.

[0098] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which this invention pertains. The terms used in this specification of the present invention are for the purpose of describing specific embodiments only and are not intended to limit the present invention. The term "and / or" as used herein includes any and all combinations of one or more of the associated listed items.

[0099] The above description is only a preferred embodiment of the present invention and does not limit the present invention in any form. Any ordinary technician in this industry can smoothly implement the present invention as shown in the drawings and described above. However, any equivalent changes, modifications and evolutions made by technicians familiar with this profession without departing from the scope of the technical solution of the present invention using the technical content disclosed above are all equivalent embodiments of the present invention. At the same time, any equivalent changes, modifications and evolutions made to the above embodiments based on the essential technology of the present invention are still within the scope of protection of the technical solution of the present invention.

Claims

1. A privacy-preserving federated learning training method based on homomorphic proxy re-encryption, characterized by: include, Based on the cloud server CS and each participant P i Generate their respective public and private key pairs; Participant P i Create re-encryption key RK i , and sent to the edge server ES; Participants randomly generate mask E locally i , and encrypt the mask E with its own public key i Get the first ciphertext C i , sent to the edge server ES; The edge server ES uses the re-encryption key RK i For the first ciphertext C i After re-encryption, the second ciphertext is obtained and store; Participant P i The neural network model is trained locally and the mask E is used i Encrypt the gradient D generated by this round of training i , get the ciphertext gradient Send to edge server ES; The edge server ES selects several participants and sends the ciphertext gradient generated by the selected participants in this round of training Second ciphertext with the selected participants Add and aggregate them to obtain the encrypted aggregate gradient T, which is sent to the cloud server CS; The encrypted aggregate gradient T is decrypted using the private key through the cloud server CS to obtain the aggregated gradient to update the global neural network model, and then distributed to participants for the next round of training until the neural network model converges.

2. A privacy-preserving federated learning training method based on homomorphic proxy re-encryption according to claim 1, characterized in that: Based on the cloud server CS and each participant P i Generate their respective public and private key pairs; Participant P i Create re-encryption key RK i , and sent to the edge server ES, specifically: The cloud server CS calls KeyGen to generate its own public and private key pair (PK c ,SK c ), each participant P i (1≤i≤N) call KeyGen to generate their respective public and private key pairs (PK i ,SK i ), where 1≤i≤N, the integer N is the number of participants; each participant P i (1≤i≤N) Call ReKeyGen to create the re-encryption key RK i Participant P i (1≤i≤N) the obtained re-encryption key RK i Sent to the edge server ES.

3. The privacy-preserving federated learning training method based on homomorphic proxy re-encryption according to claim 1 is characterized in that: Participants randomly generate mask E locally i , and encrypt the mask E with its own public key i Get the first ciphertext C i , sent to the edge server ES, specifically: Each participant P i (1≤i≤N) Generate a random mask locally The integer n represents the vector dimension, and the integer q is used to limit the mask value space to [0,q-1]. Each participant P i (1≤i≤N) Encrypt the mask E using your own public key i , get the first ciphertext C i , namely Enc(PK i ,E i )→C i , then the first ciphertext C i Sent to the edge server ES, where 1≤i≤N, the integer N represents the number of participants; The mask E i Expressed in the form of a vector, the mask E i The vector size of is the same as the gradient size, both are vectors of length n.

4. The privacy-preserving federated learning training method based on homomorphic proxy re-encryption according to claim 1 is characterized in that: The second ciphertext Stored in the tuple list List established by the edge server ES.

5. The privacy-preserving federated learning training method based on homomorphic proxy re-encryption according to claim 1 is characterized in that: The edge server ES selects several participants and generates the ciphertext gradient generated by the selected participants in this round of training. Second ciphertext with the selected participants Add and aggregate them to obtain the encrypted aggregate gradient T, which is sent to the cloud server CS. Specifically: The edge server ES collects the ciphertext gradients of all participants After that, a number of participants are selected according to the preset rules, and these selected participants form a set For all participants belonging to the set The ciphertext gradient generated by this round of training With selected participants Add them together to calculate the encrypted aggregate gradient T. The number of elements in the set is marked as And the encrypted aggregate gradient T and Forwarded to the cloud server CS.

6. A privacy-preserving federated learning training method based on homomorphic proxy re-encryption according to claim 5, characterized in that: The encrypted aggregate gradient T is calculated as follows: Where: is the second ciphertext, is the ciphertext gradient.

7. The privacy-preserving federated learning training method based on homomorphic proxy re-encryption according to claim 1 is characterized in that: The edge server ES receives the ciphertext gradient provided by each participant The federated averaging algorithm is used to aggregate multiple gradients into a single gradient; the aggregated gradient is sent to the cloud server CS.

8. A privacy-preserving federated learning training system based on homomorphic proxy re-encryption, characterized by: include, Key generation module, based on cloud server CS and each participant P i Generate their respective public and private key pairs; Participant P i Create re-encryption key RK i , and sent to the edge server ES; Mask generation and encryption module, used by participants to randomly generate mask E locally i , and encrypt the mask E with its own public key i Get the first ciphertext C i , sent to the edge server ES; Re-encryption module, used for edge server ES through re-encryption key RK i For the first ciphertext C i After re-encryption, the second ciphertext is obtained and store, Ciphertext gradient acquisition module for participant P i The neural network model is trained locally and the mask E is used i Encrypt the gradient D generated by this round of training i , get the ciphertext gradient Send to edge server ES; Aggregation module, used by edge server ES to select several participants and generate the ciphertext gradient generated by the selected participants in this round of training Second ciphertext with the selected participants Add and aggregate them to obtain the encrypted aggregate gradient T, which is sent to the cloud server CS; The decryption module is used to decrypt the encrypted aggregate gradient T using the private key through the cloud server CS, obtain the aggregated gradient to update the global neural network model, and then distribute it to participants for the next round of training until the neural network model converges.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, it implements the steps of a privacy-preserving federated learning training method based on homomorphic proxy re-encryption as described in any one of claims 1 to 7.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of a privacy-preserving federated learning training method based on homomorphic proxy re-encryption as described in any one of claims 1 to 7 are implemented.