Multi-dimensional multi-function data aggregation method and system for realizing privacy protection

By implementing multi-dimensional and multi-function operation on smart meter data, and using a SHE encryption system-based method, the problem of difficulty in meeting multi-dimensional data statistics and multi-function data operations in the prior art is solved, efficient data privacy protection and aggregation operations are achieved, and the efficiency of power grid data analysis and data confidentiality are improved.

CN119740188APending Publication Date: 2025-04-01ENG UNIV OF THE CHINESE PEOPLES ARMED POLICE FORCE
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411810856.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-10
Publication Date
2025-04-01

AI Technical Summary

Technical Problem

The prior art is difficult to meet the needs of multi-dimensional data statistics and multi-function data operations at the same time. The multi-dimensional data aggregation scheme cannot perform multi-function operations with encrypted data, while the multi-function data aggregation scheme cannot implement multi-dimensional fine-grained processing.

Method used

By implementing multidimensional and multifunctional operations on smart meter data, using a method based on SHE encryption system, the user's private key is distributed through a secure channel, the user updates his own mask and encodes the data into multidimensional data, and the control center decrypts the private key and public key and calculates the total power consumption.

Benefits of technology

The dual goals of data privacy protection and efficient aggregation operations are achieved, the efficiency of power grid data analysis is improved, the confidentiality and utilization of data are enhanced, and the computing efficiency is better than the existing Paillier encryption-based solution.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119740188A_ABST
    Figure CN119740188A_ABST
Patent Text Reader

Abstract

The invention discloses a multi-dimensional multi-function data aggregation method and system for realizing privacy protection, and the method comprises the following steps: in an aggregation period, randomly selecting a private key for a user, distributing the private key of the user through a secure channel, updating the own mask by the user according to the private key in each aggregation period, and transmitting the updated own mask to the user; a private key and a public key are generated for a control center, power consumption information of a user is obtained in real time, the user reports a ciphertext of the current power consumption information in each period, operation is carried out through homomorphic multiplication to obtain a result of a ciphertext inner product, and variance of the ciphertext is calculated through homomorphic variance to obtain multi-function aggregation data; according to the received multi-function aggregation data, the control center decrypts the obtained inner product ciphertext and variance ciphertext through a private key and a public key, and calculates the total power consumption; on the basis of an SHE encryption system, multi-function operation of data can be provided, the power grid data analysis efficiency is improved, and meanwhile the confidentiality and the utilization rate of the data are enhanced.
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 fusion, and in particular relates to a multi-dimensional and multi-function data aggregation method and system for realizing privacy protection. Background Art

[0002] Privacy protection and efficient data aggregation are two core research topics. These solutions can be roughly divided into the following categories:

[0003] (1) Paillier encryption system-based schemes: This type of scheme can realize data addition homomorphic operations, but is limited to only performing one of addition or multiplication, and cannot perform both at the same time. For example, the FPDA scheme enhances the fault tolerance of the system through the Shamir secret sharing mechanism; Shang proposed a privacy-preserving data aggregation scheme combining Paillier homomorphic encryption and ECDSA signature for edge computing-supported IIoT, which effectively solves the data privacy and integrity issues; Chen et al. combined the ElGamal homomorphic encryption system and Paillier homomorphic encryption technology to propose a flexible group-based multi-subset data aggregation scheme, which solves the problem that real-time data in smart grids may leak user privacy information.

[0004] (2) Scheme based on BGN encryption system: The BGN scheme supports infinite addition operations and finite multiplication operations, providing a new solution for data privacy. Khan et al. combined the Boneh-Goh-Nissam (BGN) homomorphic encryption technology and the elliptic curve digital signature algorithm (ECDSA) to propose a privacy-preserving data aggregation scheme in smart grids supported by fog computing, which solves the data aggregation problem in the presence of faulty smart meters and ensures data privacy, integrity and source authentication.

[0005] (3) Privacy protection algorithms based on other encryption technologies: There are many schemes in this category that are different from the above two encryption algorithms. Abdallah and Shen combined lightweight lattice-based homomorphic encryption technology and direct communication between smart home appliances, and proposed an aggregation scheme to protect the privacy and integrity of residential users' electricity consumption data in smart grids, achieving the goal of protecting user privacy and data security without increasing the computing burden of smart meters; Wang et al. combined homomorphic encryption technology and bilinear pairing technology to propose an anonymous security aggregation scheme (ASAS) that protects data privacy and user identity in fog computing environments, and successfully achieved secure and efficient uploading and processing of encrypted data between public cloud servers and terminal devices; PDA-SP is a smart grid data aggregation scheme based on the SHE encryption system, which uses the public key of the control center to encrypt data, but this method cannot guarantee the privacy of individual user data.

[0006] According to the actual needs of smart grid, it is necessary to process the data uploaded by smart meters more finely, so that user data can be processed and analyzed more in an encrypted manner. There are two main directions:

[0007] (1) Multidimensional data statistics: This type of scheme enables the control center to optimize the power distribution plan based on multidimensional power analysis by fine-grained division of user power consumption. Shen combined the Paillier cryptographic system and Horner's law to propose an efficient privacy-preserving data aggregation scheme, which solved the problem of secure aggregation of multidimensional power consumption data in smart grids and achieved flexible and efficient management of large-scale user groups. However, this scheme may need further research and improvement in terms of security issues such as resisting differential attacks. Zeng combined the Paillier homomorphic encryption technology and the HMQV key negotiation protocol to propose a multi-subset data aggregation scheme (MSDA) that does not require a trusted third party, which solved the problems of user privacy protection and dynamic user management in smart grids, and achieved user data privacy protection and efficient multi-subset aggregation functions. However, this scheme may need further optimization in actual deployment to cope with more complex network environments and security threats.

