Multi-factor dynamic authentication method and device for intelligent power grid-oriented swan equipment
By employing a multi-factor dynamic authentication method, combined with dynamic random challenge codes and the communication characteristics of HarmonyOS soft bus, the vulnerability of HarmonyOS devices to single authentication and resource consumption issues in smart grids have been resolved, achieving secure and stable device access and lightweight adaptation.
Patent Information
- Application Number
- CN202511523162.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-23
- Publication Date
- 2026-02-24
AI Technical Summary
The existing single digital certificate authentication method for HarmonyOS devices in smart grids is vulnerable to attacks in complex power scenarios, and the issues of lightweighting edge devices and resource consumption have not been effectively resolved, affecting the security of device access and real-time data transmission.
A multi-factor dynamic authentication method is adopted, which generates dynamic random challenge codes, performs correlation analysis and supplementary factor verification, and combines the communication characteristics of HarmonyOS soft bus to achieve dual verification dimensions and lightweight adaptation, avoid the theft and reuse of static authentication information, and reduce the occupation of edge device resources.
It improves the security, stability, and resource adaptability of HarmonyOS devices when connected to the smart grid, enhances the ability to identify unauthorized access, and ensures the security of device access and real-time data transmission.
Smart Images

Figure CN121567360A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of communication technology, and in particular to a multi-factor dynamic authentication method and apparatus for HarmonyOS devices in smart grids. Background Technology
[0002] As the construction of smart grids progresses, the types of power equipment become increasingly complex, protocol standards are not unified, and there is a high dependence on operating systems, hindering the digital transformation and intelligent development of the power industry. A unified IoT operating system for power based on open-source HarmonyOS and Euler has laid the foundation for solving these problems; however, with the expansion of its ecosystem applications, the security of device access in complex power scenarios still needs to be strengthened.
[0003] Currently, the main authentication method for HarmonyOS devices accessing smart grids adopts a digital certificate-based terminal network access verification mechanism. Digital certificates provide a unique identity for devices, and asymmetric encryption technology enables preliminary identification of device identity, meeting the basic security requirements for device access in smart grids. This ensures that devices connected to the grid have legitimate identities, prevents unauthorized devices from accessing the system, and guarantees the basic operational security of the power grid. However, relying solely on a single authentication factor like digital certificates lacks the multi-dimensional identity verification capabilities required for power scenarios and cannot achieve lightweight authentication for resource-constrained devices such as edge devices. In actual smart grid operation, edge devices often operate in complex electromagnetic and network environments, making single digital certificate authentication vulnerable to attacks. If a certificate is stolen or forged, unauthorized devices can easily access the system. Simultaneously, edge devices have limited computing and storage resources; complex authentication processes based on digital certificates consume excessive device resources, leading to increased authentication latency and affecting real-time data transmission and control command execution in the power grid. This makes it difficult to meet the smart grid's requirements for secure, lightweight, and dynamically adaptable device access authentication. Summary of the Invention
[0004] This invention provides a multi-factor dynamic authentication method and apparatus for HarmonyOS devices in smart grids, aiming to improve the security and stability of HarmonyOS devices accessing smart grids.
[0005] In a first aspect, the present invention provides a multi-factor dynamic authentication method for HarmonyOS devices in smart grids, applied to an authentication server of a unified IoT operating system for power grids, wherein the authentication server communicates with HarmonyOS devices via the HarmonyOS soft bus; the method includes: A dynamic random challenge code is generated based on the authentication request initiated by the HarmonyOS device to be connected, and the dynamic random challenge code is sent to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected can encrypt based on the dynamic random challenge code and return challenge response information; Based on the first communication information during the transmission of the dynamic random challenge code and the challenge response information, a correlation analysis is performed to obtain the communication linear correlation degree. Based on the communication linear correlation degree, the challenge response information is decrypted and its consistency is verified to obtain the first verification result. If the first verification result is a successful verification, then the supplementary factor returned by the HarmonyOS device to be accessed is verified based on the second communication information of the HarmonyOS soft bus to obtain the second verification result; Based on the second verification result, the HarmonyOS device to be connected is connected to the smart grid.
[0006] Secondly, the present invention also provides a multi-factor dynamic authentication device for HarmonyOS devices in smart grids, applied to the multi-factor dynamic authentication method for HarmonyOS devices in smart grids as described in the first aspect; an authentication server of a unified IoT operating system for smart grids, wherein the authentication server communicates with HarmonyOS devices via a HarmonyOS soft bus; the device includes: The network interaction module is used to generate a dynamic random challenge code based on the authentication request initiated by the HarmonyOS device to be connected, and send the dynamic random challenge code to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected can encrypt based on the dynamic random challenge code and return challenge response information; The first authentication module is used to perform correlation analysis on the first communication information during the transmission of the dynamic random challenge code and the challenge response information to obtain the communication linear correlation degree, and to decrypt and verify the consistency of the challenge response information based on the communication linear correlation degree to obtain the first verification result. The second authentication module is used to verify the supplementary factor returned by the HarmonyOS device to be accessed based on the second communication information of the HarmonyOS soft bus if the first verification result is a successful verification, and to obtain a second verification result. The device access module is used to connect the HarmonyOS device to be accessed to the smart grid based on the second verification result.
[0007] Thirdly, the present invention also provides an electronic device, comprising: a memory for storing computer software programs; and a processor for reading and executing the computer software programs, thereby realizing the HarmonyOS device multi-factor dynamic authentication method for smart grids as described above.
[0008] Fourthly, the present invention also provides a non-transitory computer-readable storage medium storing a computer software program, which, when executed by a processor, implements the multi-factor dynamic authentication method for HarmonyOS devices oriented towards smart grids as described above.
[0009] Fifthly, the present invention also provides a computer program product, including a computer program, which, when executed by a processor, implements the above-mentioned HarmonyOS device multi-factor dynamic authentication method for smart grids.
[0010] The multi-factor dynamic authentication method for HarmonyOS devices in smart grids provided in this invention uses a dynamic random challenge code to trigger the HarmonyOS device to return a challenge response. This dynamic challenge mechanism avoids the risk of static authentication information being easily stolen and reused. A correlation analysis is performed on the first communication information based on the dynamic random challenge code and challenge response information to obtain a linear correlation degree, which is then used to decrypt and verify the first verification result. By combining communication features with encrypted verification, a dual verification dimension is formed, overcoming the limitations of single digital certificate authentication. This method initially identifies unauthorized access attempts by spoofed devices or abnormal communication, and then, based on the first verification result, grants access. In this case, the second verification result is obtained by using the second communication information of the HarmonyOS soft bus to verify the supplementary factor. Therefore, the authentication dimension is further enriched by the supplementary factor. Moreover, the lightweight verification adapted to the power scenario is realized by relying on the communication characteristics of the HarmonyOS soft bus, avoiding the excessive occupation of edge device resources by complex certificate processing. Finally, the device access is completed based on the second verification result. Therefore, the authentication security is strengthened by dynamic challenge and communication correlation analysis, and the lightweight adaptation is realized by relying on the supplementary factor and soft bus characteristics. This realizes the security stability and resource adaptability of HarmonyOS device access to the smart grid, and improves the security stability of HarmonyOS device access to the smart grid. Attached Figure Description
[0011] Figure 1 This is a flowchart illustrating the multi-factor dynamic authentication method for HarmonyOS devices in smart grids provided in this embodiment of the invention. Figure 2 This is a schematic diagram of the structure of the HarmonyOS multi-factor dynamic authentication device for smart grids provided in an embodiment of the present invention; Figure 3 An embodiment diagram of the electronic device provided in this invention; Figure 4 An embodiment diagram of a computer-readable storage medium provided in accordance with the present invention. Detailed Implementation
[0012] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0013] In the description of this invention, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the stated features. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.
[0014] In the description of this invention, the term "for example" is used to mean "used as an example, illustration, or description." Any embodiment described as "for example" in this invention is not necessarily to be construed as being more preferred or advantageous than other embodiments. The following description is provided to enable any person skilled in the art to make and use the invention. Details are set forth in the following description for purposes of explanation. It should be understood that those skilled in the art will recognize that the invention can be made without using these specific details. In other instances, well-known structures and processes will not be described in detail to avoid obscuring the description of the invention with unnecessary detail. Therefore, the invention is not intended to be limited to the embodiments shown, but is consistent with the broadest scope of the principles and features disclosed herein.
[0015] See Figure 1 , Figure 1 This is a flowchart illustrating the HarmonyOS-based multi-factor dynamic authentication method for smart grid devices provided by this invention. In this embodiment, the HarmonyOS-based multi-factor dynamic authentication method for smart grid devices is applied to the authentication server of the unified IoT operating system for smart grids. The authentication server communicates with the HarmonyOS devices via the HarmonyOS soft bus. Therefore, the HarmonyOS-based multi-factor dynamic authentication method includes: Step 10: Generate a dynamic random challenge code based on the authentication request initiated by the HarmonyOS device to be connected, and send the dynamic random challenge code to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected can encrypt based on the dynamic random challenge code and return challenge response information.
[0016] Optionally, when a device seeking to connect to HarmonyOS needs to access a smart grid, it must send an authentication request to the authentication server. Therefore, upon receiving the authentication request, the authentication server initiates a dynamic random challenge code generation mechanism. The dynamic random challenge code is a random and time-sensitive code generated by the authentication server, used to verify the legitimacy and authenticity of the device seeking to connect to HarmonyOS. Its generation process is based on an internally preset encryption algorithm and a random number generator, ensuring that each generated challenge code is unique and difficult to crack.
[0017] Furthermore, the authentication server sends the generated dynamic random challenge code to the HarmonyOS device to be connected via a network communication protocol. After receiving the dynamic random challenge code, the HarmonyOS device uses its built-in encryption module to encrypt the dynamic random challenge code based on a preset encryption algorithm, encapsulates the encrypted result into challenge response information, and then returns it to the authentication server via the network communication link.
[0018] In one embodiment, in a smart grid scenario, a new HarmonyOS smart meter, acting as a HarmonyOS device to be connected, initiates an access authentication request to the authentication server. Upon receiving the request, the authentication server uses an algorithm based on a hash function and a pseudo-random number generator to generate a 128-bit dynamic random challenge code, such as "5a2f1c3e7d8b9g4h6i5j7k8l9m0n1o2p3q4r5s6t7u8v9w0x1y2z3". The authentication server sends this dynamic random challenge code to the HarmonyOS smart meter via the TCP / IP protocol. Upon receiving it, the HarmonyOS smart meter encrypts it using the AES (Advanced Encryption Standard) algorithm and returns the encrypted content as the challenge response information to the authentication server via the same TCP / IP protocol.
[0019] Step 20: Based on the first communication information during the transmission of the dynamic random challenge code and challenge response information, perform correlation analysis to obtain the communication linear correlation degree, and decrypt and verify the consistency of the challenge response information based on the communication linear correlation degree to obtain the first verification result.
[0020] Furthermore, after receiving the challenge response information returned by the HarmonyOS device to be connected, the authentication server obtains the first communication information of the dynamic random challenge code and challenge response information during transmission. In this embodiment, the first communication information includes two parts: bus communication latency data of the HarmonyOS soft bus during the transmission of the dynamic random challenge code from the authentication server to the HarmonyOS device to be connected. This data reflects the time spent transmitting data in the HarmonyOS soft bus and can be used to analyze the stability of the transmission process; and sensor drift data of the HarmonyOS device to be connected during the transmission of the challenge response information from the HarmonyOS device to the authentication server. Sensor drift data refers to the measurement data deviation caused by environmental factors or aging of the sensors in the HarmonyOS device to be connected, and this data can help determine the device status. Furthermore, the authentication server performs a correlation analysis based on the first communication information, calculating the linear correlation between the dynamic random challenge code and the challenge response information, as detailed in steps 201 to 204. The linear correlation is a quantitative indicator used to measure the degree of correlation between the two during transmission; a higher value indicates a stronger correlation and a more stable transmission process.
[0021] Furthermore, if the communication linear correlation is less than a preset correlation threshold, the authentication server will refuse the access of the HarmonyOS device to the smart grid. If the communication linear correlation is greater than or equal to the preset correlation threshold, the authentication server will use the corresponding decryption algorithm to decrypt the challenge response information and verify the decrypted content through preset consistency verification rules to obtain a first verification result. The first verification result is used to determine whether the challenge response information returned by the HarmonyOS device is authentic and valid. Continuing with the HarmonyOS smart meter example, a preset correlation threshold of 0.8 is set, and the calculated communication linear correlation is 0.85. Since the communication linear correlation is greater than the preset correlation threshold, the authentication server uses the decryption key corresponding to the encryption algorithm to decrypt the challenge response information. The decrypted content is then compared with the original dynamic random challenge code, and verification is performed according to preset consistency verification rules (such as identical content, checksum matching, etc.), ultimately yielding the first verification result.
[0022] Step 30: If the first verification result is successful, then the supplementary factor returned by the HarmonyOS device to be accessed is verified based on the second communication information of the HarmonyOS soft bus to obtain the second verification result.
[0023] Furthermore, if the first verification fails, the authentication server will refuse the access of the HarmonyOS device to the smart grid. If the first verification passes, the authentication server sends instructions to the HarmonyOS device based on the second communication information of the HarmonyOS soft bus. The second communication information represents unstable communication factors in the HarmonyOS soft bus, such as network signal strength fluctuations and electromagnetic interference, which may affect communication quality. This information is obtained by the authentication server through real-time monitoring and data analysis of the HarmonyOS soft bus.
[0024] Furthermore, after receiving the instruction, the device to be connected to HarmonyOS returns supplementary factors according to the requirements of the instruction. The supplementary factors are a set of data generated by the device to be connected to HarmonyOS based on its own state and the instruction requirements, used to further verify the device's legitimacy and compatibility. Further, after receiving the supplementary factors, the authentication server performs coupling verification on the supplementary factors, that is, it determines whether the supplementary factors are effectively coupled with the second communication information, obtaining a second verification result, specifically as described in steps 301 to 307. The second verification result characterizes whether the supplementary factors are effectively coupled with the second communication information.
[0025] Step 40: Based on the second verification result, connect the HarmonyOS device to the smart grid.
[0026] Furthermore, if the second verification result indicates valid coupling, the authentication server will formally connect the HarmonyOS device to the smart grid through a series of configuration and authorization operations, enabling it to interact and collaborate with other devices in the smart grid. If the second verification result indicates invalid coupling, the authentication server will reject the access request from the HarmonyOS device and send corresponding error messages to the device. In one embodiment, if the second verification result of the HarmonyOS smart meter indicates valid coupling, the authentication server assigns it a unique device identifier within the smart grid, configures communication protocols and permission parameters, and formally connects the smart meter to the smart grid. At this point, the smart meter can begin transmitting electricity consumption data to the grid and receiving control commands from the grid, achieving interconnection with the entire smart grid system.
[0027] This invention, based on a dynamic random challenge code, triggers the HarmonyOS device to return a challenge response. This dynamic challenge mechanism avoids the risk of static authentication information being easily stolen and reused. A correlation analysis is performed on the first communication information based on the dynamic random challenge code and challenge response information to obtain a linear correlation degree. This degree is then used for decryption and verification to obtain a first verification result. By combining communication features with encrypted verification, a dual verification dimension is formed, initially identifying unauthorized access attempts by disguised devices or abnormal communication. If the first verification result is successful, the second communication information of the HarmonyOS soft bus is used to verify supplementary factors, resulting in a second verification result. Therefore, the authentication dimension is further enriched through supplementary factors. Furthermore, leveraging the communication characteristics of the HarmonyOS soft bus, lightweight verification adapted to power scenarios is achieved, avoiding excessive resource consumption of edge devices due to complex certificate processing. Finally, device access is completed based on the second verification result. Thus, it strengthens authentication security through dynamic challenges and communication correlation analysis, and achieves lightweight adaptation through supplementary factors and soft bus characteristics. This ensures the security, stability, and resource adaptability of HarmonyOS device access to the smart grid, improving the security and stability of HarmonyOS device access to the smart grid.
[0028] In one embodiment, steps 201 to 204 include: Step 201: During the process of transmitting the dynamic random challenge code from the authentication server to the HarmonyOS device to be connected, a delay sequence matrix is constructed based on the bus communication delay data of the HarmonyOS soft bus. During the process of transmitting the challenge response information from the HarmonyOS device to be connected to the authentication server, a drift sequence matrix is constructed based on the sensor drift data of the HarmonyOS device to be connected.
[0029] Optionally, during the transmission of the dynamic random challenge code from itself to the HarmonyOS device to be connected, the authentication server continuously acquires the bus communication latency data of the HarmonyOS soft bus at a preset sampling frequency (e.g., once every 10 milliseconds). This latency data, arranged in chronological order, is stored in matrix form to construct a latency sequence matrix. The latency sequence matrix is an m-row, 1-column matrix (m being the number of samples), where each element corresponds to the bus communication latency data at a specific sampling time, used to completely record the latency changes during transmission. Simultaneously, during the transmission of the challenge response information from the HarmonyOS device to be connected to the authentication server, the authentication server acquires the sensor drift data (such as the drift values of voltage sensors, current sensors, etc.) of the HarmonyOS device to be connected at the same sampling frequency. This drift data, arranged in chronological order, is stored in matrix form to construct a drift sequence matrix. The drift sequence matrix is an n-row, 1-column matrix (n being the number of samples), where each element corresponds to the sensor drift data at a specific sampling time, used to completely record the sensor drift changes during transmission.
[0030] Continuing with the above embodiment, when the authentication server transmits the dynamic random challenge code to the HarmonyOS smart meter, it collects bus communication latency data at 10-millisecond intervals, for a total of 5 collections, obtaining data of [50ms, 52ms, 49ms, 51ms, 53ms]. The constructed latency sequence matrix is as follows: .
[0031] Furthermore, during the process of the HarmonyOS smart meter returning the challenge response information, the authentication server also collected drift data from the smart meter's voltage sensor at 10-millisecond intervals, collecting it a total of 5 times, obtaining data of [0.3V, 0.5V, 0.4V, 0.6V, 0.5V]. The constructed drift sequence matrix is as follows: .
[0032] Step 202: Based on the time delay difference between adjacent sampling points in the time delay sequence matrix, construct a time delay difference matrix, and based on the drift difference between adjacent sampling points in the drift sequence matrix, construct a drift difference matrix.
[0033] Furthermore, the authentication server processes the delay sequence matrix, calculating the delay difference between two adjacent sampling points (the delay data of the later sampling point minus the delay data of the earlier sampling point), and arranges these differences in order to form a delay difference matrix. The delay difference matrix is an (m-1) x 1 matrix (where m is the number of samples in the original delay sequence matrix), used to reflect the changing trend of the delay data. Simultaneously, the authentication server processes the drift sequence matrix, calculating the drift difference between two adjacent sampling points (the drift data of the later sampling point minus the drift data of the earlier sampling point), and arranges these differences in order to form a drift difference matrix. The drift difference matrix is an (n-1) x 1 matrix (where n is the number of samples in the original drift sequence matrix), used to reflect the changing trend of the sensor drift data.
[0034] Continuing with the time delay sequence matrix T in the above embodiment, calculate the time delay difference between adjacent sampling points: Difference between the 2nd sampling point and the 1st sampling point: 52 - 50 = 2ms; Difference between the 3rd sampling point and the 2nd sampling point: 49 - 52 = -3ms; Difference between the 4th sampling point and the 3rd sampling point: 51 - 49 = 2ms; Difference between the 5th sampling point and the 4th sampling point: 53 - 51 = 2ms. The constructed time delay difference matrix is: .
[0035] Furthermore, based on the drift sequence matrix D, the drift difference between adjacent sampling points is calculated: Difference between the 2nd and 1st sampling points: 0.5 - 0.3 = 0.2V; Difference between the 3rd and 2nd sampling points: 0.4 - 0.5 = -0.1V; Difference between the 4th and 3rd sampling points: 0.6 - 0.4 = 0.2V; Difference between the 5th and 4th sampling points: 0.5 - 0.6 = -0.1V. The constructed drift difference matrix is as follows: .
[0036] Step 203: Determine the set of positive delay difference values and the set of negative delay difference values based on the delay difference matrix, and determine the set of positive drift difference values and the set of negative drift difference values based on the drift difference matrix.
[0037] Furthermore, the authentication server filters the elements in the latency difference matrix, extracting all elements greater than 0 to form a positive latency difference set, which reflects changes in latency data that increase; and extracting all elements less than 0 to form a negative latency difference set, which reflects changes in latency data that decrease. Simultaneously, the authentication server filters the elements in the drift difference matrix, extracting all elements greater than 0 to form a positive drift difference set, which reflects changes in sensor drift data that increase; and extracting all elements less than 0 to form a negative drift difference set, which reflects changes in sensor drift data that decrease. If the difference is 0, it is not included in any set (in real-world scenarios, due to data volatility, a difference of 0 is extremely rare).
[0038] Continuing with the above delay difference matrix The set of positive delay differences is { =2, =2, =2} (Extract all positive values) The set of negative delay differences is { =-3} (Extract all negative values). Based on the drift difference matrix The set of positive drift differences is { =0.2, =0.2} (Extract all positive values) The set of negative drift differences is { =-0.1, =-0.1} (Extract all negative values).
[0039] Step 204: Based on the set of positive delay difference, the set of negative delay difference, the set of positive drift difference, and the set of negative drift difference, perform correlation analysis to obtain the linear correlation degree of communication.
[0040] Furthermore, the authentication server performs correlation analysis based on the set of positive latency difference, the set of negative latency difference, the set of positive drift difference, and the set of negative drift difference to obtain the linear correlation of communication, as detailed in steps 2041 to 2044.
[0041] The embodiments of the present invention can transform the time delay changes and sensor drift changes during the transmission of dynamic random challenge codes and challenge response information into quantified communication linear correlation. This not only reflects the consistency of the changing trends of the two types of transmitted data, but also eliminates interference from irrelevant fluctuations through detailed analysis of positive and negative differences. This provides a precise correlation basis for the subsequent decryption and consistency verification of challenge response information, effectively improving the accuracy and anti-interference capability of the verification process.
[0042] In one embodiment, steps 2041 to 2044 include: Step 2041: Perform co-occurrence analysis of the same sign difference based on the set of positive time delay difference and the set of positive drift difference to obtain the first co-occurrence frequency of the same sign difference, and perform co-occurrence analysis of the same sign difference based on the set of negative time delay difference and the set of negative drift difference to obtain the second co-occurrence frequency of the same sign difference.
[0043] Optionally, the authentication server performs same-sign difference analysis on the set of positive delay differences and the set of positive drift differences. That is, it compares the elements in the two sets and counts the number of times that two elements at the same position are positive at the same time. This number is the co-occurrence frequency of the first same-sign difference.
[0044] Furthermore, the authentication server performs same-sign difference analysis on the set of negative delay difference and the set of negative drift difference, counts the number of times two elements at the same position are simultaneously negative, and obtains the co-occurrence frequency of the second same-sign difference.
[0045] In this embodiment of the invention, the co-occurrence frequency of the same sign difference is used to measure the correlation between time delay changes and sensor drift changes when they fluctuate in the same direction.
[0046] Continuing with the above embodiments, the known set of positive time delay differences is { =2, =2, =2}, the set of positive drift differences is { =0.2, =0.2}. Since the two sets have different lengths, the shorter set is used for comparison. The comparison reveals that the first two elements in both sets are positive, so the co-occurrence frequency of the first difference with the same sign is 2. The set of negative time delay differences is { =-3}, the set of negative drift differences is { =-0.1, =-0.1}, and comparing the shorter set length, we find that the first element in both sets is negative, so the co-occurrence frequency of the second difference with the same sign is 1.
[0047] Step 2042: Perform out-of-sign difference analysis based on the set of positive delay difference values and the set of negative drift difference values to obtain the first out-of-sign difference co-occurrence frequency, and perform out-of-sign difference analysis based on the set of negative delay difference values and the set of positive drift difference values to obtain the second out-of-sign difference co-occurrence frequency.
[0048] Furthermore, the authentication server performs opposite-sign difference analysis on the set of positive delay differences and the set of negative drift differences. It compares the elements in the two sets and counts the number of times that one element at the same position is positive and the other is negative; this number is the first opposite-sign difference co-occurrence frequency. Further, the authentication server performs opposite-sign difference analysis on the set of negative delay differences and the set of positive drift differences, counting the number of times that one element at the same position is negative and the other is positive, obtaining the second opposite-sign difference co-occurrence frequency. The opposite-sign difference co-occurrence frequency in this embodiment of the invention is used to measure the correlation between delay changes and sensor drift changes during reverse fluctuations.
[0049] Continuing with the above embodiments, for the set of positive delay differences { =2, =2, =2} and the set of negative drift differences { =-0.1, =-0.1}, comparing the shorter set length, we find that the first two elements in the two sets are one positive and one negative, so the co-occurrence frequency of the first difference with opposite signs is 2. For the set of negative time delay differences { =-3} and the set of positive drift differences { =0.2, =0.2}, comparing the first position elements of the two sets, one is negative and the other is positive, so the co-occurrence frequency of the second difference with different signs is 1.
[0050] Step 2043: Perform same-sign association calculation based on the co-occurrence frequency of the first same-sign difference and the co-occurrence frequency of the second same-sign difference to obtain the cumulative amount of same-sign association; and perform opposite-sign association calculation based on the co-occurrence frequency of the first different-sign difference and the co-occurrence frequency of the second different-sign difference to obtain the cumulative amount of opposite-sign association.
[0051] Furthermore, the authentication server performs same-sign association calculation based on the co-occurrence frequency of the first and second same-sign difference values. This embodiment of the invention employs a calculation method based on nonlinear mapping to convert the same-sign difference co-occurrence frequency into a cumulative same-sign association amount. The specific formula is as follows: .
[0052] in, This indicates the cumulative amount of items with the same sign. This indicates the co-occurrence frequency of the first difference with the same sign. This represents the co-occurrence frequency of the second co-occurrence difference. By taking the cube root of the sum of squares of the co-occurrence frequencies, the influence of high co-occurrence frequencies on the results is enhanced, while low-frequency fluctuation interference is suppressed.
[0053] Furthermore, the authentication server performs out-of-sign association calculations based on the co-occurrence frequency of the first out-of-sign difference and the co-occurrence frequency of the second out-of-sign difference, obtaining the cumulative out-of-sign association amount. The specific formula is as follows: .
[0054] in, Indicates the cumulative amount of opposite signs. This indicates the co-occurrence frequency of the first difference with different signs. This indicates the frequency of co-occurrence of the second sign difference. The cumulative amount of sign correlation reflects the degree of correlation between delay and drift in opposite directions.
[0055] Continuing with the above embodiments, the co-occurrence frequency of the first same sign difference is known. =2, co-occurrence frequency of the second difference with the same sign =1, substituting into the formula for cumulative totals with the same sign, we get: ≈1.71. Co-occurrence frequency of the first difference with different signs. =2, frequency of co-occurrence of the second difference with opposite signs =1, substituting into the formula for cumulative amount of opposite signs, we get: ≈0.55.
[0056] Step 2044: Based on the cumulative amount of same-sign association and cumulative amount of different-sign association, combined with communication fluctuation characteristics, conduct correlation analysis to obtain the linear correlation degree of communication.
[0057] Furthermore, the authentication server performs correlation analysis based on the cumulative amount of same-number association and the cumulative amount of different-number association, combined with communication fluctuation characteristics, to obtain the linear correlation degree of communication, as detailed in steps 20441 to 20445.
[0058] This invention analyzes the correlation between time delay changes and sensor drift changes from different directions (same sign, different sign), converts them into co-occurrence frequencies, calculates the cumulative correlation, and finally obtains the linear correlation degree of communication. Therefore, through multi-angle quantitative analysis, it comprehensively captures the correlation characteristics of the two types of changes during data transmission, accurately reflects the degree of linear correlation between dynamic random challenge codes and challenge response information during transmission, provides a reliable quantitative basis for subsequent device authentication, and effectively improves the accuracy and stability of device authentication.
[0059] In one embodiment, the process of steps 20441 to 20445 includes: Step 20441: Determine the delay fluctuation characteristic value based on the number of delay differences less than a preset delay threshold and the first total number of bus communication delay data, and determine the drift fluctuation characteristic value based on the number of drift differences less than a preset drift threshold and the second total number of sensor drift data.
[0060] Optionally, a preset delay threshold (a critical value used to measure the fluctuation of bus communication delay data) and a preset drift threshold (a critical value used to measure the fluctuation of sensor drift data) are set. The authentication server counts the number of bus communication delay data where the delay difference (i.e., the delay difference between adjacent sampling points calculated in step 202) is less than the preset delay threshold. This number is compared with the first total number of bus communication delay data (i.e., the total number of samples in the delay sequence matrix in step 201), and the resulting ratio is the delay fluctuation characteristic value. This value reflects the overall stability of the bus communication delay data; the closer the value is to 1, the more stable the delay fluctuation. Simultaneously, the authentication server counts the number of sensor drift data where the drift difference (i.e., the drift difference between adjacent sampling points calculated in step 202) is less than the preset drift threshold. This number is compared with the second total number of sensor drift data (i.e., the total number of samples in the drift sequence matrix in step 201), and the resulting ratio is the drift fluctuation characteristic value. This value reflects the overall stability of the sensor drift data; the closer the value is to 1, the more stable the drift fluctuation.
[0061] In one embodiment, the first total number of bus communication delay data is 5 (the number of times the delay sequence matrix is sampled), and the delay difference matrix in step 202 has a total of 4 delay differences. A preset delay threshold is set to 4ms, and the number of delay differences less than 4ms is counted: all 4 delay differences are less than 4ms, therefore this number is 4. The delay fluctuation characteristic value = number of delay differences less than the preset delay threshold / first total number = 4 / 5 = 0.8. The second total number of sensor drift data is 5 (the number of times the drift sequence matrix is sampled), and the drift difference matrix in step 202 has a total of 4 drift differences. A preset drift threshold is set to 0.3V, and the number of drift differences less than 0.3V is counted: all 4 drift differences are less than 0.3V, therefore this number is 4. The drift fluctuation characteristic value = number of drift differences less than the preset drift threshold / second total number = 4 / 5 = 0.8.
[0062] Step 20442: Determine the time delay fluctuation range based on the time delay fluctuation characteristic value and the preset upper and lower limit coefficients, and determine the drift fluctuation range based on the drift fluctuation characteristic value and the preset upper and lower limit coefficients.
[0063] Furthermore, preset upper and lower limit coefficients are set according to communication stability requirements, including an upper limit coefficient and a lower limit coefficient. The authentication server multiplies the latency fluctuation characteristic value by the preset upper limit coefficient and the preset lower limit coefficient, respectively. The range formed by the two results is the latency fluctuation interval, which reflects the numerical boundary of the bus communication latency data within the stable fluctuation range. Simultaneously, the authentication server multiplies the drift fluctuation characteristic value by the preset upper limit coefficient and the preset lower limit coefficient, respectively. The range formed by the two results is the drift fluctuation interval, which reflects the numerical boundary of the sensor drift data within the stable fluctuation range.
[0064] In one embodiment, preset upper and lower limit coefficients are set, with the upper limit coefficient being 1.2 and the lower limit coefficient being 0.8. The delay fluctuation range is calculated based on the delay fluctuation characteristic value of 0.8: Lower limit of delay fluctuation range = Delay fluctuation characteristic value * Preset lower limit coefficient = 0.8 * 0.8 = 0.64; Upper limit of delay fluctuation range = Delay fluctuation characteristic value * Preset upper limit coefficient = 0.8 * 1.2 = 0.96. Therefore, the delay fluctuation range is [0.64, 0.96]. The drift fluctuation range is calculated based on the drift fluctuation characteristic value of 0.8: Lower limit of drift fluctuation range = Drift fluctuation characteristic value * Preset lower limit coefficient = 0.8 * 0.8 = 0.64; Upper limit of drift fluctuation range = Drift fluctuation characteristic value * Preset upper limit coefficient = 0.8 * 1.2 = 0.96. Therefore, the drift fluctuation range is [0.64, 0.96].
[0065] Step 20443: Based on the number of bus communication delay data within the delay fluctuation interval and the first total number, determine the proportion of the delay interval; and based on the number of sensor drift data within the drift fluctuation interval and the second total number, determine the proportion of the drift interval.
[0066] Furthermore, the authentication server counts the number of bus communication latency data values falling within the latency fluctuation range. This number is compared to the first total number of bus communication latency data values; the resulting ratio is the latency range percentage. This value reflects the distribution proportion of bus communication latency data within the stable fluctuation range; a higher value indicates that the latency data is more concentrated in the stable range. Simultaneously, the authentication server counts the number of sensor drift data values falling within the drift fluctuation range. This number is compared to the second total number of sensor drift data values; the resulting ratio is the drift range percentage. This value reflects the distribution proportion of sensor drift data within the stable fluctuation range; a higher value indicates that the drift data is more concentrated in the stable range.
[0067] Continuing with the above embodiment, the bus communication latency data is [50ms, 52ms, 49ms, 51ms, 53ms] (the first total number is 5), and the latency fluctuation range is [0.64, 0.96]. In actual calculation, the latency data needs to be normalized. Assume the normalized data is [0.7, 0.8, 0.65, 0.75, 0.9]). Count the number of data points within the range [0.64, 0.96]: all 5 data points are within the range, therefore the number is 5. The percentage of delay intervals = the number of bus communication delay data points within the delay fluctuation interval / the first total number = 5 / 5 = 1. The sensor drift data is [0.3V, 0.5V, 0.4V, 0.6V, 0.5V] (the second total number is 5), and the drift fluctuation interval is [0.64, 0.96]. Normalization is performed, assuming the normalized data is [0.6, 0.8, 0.7, 0.9, 0.8]). The number of data points within the [0.64, 0.96] interval is 4 (0.8, 0.7, 0.9, 0.8). Therefore, the number is 4. The percentage of drift intervals = the number of sensor drift data points within the drift fluctuation interval / the second total number = 4 / 5 = 0.8.
[0068] Step 20444: Determine the correlation tendency coefficient based on the proportion of the time delay interval and the proportion of the drift interval.
[0069] Furthermore, the authentication server determines the association tendency coefficient based on the proportion of latency intervals and the proportion of drift intervals, as detailed in steps A1 to A4.
[0070] Step 20445: Calculate the correlation degree based on the correlation tendency coefficient, the cumulative amount of same-sign correlation, and the cumulative amount of opposite-sign correlation to obtain the linear correlation degree of communication.
[0071] Furthermore, the authentication server substitutes the association tendency coefficient, the cumulative amount of same-sign associations, and the cumulative amount of opposite-sign associations into a preset calculation formula to calculate the communication linearity degree. The formula for calculating the communication linearity degree is: .in, Indicates the degree of linear correlation in communication. Represents the propensity to associate coefficient. This indicates the cumulative amount of items with the same sign. This represents the cumulative amount of cross-signal association. The linear correlation degree of communication ranges from [0, +∞), and in practical applications, it can be normalized to the interval [0, 1]. The higher the value, the higher the linear correlation degree between the dynamic random challenge code and the challenge response information during transmission.
[0072] In one embodiment, the association tendency coefficient =1, cumulative amount of related items with the same sign ≈1.71, cumulative amount of different signs ≈0.55, substituting into the formula, we get: ≈0.5013.
[0073] This invention combines the fluctuation characteristics of communication data (including stability and interval distribution) with the cumulative amount of same / different number associations to construct a multi-dimensional communication linear correlation calculation model. This makes the correlation results more consistent with the dynamic characteristics of actual communication scenarios, and can more accurately quantify the linear correlation between dynamic random challenge codes and challenge response information during transmission. This provides a more reliable basis for the subsequent decryption and verification of challenge response information, and improves the anti-interference capability and accuracy of the device authentication process.
[0074] In one embodiment, the process of steps A1 to A4 includes: Step A1: Calculate the difference between the time delay interval proportion and the drift interval proportion and 1 respectively to obtain the time delay interval dispersion and the drift interval dispersion.
[0075] Optionally, the authentication server calculates the difference between the latency interval percentage and 1 (subtracting the latency interval percentage from 1), and the result is the latency interval dispersion. The latency interval dispersion reflects the degree to which the bus communication latency data deviates from the latency fluctuation range; the larger the value, the more the latency data is dispersed outside the stable range.
[0076] Meanwhile, the authentication server calculates the difference between the drift interval percentage and 1 (subtracting the drift interval percentage from 1), and the result is the drift interval dispersion. The drift interval dispersion reflects the degree to which the sensor drift data deviates from the drift fluctuation range; the larger the value, the more the drift data is dispersed outside the stable range.
[0077] Continuing with the above embodiment, it is known that the proportion of the delay interval is 1 and the proportion of the drift interval is 0.8. Therefore, the dispersion of the delay interval = 1 - the proportion of the delay interval = 0, and the dispersion of the drift interval = 1 - the proportion of the drift interval = 0.2.
[0078] Step A2: Based on the set of delay out-of-bounds data that are not within the delay fluctuation range in the bus communication delay data, determine the total delay out-of-bounds amplitude; and based on the set of drift out-of-bounds data that are not within the drift fluctuation range in the sensor drift data, determine the total drift out-of-bounds amplitude.
[0079] Furthermore, the authentication server filters out all data that is not within the latency fluctuation range from the bus communication latency data, forming a latency out-of-bounds data set. For each data in this set, the difference between it and the boundary of the latency fluctuation range is calculated (if the data is less than the lower limit of the range, the lower limit is subtracted from the data; if the data is greater than the upper limit of the range, the upper limit is subtracted from the data). All differences are added together to obtain the total latency out-of-bounds amplitude, which reflects the total amplitude of the latency data exceeding the stable range.
[0080] Furthermore, the authentication server filters out all data from the sensor drift data that are not within the drift fluctuation range, forming a drift out-of-bounds data set. For each data in this set, the difference between it and the boundary of the drift fluctuation range is calculated (the calculation rule extends to the out-of-bounds amplitude). All differences are summed to obtain the total drift out-of-bounds amplitude, which reflects the total amplitude of the drift data exceeding the stable range.
[0081] Continuing with the above embodiment, the bus communication delay data, after normalization, is [0.7, 0.8, 0.65, 0.75, 0.9], with a delay fluctuation range of [0.64, 0.96]. It is determined that all data are within this range; therefore, the delay out-of-bounds data set is empty, and the sum of the delay out-of-bounds amplitudes is 0. The sensor drift data, after normalization, is [0.6, 0.8, 0.7, 0.9, 0.8], with a drift fluctuation range of [0.64, 0.96]. Data not within this range is selected as 0.6 (less than the lower limit of 0.64), forming the drift out-of-bounds data set {0.6}.
[0082] Therefore, the difference between this data and the interval boundary is calculated as: 0.64 - 0.6 = 0.04, that is, the total drift over the boundary is 0.04.
[0083] Step A3: Calculate the time delay correlation factor by multiplying the time delay interval dispersion and the sum of the time delay out-of-bounds amplitude, and calculate the drift correlation factor by multiplying the drift interval dispersion and the sum of the drift out-of-bounds amplitude.
[0084] Furthermore, the authentication server multiplies the latency interval dispersion by the sum of the latency out-of-bounds amplitudes to calculate the latency correlation factor. The latency correlation factor comprehensively reflects the dispersion and out-of-bounds amplitude of the latency data; a larger value indicates a higher overall degree of deviation of the latency data from the stable range.
[0085] Furthermore, the authentication server multiplies the dispersion of the drift interval with the sum of the drift out-of-bounds amplitudes to calculate the drift correlation factor. The drift correlation factor comprehensively reflects the dispersion and out-of-bounds amplitude of the drift data; the larger the value, the higher the overall degree of deviation of the drift data from the stable interval.
[0086] Continuing with the above embodiments, given that the time delay interval dispersion is 0 and the total time delay out-of-bounds amplitude is 0, the time delay correlation factor = time delay interval dispersion * total time delay out-of-bounds amplitude = 0 * 0 = 0. Given that the drift interval dispersion is 0.2 and the total drift out-of-bounds amplitude is 0.04, the drift correlation factor = drift interval dispersion * total drift out-of-bounds amplitude = 0.2 * 0.04 = 0.008.
[0087] Step A4: Calculate the quotient based on the absolute value of the difference between the time delay correlation factor and the drift correlation factor, and the sum of the time delay correlation factor and the drift correlation factor, to obtain the correlation tendency coefficient.
[0088] Furthermore, the authentication server first calculates the absolute value of the difference between the latency correlation factor and the drift correlation factor (i.e., |latency correlation factor - drift correlation factor|), then calculates the sum of the two (i.e., latency correlation factor + drift correlation factor), and finally calculates the quotient of the absolute value of the difference and the sum (by dividing the absolute value of the difference by the sum) to obtain the correlation tendency coefficient. The closer the value is to 0, the closer the overall degree of the latency data and drift data deviates from the stable range; the closer the value is to 1, the greater the difference in the degree of deviation between the two.
[0089] Continuing with the above embodiment, the time delay correlation factor is 0, and the drift correlation factor is 0.008. Therefore, the absolute value of the difference between the time delay correlation factor and the drift correlation factor = |0 - 0.008| = 0.008, the sum of the time delay correlation factor and the drift correlation factor = 0 + 0.008 = 0.008, and the correlation tendency coefficient = 0.008 / 0.008 = 1.
[0090] This invention comprehensively quantifies the overall characteristics of time-delayed data and drift data deviating from the stable range from two dimensions: data dispersion and out-of-bounds amplitude. By calculating the quotient of the difference and the sum, a correlation tendency coefficient that reflects the difference in the degree of deviation between the two is obtained. Therefore, it more accurately captures the inherent difference in the fluctuation stability of the two types of data, and provides a more relevant tendency index for the subsequent calculation of the linear correlation of communication, thus improving the accuracy and comprehensiveness of the correlation analysis.
[0091] In one embodiment, steps 301 to 304 include: Step 301: If the second communication information is the bus load fluctuation frequency, then determine the load fluctuation threshold based on the bus load fluctuation frequency, and generate a first instruction based on the load fluctuation threshold to return to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected returns a supplementary factor group based on the first instruction. The first instruction indicates whether the load exceeds the threshold to return supplementary factors.
[0092] Optionally, the authentication server obtains the bus load fluctuation frequency from the second communication information. The bus load fluctuation frequency refers to the number of times the bus load in the smart grid fluctuates per unit time, reflecting the rate of change of the bus load. Further, the authentication server analyzes the bus load fluctuation frequency based on a preset algorithm and historical data to determine a load fluctuation threshold. This threshold is a boundary value used to distinguish between high and low bus load states. Further, the authentication server generates a first instruction based on the load fluctuation threshold and sends it to the HarmonyOS device to be connected. The first instruction explicitly instructs the HarmonyOS device to return different supplementary factors according to whether the bus load exceeds the load fluctuation threshold; these supplementary factors collectively constitute the supplementary factor.
[0093] In one embodiment, the authentication server detects a bus load fluctuation frequency of 10 times per minute. Through analysis of historical data, an algorithm based on statistical distribution is used to determine a load fluctuation threshold of 70% (indicating that the bus load has reached 70% of its total carrying capacity). The authentication server generates a first instruction: "When the bus load exceeds 70%, return supplementary factors containing data such as the device's current operating power and response time; when the bus load does not exceed 70%, return supplementary factors containing data such as the device's basic configuration parameters and idle resource quantity," and sends this instruction to the HarmonyOS smart meter to be connected.
[0094] Step 302: Group the supplementary factor groups based on the load fluctuation threshold to obtain a first load supplementary factor group and a second load supplementary factor group. Then, determine the characteristic response difference based on the first load response characteristics of the supplementary factors in the first load supplementary factor group and the second load response characteristics of the supplementary factors in the second load supplementary factor group. The load response characteristics represent the instantaneous change of the supplementary factor with load fluctuation.
[0095] Furthermore, after the connected HarmonyOS device returns the supplementary factor group according to the first instruction, the authentication server groups the supplementary factor group based on the load fluctuation threshold. The supplementary factors corresponding to the bus load exceeding the load fluctuation threshold are assigned to the first load supplementary factor group, and the supplementary factors corresponding to the bus load not exceeding the load fluctuation threshold are assigned to the second load supplementary factor group.
[0096] Furthermore, for each supplementary factor in the first load supplementary factor group, the authentication server calculates its load response characteristic. The load response characteristic represents the instantaneous change of the supplementary factor with load fluctuations, obtained by calculating the difference between the supplementary factor before and after the load change. Similarly, the authentication server calculates the load response characteristics of the supplementary factors in the second load supplementary factor group. Finally, the authentication server calculates the difference between the average first load response characteristic of the supplementary factors in the first load supplementary factor group and the average second load response characteristic of the supplementary factors in the second load supplementary factor group, obtaining the characteristic response difference.
[0097] Continuing with the above embodiments, after the HarmonyOS smart meter receives the first instruction, when the bus load exceeds 70%, it returns supplementary factor group A={operating power 1000W, response time 50ms}; when the bus load does not exceed 70%, it returns supplementary factor group B={basic configuration parameters (model XX), idle resource amount 20%}.
[0098] The authentication server assigns supplementary factor group A to the first load supplementary factor group and group B to the second load supplementary factor group. The load response characteristics of the operating power in the first load supplementary factor group are calculated as follows: Assuming the operating power was 800W when the load did not exceed the critical value, the load response characteristic = 1000 - 800 = 200W; the load response characteristics of the response time are as follows: the previous response time was 30ms, the load response characteristic = 50 - 30 = 20ms; the average first load response characteristic = (200 + 20) / 2 = 110.
[0099] The load response characteristics of the idle resources in the second load supplement factor group are not calculated if the basic configuration parameters do not change due to load. Assuming the previous idle resource amount was 30%, the load response characteristic = 20 - 30 = -10%, and the average second load response characteristic = -10%. The characteristic response difference = 110 - (-10) = 120.
[0100] Step 303: If the product of the characteristic response difference and the first load response characteristic is greater than the preset response threshold, then the response trend is determined to be a same-direction response; otherwise, the response trend is a reverse-direction response.
[0101] Furthermore, the authentication server compares the product of the characteristic response difference and the first load response characteristic with a preset response threshold. The preset response threshold is a numerical standard pre-set based on the operating characteristics of the smart grid and the device access requirements. If the product is greater than the preset response threshold, the response trend is determined to be a unidirectional response, meaning that the change trend of the supplementary factor of the HarmonyOS device to be connected is the same as the bus load fluctuation trend; if the product is less than or equal to the preset response threshold, the response trend is determined to be a reversible response, meaning that the two change trends are opposite.
[0102] In one embodiment, the preset response threshold is 1000, the average value of the first load response characteristics is 110, the characteristic response difference is 120, and the product = 110 * 120 = 13200 > 1000, so the response trend is determined to be a unidirectional response.
[0103] Step 304: Determine the peak density based on the number of times the bus load fluctuation frequency peaks within the preset load fluctuation period, and perform coupled verification of the supplementary factor based on the response trend and peak density to obtain the second verification result.
[0104] Furthermore, the authentication server counts the number of times the bus load fluctuation frequency peaks occur within a preset load fluctuation period. The preset load fluctuation period is a time period set according to the operating rules of the smart grid and is used to count the period range of load fluctuation peaks. The number of peak occurrences is divided by the duration of the preset load fluctuation period to obtain the peak density, which reflects the density of bus load fluctuation peaks.
[0105] In one embodiment, the preset load fluctuation period is 1 hour (3600 seconds). The number of times the bus load fluctuation frequency peaks within 1 hour is counted to be 20 times, and the peak density is 20 / 3600≈0.0056 times / second.
[0106] Furthermore, the authentication server performs coupled verification of the supplementary factor based on the response trend and peak density to obtain the second verification result, as detailed in steps 3041 to 3044.
[0107] This invention uses the bus load fluctuation frequency as the core, and combines multi-dimensional information such as load fluctuation threshold, supplementary factor load response characteristics, response trend and peak density to construct a supplementary factor coupling verification system. Therefore, it can deeply analyze the variation characteristics of supplementary factors of the HarmonyOS device to be connected under different bus load conditions, accurately judge its adaptability to the bus load fluctuation situation, ensure that the device connected to the smart grid can adapt to the grid load change, and improve the stability of smart grid operation and the reliability of device access.
[0108] In one embodiment, steps 3041 to 3044 include: Step 3041: Determine the coupling strength level based on the load coupling coefficient calculated from the peak density and response trend, and extract the target supplementary factor group within the corresponding level based on the coupling strength level.
[0109] Optionally, the authentication server calculates the load coupling coefficient based on preset calculation rules, combining peak density and response trend. Peak density refers to the ratio of the number of peak occurrences of the bus load fluctuation frequency within a preset load fluctuation period to the period duration, reflecting the density of bus load fluctuation peaks. Response trend is divided into unidirectional response and inverse response, characterizing the relationship between the change trend of the supplementary factor of the HarmonyOS device to be connected and the bus load fluctuation trend. The load coupling coefficient quantifies the degree of coupling between the supplementary factor and the bus load fluctuation frequency.
[0110] Furthermore, the authentication server maps the load coupling coefficient to different coupling strength levels based on a preset coupling strength level classification standard. Common levels include "weak coupling," "medium coupling," and "strong coupling." Each coupling strength level corresponds to a range of load coupling coefficients. After determining the coupling strength level, the authentication server extracts the target supplementary factor set within the corresponding level from the supplementary factor set.
[0111] Continuing with the above embodiment, the peak density is 0.0056 times / second, and the response trend is a unidirectional response. The authentication server uses the formula C=a*P+b*T to calculate the load coupling coefficient C, where a=0.6 and b=0.4 are weighting coefficients, P is the peak density (normalized to the [0,1] interval, here P=0.0056 / 0.01=0.56), and T is the response trend indicator (unidirectional response T=1, reverse response T=-1). Therefore, C=0.6*0.56+0.4*1=0.736.
[0112] The preset coupling strength level classification standard is: C < 0.3 is weak coupling, 0.3 ≤ C < 0.7 is medium coupling, and C ≥ 0.7 is strong coupling. Therefore, the current load coupling coefficient corresponds to a strong coupling level. The authentication server extracts the target supplementary factor group corresponding to the strong coupling level from the supplementary factor group, namely the first load supplementary factor group {operating power 1000W, response time 50ms}.
[0113] Step 3042: Based on the number of positive and negative differences between each supplementary factor and the previous supplementary factor within the target supplementary factor group, determine the intra-group response consistency. Intra-group response consistency characterizes the degree of uniformity in the direction of change of supplementary factors within the group.
[0114] Furthermore, for the target supplementary factor group, the authentication server arranges the supplementary factors within the group in a certain order (such as the time order of data return or the order of factor importance), and calculates the difference between each supplementary factor and the previous supplementary factor in turn. Further, the authentication server counts the number of positive and negative differences among these differences and calculates the intra-group response consistency using a preset formula. Intra-group response consistency characterizes the degree of uniformity in the direction of change of each supplementary factor within the target supplementary factor group; the closer the value is to 1, the more consistent the direction of change of the supplementary factors within the group; the closer the value is to 0, the more chaotic the direction of change of the supplementary factors within the group.
[0115] Continuing with the above embodiment, for the target supplementary factor group {operating power 1000W, response time 50ms}, assume it is initially arranged according to the data return order. The operating power changes from 800W to 1000W, with a difference of 1000-800=200 (positive difference); the response time changes from 30ms to 50ms, with a difference of 50-30=20 (positive difference). The number of positive differences is 2, and the total number of differences is 2. This embodiment uses the formula U=number of positive differences / total number of differences to calculate the intra-group response consistency U. Therefore, U=2 / 2=1, indicating that the direction of change of the supplementary factors within this target supplementary factor group is completely consistent.
[0116] Step 3043: Determine the load verification index based on the intra-group response consistency and load coupling coefficient.
[0117] Furthermore, the authentication server combines intra-group response consistency and load coupling coefficient to determine the load verification index using a preset calculation formula. The load verification index comprehensively reflects the overall performance of the supplementary factor group in terms of coupling degree and intra-group change consistency, and is a key indicator for judging whether the supplementary factor is effectively coupled with the bus load fluctuation frequency.
[0118] Continuing with the above embodiments, the intra-group response consistency U=1, the load coupling coefficient C=0.736, and the load verification index I is calculated using the formula I=U*C in this embodiment of the invention, so I=1*0.736=0.736.
[0119] Step 3044: If the load verification index is within the preset valid range, then the second verification result is determined to be an effective coupling between the supplementary factor and the bus load fluctuation frequency. Otherwise, it is determined to be an ineffective coupling.
[0120] Furthermore, the authentication server compares the calculated load verification index with a preset valid index range. The preset valid index range is a numerical range pre-defined based on the smart grid device access requirements and historical operating data. If the load verification index falls within this range, the second verification result is determined to be an effective coupling between the supplementary factor and the bus load fluctuation frequency; if the load verification index is not within this range, the second verification result is determined to be an ineffective coupling. Continuing with the above embodiment, the preset valid index range is [0.6, 1], and the calculated load verification index I = 0.736. Since 0.6 < 0.736 < 1, the authentication server determines that the second verification result is an effective coupling between the supplementary factor and the bus load fluctuation frequency.
[0121] This invention determines the coupling strength level based on peak density and response trend, extracts target supplementary factor groups, focuses on key data, analyzes the consistency of responses within the group, explores the synergistic changes among supplementary factors, and finally combines the load coupling coefficient to obtain the load verification index to judge the coupling effectiveness. Therefore, it can accurately evaluate the compatibility between supplementary factors and bus load fluctuation frequency, ensuring that devices connected to the smart grid can operate stably under different load fluctuation conditions, improving the accuracy of device access certification and the overall stability of the smart grid.
[0122] In one embodiment, steps 305 to 307 include: Step 305: If the second communication information is the signal interference pulse intensity, then an interference pulse classification threshold is determined based on the signal interference pulse intensity, and a second instruction is generated based on the interference pulse classification threshold and returned to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected returns a supplementary factor group based on the second instruction. The second instruction indicates that supplementary factors are returned according to the interference intensity level.
[0123] Optionally, the authentication server obtains the signal interference pulse intensity from the second communication information. The signal interference pulse intensity refers to the intensity value of signal pulses such as electromagnetic interference received during the smart grid communication process, which reflects the degree of interference in the communication environment.
[0124] Furthermore, the authentication server analyzes the intensity of signal interference pulses based on a preset signal interference analysis model and historical interference data, and determines multiple interference pulse classification thresholds. These thresholds are used to classify the signal interference intensity into different levels.
[0125] Furthermore, after determining the interference pulse classification threshold, the authentication server generates a second instruction and sends it to the HarmonyOS device to be connected. This second instruction explicitly instructs the HarmonyOS device to return the corresponding supplementary factor set according to the different levels of signal interference intensity. The supplementary factors within the supplementary factor set include information such as the device's operating parameters and status data under the corresponding interference intensity.
[0126] In one embodiment, the authentication server detects that the signal interference pulse intensity of the environment where the HarmonyOS device to be connected to the smart grid is located is 80 dB. Through statistical analysis of historical interference data, using a clustering algorithm-based model, three interference pulse classification thresholds are determined to be 30 dB, 60 dB, and 90 dB, respectively, and the signal interference intensity is divided into four levels: "low interference" (less than 30 dB), "medium interference" (30 dB-60 dB), "high interference" (60 dB-90 dB), and "extremely high interference" (greater than 90 dB).
[0127] The authentication server generates a second instruction, which reads: "When the interference level is low, return a supplementary factor containing data such as the device's basic communication rate and default encoding method; when the interference level is medium, return a supplementary factor containing data such as the device's adaptively adjusted communication rate and anti-interference encoding parameters; when the interference level is high, return a supplementary factor containing data such as the device's maximum communication rate and strong anti-interference encoding scheme; when the interference level is extremely high, return a supplementary factor containing data such as the device's fault response strategy and backup communication link information." This instruction is then sent to the HarmonyOS smart meter to be connected.
[0128] Step 306: Group the supplementary factor group based on the interference pulse classification threshold to obtain supplementary factor sequences for three interference levels, and calculate the feature resistance gradient based on the interference resistance features corresponding to the supplementary factor sequence for each interference level.
[0129] Furthermore, after the connected HarmonyOS device returns the supplementary factor group according to the second instruction, the authentication server groups the supplementary factor group based on the interference pulse classification threshold, obtaining supplementary factor sequences corresponding to three interference levels (e.g., medium interference, high interference, and extremely high interference; data under low interference is assumed to show no significant change and is not included in the core analysis). For each interference level's supplementary factor sequence, the authentication server calculates its interference resistance characteristic. The interference resistance characteristic is characterized by calculating the stable difference between the supplementary factor at two adjacent interference levels, i.e., the supplementary factor value at the higher interference level minus the supplementary factor value at the lower interference level. For example, if the supplementary factor is the communication rate, the difference between the communication rate at the high interference level and the communication rate at the medium interference level is calculated.
[0130] Furthermore, the authentication server calculates the feature resistance gradient based on the interference resistance characteristics of the supplementary factor sequence for each interference level. The feature resistance gradient measures the trend of the interference resistance capability of the supplementary factors as the interference intensity increases, and is obtained by calculating the difference between the interference resistance characteristics of two adjacent interference levels.
[0131] Continuing with the above embodiment, after receiving the second instruction, the HarmonyOS smart meter returns supplementary factor group A={communication rate 80Mbps, anti-interference coding parameter X1} when it is at a medium interference level; it returns supplementary factor group B={communication rate 60Mbps, anti-interference coding parameter X2} when it is at a high interference level; and it returns supplementary factor group C={communication rate 40Mbps, anti-interference coding parameter X3} when it is at an extremely high interference level.
[0132] Furthermore, the authentication server will supplement factor groups A, B, and C with supplementary factor sequences corresponding to medium interference, high interference, and extremely high interference levels, respectively. The interference resistance characteristic for communication rates from medium to high interference levels is calculated as: 60 - 80 = -20 Mbps; the interference resistance characteristic for communication rates from high to extremely high interference levels is: 40 - 60 = -20 Mbps. Therefore, the characteristic resistance gradient = (interference resistance characteristic from high to extremely high interference levels) - (interference resistance characteristic from medium to high interference levels) = -20 - (-20) = 0.
[0133] Step 307: If the feature resistance gradient is greater than a preset gradient threshold, the gradient direction is determined to be an increasing gradient; otherwise, the gradient direction is a decreasing gradient. The supplementary factor is then coupled and verified based on the gradient direction and the number of intensity traversals of the signal interference pulse intensity within a preset time period to obtain a second verification result. The number of intensity traversals represents the number of times the interference pulse grading threshold is crossed.
[0134] Furthermore, the authentication server compares the calculated feature resistance gradient with a preset gradient threshold. The preset gradient threshold is a numerical standard pre-set based on the normal operation requirements of smart grid equipment under different interference environments. If the feature resistance gradient is greater than the preset gradient threshold, the authentication server determines the gradient direction to be increasing, indicating that the interference resistance capability of the device's supplementary factor increases with increasing interference intensity; if the feature resistance gradient is less than or equal to the preset gradient threshold, the gradient direction is determined to be decreasing, meaning the interference resistance capability of the device's supplementary factor weakens or remains unchanged. In one embodiment, the preset gradient threshold is -10 Mbps, and the calculated feature resistance gradient is 0 > -10, therefore the gradient direction is determined to be increasing.
[0135] Furthermore, the authentication server counts the number of times the signal interference pulse intensity crosses the interference pulse classification threshold within a preset time, and performs coupled verification of the supplementary factor based on the gradient direction and the number of times the signal interference pulse intensity crosses the threshold within the preset time to obtain the second verification result, as detailed in steps 3071 to 3074.
[0136] This invention, through determining the threshold for interference pulse classification and guiding the device back to a targeted supplementary factor group, to grouping and calculating the characteristic resistance gradient analysis of the supplementary factors to determine the trend of interference resistance capability changes, and then combining the number of times the signal interference intensity is crossed to comprehensively judge the coupling effectiveness, can comprehensively evaluate the adaptability and stability of the supplementary factors of the HarmonyOS device to be connected under different signal interference intensities, and screen out the devices that can still operate reliably in complex interference environments, thus ensuring the stability of smart grid communication and the reliability of device access.
[0137] In one embodiment, steps 3071 to 3074 include: Step 3071: Determine the interference activity coefficient based on the number of intensity traversals and the duration of the preset time, and determine the gradient intensity based on the interference coupling gradient calculated from the interference activity coefficient and the gradient direction.
[0138] Optionally, the authentication server divides the number of times the signal interference pulse intensity crosses a preset time interval by the preset time duration to obtain an interference activity coefficient. The interference activity coefficient quantifies the frequency with which the signal interference pulse intensity crosses a graded threshold per unit time; a larger coefficient indicates more frequent interference changes. Further, after determining the interference activity coefficient, the gradient strength is calculated using a specific formula, combined with the interference coupling gradient (calculated based on the gradient direction and interference resistance characteristics, reflecting the changing trend of the complementary factor's interference resistance capability). The gradient strength comprehensively considers both the interference activity level and the changing trend of the complementary factor's resistance capability, and is used to measure the tightness of coupling between the complementary factor and the interference signal.
[0139] In one embodiment, the known signal interference pulse intensity has crossed the interference pulse classification threshold 5 times within the past 5 minutes (i.e., a preset time, equivalent to 300 seconds). Therefore, the interference activity coefficient = number of intensity crossings / preset time duration = 5 / 300 ≈ 0.0167 times / second. The interference coupling gradient is 0 (calculated in step 306), using the formula... Calculate the gradient strength G, where, The interference activity coefficient, To eliminate the interference of the coupled gradient, substituting the numerical values into the formula yields: =0.0167.
[0140] Step 3072: Extract the target complementary factor sequence within the corresponding gradient intensity, and determine the sequence's disturbance robustness based on the difference between two adjacent complementary factors within the target complementary factor sequence. Sequence disturbance robustness characterizes the degree of convergence of fluctuations in the complementary factors of the sequence under disturbance.
[0141] Furthermore, based on the calculated gradient strength, the authentication server extracts the target supplementary factor sequence within the corresponding strength range by referring to a preset correspondence table between gradient strength and supplementary factor sequence. This correspondence table is preset according to the operating characteristics of smart grid equipment under different interference environments.
[0142] Furthermore, for the target complementary factor sequence, the authentication server sequentially calculates the difference between any two adjacent complementary factors within the sequence, and then calculates the dispersion of these differences using a preset formula to determine the sequence's anti-interference stability. The sequence's anti-interference stability characterizes the degree of convergence of fluctuations in the complementary factors within the target complementary factor sequence under signal interference; the closer the value is to 0, the smaller the fluctuations of the complementary factors under interference and the higher their stability.
[0143] In one embodiment, it is assumed that the preset correspondence between gradient strength and supplementary factor sequence is as follows: a gradient strength less than 0.02 corresponds to a supplementary factor sequence of extremely high interference level. Since the calculated gradient strength G = 0.0167 is less than 0.02, the supplementary factor sequence C = {communication rate 40Mbps, anti-interference coding parameter X3} of extremely high interference level is extracted. For sequence C, the communication rate is the only quantifiable and comparable supplementary factor (assuming that the anti-interference coding parameter X3 is difficult to directly quantify and compare). Since there is only one communication rate data in the sequence, there is no adjacent difference calculation. If we consider the comparison with the previous level (high interference level), the communication rate of the high interference level is 60Mbps, and the difference is 40-60=-20Mbps. Using the formula S = |difference| / value of the supplementary factor of the previous level, the anti-interference stability S of the sequence is calculated, then S = |-20| / 60≈0.33.
[0144] Step 3073: Determine the interference verification index based on sequence anti-interference stability and interference coupling gradient.
[0145] Furthermore, the authentication server substitutes the sequence's anti-interference stability and the interference coupling gradient into a preset formula to calculate the interference verification index. The interference verification index comprehensively reflects the stability of the supplementary factor sequence in the face of signal interference, as well as the changing trend of the supplementary factor's resistance capability. It is a key quantitative indicator for judging whether the supplementary factor is effectively coupled with the signal interference pulse intensity.
[0146] Continuing with the above embodiments, the sequence disturbance rejection stability S≈0.33, and the interference coupling gradient... =0. Using the formula V=S*(1+| |) Calculate the interference verification index V, and substitute the value into the equation to get V = 0.33 * (1 + |0|) = 0.33.
[0147] Step 3074: If the interference verification index is within the preset index range, then the second verification result is determined to be an effective coupling between the supplementary factor and the signal interference pulse intensity. Otherwise, it is determined to be an ineffective coupling.
[0148] Furthermore, the authentication server compares the calculated interference verification index with a preset index compliance range. The preset index compliance range is a numerical interval pre-defined based on the requirements for stable operation of smart grid equipment in complex interference environments, combined with historical operating data. If the interference verification index falls within the preset index compliance range, the second verification result is determined to be an effective coupling between the supplementary factor and the signal interference pulse intensity; otherwise, the second verification result is determined to be an ineffective coupling.
[0149] Continuing with the above embodiment, the preset index range is [0.2, 0.8]. The calculated interference verification index V = 0.33. Since 0.2 < 0.33 < 0.8, the authentication server determines that the second verification result is that the coupling between the supplementary factor and the signal interference pulse intensity is effective.
[0150] This invention determines the gradient strength based on the changing trends of interference activity and resistance capability, then selects target supplementary factor sequences based on the gradient strength and analyzes their anti-interference stability, and finally combines stability with the interference coupling gradient to obtain the interference verification index. Finally, it judges the coupling effectiveness by comparing with a preset range. Therefore, it comprehensively considers the dynamic change characteristics of signal interference and the response characteristics of supplementary factors, and can accurately assess the adaptability of equipment in complex interference environments, ensuring that equipment connected to the smart grid has reliable anti-interference capability, and improving the stability of the smart grid communication system and the reliability of equipment access.
[0151] Furthermore, the multi-factor dynamic authentication device for HarmonyOS devices for smart grids provided by the present invention will be described below. The multi-factor dynamic authentication device for HarmonyOS devices for smart grids described below can be referred to in correspondence with the multi-factor dynamic authentication method for HarmonyOS devices for smart grids described above.
[0152] Optional, refer to Figure 2 , Figure 2 This is a schematic diagram of the structure of the HarmonyOS multi-factor dynamic authentication device for smart grids provided by the present invention. The HarmonyOS multi-factor dynamic authentication for smart grids is applied to the authentication server of the unified IoT operating system for power systems in smart grids. The authentication server communicates with HarmonyOS devices via the HarmonyOS soft bus. The HarmonyOS multi-factor dynamic authentication device includes: The network interaction module 210 is used to generate a dynamic random challenge code based on the authentication request initiated by the HarmonyOS device to be connected, and send the dynamic random challenge code to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected can encrypt based on the dynamic random challenge code and return challenge response information. The first authentication module 220 is used to perform correlation analysis on the first communication information during the transmission of the dynamic random challenge code and challenge response information to obtain the communication linear correlation degree, and to decrypt and verify the consistency of the challenge response information based on the communication linear correlation degree to obtain the first verification result. The second authentication module 230 is used to verify the supplementary factor returned by the HarmonyOS device to be accessed based on the second communication information of the HarmonyOS soft bus if the first verification result is successful, and to obtain the second verification result. The device access module 240 connects the HarmonyOS device to the smart grid based on the second verification result.
[0153] The embodiments of the present invention improve the security and stability of HarmonyOS devices when connected to the smart grid.
[0154] Please see Figure 3 , Figure 3 An embodiment diagram of an electronic device provided in accordance with the present invention. For example... Figure 3 As shown, an embodiment of the present invention provides an electronic device 300, including a memory 310, a processor 320, and a computer program 311 stored in the memory 310 and executable on the processor 320. When the processor 320 executes the computer program 311, it implements the processes of steps 10 to 40.
[0155] Please see Figure 4 , Figure 4 An embodiment diagram of a computer-readable storage medium provided in accordance with an embodiment of the present invention is shown. Figure 4As shown, this embodiment provides a computer-readable storage medium 400 on which a computer program 311 is stored. When the computer program 311 is executed by a processor, it implements the processes of steps 10 to 40.
[0156] On the other hand, the present invention also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the HarmonyOS device multi-factor dynamic authentication method for smart grids provided by the above methods, which includes steps 10 to 40.
[0157] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0158] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0159] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A multi-factor dynamic authentication method for HarmonyOS devices in smart grids, characterized in that, An authentication server for a unified IoT operating system for smart grids, wherein the authentication server communicates with HarmonyOS devices via the HarmonyOS soft bus; the method includes: A dynamic random challenge code is generated based on the authentication request initiated by the HarmonyOS device to be connected, and the dynamic random challenge code is sent to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected can encrypt based on the dynamic random challenge code and return challenge response information; Based on the first communication information during the transmission of the dynamic random challenge code and the challenge response information, a correlation analysis is performed to obtain the communication linear correlation degree. Based on the communication linear correlation degree, the challenge response information is decrypted and its consistency is verified to obtain the first verification result. If the first verification result is a successful verification, then the supplementary factor returned by the HarmonyOS device to be accessed is verified based on the second communication information of the HarmonyOS soft bus to obtain the second verification result; Based on the second verification result, the HarmonyOS device to be connected is connected to the smart grid.
2. The multi-factor dynamic authentication method for HarmonyOS devices in smart grids according to claim 1, characterized in that, The steps for determining the linear correlation of the communication include: During the process of transmitting the dynamic random challenge code from the authentication server to the HarmonyOS device to be accessed, a delay sequence matrix is constructed based on the bus communication delay data of the HarmonyOS soft bus obtained. During the process of transmitting the challenge response information from the HarmonyOS device to be accessed to the authentication server, a drift sequence matrix is constructed based on the sensor drift data of the HarmonyOS device to be accessed obtained. Based on the time delay difference between adjacent sampling points in the time delay sequence matrix, a time delay difference matrix is constructed, and based on the drift difference between adjacent sampling points in the drift sequence matrix, a drift difference matrix is constructed. The set of positive delay difference values and the set of negative delay difference values are determined based on the delay difference matrix, and the set of positive drift difference values and the set of negative drift difference values are determined based on the drift difference matrix; The linear correlation degree of the communication is obtained by performing correlation analysis based on the set of positive delay difference, the set of negative delay difference, the set of positive drift difference, and the set of negative drift difference.
3. The multi-factor dynamic authentication method for HarmonyOS devices in smart grids according to claim 2, characterized in that, The correlation analysis based on the sets of positive delay error values, negative delay error values, positive drift error values, and negative drift error values yields the communication linear correlation degree, including: Based on the set of positive delay differences and the set of positive drift differences, a co-occurrence frequency of the first co-occurrence difference is obtained by performing a co-occurrence analysis of the same sign difference. Based on the set of negative delay differences and the set of negative drift differences, a co-occurrence frequency of the second co-occurrence difference is obtained by performing a co-occurrence analysis of the same sign difference. Based on the set of positive time delay differences and the set of negative drift differences, an opposite sign difference analysis is performed to obtain the first co-occurrence frequency of opposite sign differences; and based on the set of negative time delay differences and the set of positive drift differences, an opposite sign difference analysis is performed to obtain the second co-occurrence frequency of opposite sign differences. Based on the co-occurrence frequency of the first and second co-occurrence frequencies of the same sign difference, the same sign association is calculated to obtain the cumulative amount of same sign association; and based on the co-occurrence frequency of the first and second co-occurrence frequencies of the different sign difference, the different sign association is calculated to obtain the cumulative amount of different sign association. Based on the cumulative amount of same-sign association and the cumulative amount of different-sign association, combined with communication fluctuation characteristics, the correlation degree is analyzed to obtain the linear correlation degree of communication.
4. The multi-factor dynamic authentication method for HarmonyOS devices in smart grids according to claim 3, characterized in that, The method of performing correlation analysis based on the cumulative amount of same-sign association and the cumulative amount of opposite-sign association, combined with communication fluctuation characteristics, to obtain the linear correlation degree of communication includes: Based on the number of delay differences less than a preset delay threshold and the first total number of bus communication delay data, a delay fluctuation characteristic value is determined, and based on the number of drift differences less than a preset drift threshold and the second total number of sensor drift data, a drift fluctuation characteristic value is determined. Based on the time delay fluctuation characteristic value and the preset upper and lower limit coefficients, the time delay fluctuation range is determined, and based on the drift fluctuation characteristic value and the preset upper and lower limit coefficients, the drift fluctuation range is determined. Based on the quantity of bus communication delay data within the delay fluctuation range and the first total quantity, the proportion of the delay range is determined, and based on the quantity of sensor drift data within the drift fluctuation range and the second total quantity, the proportion of the drift range is determined. Based on the proportion of the delay interval and the proportion of the drift interval, the correlation tendency coefficient is determined; The correlation degree is calculated based on the correlation tendency coefficient, the cumulative amount of same-sign correlation, and the cumulative amount of opposite-sign correlation to obtain the communication linear correlation degree; the formula for calculating the communication linear correlation degree is: ;in, Indicates the degree of linear correlation in communication. Represents the propensity to associate coefficient. This indicates the cumulative amount of items with the same sign. This indicates the cumulative amount of different signs associated with each other.
5. The multi-factor dynamic authentication method for HarmonyOS devices in smart grids according to claim 4, characterized in that, The determination of the correlation tendency coefficient based on the proportion of the delay interval and the proportion of the drift interval includes: The time delay interval dispersion and the drift interval dispersion are obtained by calculating the difference between the time delay interval proportion and the drift interval proportion and 1, respectively. Based on the set of delay out-of-bounds data in the bus communication delay data that is not within the delay fluctuation range, the total delay out-of-bounds amplitude is determined, and based on the set of drift out-of-bounds data in the sensor drift data that is not within the drift fluctuation range, the total drift out-of-bounds amplitude is determined. The delay correlation factor is obtained by multiplying the dispersion of the delay interval with the sum of the amplitudes of the delay exceeding the limit; and the drift correlation factor is obtained by multiplying the dispersion of the drift interval with the sum of the amplitudes of the drift exceeding the limit. The correlation tendency coefficient is obtained by calculating the quotient of the absolute value of the difference between the time delay correlation factor and the drift correlation factor, and the sum of the time delay correlation factor and the drift correlation factor.
6. The multi-factor dynamic authentication method for HarmonyOS devices oriented towards smart grids according to claim 1, characterized in that, The second communication information characterizes the unstable communication factors in the HarmonyOS soft bus; The second communication information based on the HarmonyOS soft bus verifies the supplementary factor returned by the HarmonyOS device to be accessed, and obtains a second verification result, including: If the second communication information is the bus load fluctuation frequency, then a load fluctuation threshold is determined based on the bus load fluctuation frequency, and a first instruction is generated based on the load fluctuation threshold and returned to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected returns a supplementary factor group based on the first instruction; the first instruction indicates whether the load exceeds the threshold and returns a supplementary factor. The supplementary factor group is grouped based on the load fluctuation threshold to obtain a first load supplementary factor group and a second load supplementary factor group. The characteristic response difference is determined based on the first load response characteristics of the supplementary factors in the first load supplementary factor group and the second load response characteristics of the supplementary factors in the second load supplementary factor group. The load response characteristics represent the instantaneous change of the supplementary factor with load fluctuation. If the product of the characteristic response difference and the first load response characteristic is greater than a preset response threshold, then the response trend is determined to be a unidirectional response; otherwise, the response trend is a reversible response. Based on the number of times the bus load fluctuation frequency peaks within a preset load fluctuation period, the peak density is determined, and the supplementary factor is coupled and verified based on the response trend and the peak density to obtain the second verification result.
7. The multi-factor dynamic authentication method for HarmonyOS devices in smart grids according to claim 6, characterized in that, The second verification result is obtained by coupling the supplementary factor based on the response trend and the peak density, including: The coupling strength level is determined based on the load coupling coefficient calculated from the peak density and the response trend, and the target supplementary factor group within the corresponding level is extracted based on the coupling strength level. Based on the number of positive and negative differences between each supplementary factor and the previous supplementary factor within the target supplementary factor group, the consistency of response within the group is determined; the consistency of response within the group characterizes the degree of uniformity in the direction of change of supplementary factors within the group. Based on the intra-group response consistency and the load coupling coefficient, the load verification index is determined; If the load verification index is within the preset valid range, the second verification result is determined to be an effective coupling between the supplementary factor and the bus load fluctuation frequency; otherwise, it is determined to be an invalid coupling.
8. The multi-factor dynamic authentication method for HarmonyOS devices in smart grids according to claim 1, characterized in that, The second verification result is obtained by verifying the supplementary factors returned by the HarmonyOS device to be accessed based on the first verification result and the second communication information of the HarmonyOS soft bus, including: If the second communication information is the signal interference pulse strength, then an interference pulse classification threshold is determined based on the signal interference pulse strength, and a second instruction is generated based on the interference pulse classification threshold and returned to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected returns a supplementary factor group based on the second instruction; the second instruction indicates that supplementary factors are returned according to the interference strength level; The supplementary factor group is grouped based on the interference pulse classification threshold to obtain supplementary factor sequences of three interference levels. Based on the interference resistance features corresponding to the supplementary factor sequences of each interference level, the feature resistance gradient is calculated. The interference resistance features characterize the stability difference of the supplementary factors under different interference levels. If the feature resistance gradient is greater than a preset gradient threshold, the gradient direction is determined to be an increasing gradient; otherwise, the gradient direction is a decreasing gradient. Based on the gradient direction and the number of intensity spans of the signal interference pulse intensity within a preset time, the supplementary factor is coupled and verified to obtain the second verification result.
9. The multi-factor dynamic authentication method for HarmonyOS devices in smart grids according to claim 8, characterized in that, The second verification result is obtained by coupling the supplementary factor based on the gradient direction and the number of intensity spans of the signal interference pulse intensity per unit time, including: Based on the number of intensity traversals and the duration of the preset time, the interference activity coefficient is determined, and the gradient intensity is determined based on the interference activity coefficient and the interference coupling gradient calculated from the gradient direction. Based on the gradient intensity, the target complementary factor sequence within the corresponding intensity is extracted, and based on the difference between two adjacent complementary factors within the target complementary factor sequence, the sequence disturbance resistance stability is determined; the sequence disturbance resistance stability characterizes the degree of convergence of the fluctuation of the complementary factors in the sequence under disturbance. Based on the sequence anti-interference stability and the interference coupling gradient, the interference verification index is determined; If the interference verification index is within the preset index compliance range, then the second verification result is determined to be an effective coupling between the supplementary factor and the signal interference pulse intensity; otherwise, it is determined to be an ineffective coupling.
10. A multi-factor dynamic authentication device for HarmonyOS devices in smart grids, characterized in that, The method for multi-factor dynamic authentication of HarmonyOS devices for smart grids as described in any one of claims 1 to 9; An authentication server for a unified IoT operating system for smart grids, the authentication server communicating with HarmonyOS devices via the HarmonyOS soft bus; the device includes: The network interaction module is used to generate a dynamic random challenge code based on the authentication request initiated by the HarmonyOS device to be connected, and send the dynamic random challenge code to the HarmonyOS device to be connected, so that the HarmonyOS device to be connected can encrypt based on the dynamic random challenge code and return challenge response information; The first authentication module is used to perform correlation analysis on the first communication information during the transmission of the dynamic random challenge code and the challenge response information to obtain the communication linear correlation degree, and to decrypt and verify the consistency of the challenge response information based on the communication linear correlation degree to obtain the first verification result. The second authentication module is used to verify the supplementary factor returned by the HarmonyOS device to be accessed based on the second communication information of the HarmonyOS soft bus if the first verification result is a successful verification, and to obtain a second verification result. The device access module is used to connect the HarmonyOS device to be accessed to the smart grid based on the second verification result.