Power system illegal equipment identification method and device, electronic equipment and storage medium
By acquiring equipment signals in the power system, extracting preamble signals, and calculating the target spectrum, and using the Gaussian distribution goodness-of-fit test method to identify illegal equipment, this method solves the problem of insufficient real-time performance in the identification of illegal equipment in the power system in existing technologies, and achieves low-cost and high-efficiency illegal equipment detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GLOBAL ENERGY INTERCONNECTION RES INST CO LTD
- Filing Date
- 2023-04-24
- Publication Date
- 2026-05-29
AI Technical Summary
Existing technologies for identifying illegal devices in power systems have poor real-time performance, making it difficult to accurately detect illegal devices in new energy power plants, especially in cellular communication environments where existing methods are computationally expensive and lack real-time performance.
By acquiring the sampling signals of power system equipment, extracting the preamble signal and calculating its target spectrum, and using the distribution function fit goodness test method to determine whether the target spectrum follows a Gaussian distribution, illegal equipment can be identified. Discrete Haar wavelet transform is used to remove noise, reducing computational complexity and cost.
It enables real-time identification of illegal devices with low cost and low computational complexity, improving the real-time performance and accuracy of illegal device identification in power systems and reducing detection costs.
Smart Images

Figure CN116451061B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of information security, and in particular to a method, apparatus, electronic device, and storage medium for identifying illegal equipment in a power system. Background Technology
[0002] Due to the construction of new power systems and the implementation of the dual-carbon strategy, the power system is making extensive use of new energy sources such as wind power and photovoltaics. New energy power plants generally use wireless network coverage to monitor power production. Because these power plants occupy large areas, are open to the public, and have insufficient personnel, network security risks are significant. For example, it is difficult to detect external personnel accessing control equipment, leading to external wiring connections and man-in-the-middle attacks. Many illegal devices use cellular mobile communication to connect to the wired networks of power production equipment. Whenever a user connects to the wireless network, these illegal devices steal the user's information through the wired network and send it to external base stations, resulting in information leaks and incalculable losses.
[0003] Existing methods for detecting unauthorized devices involve multiple signal acquisitions and complex calculations to extract the effective bands after denoising. This requires a large number of training samples and incurs high computational costs, making it unsuitable for applications with high real-time requirements. Furthermore, unauthorized devices utilize cellular communication, characterized by small coverage areas and low power transmission. In renewable energy power plants, both employee mobile phones and unauthorized devices use the same network, making it difficult for existing methods to accurately and effectively detect unauthorized devices. Therefore, existing technologies suffer from poor real-time performance in identifying unauthorized devices in power systems. Summary of the Invention
[0004] This invention provides a method, apparatus, electronic device, and storage medium for identifying illegal devices in a power system, in order to at least solve the problem of poor real-time performance in identifying illegal devices in power systems in related technologies.
[0005] According to a first aspect of the present invention, a method for identifying illegal devices in a power system is provided. The method includes: acquiring a sampling signal of any device in the power system according to a preset sampling frequency; extracting a preamble signal of the sampling signal; calculating a target spectrum of the preamble signal, wherein the target spectrum is the spectrum corresponding to the square of the preamble signal; and determining whether the device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution.
[0006] Optionally, determining whether any device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution includes: obtaining the real part of the target spectrum; and using a distribution function goodness-of-fit test method to determine whether any device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution.
[0007] Optionally, the method of using the distribution function goodness-of-fit test to determine whether any device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution includes: using the distribution function goodness-of-fit test to test whether the distribution of the real part follows a Gaussian distribution; if the distribution of the real part follows a Gaussian distribution, determining that any device is an illegal device; if the distribution of the real part does not follow a Gaussian distribution, determining that any device is a legal device.
[0008] Optionally, the method of using the goodness-of-fit test of the distribution function to test whether the distribution of the real part follows a Gaussian distribution includes: calculating the empirical cumulative distribution function and the assumed cumulative distribution function of the real part; comparing the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function with a preset threshold; if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is less than the preset threshold, it is determined that the real part follows a Gaussian distribution; if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is greater than the preset threshold, it is determined that the real part does not follow a Gaussian distribution.
[0009] Optionally, before extracting the preamble signal of the sampled signal, the method further includes: performing wavelet transform on the sampled signal using a discrete Haar wavelet transform function; removing noise from the sampled signal according to a preset criterion, the scaling scale and translation factor corresponding to the discrete Haar wavelet transform function, to obtain a noise-removed sampled signal.
[0010] Optionally, the preset sampling frequency is greater than twice the signal width of any device.
[0011] According to a second aspect of the present invention, a power system illegal device identification device is also provided. The device includes: an acquisition module, configured to acquire a sampling signal of any device in the power system according to a preset sampling frequency; an extraction module, configured to extract a preamble signal of the sampling signal; a calculation module, configured to calculate a target spectrum of the preamble signal, wherein the target spectrum is the spectrum corresponding to the square of the preamble signal; and a judgment module, configured to judge whether any device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution.
[0012] Optionally, the acquisition module includes a general-purpose software radio peripheral for acquiring and sampling signals from any device.
[0013] Optionally, the judgment module includes: an acquisition unit for acquiring the real part of the target spectrum; and a judgment unit for using a distribution function goodness-of-fit test method to determine whether any device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution.
[0014] Optionally, the judgment unit includes: a verification submodule, used to verify whether the distribution of the real part follows a Gaussian distribution using a distribution function goodness-of-fit test method; a first judgment submodule, used to determine any device as an illegal device if the distribution of the real part follows a Gaussian distribution; and a second judgment submodule, used to determine any device as a legal device if the distribution of the real part does not follow a Gaussian distribution.
[0015] Optionally, the verification submodule includes: a calculation subunit for calculating the empirical cumulative distribution function and the assumed cumulative distribution function of the real part; a comparison subunit for comparing the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function with a preset threshold; a first determination subunit for determining that the real part follows a Gaussian distribution if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is less than the preset threshold; and a second determination subunit for determining that the real part does not follow a Gaussian distribution if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is greater than the preset threshold.
[0016] Optionally, the device further includes: a transformation module for performing wavelet transform on the sampled signal using a discrete Haar wavelet transform function; and an acquisition module for removing noise from the sampled signal according to a preset criterion and the scaling and translation factors corresponding to the discrete Haar wavelet transform function, to obtain a noise-removed sampled signal.
[0017] Optionally, the preset sampling frequency is greater than twice the signal width of any device.
[0018] According to a third aspect of the present invention, an electronic device is also provided, including a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; wherein the memory is used to store a computer program; and the processor is used to execute the power system illegal device identification method in any of the above embodiments by running the computer program stored in the memory.
[0019] According to a fourth aspect of the present invention, a computer-readable storage medium is also provided, wherein a computer program is stored therein, wherein the computer program is configured to execute the power system illegal device identification method of any of the above embodiments when running.
[0020] In this embodiment of the invention, a sampling signal from any device in the power system is acquired according to a preset sampling frequency; a preamble signal is extracted from the sampling signal; the target spectrum of the preamble signal is calculated, which is the spectrum corresponding to the square of the preamble signal; and the device is determined to be an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution. Since illegal devices remain stationary while stealing user information and sending it to external base stations via cellular mobile communication to connect to the photovoltaic cloud network, while legitimate devices move with personnel, the problem of identifying illegal devices is transformed into the problem of identifying stationary / mobile devices. The statistical characteristics of the spectrum after the square of the preamble signal, i.e., the target spectrum, are used for verification. This achieves real-time detection of illegal devices in the power system without requiring a large number of training samples and high computational costs, improving the real-time performance of illegal device identification and thus solving the problem of poor real-time performance in related technologies for identifying illegal devices in power systems.
[0021] In this embodiment of the invention, a goodness-of-fit test is used to determine whether the device is an illegitimate device by examining whether the real part of the target spectrum follows a Gaussian distribution. Since the algorithm has low implementation complexity and requires no prior information about the device, it can reduce testing costs and has certain engineering application value. Attached Figure Description
[0022] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0023] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0024] Figure 1 This is a schematic diagram of the hardware environment for an optional power system illegal device identification method according to an embodiment of the present invention;
[0025] Figure 2 This is a flowchart illustrating an optional method for identifying illegal equipment in a power system according to an embodiment of the present invention.
[0026] Figure 3 This is a schematic diagram of the simulation results of an optional ZC sequence Gaussian distribution fitting according to an embodiment of the present invention;
[0027] Figure 4a This is a schematic diagram of the goodness-of-fit test results for an optional illegal device distribution according to an embodiment of the present invention;
[0028] Figure 4b This is a schematic diagram of the goodness-of-fit test results for an optional legal device distribution according to an embodiment of the present invention;
[0029] Figure 4c This is a partially enlarged view of the goodness-of-fit test results for the distribution of illegal devices;
[0030] Figure 4d This is a partially enlarged view of the schematic diagram of the goodness-of-fit test results for the distribution of legal equipment;
[0031] Figure 5a This is a schematic diagram of the arrival and end times of the preamble signal before denoising using wavelet transform according to an embodiment of the present invention;
[0032] Figure 5b This is a schematic diagram of the arrival and end times of the preamble signal after noise reduction using wavelet transform according to an embodiment of the present invention;
[0033] Figure 6 This is a schematic diagram of an optional application scenario according to an embodiment of the present invention;
[0034] Figure 7 This is a schematic diagram of the overall process of an optional method for identifying illegal equipment in a power system according to an embodiment of the present invention;
[0035] Figure 8 This is a schematic diagram illustrating the recognition accuracy under optional different signal-to-noise ratios according to an embodiment of the present invention;
[0036] Figure 9 This is a structural block diagram of an optional power system illegal equipment identification device according to an embodiment of the present invention;
[0037] Figure 10 This is a structural block diagram of an optional electronic device according to an embodiment of the present invention. Detailed Implementation
[0038] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. 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 should fall within the scope of protection of the present invention.
[0039] It should be noted that in the description of this invention, the terms "first," "second," etc., are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or device that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or devices. The terms "installed," "connected," and "linked" should be interpreted broadly; for example, they can refer to a fixed connection, a detachable connection, or an integral connection; a mechanical connection or an electrical connection; a direct connection or an indirect connection through an intermediate medium; a connection within two elements; a wireless connection or a wired connection. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.
[0040] According to one aspect of the present invention, a method for identifying illegal equipment in a power system is provided. Optionally, in this embodiment, the above-described method for identifying illegal equipment in a power system can be applied to, for example... Figure 1 In the hardware environment shown. For example... Figure 1 As shown, terminal 102 may include memory 104, processor 106, and display 108 (optional component). Terminal 102 can communicate with server 112 via network 110. Server 112 can provide services (such as application services) to the terminal or clients installed on the terminal. Database 114 can be set up on or independently of server 112 to provide data storage services to server 112. In addition, server 112 may run a processing engine 116, which can be used to execute the steps performed by server 112.
[0041] Optionally, terminal 102 may be, but is not limited to, a terminal capable of computing data, such as a mobile terminal (e.g., mobile phone, tablet computer), laptop computer, PC (Personal Computer), etc. The aforementioned network may include, but is not limited to, a wireless network or a wired network. The wireless network includes Bluetooth, Wi-Fi (Wireless Fidelity), and other networks that enable wireless communication. The aforementioned wired network may include, but is not limited to, a wide area network (WAN), a metropolitan area network (MAN), and a local area network (LAN). The aforementioned server 112 may include, but is not limited to, any hardware device capable of computing.
[0042] Furthermore, in this embodiment, the above-described method for identifying illegal devices in a power system can also be applied, but is not limited to, to a powerful independent processing device without requiring data interaction. For example, the processing device can be, but is not limited to, a powerful terminal device; that is, the various operations in the above-described method for identifying illegal devices in a power system can be integrated into a single independent processing device. The above is merely an example, and no limitation is made in this embodiment.
[0043] Optionally, in this embodiment, the above-described method for identifying illegal devices in a power system can be executed by server 112, by terminal 102, or by both server 112 and terminal 102. Alternatively, the method for identifying illegal devices in a power system as described in this embodiment can be executed by a client installed on terminal 102.
[0044] Taking the application of illegal equipment identification methods in power systems to central processing units as an example, Figure 2 This is a flowchart illustrating an optional method for identifying illegal devices in a power system according to an embodiment of the present invention, as shown below. Figure 2 As shown, the process of this method may include the following steps:
[0045] Step S201: Acquire the sampling signal of any device in the power system according to a preset sampling frequency. Optionally, a USRP (Universal Software Radio Peripheral) is used to acquire and sample the wireless device signal in the power system. It should be noted that the USRP enables a regular computer to function like a high-bandwidth software radio device; that is, the USRP can act as the digital baseband and intermediate frequency (IF) section of a radio communication system. For example, a base station system is built using a USRPB210 device, and a USRP N210 device is used to acquire and sample the wireless device signal at a preset sampling frequency. The preset sampling frequency can be 20MHz or other values, depending on the specific circumstances.
[0046] Step S202: Extract the preamble signal from the sampled signal. Optionally, the preamble signal is a series of signals transmitted before sending the useful signal, and the preamble signal is triggered when the device accesses the network. The preamble signal can be extracted by processing the sampled signal obtained in step S201. Specifically, the preamble signal can be extracted based on abrupt changes in the sampled signal.
[0047] Step S203: Calculate the target spectrum of the preamble signal. The target spectrum is the spectrum obtained by squaring the preamble signal. Optionally, the preamble signal consists of one or more cyclically shifted Zadoff-Chu (ZC) sequences. The ZC sequence signal model is as follows:
[0048]
[0049] In the formula, n is the index of the ZC sequence, there are 63 different ZC sequences, and q and N are adjustable parameters. Let be the length of the ZC sequence. The preamble signal, composed of the ZC sequence, is squared and then transformed from the time domain to the frequency domain using a Fourier transform, yielding the simple harmonic wave components of different frequencies after squaring the preamble signal. The amplitude of each component represents its strength, and the target spectrum is determined based on the amplitude of each frequency component.
[0050] Step S204: Determine whether any device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution. Optionally, illegal devices remain stationary during the information theft and forwarding process, while legitimate devices will move with the personnel. Figure 3 This is a schematic diagram of a simulation result of Gaussian distribution fitting for an optional ZC sequence according to an embodiment of the present invention, wherein the actual distribution of the CDF (Cumulative Distribution Function) of the ZC sequence is consistent with the theoretical distribution, i.e., a Gaussian distribution. Since different cyclic shifts of the ZC sequence are orthogonal and different ZC sequences are independent of each other, the preamble signal follows a Gaussian distribution. Furthermore, since the Fourier transform of the Gaussian function is still a Gaussian function, the target spectrum of a stationary device (i.e., an illegal device) follows a Gaussian distribution. For a mobile device (i.e., a legitimate device), due to the Doppler effect, the orthogonality between different cyclic shifts of the ZC sequence is destroyed, and different ZC sequences are no longer independent of each other. Therefore, when a mobile device accesses the network, the target spectrum does not follow a Gaussian distribution.
[0051] In this embodiment of the invention, a sampling signal from any device in the power system is acquired according to a preset sampling frequency; a preamble signal is extracted from the sampling signal; the target spectrum of the preamble signal is calculated, which is the spectrum corresponding to the square of the preamble signal; and the device is determined to be an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution. Since illegal devices remain stationary while stealing user information and sending it to external base stations via cellular mobile communication to connect to the photovoltaic cloud network, while legitimate devices move with personnel, the problem of identifying illegal devices is transformed into the problem of identifying stationary / mobile devices. The statistical characteristics of the spectrum after the square of the preamble signal, i.e., the target spectrum, are used for verification. This achieves real-time detection of illegal devices in the power system without requiring a large number of training samples and high computational costs, improving the real-time performance of illegal device identification and thus solving the problem of poor real-time performance in related technologies for identifying illegal devices in power systems.
[0052] As an optional embodiment, determining whether any device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution includes: obtaining the real part of the target spectrum; and using a distribution function goodness-of-fit test method to determine whether any device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution. Optionally, in a complex Gaussian distribution, if a complex random variable follows a Gaussian distribution, then the real part of the complex random variable also follows a Gaussian distribution. Therefore, the real part of the target spectrum can be analyzed, and the distribution function goodness-of-fit test method can be used to determine whether the device is an illegal device based on the real part of the target spectrum. The distribution function goodness-of-fit test method is mainly used to test whether a set of random samples conforms to a specific probability distribution. Widely used methods include the chi-square test, Anderson-Dalling (AD) test, and Kolmogorov-Smirnov (KS) test. In this embodiment of the invention, a goodness-of-fit test is used to determine whether the device is an illegal device by testing whether the real part of the target spectrum follows a Gaussian distribution. Since the algorithm has low implementation complexity and does not require prior information about the device, it can reduce the inspection cost and has certain engineering application value.
[0053] As an optional embodiment, the goodness-of-fit test method for the distribution function is used to determine whether any device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution. This includes: using the goodness-of-fit test method to check whether the distribution of the real part follows a Gaussian distribution; if the distribution of the real part follows a Gaussian distribution, determining that any device is an illegal device; if the distribution of the real part does not follow a Gaussian distribution, determining that any device is a legal device. Optionally, the goodness-of-fit test method for the distribution function is a method for performing hypothesis testing on an unknown population to determine its population distribution. Let the zero test H0: F γ (x)=F(x,θ), where F γ (x) represents the empirical distribution of the real part of the target spectrum, F(x,θ) is the assumed distribution, i.e., the Gaussian distribution, F is the distribution family, and θ is a parameter. When H0 is accepted, i.e., the distribution of the real part follows a Gaussian distribution, the device is an illegal device; when H0 is rejected, i.e., the distribution of the real part does not follow a Gaussian distribution, the device is a legal device.
[0054] As an optional embodiment, the goodness-of-fit test method for the distribution function is used to test whether the distribution of the real part follows a Gaussian distribution, including: calculating the empirical cumulative distribution function and the assumed cumulative distribution function of the real part; comparing the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function with a preset threshold; if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is less than the preset threshold, it is determined that the real part follows a Gaussian distribution; if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is greater than the preset threshold, it is determined that the real part does not follow a Gaussian distribution.
[0055] Alternatively, assume that the sample x1≤x2≤...≤x N These are N independent and identically distributed observation samples in the target spectrum, arranged in ascending order, all derived from the population empirical distribution sample F. R (x). The basic idea of the empirical distribution function goodness-of-fit test is to compare the distance between the assumed distribution (assumed cumulative distribution function) and the empirical distribution (empirical cumulative distribution function). Specifically, the empirical cumulative distribution function of the real part of the target spectrum. It can be calculated using the following formula:
[0056]
[0057] Assumed cumulative distribution function of the real part of the target spectrum for:
[0058]
[0059] The KS test is used to calculate the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function according to the following formula. definition The test statistic for goodness of fit:
[0060]
[0061] The test statistic of goodness of fit With preset threshold Compare, if Then accept H0, and determine that the real part follows a Gaussian distribution, i.e., the device is an illegal device; if If H0 is rejected, the device is considered a valid device if its real part does not follow a Gaussian distribution. Figure 4a as well as Figure 4b These are schematic diagrams illustrating the goodness-of-fit test results for the distribution of illegal devices and the distribution of legal devices, respectively. The solid line represents the theoretical distribution, and the circles represent the actual distribution. Figure 4c as well as Figure 4d These are schematic diagrams illustrating the goodness-of-fit test results for the distribution of illegal devices. Figure 4a The enlarged view of the local area and the schematic diagram of the goodness-of-fit test results of the distribution of legal devices are shown below. Figure 4b The magnified view shows the results of the goodness-of-fit test on the distributions of illegal and legal devices. By magnifying the data locally to eliminate visual interference, it is clear that the curves of the theoretical and actual distributions of illegal devices are highly consistent and follow a Gaussian distribution; while the curves of the theoretical and actual distributions of legal devices are poorly consistent and do not follow a Gaussian distribution.
[0062] As an optional embodiment, before extracting the preamble signal of the sampled signal, the method further includes: performing a wavelet transform on the sampled signal using a discrete Haar wavelet transform function; removing noise from the sampled signal according to a preset criterion and the scaling and translation factors corresponding to the discrete Haar wavelet transform function, to obtain a noise-removed sampled signal. Optionally, the sampled signal often contains noise, causing inaccurate start and end times of the extracted preamble signal. Therefore, in this embodiment, the sampled signal is removed using a Haar wavelet transform. Since the Haar wavelet transform has edge detection and abrupt change point localization functions, it can effectively extract the preamble signal. Specifically, the sampled signal is transformed using the discrete Haar wavelet transform function shown below:
[0063]
[0064] In the formula, a is the scaling factor, n is the translation factor, and ψ(k) is the mother wavelet function, as shown below:
[0065]
[0066] When transforming the sampled signal using the discrete Haar wavelet transform function, the scaling scale *a* and translation factor *n* are used. Since the wavelet coefficients of signal and noise have different properties at different scales, the optimal approximation of the original sampled signal is found in the function space expanded by the mother wavelet function ψ(k) after scaling and translation, according to a preset criterion, to remove the noise contained in the sampled signal. Finally, an inverse wavelet transform is performed on the processed wavelet coefficients to obtain the denoised sampled signal.
[0067] Figure 5a and Figure 5b The diagrams show the arrival and end times of the preamble signal before and after wavelet transform denoising, respectively. Clearly, wavelet transform denoising allows for a more accurate estimation of the start and end times of the preamble signal, thus improving the accuracy of preamble signal extraction.
[0068] As an optional embodiment, the preset sampling frequency is greater than twice the signal width of any device. Alternatively, according to the Nyquist sampling theorem, the sampling frequency should be higher than twice the signal width of the wireless device; otherwise, aliasing will occur.
[0069] As an optional embodiment, Figure 6 This is a schematic diagram of an optional application scenario according to an embodiment of the present invention, such as... Figure 6As shown, the illegal device uses cellular mobile communication to connect with the wired network of the power production equipment, namely the photovoltaic cloud network. Whenever a user connects to the photovoltaic cloud network, the illegal device will steal the user's information through the wired network and send the user information to the external base station, resulting in the leakage of user information such as name, age, telephone number and IP address. Figure 7 This is a schematic diagram of the overall process of an optional method for identifying illegal equipment in a power system, such as... Figure 7 As shown, an ESRP B210 platform is built to collect preamble signals, acquiring the preamble signals of wireless devices in the power system. Wavelet transform is used to estimate the arrival and end times of the preamble signals. Wavelet transform can denoise the collected signals, making the estimation of the arrival and end times of the preamble signals more accurate. A squared spectrum is constructed, and the real part is extracted for feature extraction. The squared spectrum is the spectrum corresponding to the squared preamble signal. By determining whether the real part of the squared spectrum follows a Gaussian distribution, the sampling device is determined to be an illegitimate device. If the distribution of the real part follows a Gaussian distribution, the device is determined to be illegitimate; if the distribution of the real part does not follow a Gaussian distribution, the device is determined to be legitimate.
[0070] Figure 8 This is a schematic diagram illustrating the recognition accuracy under optional different signal-to-noise ratios according to an embodiment of the present invention. Signal-to-noise ratio (SINR) is the ratio of the strength of the received useful signal to the strength of the received interference signal (noise and interference). Figure 8 As shown, the higher the signal-to-noise ratio (SNR), the higher the accuracy of device recognition. When the SNR is greater than 15dB, the average recognition rate of the algorithm can reach over 92%. The method used in this embodiment has the advantages of low complexity, high recognition accuracy, and high real-time performance.
[0071] According to another aspect of the present invention, an illegal device for identifying power system equipment is also provided. Figure 9 This is a structural block diagram of an optional power system illegal equipment identification device according to an embodiment of the present invention, such as... Figure 9 As shown, the device may include: an acquisition module 901, used to acquire the sampling signal of any device in the power system according to a preset sampling frequency; an extraction module 902, used to extract the preamble signal of the sampling signal; a calculation module 903, used to calculate the target spectrum of the preamble signal, wherein the target spectrum is the spectrum corresponding to the square of the preamble signal; and a judgment module 904, used to judge whether any device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution.
[0072] It should be noted that the acquisition module 901 in this embodiment can be used to perform the above step S201, the extraction module 902 in this embodiment can be used to perform the above step S202, the calculation module 903 in this embodiment can be used to perform the above step S203, and the judgment module 904 in this embodiment can be used to perform the above step S204.
[0073] The aforementioned modules transform the problem of identifying illegal devices into the problem of identifying stationary / mobile devices, and utilize the statistical properties of the target spectrum (i.e., the spectrum obtained by squaring the preamble signal) for verification. This approach achieves real-time detection of illegal devices in power systems without requiring a large number of training samples or high computational costs, improving the real-time performance of illegal device identification and thus resolving the problem of poor real-time performance in power system illegal device identification in related technologies.
[0074] As an optional embodiment, the acquisition module includes a general-purpose software radio peripheral for acquiring and sampling signals from any device.
[0075] As an optional embodiment, the judgment module includes: an acquisition unit for acquiring the real part of the target spectrum; and a judgment unit for using a distribution function goodness-of-fit test method to determine whether any device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution.
[0076] As an optional embodiment, the judgment unit includes: a verification submodule, used to verify whether the distribution of the real part follows a Gaussian distribution using a distribution function goodness-of-fit test method; a first judgment submodule, used to determine any device as an illegal device if the distribution of the real part follows a Gaussian distribution; and a second judgment submodule, used to determine any device as a legal device if the distribution of the real part does not follow a Gaussian distribution.
[0077] As an optional embodiment, the verification submodule includes: a calculation subunit for calculating the empirical cumulative distribution function and the assumed cumulative distribution function of the real part; a comparison subunit for comparing the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function with a preset threshold; a first determination subunit for determining that the real part follows a Gaussian distribution if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is less than the preset threshold; and a second determination subunit for determining that the real part does not follow a Gaussian distribution if the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is greater than the preset threshold.
[0078] As an optional embodiment, the device further includes: a transformation module for performing wavelet transform on the sampled signal using a discrete Haar wavelet transform function; and an acquisition module for removing noise from the sampled signal according to a preset criterion and the scaling and translation factors corresponding to the discrete Haar wavelet transform function, to obtain a noise-removed sampled signal.
[0079] As an optional embodiment, the preset sampling frequency is greater than twice the signal width of any device.
[0080] According to another aspect of the present invention, an electronic device for implementing the above-described method for identifying illegal devices in a power system is also provided. The electronic device may be a server, a terminal, or a combination thereof.
[0081] Figure 10 This is a structural block diagram of an optional electronic device according to an embodiment of the present invention, such as... Figure 10 As shown, the system includes a processor 1001, a communication interface 1002, a memory 1003, and a communication bus 1004. The processor 1001, communication interface 1002, and memory 1003 communicate with each other via the communication bus 1004. The memory 1003 stores computer programs. When the processor 1001 executes the computer program stored in the memory 1003, it performs the following steps:
[0082] The sampling signal of any device in the power system is obtained according to the preset sampling frequency; the preamble signal of the sampling signal is extracted; the target spectrum of the preamble signal is calculated, which is the spectrum corresponding to the square of the preamble signal; and the device is determined to be an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution.
[0083] Optionally, in this embodiment, the communication bus can be a PCI (Peripheral Component Interconnect) bus or an EISA (Extended Industry Standard Architecture) bus, etc. This communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 10 The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.
[0084] The communication interface is used for communication between the aforementioned electronic devices and other devices.
[0085] The memory may include RAM or non-volatile memory, such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor.
[0086] As an example, such as Figure 10As shown, the memory 1003 may include, but is not limited to, the acquisition module 901, extraction module 902, calculation module 903, and judgment module 904 of the aforementioned illegal equipment identification device for power systems. Furthermore, it may include, but is not limited to, other module units of the aforementioned illegal equipment identification device for power systems, which will not be elaborated upon in this example.
[0087] The processors mentioned above can be general-purpose processors, including but not limited to: CPU (Central Processing Unit), NP (Network Processor), etc.; they can also be DSP (Digital Signal Processor), ASIC (Application Specific Integrated Circuit), FPGA (Field-Programmable Gate Array), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0088] In addition, the aforementioned electronic devices also include: a display for showing the results of illegal device identification in the power system.
[0089] Optionally, specific examples in this embodiment can refer to the examples described in the above embodiments, and will not be repeated here.
[0090] Those skilled in the art will understand that Figure 10 The structure shown is for illustrative purposes only. The device implementing the above-mentioned method for identifying illegal devices in the power system can be a terminal device, such as a smartphone (e.g., an Android phone, an iOS phone), a tablet computer, a PDA, a mobile internet device (MID), a PAD, or other terminal devices. Figure 10 This does not limit the structure of the aforementioned electronic devices. For example, the terminal device may also include components that are more... Figure 10 The more or fewer components shown (such as network interfaces, display devices, etc.), or having the same Figure 10 The different configurations shown.
[0091] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing the hardware related to the terminal device. The program can be stored in a computer-readable storage medium, which may include: flash drive, ROM, RAM, disk or optical disk, etc.
[0092] According to another aspect of the present invention, a storage medium is also provided. Optionally, in this embodiment, the storage medium can be used to execute program code for a power system illegal device identification method.
[0093] Optionally, in this embodiment, the storage medium may be located on at least one of the multiple network devices in the network shown in the above embodiment.
[0094] Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps:
[0095] The sampling signal of any device in the power system is obtained according to the preset sampling frequency; the preamble signal of the sampling signal is extracted; the target spectrum of the preamble signal is calculated, which is the spectrum corresponding to the square of the preamble signal; and the device is determined to be an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution.
[0096] Optionally, specific examples in this embodiment can refer to the examples described in the above embodiments, and will not be repeated in this embodiment.
[0097] Optionally, in this embodiment, the storage medium may include, but is not limited to, various media capable of storing program code, such as USB flash drives, ROMs, RAMs, portable hard drives, magnetic disks, or optical disks.
[0098] According to another aspect of the present invention, a computer program product or computer program is also provided, the computer program product or computer program including computer instructions stored in a computer-readable storage medium; a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, causing the computer device to perform the power system illegal device identification method in any of the above embodiments.
[0099] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0100] If the integrated units in the above embodiments are implemented as software functional units and sold or used as independent products, they can be stored in the aforementioned computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause one or more computer devices (which may be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the power system illegal device identification method of the various embodiments of the present invention.
[0101] In the above embodiments of the present invention, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0102] In the several embodiments provided by this invention, it should be understood that the disclosed client can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection of units or modules may be electrical or other forms.
[0103] 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 units can be selected to achieve the purpose of the solution provided in this embodiment, depending on actual needs.
[0104] Furthermore, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0105] The above description is only a preferred embodiment of the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A method for identifying illegal equipment in a power system, characterized in that, The method includes: The sampling signal of any device in the power system is obtained according to a preset sampling frequency; Extract the preamble signal of the sampled signal, which is a series of signals sent before the useful signal is sent; Calculate the target spectrum of the preamble signal, where the target spectrum is the spectrum obtained by squaring the preamble signal. Whether any device is an illegal device is determined based on whether the target spectrum of the preamble signal follows a Gaussian distribution.
2. The method for identifying illegal equipment in a power system according to claim 1, characterized in that, The step of determining whether any device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution includes: Obtain the real part of the target spectrum; The goodness-of-fit test method of the distribution function is used to determine whether any device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution.
3. The method for identifying illegal equipment in a power system according to claim 2, characterized in that, The method for determining whether a device is an illegal device based on whether the distribution of the real part follows a Gaussian distribution includes: The goodness-of-fit test of the distribution function is used to test whether the distribution of the real part follows a Gaussian distribution. If the distribution of the real part follows a Gaussian distribution, any device is determined to be an illegal device. If the distribution of the real part does not follow a Gaussian distribution, any device is determined to be a valid device.
4. The method for identifying illegal equipment in a power system according to claim 3, characterized in that, The method of testing whether the distribution of the real part follows a Gaussian distribution using the goodness-of-fit test of the distribution function includes: Calculate the empirical cumulative distribution function and the assumed cumulative distribution function for the real part; Compare the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function with a preset threshold. If the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is less than a preset threshold, it is determined that the real part follows a Gaussian distribution. If the absolute value of the maximum difference between the empirical cumulative distribution function and the assumed cumulative distribution function is greater than a preset threshold, it is determined that the real part does not follow a Gaussian distribution.
5. The method for identifying illegal equipment in a power system according to claim 1, characterized in that, Before extracting the preamble signal of the sampled signal, the method further includes: The sampled signal is subjected to wavelet transform using the Discrete Haar wavelet transform function; The noise in the sampled signal is removed by using a preset metric, the scaling factor and translation factor corresponding to the discrete Haar wavelet transform function, and so on.
6. The method for identifying illegal equipment in a power system according to claim 1, characterized in that, The preset sampling frequency is greater than twice the signal width of any device.
7. A device for identifying illegal equipment in a power system, characterized in that, The device includes: The acquisition module is used to acquire the sampling signal of any device in the power system according to a preset sampling frequency; An extraction module is used to extract the preamble signal of the sampled signal, wherein the preamble signal is a series of signals transmitted before the useful signal is transmitted; The calculation module is used to calculate the target spectrum of the preamble signal, wherein the target spectrum is the spectrum corresponding to the square of the preamble signal; The judgment module is used to determine whether any device is an illegal device based on whether the target spectrum of the preamble signal follows a Gaussian distribution.
8. The power system illegal equipment identification device according to claim 7, characterized in that, The acquisition module includes a general-purpose software radio peripheral for acquiring and sampling signals from any device.
9. An electronic device comprising a processor, a communication interface, a memory, and a communication bus, wherein, The processor, the communication interface, and the memory communicate with each other via the communication bus, characterized in that... The memory is used to store computer programs; The processor is configured to execute the power system illegal device identification method according to any one of claims 1 to 6 by running the computer program stored in the memory.
10. A computer-readable storage medium, characterized in that, The storage medium stores a computer program, wherein when the computer program is executed by a processor, it implements the power system illegal device identification method according to any one of claims 1 to 6.