[0008] (2) Multi-function data operations: This type of scheme allows summation, variance, and average operations on user power consumption in an encrypted state, providing more dimensions for user power consumption analysis. Zhao combined the SomewhatHomomorphic Encryption (SHE) technology and the packaging method to propose an intelligent and practical privacy-preserving data aggregation scheme, which solves the problems of diversified billing, multi-function statistics, and efficiency in fog computing-based smart grids, and achieves efficient data aggregation and secure computing while protecting user privacy. However, further optimization may be required in actual deployment to cope with more complex network environments and security threats.

[0009] However, existing solutions are difficult to meet the needs of multidimensional data statistics and multi-function data operations at the same time. Multidimensional data aggregation solutions are mainly based on exponential encoding. Although they can process multidimensional data, they cannot perform multi-function operations on encrypted data, such as data square, data variance, etc. At the same time, although multi-function data aggregation solutions can perform complex operations on encrypted data, they cannot achieve multi-dimensional fine-grained processing of user data. Summary of the invention

[0010] In order to solve the problems existing in the prior art, the present invention provides a multi-dimensional and multi-function data aggregation method for realizing privacy protection, achieving the dual goals of data privacy protection and efficient aggregation operation. Through the multi-dimensionalization and multi-function operation of smart meter data, the scheme of the present invention not only improves the efficiency of power grid data analysis, but also enhances the confidentiality and utilization of data.

[0011] In order to achieve the above object, the technical solution adopted by the present invention is: a multi-dimensional multi-function data aggregation method for realizing privacy protection, comprising the following steps:

[0012] In an aggregation cycle, a private key is randomly selected for the user and distributed through a secure channel. In each aggregation cycle, the user updates his own mask according to the private key.

[0013] Generate private and public keys for the control center to obtain the user's power consumption information in real time. The user reports the ciphertext of the current power consumption information in each cycle, and the result of the ciphertext inner product is obtained through homomorphic multiplication. The variance of the ciphertext is calculated through homomorphic variance to obtain multi-function aggregated data;

[0014] Based on the received multi-function aggregate data, the control center decrypts the obtained inner product ciphertext and variance ciphertext through the private key and public key, and calculates the total power consumption.

[0015] Furthermore, within an aggregation cycle, the trusted center randomly selects a private key for the user. The user's private key is distributed through a secure channel. In each aggregation cycle, the user updates his own mask to The maximum number of digits (d i0 d i2 ,…,d il ), constructed as follows: m i (x) = d i0 +d i1 x+d i2 x 2 +…+d il x l , after encoding, the multidimensional data contained by the user is represented as m i (x).

[0016] Further, generating a private key and a public key for the control center includes: the trusted center generates a private key and a public key for the control center, selects an element in s←χ, selects a1←R q as a random element, e←-χ as an error, let sk=s be the private key, calculate a0=-(a1·s+t·e), pk=(a0,a1) is the public key, and denote the hash function SHA-256 as H.

[0017] Furthermore, by performing homomorphic multiplication, the results of the ciphertext inner product include:

[0018] Fog nodes use homomorphic addition For all ciphertexts c i (i=1,2,3…n1) for polymerization, using c i Calculate C sum for Send the calculation results to the control center;

[0019] The fog node first removes the user's mask, Calculate the result of the ciphertext inner product;

[0020] Furthermore, the variance of the ciphertext is calculated by homomorphic variance: for a series of ciphertexts cc1,cc2,...,cc n , calculate the average ciphertext Next, define the homomorphic variance operation For each ciphertext cc i The corresponding average ciphertext difference Then calculate the squared difference And perform homomorphic addition on all squared differences and finally divide by n-1.

[0021] Furthermore, the control center decrypts the obtained inner product ciphertext and variance ciphertext through the private key and the public key, and calculates the total power consumption including:

[0022] Perform the following calculation to obtain the total electricity usage:

[0023]

[0024] The control center decrypts the obtained inner product ciphertext as follows:

[0025]

[0026] in is the representation of the remaining items, and the variance ciphertext is decrypted using the same steps.

[0027] The present invention also provides a multi-dimensional and multi-function data aggregation system for realizing privacy protection, a trusted center, a control center, a fog node, and a smart meter;

[0028] The trusted center is the most reliable entity in the system, responsible for providing parameter initialization, user registration services and online user mask aggregation for the smart grid;

[0029] The fog nodes are used to aggregate the ciphertext sent by users and forward the results to the control center;

[0030] The control center performs the decryption process, obtains the correct aggregated data results, and processes the aggregated values;

[0031] The smart meter collects the amount of electricity used by the user within the specified timestamp, performs encryption operations for privacy protection and sends the encrypted information to the connected fog nodes.

[0032] Furthermore, within an aggregation cycle, the trusted center randomly selects a private key for the user and distributes the private key of the smart meter through a secure channel. In each aggregation cycle, the smart meter updates its own mask according to the private key.

[0033] The trusted center generates private keys and public keys for the control center. The smart meter obtains the user's power consumption information in real time. The smart meter reports the ciphertext of the current power consumption information in each cycle. The fog node performs operations through homomorphic multiplication to obtain the result of the inner product of the ciphertext, and calculates the variance of the ciphertext through homomorphic variance to obtain multi-function aggregated data.

[0034] Based on the received multi-function aggregate data, the control center decrypts the obtained inner product ciphertext and variance ciphertext through the private key and public key, and calculates the total power consumption.

[0035] The present invention can also provide a computer device, including a processor and a memory, the memory is used to store a computer executable program, the processor reads the computer executable program from the memory and executes it, and when the processor executes the computer executable program, it can implement the multi-dimensional and multi-function data aggregation method for realizing privacy protection as described in the present invention.

[0036] At the same time, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, the multi-dimensional and multi-function data aggregation method for realizing privacy protection described in the present invention can be implemented.

[0037] Compared with the prior art, the present invention has at least the following beneficial effects: by multidimensionalizing and multi-functioning the smart meter data, the scheme of the present invention not only improves the efficiency of power grid data analysis, but also strengthens the confidentiality and utilization of the data. The scheme is based on the SHE encryption system and can provide multi-function operations of data, such as aggregation, inner product and variance, to improve the utilization of data analysis. In terms of security analysis, the scheme of the present invention proves that it can resist chosen ciphertext attacks. Experimental verification shows that the scheme of the present invention is superior to the existing scheme based on Paillier encryption in terms of computational efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] Figure 1 Schematic diagram of the system model.

[0039] Figure 2 Schematic diagram of the multidimensional data encoding and decoding process.

[0040] Figure 3 Comparison chart of encryption time for different schemes.

[0041] Figure 4 Comparison chart of decryption time for different schemes.

[0042] Figure 5 Comparison chart of aggregation times for different scenarios.

[0043] Figure 6 A comparison chart of processing time for different solutions. DETAILED DESCRIPTION

[0044] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0045] The solution of the present invention is based on the smart grid framework and involves four types of entities, including a trusted center, a control center, fog nodes, and smart meters. The system model is as follows: Figure 1 shown.

[0046] (1) Trusted Center (Authority, TA): In the entire system, TA is the most reliable entity in the system and is responsible for providing parameter initialization, user registration services and online user mask aggregation for the smart grid. In the initialization phase, TA generates system parameters; in the registration phase, it sends keys to users and the control center through a secure channel; in the aggregation process, TA provides the FN with the mask and of online users.

[0047] (2) Control Center (CC): CC performs the decryption process, obtains the correct aggregated data results, and processes the aggregated values.

[0048] (3) Fog Node (FN): Fog nodes have strong computing capabilities and are mainly responsible for aggregating the ciphertext sent by users and forwarding the results to CC.

[0049] (4) Smart Meter (SM): Smart meters collect the amount of electricity used by users within a specified timestamp. In addition, SM performs encryption operations for privacy protection and sends the encrypted information to the connected fog nodes (FN).

[0050] In the attacker model of the present invention, it is assumed that the user (SM), front-end node (FN), control center (CC) and cloud service are "honest but curious" to some extent. These entities may try to obtain the user's private information if they follow the protocol correctly. The attack model of the present invention is based on the following assumptions:

[0051] (1) Both the front-end node and the control center are of the “honest but curious” type. They follow the protocol but are also eager to obtain the value of the smart meter reading.

[0052] (2) Although every user wants the electricity bill to be as low as possible, it is assumed that all smart meter users are honest.

[0053] (3) External adversaries It is possible to break into the control center, but only the final aggregated result can be obtained without obtaining the private information of individual users.

[0054] Based on the above system model and attack model, the present invention achieves the following design goals:

[0055] Confidentiality: Adversary The adversary cannot obtain the real-time electricity consumption information of any single user, that is, eavesdrop on the channels between the user and FN and between FN and CC, or invade the databases of FN and CC. It is impossible to obtain the real-time electricity consumption information of any individual user.

[0056] Multi-dimensional and multi-function operations: Multi-function operations such as sum, inner product, variance, etc. can be performed on multi-dimensional data, which meets the needs of intelligent development and enriches the application of power grid functions.

[0057] Efficiency: Lightweight quantum-resistant data aggregation. The semi-homomorphic encryption scheme based on RLWE has a faster aggregation process than the Paillier-based one, and is also quantum-resistant.

[0058] The present invention designs a multi-dimensional multi-function data aggregation scheme. In an aggregation cycle, the smart meter measures the user's power consumption and encrypts it with a private key. The encrypted power consumption is sent through the connection with the fog node. The fog node aggregates and sends the aggregated value to the CC, which decrypts it. The smart meter forms a multi-dimensional data of the total power consumption according to the type of electrical appliances. The list of symbols used in the designed scheme and their descriptions are shown in Table 1.

[0059] Table 1 Symbol Description

[0060]

[0061]

[0062] All SM, FN and CC need to be registered with TA. TA is SM i Randomly select a private key And SM i The private key of S Next, SM i Update your mask to TA generates a private key and a public key for CC. TA selects an element in s←X and chooses a1←R q As a random element, e←χ as an error. Let sk=s be the private key, calculate a0=-(a1·s+t·e), and pk=(a0,a1) be the public key. Let the hash function SHA-256 be H. SM i The maximum number of bits (d i0 d i2 ,…,d il ). It is constructed as follows: m i (x) = d i0 +d i1 x+d i2 x 2 +...+d il x l , after encoding, SM i The multidimensional data contained is represented as m i (x), hereinafter abbreviated as m i . Figure 2 The encoding and decoding process is shown. Algorithm 1 and Algorithm 2 show the data encoding and decoding process:

[0063] Algorithm 1. Data encoding Encode

[0064] Input: integer d i,0 ,d i,1 ,…,d i,l , x i

[0065] Output: Encoded polynomial m i d i,j

[0066] Algorithm: For integers, calculate m i , that is, m i (x) = d i0 +d i1 x+d i2 x 2 +...+d il x l And output m i .

[0067] Algorithm 2 Data Decoding

[0068] Input: polynomial m i

[0069] Output: Encoded coefficient d i,0 ,d i,1 ,…,d i,l

[0070] Algorithm: Calculate the polynomial m i (x) = d i0 +d i1 x+d i2 x 2 +...+d il x l The coefficients d i,0 ,d i,1 ,…,d i,l The value of .

[0071] User reporting stage: CC needs to collect the user's power consumption information in real time. SM reports the current power consumption information to FN every Ts time (for example, Ts = 15 minutes). The specific operation of SM is as follows:

[0072] Step 1: SM i First, randomly select R←u,f,g←χ and calculate the power consumption information m i The ciphertext

[0073] Step 2: SM i (c i ,Ts,ID i ) is sent to FN.

[0074] Data aggregation phase: FN records the set of users who receive messages within Ts as U2, note that U2∈U1, and sends the set of online users U2 to TA. TA converts the noise of online users into Sent to FN. According to CC’s requirements, customers’ electricity consumption data can be aggregated while protecting their privacy. i . FN by homomorphic addition For all ciphertexts c i (i=1,2,3…n1) for aggregation. Homomorphic addition Two ciphertexts of arbitrary length Defined as ccη=(c0,...,cη) and ccξ=(c0,...,cξ). Then, calculate the homomorphic addition Right now: The specific steps are as follows:

[0075] Step 1: The fog node FN first uses c i Calculate C sum for

[0076] Step 2: FN gets the result and sends it (C sum ,Ts) to CC.

[0077] Multi-function operation stage:

[0078] In order to conduct multi-dimensional analysis of user power consumption, multi-function operations are performed below. According to CC’s requirements for data operations, TA converts the noise of online users into Sent to FN, and then perform multi-function operations.

[0079] FN can be obtained by homomorphic multiplication Perform the operation. Homomorphic multiplication Right now Set x to a symbolic variable and ct to be its elements, ct′←R q [x], and then by Compute the embedding map for any u ≥ 1. Therefore, all elements Calculation method FN calculation Get the result of the ciphertext inner product; the specific steps are as follows:

[0080] Step 1: The fog node FN first removes the mask

[0081] Step 2: Get the result of the ciphertext inner product.

[0082] FN can be operated through homomorphic variance To calculate the variance of the ciphertext.

[0083] First, define the homomorphic averaging operation. For a series of ciphertexts cc1,cc2,...,cc n , calculate the average ciphertext Next, define the homomorphic variance operation For each ciphertext cc i The corresponding average ciphertext difference Then calculate the squared difference And perform homomorphic addition on all squared differences and finally divide by n-1: Where n is the number of ciphertexts, η i Each ciphertext cc i The dimension of represents homomorphic subtraction, Represents homomorphic multiplication. The specific steps are as follows:

[0084] Step 1: FN according to Calculate the average ciphertext

[0085]

[0086] Step 2: For each ciphertext c i The corresponding average ciphertext difference

[0087] Step 3: Perform homomorphic addition on all square differences and finally divide by n-1:

[0088]

[0089] Where n is the number of ciphertexts, η i is each ciphertext c i Dimension.

[0090] Data recovery phase:

[0091] After receiving the aggregation message from the fog node FN, CC can easily calculate the sum statistics without exposing the privacy of individual customers. Specifically, CC performs the following calculation to obtain the sum of electricity consumption:

[0092]

[0093] CC decrypts the obtained inner product ciphertext as follows:

[0094]

[0095] in is the representation of the remaining items, and the same decryption steps are performed on the variance ciphertext.

[0096] After receiving the aggregated ciphertext, CC performs decryption operation:

[0097]

[0098] Finally, the correct aggregated data can be obtained and decrypted successfully.

[0099] The present invention is through the challenger and the attacker The IND-CPA security of the scheme of the present invention is defined by a security game between the two stages, and the game is divided into the following three stages.

[0100] Initial stage: The challenger inputs the security parameter λ into KG(), outputs the public parameter pp, and sends pp to according to Whether the user's private key information is known, the users are divided into honest users and corrupt users.

[0101] Learning Phase: Attacker The challenger can be issued any polynomial number of the following queries:

[0102] (1) Private key query: Initiate a private key query to the challenger. If the querying user is a corrupt user, the challenger returns The corresponding user private key sk i , otherwise the terminal symbol ⊥ is returned.

[0103] (2) Encrypted query: Send plaintext m to the challenger i The challenger uses the CC public key to run Enc() to obtain the encrypted ciphertext C i , and returns it to If the plaintext in the query is a test plaintext, the challenger ignores A random value is returned for a request.

[0104] Challenge phase: When When the learning phase is considered to be over, two plaintexts (m0, m1) and the target user i* (i* cannot be a corrupted user) are selected and submitted to the challenger. The challenger randomly selects a random number d∈{0,1} and returns the result to user i. * The encrypted ciphertext Give As a challenge ciphertext.

[0105] After receiving the challenge ciphertext, you can continue to initiate private key queries and encryption queries in the learning phase, but the requirement is that you cannot query the private key of user i. * , the challenger's response remains consistent.

[0106] Guess: Finally, A stops the query and outputs a guess value d∈{0,1}. If d=d, then it is declared The advantages of winning are:

[0107]

[0108] If the attacker's advantage is negligible for any polynomial-time attacker, the multi-dimensional multi-function scheme based on RLWE is called IND-CPA secure.

[0109] According to the Kerckhoff principle, even if an attacker monitors the communications between all parties involved, he cannot use this information to crack the user's personal power consumption data or tamper with the transmitted data information. All data that can be obtained through eavesdropping is encrypted data, and the attacker cannot obtain substantial data from it. Only by holding the correct key can the true content of the data be decrypted.

[0110] Definition 1 (RLWE Assumption): For given parameters (κ, N, q, t, σ), RLWE assumes E κ,N,q,t,χ Show that the following two distributions are indistinguishable:

[0111] (1) From (R q ) 2 uniformly drawn from i ,b i ).

[0112] (2) First, A secret random vector s is uniformly drawn from R, and then for each i, q Uniformly extract b i ,from Select t (t and q are mutually prime) from , and extract e from χ i , and calculate a i =-(b i ·s+t·e i ).

[0113] Theorem 1: Assume there exists an IND-CPA attacker If we can break this scheme with the advantage of ε, then there must be a polynomial time algorithm β that can The advantages of RLWE are used to solve the RLWE problem.

[0114] Proof: Initialization phase: According to the attacker Whether the private key information of a user is known, the users are divided into honest users and corrupt users. The algorithm β accesses the oracle O sample Random uniform sampling attacker Query information, O sample by The probability of selecting R q ×R q Random uniform distribution on R q ×R q Upper RLWE Distribution A s,χ Take samples.

[0115] Learning Phase: Attacker You can query algorithm β any polynomial number of times:

[0116] (1) Private key query: attacker Initiate a private key query to algorithm β. If the queried user is not the target user i * , algorithm β runs the KG algorithm and returns the corresponding user private key p to the attacker i , otherwise the terminal symbol ⊥ is returned.

[0117] (2) Encrypted Query: Attacker Send plaintext m to algorithm β i To ciphertext C i The encrypted query algorithm β uses the encryption key sk c Run the Enc algorithm to get the encrypted ciphertext C i , and returns it to the attacker If the plaintext in the query is a test plaintext, the challenger ignores A random value is returned for a request.

[0118] Challenge phase: When When the learning phase is considered to be over, two plaintexts (m0, m1) and the target user i* (i* cannot be a corrupted user) are selected and submitted to the challenger. The challenger randomly selects a random number d∈{0,1} and accesses the oracle O sample Get the sample value calculate

[0119]

[0120] Sent as a challenge ciphertext to the attacker Attacker After receiving the challenge ciphertext, the above query can be continued, but it cannot be targeted at user i * , the way algorithm β responds is the same as in the previous stage.

[0121] Guess: Attacker After multiple queries, stop the query and output a guess value d′∈{0,1}. If d′=d, then the attacker is declared Win, algorithm β outputs 1 and determines O sample The sampling distribution is RLWE distribution A s,X , otherwise judge O sample The distribution of the output samples is R q ×R q The probability of the RLWE problem is discussed in the following two cases.

[0122] (1) Oracle O sample sampling The distribution of is RLWE distribution A s,χ The sampled value is in the form of Challenge Ciphertext At this time the attacker The probability of guessing correctly is Then algorithm β determines O sample The sampling distribution is RLWE distribution A s,χ The probability of So the challenge ciphertext In R q The random distribution is uniform and independent of the random value d. The probability of guessing correctly is Then algorithm β determines O sample The sampling distribution is RLWE distribution A s,χ The probability of

[0123] In summary, because O sample The probability of selecting the above announcement is When the attacker When the algorithm can break the solution with a non-negligible advantage ε, the probability that the algorithm β can crack the RLWE problem is

[0124] Advantages

[0125] The above results conflict with the difficulty assumption of the RLWE problem, because ε is non-negligible. Therefore, the cryptographic system designed by the present invention is semantically secure for CPA under the RLWE assumption.

[0126] The scheme ensures that user privacy data can be effectively protected. i It is distributed through a secure channel and is only used to encrypt user data, so it can be guaranteed that even if the SM is attacked Even if the private key is compromised, it will not be leaked. The encryption function Enc ensures the confidentiality of the data during transmission, because only the entity with the correct private key can decrypt the information. And by introducing the random mask factor p i , each user's electricity consumption data m i Before encryption, it will be masked with p i Combined to generate a new mask value c i . Because p i It is randomly selected and may be different for each communication, which increases the security of the scheme.

[0127] When FN aggregates data, it only operates on encrypted data without involving decryption, so it cannot obtain the user's private information. When TA calculates the noise sum, it only hashes the timestamp without involving the plaintext of the user data, so it cannot obtain private information from this process. During the aggregation process, FN keeps the data encrypted to ensure that the data is not tampered with during transmission.

[0128] CC decrypts the aggregated data using its private key. Due to the confidentiality of the private key, only CC can correctly decrypt and obtain the total statistics, which ensures the confidentiality and authenticity of the message.

[0129] The inner product operation of the scheme is a homomorphic encryption operation. Homomorphic encryption allows arithmetic operations to be performed directly on encrypted data. The decrypted result is the same as the result of the same operation performed directly on the plaintext. Therefore, in the inner product calculation, even if the data C1 and C2 are both encrypted, their homomorphic multiplication C prod =C1·C2 can still correctly reflect the inner product of the plaintext data. Due to the randomness of the mask and the mathematical properties of homomorphic encryption, through the challenge-response game, the attacker cannot distinguish the encrypted data of different users, nor can he extract any information about individual users from the encrypted inner product results.

[0130] The performance of the scheme is evaluated by measuring the encryption overhead, decryption overhead, inner product overhead, and aggregation overhead, and the communication overhead is also given. When conducting experimental analysis, the code is developed based on Helib, and the simulation system is an Intel(R) Core(TM) i5-8265U, 1.60GHzCPU, and 16G memory laptop. The SHE system uses a ciphertext length of 2048bit to achieve provably secure security parameters. The Paillier homomorphic cryptosystem uses 1024-bit prime numbers p and q to meet the provably secure parameters, and the ciphertext length is 4096bits. SHA-256 is used to implement the pseudo-random function, and the selected Hmac is HmacSHA1 in the Javax.Crypto.Mac library. During the aggregation period, the power consumption of each meter is a random value within 1000, and it is aggregated every 15min.

[0131] In the scheme of the present invention, the scheme is designed to be more efficient than the Paillier-based encryption scheme and meet the requirements of smart grids for efficient data transmission. In this scheme, SM encrypts the data and completes the inner product operation, FN aggregates the received data, and the control center (CC) completes the decryption task. Specifically, SM mainly faces one exponential operation in the encryption process, which mainly occurs in mask generation. The main operation that FN needs to perform in the aggregation process is addition, and the number of executions is proportional to the amount of data. For the FPDA and SEMDA encryption schemes, multiple multiplication and exponential operations are required in encryption, and the computational overhead is higher than that of the scheme of the present invention.

[0132] Figure 3Comparison of encryption time overhead. It can be seen that the scheme of the present invention has an advantage in encryption time. As the number of users increases, the encryption time of the scheme of the present invention increases slowly, thanks to its optimized algorithm and efficient data processing capabilities. The scheme of the present invention only involves addition during the encryption process, so the calculation efficiency is high. In contrast, the FPDA and SEMDA schemes involve complex multiplication and exponential operations, so the encryption time overhead increases significantly when the number of users increases, especially when large-scale data processing is inefficient. The scheme of the present invention is superior to the FPDA and SEMDA schemes in encryption efficiency, especially when the number of users is large, this advantage is more obvious. This shows that the scheme of the present invention is more suitable for large-scale user environments.

[0133] On the CC side, the decryption operation is relatively simple, involving only one modulus and one multiplication operation, which is not a problem for CC with strong computing power. As a resource-constrained device, it is crucial to reduce the computing pressure of smart meters, and FN can use its computing power to support more complex operations. Figure 4 The decryption time comparison chart illustrates the difference in decryption efficiency among the scheme of the present invention, the FPDA scheme, and the SEMDA scheme at different levels of user numbers. The scheme of the present invention exhibits a lower decryption time at all levels of user numbers, mainly because the decryption process of the two schemes only involves one modulus and one multiplication operation, thereby reducing the demand for computing resources and is suitable for resource-constrained environments such as smart meters. In contrast, the SEMDA scheme has a slightly higher decryption time, especially when the number of users is large, the difference is more obvious, because it needs to perform more complex calculations during the decryption process. In general, the scheme of the present invention is significantly better than the SEMDA scheme in decryption efficiency. This emphasizes the importance of considering computational efficiency when designing smart grid data aggregation schemes, especially on resource-constrained smart meters.

[0134] In summary, the solution of the present invention realizes the reasonable allocation and utilization of computing resources under the premise of ensuring data security, making the entire system more suitable for resource-constrained smart grid environments.

[0135] For the comparison of aggregation time, the scheme of the present invention is based on the SHE encryption scheme, and is also better than the Paillie-based encryption scheme in terms of the efficiency of homomorphic addition operations. The comparison of aggregation overhead is as follows: Figure 5 . Figure 5The performance difference in data aggregation time between the scheme of the present invention using SHE encryption and the FPDA and SEMDA schemes based on Paillier encryption under different numbers of users is demonstrated. As the number of users increases, the scheme of the present invention always maintains a low aggregation time overhead, highlighting the high efficiency of SHE in homomorphic addition operations, especially in large-scale data processing. In contrast, the aggregation time of the FPDA and SEMDA schemes increases with the increase in the number of users, and is generally higher than that of the scheme of the present invention, which shows that Paillier encryption is lower than the SHE scheme in aggregation efficiency. This result emphasizes the applicability and efficiency advantages of the scheme of the present invention in environments such as smart grids that require processing of large amounts of user data.

[0136] Finally, the encryption overhead, aggregation overhead, and decryption overhead of the solution of the present invention are summarized. Figure 6 This is a comparison chart of various time costs of the solution of the present invention. It can be seen that in the system implementation process, the main time cost is in the user encryption process, while the decryption process takes the least time, which is consistent with the characteristics of edge computing. By reducing the burden on the control center (CC), the efficiency of the entire system is improved.

[0137] In the scheme of the present invention, the communication and storage load between the smart meter SM, the fog node FN and the control center CC are evaluated in detail. First, the size of the data packet generated by each SM is 2048 bits, which includes the sequence number, timestamp, attribute pair, label and MAC value. Each user sends 96 times a day, so the daily communication volume is 96×2048 bits, that is, 192B, and the amount of data sent to CC after FN aggregation is 96×2048n bits, that is, 192n B.

[0138] Table 2 Communication and storage overhead

[0139]

[0140] In terms of storage requirements, SM needs to store its own private key of 2048 bits and each generated mask of 2048 bits, a total of 4B. FN needs to store the key (n+1) 2048 bits, where n is the number of SMs, a total of 2(n+1)B. CC only needs to store the private key of 2048 bits. The communication and storage overhead are shown in Table 2.

[0141] The analysis results show that the main communication overhead during the aggregation process is between SM and FN, but SM and FN are only one hop apart, so the generated communication overhead is acceptable. In addition, the fog node (FN) undertakes more storage tasks, which is in line with the original design plan, that is, to relieve the pressure of CC through the storage and computing resources of FN and effectively utilize the advantages of fog computing. This design makes data processing more efficient and reflects the characteristics of fog computing's decentralized computing and storage.

[0142] The present invention designs a multi-dimensional and multi-function data aggregation scheme based on RLWE. In order to achieve the dual goals of data privacy protection and efficient aggregation operation in the field of smart grid, the scheme of the present invention not only improves the efficiency of grid data analysis, but also strengthens the confidentiality and utilization of data through multi-dimensionalization and multi-function operation of smart meter data. The scheme is based on the SHE encryption system, which can provide multi-function operations of data, such as aggregation, inner product and variance, and improve the utilization of data analysis. In terms of security analysis, the scheme of the present invention proves that it can resist chosen ciphertext attacks, and experimentally verifies that it is superior to the existing scheme based on Paillier encryption in terms of computational efficiency. Finally, future work will focus on further improving the computing speed and processing power of the scheme through algorithm parallelization and hardware acceleration technology, and at the same time conduct extensive testing in smart grids of different sizes to verify its scalability and practicality. In addition, the potential application of the scheme of the present invention in other data-intensive application scenarios such as medical and health data analysis and financial transaction record aggregation will be explored, in order to provide technical support for data security and privacy protection in a wider range of fields.

[0143] The present invention can also provide a multi-dimensional and multi-function data aggregation system for realizing privacy protection, a trusted center, a control center, a fog node, and a smart meter;

[0144] The trusted center is the most reliable entity in the system, responsible for providing parameter initialization, user registration services and online user mask aggregation for the smart grid;

[0145] The fog nodes are used to aggregate the ciphertext sent by users and forward the results to the control center;

[0146] The control center performs the decryption process, obtains the correct aggregated data results, and processes the aggregated values;

[0147] The smart meter collects the amount of electricity used by the user within the specified timestamp, performs encryption operations for privacy protection and sends the encrypted information to the connected fog nodes;

[0148] In an aggregation cycle, the trusted center randomly selects a private key for the user and distributes the private key of the smart meter through a secure channel. In each aggregation cycle, the smart meter updates its own mask according to the private key.

[0149] The trusted center generates private keys and public keys for the control center. The smart meter obtains the user's power consumption information in real time. The smart meter reports the ciphertext of the current power consumption information in each cycle. The fog node performs operations through homomorphic multiplication to obtain the result of the inner product of the ciphertext, and calculates the variance of the ciphertext through homomorphic variance to obtain multi-function aggregated data.

[0150] Based on the received multi-function aggregate data, the control center decrypts the obtained inner product ciphertext and variance ciphertext through the private key and public key, and calculates the total power consumption.

[0151] On the other hand, the present invention provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the multi-dimensional and multi-function data aggregation method for realizing privacy protection described in the present invention can be implemented.

[0152] The present invention can also provide a computer device, including a processor and a memory, the memory is used to store a computer executable program, the processor reads the computer executable program from the memory and executes it, and when the processor executes the computer executable program, it can implement the multi-dimensional and multi-function data aggregation method for realizing privacy protection described in the present invention.

[0153] The computer device may be a laptop computer, a desktop computer or a workstation.

[0154] The processor may be a central processing unit (CPU), a digital signal processor (DSP), an application specific integrated circuit (ASIC), or an off-the-shelf field programmable gate array (FPGA).

[0155] The memory of the present invention may be an internal storage unit of a laptop computer, a desktop computer or a workstation, such as a memory or a hard disk; or an external storage unit, such as a mobile hard disk or a flash memory card.

[0156] Computer-readable storage media may include computer storage media and communication media. Computer storage media include volatile and non-volatile, removable and non-removable media implemented by any method or technology for storing information such as computer-readable instructions, data structures, program modules or other data. Computer-readable storage media may include: read-only memory (ROM), random access memory (RAM), solid-state drive (SSD) or optical disk, etc. Among them, random access memory may include resistance random access memory (ReRAM) and dynamic random access memory (DRAM).

[0157] The above contents are only for explaining the technical idea of ​​the present invention and cannot be used to limit the protection scope of the present invention. Any changes made on the basis of the technical solution in accordance with the technical idea proposed by the present invention shall fall within the protection scope of the claims of the present invention.

Claims

1. A multi-dimensional and multi-function data aggregation method for achieving privacy protection, characterized in that: The following steps are involved: In an aggregation cycle, a private key is randomly selected for the user and distributed through a secure channel. In each aggregation cycle, the user updates his own mask according to the private key, generates a private key and a public key for the control center, and obtains the user's power consumption information in real time. The user reports the ciphertext of the current power consumption information in each cycle, and the result of the inner product of the ciphertext is obtained through homomorphic multiplication. The variance of the ciphertext is calculated through homomorphic variance to obtain multi-function aggregation data; Based on the received multi-function aggregate data, the control center decrypts the obtained inner product ciphertext and variance ciphertext through the private key and public key, and calculates the total power consumption.

2. The multi-dimensional multi-function data aggregation method for realizing privacy protection according to claim 1, characterized in that: In an aggregation cycle, the trusted center randomly selects a private key for the user The user's private key is distributed through a secure channel. In each aggregation cycle, the user updates his own mask to The maximum number of digits (d i0 d i2 ,...,d il ), constructed as follows: m i (x) = d i0 +d i1 x+d i2 x 2 +...+d il x l , after encoding, the multidimensional data contained by the user is represented as m i (x).

3. The multi-dimensional multi-function data aggregation method for realizing privacy protection according to claim 1, characterized in that: Generating a private key and a public key for the control center includes: the trusted center generates a private key and a public key for the control center, selects an element in s←χ, selects a1←R q as a random element, e←χ as an error, let sk=s be the private key, calculate a0=-(a1·s+t·e), pk=(a0,a1) is the public key, and denote the hash function SHA-256 as H.

4. The multi-dimensional multi-function data aggregation method for realizing privacy protection according to claim 1, characterized in that: Through homomorphic multiplication, the results of the ciphertext inner product include: Fog nodes use homomorphic addition For all ciphertexts c i (i=1,2,3…n1) for polymerization, using c i Calculate C sum for The calculation results are sent to the control center; the fog node first removes the user's mask, Calculate the result of the ciphertext inner product.

5. The multi-dimensional multi-function data aggregation method for realizing privacy protection according to claim 1, characterized in that: Calculating the variance of the ciphertext by homomorphic variance includes: for a series of ciphertexts cc1,cc2,...,cc n , calculate the average ciphertext Next, define the homomorphic variance operation For each ciphertext cc i The corresponding average ciphertext difference Then calculate the squared difference And perform homomorphic addition on all squared differences and finally divide by n-1.

6. The multi-dimensional multi-function data aggregation method for realizing privacy protection according to claim 1, characterized in that: The control center decrypts the obtained inner product ciphertext and variance ciphertext through the private key and public key, and calculates the total power consumption including: Perform the following calculation to obtain the total electricity usage: The control center decrypts the obtained inner product ciphertext as follows: in is the representation of the remaining items, and the variance ciphertext is decrypted using the same steps.

7. A multi-dimensional multi-function data aggregation system for achieving privacy protection, characterized in that: Trusted center, control center, fog node, smart meter; The trusted center is the most reliable entity in the system, responsible for providing parameter initialization, user registration services and online user mask aggregation for the smart grid; The fog nodes are used to aggregate the ciphertext sent by users and forward the results to the control center; The control center performs the decryption process, obtains the correct aggregated data results, and processes the aggregated values; The smart meter collects the amount of electricity used by the user within the specified timestamp, performs encryption operations for privacy protection and sends the encrypted information to the connected fog nodes.

8. The multi-dimensional multi-function data aggregation system for implementing privacy protection according to claim 7, characterized in that: In an aggregation cycle, the trusted center randomly selects a private key for the user and distributes the private key of the smart meter through a secure channel. In each aggregation cycle, the smart meter updates its own mask according to the private key. The trusted center generates private and public keys for the control center. The smart meter obtains the user's power consumption information in real time. The smart meter reports the ciphertext of the current power consumption information in each cycle. The fog node performs operations through homomorphic multiplication to obtain the result of the inner product of the ciphertext, and calculates the variance of the ciphertext through homomorphic variance to obtain multi-function aggregated data; Based on the received multi-function aggregate data, the control center decrypts the obtained inner product ciphertext and variance ciphertext through the private key and public key, and calculates the total power consumption.

9. A computer device, characterized in that: It includes a processor and a memory, the memory is used to store computer executable programs, the processor reads part or all of the computer executable programs from the memory and executes them, and when the processor executes part or all of the computer executable programs, it can implement the multi-dimensional and multi-function data aggregation method for realizing privacy protection as described in any one of claims 1 to 6.

10. A computer-readable storage medium, characterized in that: A computer program is stored in a computer-readable storage medium. When the computer program is executed by a processor, it can implement the multi-dimensional and multi-function data aggregation method for realizing privacy protection as described in any one of claims 1 to 6.