A method, apparatus, device, and storage medium for attack testing of a power cyber-physical system.

By constructing a joint simulation system for power cyber-physical systems, reconstructing message semantics, and implementing dynamic time-varying function injection, the problems of poor cross-domain synchronization and dynamic resonance instability in the existing GOOSE protocol are solved, achieving high-fidelity quantitative evaluation and closed-loop verification.

CN123123030APending Publication Date: 2026-11-17CHANGSHA UNIVERSITY OF SCIENCE AND TECHNOLOGY +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611612964.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-19
Publication Date
2026-11-17

AI Technical Summary

Technical Problem

Existing technologies for advanced network attack defense and testing of the GOOSE protocol suffer from poor cross-domain synchronization, and traditional co-simulation is prone to clock out-of-sync and algebraic loop solution collapse due to network card congestion. Furthermore, spoof data injection attacks are unlikely to induce dynamic resonance instability within the grid-connected inverter, thus failing to effectively support closed-loop verification.

Method used

By constructing a joint simulation system for power cyber-physical systems, reconstructing message semantics and implementing dynamic time-varying function injection, a high-fidelity quantitative assessment of the penetration and diffusion mechanisms of high-risk network threats and the cross-domain instability characteristics of the power grid is achieved.

Benefits of technology

It achieves high-fidelity quantitative assessment of the penetration and diffusion mechanisms of high-risk network threats and the cross-domain instability characteristics of the power grid, avoiding clock out-of-sync and algebraic loop solution collapse in traditional methods, and can effectively assess the dynamic resonance instability risk of grid-connected inverters.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123123030A_ABST
    Figure CN123123030A_ABST
Patent Text Reader

Abstract

This invention discloses an attack testing method, apparatus, device, and storage medium for power cyber-physical systems (PFPS). Applied to the field of attack testing, it constructs an electromagnetic transient model and a corresponding virtual communication network topology based on information from the target PFPS. It maps the physical communication interfaces of the electromagnetic transient model to the virtual nodes of the virtual communication network topology to construct a co-simulation system. In the communication transmission path of the co-simulation system, it determines the payload field storing the target control command from the message. It writes a time-varying disturbance signal to the payload field and sends the message with the added disturbance signal back to the communication transmission path. It records the state variables of the co-simulation system during the time-varying disturbance signal's action and evaluates the cross-domain instability of the target PFPS based on these state variables. By reconstructing message semantics and implementing dynamic time-varying function injection, it achieves a high-fidelity quantitative assessment of the penetration and diffusion mechanisms of high-risk network threats and the cross-domain instability characteristics of the power grid.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of attack testing, and in particular to an attack testing method, an attack testing device, an electronic device, and a computer-readable storage medium for a power cyber-physical system. Background Technology

[0002] With the increasing penetration of distributed clean energy sources in modern main power grids and local microgrids, power systems are becoming increasingly reliant on the deep coupling between underlying electrical systems and upper-level communication networks. The IEC 61850 (International Electrotechnical Commission) international standard system has become the foundation for data transmission in substation automation systems. Among these standards, the GOOSE (Generic Object Oriented Substation Event) protocol is responsible for issuing critical control commands and tripping fault protection devices. This protocol abandons complex network layer routing processing, directly encapsulating data at the data link layer, thereby meeting extremely stringent latency requirements.

[0003] However, existing technologies still have significant limitations in conducting advanced network attack defense and testing against the GOOSE protocol. The underlying architecture of existing simulation platforms suffers from poor cross-domain synchronization. Traditional co-simulation often relies on direct physical network connections, which can easily lead to clock outages and algebraic loop solution crashes due to network card congestion when performing microsecond-level electromagnetic transient solutions, making it difficult to effectively support closed-loop verification. Furthermore, existing spoofing attacks are mostly limited to the static level; attackers typically only employ denial-of-service attacks or perform one-time fixed-value tampering, making it difficult to induce dynamic resonance instability within the grid-connected inverter. In addition, traditional protocol tampering methods often neglect the synchronous maintenance of the underlying state machine semantics. Since the GOOSE protocol heavily relies on state sequence numbers and sequence numbers to maintain anti-replay logic, statically tampered messages are easily intercepted by malicious data detection mechanisms if timing legitimacy forgery is not implemented. Summary of the Invention

[0004] The purpose of this invention is to provide an attack testing method, apparatus, device, and storage medium for power cyber-physical systems, applicable to the field of attack testing. This method achieves high-fidelity quantitative assessment of the penetration and diffusion mechanisms of high-risk network threats and the cross-domain instability characteristics of the power grid by reconstructing message semantics and implementing dynamic time-varying function injection.

[0005] To address the aforementioned technical problems, this invention provides an attack testing method for a power cyber-physical system, comprising: Acquire physical-side and information-side data information of the target power information physical system; An electromagnetic transient model of the target power information physical system is constructed based on the physical side data information, and a virtual communication network topology corresponding to the electromagnetic transient model is constructed based on the information side data information. The physical communication interface of the electromagnetic transient model is mapped to the virtual nodes in the virtual communication network topology to construct a joint simulation system of the physical side and the information side. In the communication transmission path of the co-simulation system, a message containing the target control command is identified, and the payload field storing the target control command is determined from the message; A time-varying disturbance signal is written into the payload field, and the message after the time-varying disturbance signal is written is sent back to the communication transmission path; Record the state variables of the co-simulation system during the time-varying disturbance signal, and evaluate the cross-domain instability of the target power cyber-physical system based on the state variables.

[0006] Optionally, the physical communication interface of the electromagnetic transient model is mapped to the virtual nodes in the virtual communication network topology to construct a joint simulation system of the physical and information sides, including: The physical domain real-time simulation subsystem corresponding to the electromagnetic transient model and the communication network simulation subsystem corresponding to the virtual communication network topology are respectively assigned to run on different processor cores of the same multi-core real-time simulator. The kernel of the multi-core real-time simulator creates a virtual Ethernet interface pair and uses the virtual Ethernet interface pair as the connection link between the physical communication interface and the virtual node, thereby establishing a bidirectional communication connection between the physical domain real-time simulation subsystem and the communication network simulation subsystem. Namespace migration and isolation encapsulation are performed on the virtual Ethernet interface belonging to the communication network simulation subsystem in the virtual Ethernet interface pair to eliminate cross-domain latency and clock jitter between the physical domain real-time simulation subsystem and the communication network simulation subsystem during operation, thereby constructing the joint simulation system of the physical side and the information side.

[0007] Optionally, in the communication transmission path of the co-simulation system, a message containing the target control command is identified, and a payload field storing the target control command is determined from the message, including: Configure the network card to promiscuous monitoring mode, and in the communication transmission path of the co-simulation system, filter the packets containing the target control command by using the preset target medium access control address and Ethernet frame header identifier field as filtering conditions; The absolute byte offsets of the status sequence number field, the sequence number field, and the payload field storing the target control instructions are obtained from the message based on the application layer protocol encoding rules.

[0008] Optionally, writing a time-varying perturbation signal into the payload field and then sending the message with the time-varying perturbation signal written back to the communication transmission path includes: Extract the current system's absolute running timestamp to generate a time-varying sinusoidal disturbance with a preset amplitude and preset frequency; The message is processed based on semantic reconstruction technology. While maintaining the structural compliance of the message, the status sequence number field in the message is arithmetically incremented, and the sequence number field in the message is reset to the initial semantic value of the protocol to bypass the security verification mechanism on the communication side. The generated time-varying sinusoidal disturbance is re-encoded and overwritten into the payload field of the message, and the message after recalculation of the protocol checksum is sent back to the communication transmission path.

[0009] Optionally, extract the current system's absolute running timestamp to generate a time-varying sinusoidal disturbance with a preset amplitude and preset frequency, including: The dynamic deviation increment is obtained by inputting the absolute running timestamp into the time-varying disturbance function of the preset amplitude and the preset frequency; The dynamic deviation increment is determined as the time-varying sinusoidal disturbance of the reactive current reference command in the load field.

[0010] Optionally, the time-varying perturbation function is a sinusoidal waveform function, a continuous function of a swept frequency signal, or a piecewise step time-varying function.

[0011] Optionally, the state variables of the co-simulation system are recorded during the time-varying disturbance signal, and the cross-domain instability of the target power cyber-physical system is evaluated based on the state variables, including: Record the AC voltage at the main grid common connection point, the DC bus voltage at the source end, and the active power at the photovoltaic array side in the joint simulation system; When the DC bus voltage at the source end exhibits wide-band oscillation, the active power on the photovoltaic array side experiences intermittent pulse drops, and the AC voltage on the main grid common connection point side exhibits oscillating instability, it is determined that the target power information physical system has experienced main grid cross-domain instability.

[0012] To address the aforementioned technical problems, this invention provides an attack testing device for a power cyber-physical system, comprising: The first module is used to acquire physical-side data information and information-side data information of the target power information physical system; The second module is used to construct an electromagnetic transient model of the target power information physical system based on the physical side data information, and to construct a virtual communication network topology corresponding to the electromagnetic transient model based on the information side data information. The third module is used to map the physical communication interface of the electromagnetic transient model to the virtual nodes in the virtual communication network topology, and to construct a joint simulation system of the physical side and the information side. The fourth module is used to determine, in the communication transmission path of the co-simulation system, a message containing the target control command, and to determine from the message the payload field storing the target control command; The fifth module is used to write a time-varying disturbance signal into the payload field and send the message after writing the time-varying disturbance signal back to the communication transmission path; The sixth module is used to record the state variables of the co-simulation system during the time-varying disturbance signal, and to evaluate the cross-domain instability of the target power cyber-physical system based on the state variables.

[0013] To solve the above-mentioned technical problems, the present invention provides an electronic device, comprising: Memory, used to store computer programs; A processor for implementing an attack testing method for the power cyber-physical system when executing the computer program.

[0014] To address the aforementioned technical problems, the present invention provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement an attack testing method for the power information physical system.

[0015] As can be seen, this invention acquires physical and information-side data information of the target power information physical system; constructs an electromagnetic transient model of the target power information physical system based on the physical-side data information, and constructs a virtual communication network topology corresponding to the electromagnetic transient model based on the information-side data information; maps the physical communication interface of the electromagnetic transient model to the virtual nodes in the virtual communication network topology to construct a joint simulation system of the physical and information sides; identifies messages containing target control commands in the communication transmission path of the joint simulation system, and determines the load field storing the target control commands from the messages; writes time-varying disturbance signals into the load field, and sends the messages with the time-varying disturbance signals back to the communication transmission path; records the state variables of the joint simulation system during the action of the time-varying disturbance signals, and evaluates the cross-domain instability of the target power information physical system based on the state variables. This invention achieves high-fidelity quantitative evaluation of the penetration and diffusion mechanism of high-risk network threats and the cross-domain instability characteristics of the power grid by reconstructing message semantics and implementing dynamic time-varying function injection. Attached Figure Description

[0016] 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, the drawings described below are only embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.

[0017] Figure 1 A flowchart illustrating an attack testing method for a power cyber-physical system provided in an embodiment of the present invention; Figure 2 This is a waveform diagram of a main network node after being subjected to a dynamic instruction tampering attack, provided in an embodiment of the present invention. Figure 3 This is a structural block diagram of an attack testing device for a power cyber-physical system provided in an embodiment of the present invention. Detailed Implementation

[0018] 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.

[0019] The following combination Figure 1 , Figure 1 A flowchart of an attack testing method for a power cyber-physical system provided in an embodiment of the present invention, the method may include: S101: Obtain physical-side data information and information-side data information of the target power information physical system.

[0020] The target power cyber-physical system in this embodiment is a power cyber-physical system that needs to be attacked and tested. This embodiment divides the target power system into a primary physical loop and a secondary control loop. The primary physical loop includes a nonlinear photovoltaic array equivalent circuit model, a DC-DC boost converter model, a large-capacity DC bus capacitor model, a multi-order AC low-pass filter network, and main grid transmission lines, etc. The secondary control loop includes a maximum power point tracking controller model based on the disturbance observation method, and a dual-level voltage source grid-connected converter model employing a decoupling control strategy based on a grid voltage-oriented synchronous rotating orthogonal coordinate system, etc.

[0021] The physical side data includes, but is not limited to: the power grid spatial topology, transmission line impedance parameters, operating conditions and equipment parameters of distributed photovoltaic power generation arrays and power electronic power converters at all levels, and logic and gain parameters of the underlying dual-loop decoupled control system. The information side data includes, but is not limited to: the communication network topology, node device types and media access control addresses, network protocol stack specifications, and routing rules. Specific settings can be configured based on actual applications and are not limited here.

[0022] In a specific embodiment, a photovoltaic grid-connected unit can be constructed based on a modeling matrix from Simulink / RT-LAB (Real-Time Laboratory). Specifically, the photovoltaic array is connected to a Boost converter via a perturbation-observation method MPPT (Maximum Power Point Tracking) controller, and a large-capacity DC bus capacitor is connected in parallel. Subsequently, a two-level voltage source grid-connected converter, an AC-side LCL (inductor-capacitor-inductor) filter impedance, a main transformer, and grid nodes are sequentially connected to the grid-connected branches.

[0023] The converter internally can employ a synchronous rotating dq coordinate system decoupling algorithm based on grid voltage-oriented vector control. The d-axis represents the outer voltage loop, and the q-axis represents the inner unloaded loop. Its microscopic electromagnetic transient dynamic coupling control equations are expressed as follows: ; ; In the formula, R is the internal resistance of the filter branch, and L is the inductance of the filter branch. The grid angular velocity is the result of phase-locked loop closed-loop dynamic tracking. The voltage along the d-axis. This is the q-axis voltage. For q-axis current, For d-axis current, This represents the forced tracking error along the d-axis. For the forced tracking error of the q-axis, in Under directional control with a value of 0, the outer loop of the d-axis voltage is responsible for maintaining the DC voltage. Energy conservation balance and output of active power command The q-axis reactive inner loop directly absorbs reactive current commands issued by the communication network. Perform rapid adjustment. Due to... It directly relates to the voltage support and reactive power supply of the local grid connection point, and lacks an outer ring rigid limiting buffer, making it an excellent target for the infiltration of false data in dynamic networks.

[0024] It is understood that selecting the reactive current reference value as the object to be tampered with is only a preferred implementation of this embodiment. Those skilled in the art can also select other control command loads such as active current reference value and voltage reference value as the object to be tampered with according to the test purpose.

[0025] S102: Construct an electromagnetic transient model of the target power information physical system based on physical side data information, and construct a virtual communication network topology corresponding to the electromagnetic transient model based on information side data information.

[0026] This embodiment can construct an electromagnetic transient model of the target power information physical system based on the acquired physical side data information. In the physical domain real-time simulation subsystem, an electromagnetic transient model of the power system including dynamic environmental condition input, distributed photovoltaic power generation array, power electronic power converters at all levels and their underlying dual closed-loop decoupled control system is constructed, and a real-time communication interface module is configured at the control signal interaction node.

[0027] This embodiment can construct a virtual communication network topology corresponding to the electromagnetic transient model based on the acquired information-side data. In the communication network simulation subsystem, a virtual communication network topology, node protocol stack, and routing forwarding rules that are equivalent to the spatial topology and logical control relationship of the electromagnetic transient model are established.

[0028] In a specific embodiment, a virtual network topology corresponding to the physical model is constructed in the EXata advanced network behavior simulation software for cyber-physical systems. The physical communication interface is configured as an endpoint supporting IEC 61850 GOOSE and TCP / IP protocols (Transmission Control Protocol / Internet Protocol). Specifically, the process layer and the interval layer use the GOOSE protocol of the multicast publish / subscribe model to transmit high-frequency control parameters, while the station control layer and the interval layer transmit slow monitoring data based on TCP.

[0029] S103: Map the physical communication interface of the electromagnetic transient model to the virtual nodes in the virtual communication network topology to construct a joint simulation system of the physical side and the information side.

[0030] This embodiment can map the physical communication interface of the electromagnetic transient model to the virtual nodes in the virtual communication network topology to construct a joint simulation system of the physical side and the information side.

[0031] For example, the physical domain real-time simulation subsystem corresponding to the electromagnetic transient model and the communication network simulation subsystem corresponding to the virtual communication network topology are respectively assigned to run on different processor cores of the same multi-core real-time simulator; virtual Ethernet interface pairs are created through the kernel of the multi-core real-time simulator, and the virtual Ethernet interface pairs are used as the connection links between the physical communication interface and the virtual node, so as to establish a bidirectional communication connection between the physical domain real-time simulation subsystem and the communication network simulation subsystem; namespace migration and isolation encapsulation are performed on the virtual Ethernet interface of the virtual Ethernet interface pair belonging to the communication network simulation subsystem to eliminate cross-domain latency and clock jitter during the operation of the physical domain real-time simulation subsystem and the communication network simulation subsystem, thus constructing a joint simulation system of the physical side and the information side.

[0032] In a specific embodiment, the RT-LAB physical electromagnetic transient solver and the EXata network engine are respectively bound and run on the independent CPU (Central Processing Unit) cores of the OPAL-RT (Open Parallel Architecture Laboratory-Real-Time) simulation host, such as the OP5707XG simulation host, without interference. The vethscript.sh initialization script of the target machine's underlying Linux kernel is called to create pairs of high-speed virtual Ethernet interfaces, including the veth125 sniffing port. When loading the model, the exata_opalrt_configfile.json file is generated as a co-simulation configuration bridge, automatically completing the connection between the physical power grid interface IP (Internet Protocol) and the virtual switching network. To achieve a clean environment, the network namespace directive is used to migrate and isolate the EXata-specific network interfaces within a dedicated namespace.

[0033] This embodiment can utilize the virtual Ethernet interface pairs created in the underlying operating system kernel space for mapping and execute network namespace migration strategies to eliminate network latency and communication clock jitter caused by cross-host co-simulation, and build a hardware real-time high-frequency co-simulation base on the same machine.

[0034] This embodiment creates pairs of virtual Ethernet interfaces in the kernel of the same multi-machine real-time simulator, and performs namespace migration and isolation encapsulation on the virtual Ethernet interface belonging to the communication network simulation subsystem, thus constructing a hardware real-time high-frequency co-simulation base on the same machine. This fundamentally eliminates network latency and communication clock jitter caused by cross-host co-simulation, avoids clock out-of-sync and algebraic loop solution crashes in the microsecond-level electromagnetic transient solution process, and enables closed-loop verification on the physical and information sides to be carried out effectively.

[0035] S104: In the communication transmission path of the co-simulation system, identify the message containing the target control command, and determine the payload field storing the target control command from the message.

[0036] In this embodiment, the target of the attack can be the reactive current reference command of the grid-connected inverter carried by the GOOSE protocol. It is understood that this embodiment is also applicable to other industrial Ethernet protocols that carry control commands and other types of controlled objects, and there are no limitations on this.

[0037] This embodiment can identify messages containing target control commands in the communication transmission path of the co-simulation system, and determine the payload field storing the target control commands from the messages.

[0038] For example, the network card is configured to promiscuous listening mode. In the communication transmission path of the co-simulation system, the target medium access control address and the Ethernet frame header identifier field are used as filtering conditions to filter out messages containing target control commands. Based on the application layer protocol encoding rules, the absolute byte offset of the status sequence number field, the sequence number field, and the payload field storing the target control commands is parsed from the message.

[0039] Specifically, the underlying network interface card is configured to use a promiscuous listening mode. By utilizing the preset target media access control address and matching the Ethernet frame header identifier field EtherType of 0x88B8, IEC61850 GOOSE control messages in publish / subscribe mode are filtered and intercepted at high speed. Based on the architecture of the basic encoding rules of the abstract syntax markup, the fixed length of the network layer and application layer protocol headers is added to accurately locate the status sequence number, sequence number, and the offset position of the first byte of the data unit carrying the floating-point continuous control reference value in byte-level memory coordinates.

[0040] In a specific embodiment, a dynamic instruction tampering attack script based on Python and the Scapy traffic processing library is deployed. The network interface card (NIC) is set to promiscuous monitoring mode, implementing high-speed dual hardware fingerprint filtering: the Ethernet frame attribute EtherType must strictly match the GOOSE protocol proprietary identifier code 0x88B8, and the receiver's destination MAC address (Media Access Control Address) is locked to the controlled inverter interface fingerprint 01:0c:cd:01:28:73. After capturing packets, based on the basic encoding rules of the abstract syntax markup, the absolute byte offset coordinates of the core memory are located: the offset of the control service switching status sequence number field STNUM_OFFSET=148; the offset of the sequence number retransmission confirmation index SQNUM_OFFSET=155; and the offset of the floating-point control instruction payload area PAYLOAD_OFFSET=181.

[0041] S105: Write a time-varying disturbance signal to the payload field and send the message after writing the time-varying disturbance signal back to the communication transmission path.

[0042] This embodiment can write time-varying perturbation signals into the payload field and then transmit the message with the added perturbation signals back to the communication transmission path. The system extracts the current absolute running timestamp to generate a time-varying sinusoidal perturbation with a preset amplitude and frequency. Based on semantic reconstruction technology, the message is processed. While maintaining the message's structural compliance, the status sequence number field in the message is arithmetically incremented, and the sequence number field is reset to the initial semantic value of the protocol to bypass the security verification mechanism on the communication side. The generated time-varying sinusoidal perturbation is re-encoded and overwritten into the payload field of the message. The message, after recalculation of the protocol checksum, is then transmitted back to the communication transmission path.

[0043] When the payload field of the target control command is substantially tampered with, the status sequence number field in the message is extracted and an auto-increment operation is forcibly performed to disguise a legitimate declaration of a change in control status; the synchronous linkage forces the sequence number field representing the number of heartbeat retransmissions of the same control status to be reset to zero, so as to comply with the anti-replay timing verification mechanism built into the target receiver's smart electronic device and the legitimate retransmission logic of the protocol state machine state switching update event.

[0044] This embodiment does not limit the specific method of generating time-varying sinusoidal disturbances. Generally, the dynamic deviation increment can be obtained by inputting the absolute running timestamp into a time-varying disturbance function with a preset amplitude and a preset frequency. The dynamic deviation increment is then determined as the time-varying sinusoidal disturbance of the reactive current reference command in the load field.

[0045] Specifically, to bypass the anti-replay interception logic and the intrusion detection system based on time-limited rule trees of the target receiving device, the attack code forcibly takes over the protocol state machine before tampering with the payload. It uses a binary write instruction to directly increment stNum by one at offset 148 (global_fake_stnum+=1), and simultaneously forces a single-byte reset value of 0x00 to be written to the sequence number index sqNum at offset 155.

[0046] Subsequently, at the load offset, a legitimate source reference is extracted by floating-point unpacking. The absolute running timestamp is input into a time-varying disturbance function with a preset amplitude and a preset frequency to obtain the dynamic deviation increment. The reference value is then modified based on the dynamic deviation increment, as shown in the following formula: ; In the formula, Let be the time-varying perturbation function of a sinusoidal waveform. To prepare the tampered reactive current reference command for refeedback after semantic reconstruction encapsulation, The reactive current reference command is used; A is the set high-frequency dynamic sinusoidal disturbance peak amplitude, which can be 0.2. The characteristic frequency of the directional excitation current control closed-loop pole shift and subsynchronous oscillation can be taken as 1.2Hz; t is the absolute running timestamp, which is the difference between the current system's absolute simulation timestamp and the start time of the dynamic injection attack.

[0047] Calculated and generated continuous high-frequency changing target reference value The message is repackaged in big-endian byte order and written back into the original memory. The system forces a full loop check to be recalculated, and under the control of the preset minimum security injection time limit, calls the link-level sending interface to transparently feed the repackaged GOOSE message back into the controlled channel.

[0048] In addition to the sine waveform, the time-varying dynamic disturbance function can also be configured as a continuous function of the swept frequency signal or a piecewise step time-varying function; and when the tampered message is forcibly called to retransmit and re-feed back to the data link layer interface, a minimum security injection time interval of milliseconds is set to limit the network bandwidth blockage caused by repeated UHF packet transmission.

[0049] Finally, the generated time-varying sinusoidal disturbance is re-encoded and overwritten into the payload field of the message, and the message, after recalculation of the protocol checksum, is transmitted back to the communication transmission path. In one specific implementation, the calculated continuous high-frequency variation target reference value is re-encapsulated in big-endian byte order and overwritten into the payload area of ​​the original memory; the system forcibly recalculates the full cyclic redundancy check as the protocol checksum, and under the constraint of a preset minimum security injection time limit, calls the link-level sending interface to transparently feed the re-encapsulated GOOSE message back into the controlled channel. The minimum security injection time limit is in the millisecond range, used to limit network bandwidth congestion caused by ultra-high frequency repeated packet transmission and ensure the stability of the joint simulation communication link.

[0050] This embodiment utilizes semantic reconstruction technology to perform arithmetic increment on the state sequence number field and reset the sequence number field to the initial semantic value of the protocol without altering the overall message structure. It also recalculates the protocol checksum and re-feeds back the link, ensuring that the forged message satisfies the anti-replay timing verification mechanism and protocol state machine state switching logic built into the receiving end's intelligent electronic device. This allows for transparent delivery of the attack payload without triggering malicious data detection mechanisms. By replacing one-time fixed-value tampering with continuously time-varying dynamic disturbance signals, the inner current loop of the grid-connected inverter is continuously stimulated, forcing the dominant pole of the control loop to drift towards the negative damping region. This, in turn, breaks through the AC / DC physical boundary via the grid-connected transformer, effectively inducing cross-domain cascade instability in the main grid. This realistically reproduces the disaster mechanism initiated by a vulnerability in the underlying information layer protocol, amplified through cascade control in the inverter's inner loop, and ultimately leading to transient instability on the high-voltage side of the main grid.

[0051] S106: Record the state variables of the co-simulation system during the action of time-varying disturbance signals, and evaluate the cross-domain instability of the target power cyber-physical system based on the state variables.

[0052] This embodiment can record the AC voltage, source-side DC bus voltage, and photovoltaic array active power at the main grid common connection point in the co-simulation system. When the source-side DC bus voltage exhibits wide-band oscillations, the photovoltaic array active power exhibits intermittent pulse drops, and the AC voltage at the main grid common connection point exhibits oscillation instability, it can be determined that the target power information physical system has experienced main grid cross-domain instability.

[0053] In a specific embodiment, during the joint simulation test, the electrical transient response trajectories of the physical network and the information side are recorded in real time before and after the attack occurs and during the period of dynamic command tampering. The oscillation divergence, limit exceedance degree and control closed-loop instability characteristics of each physical state quantity after being disturbed are analyzed, and the cross-domain damage effect caused by dynamic command tampering is quantitatively evaluated.

[0054] Inside the inverter's source side, continuously changing dynamic command tampering directly disrupts the steady-state operating boundary of the control loop. The inner loop controller, forced to continuously track rapidly changing spurious reactive current commands at high frequency, generates severe quadrature-axis coupling interference in the dual-loop control logic based on a synchronous rotating coordinate system. This broadband disturbance drastically depletes the inverter's inherent damping margin, forcing the system's dominant pole to drift towards the negative damping region. The control loop failure further triggers abnormal tracking of the phase-locked loop's grid synchronization reference phase, inducing a severe deviation between the control command and the actual phase.

[0055] The slippage of the control poles and the failure of the inner loop are not limited to the local equipment end. The energy and transient impacts on the DC side of the source rapidly cross the AC / DC physical boundary and spread outward through the grid-connected transformer, resulting in severe broadband impedance mismatch and poor frequency coupling at the grid connection point.

[0056] like Figure 2 As shown, the AC voltage on the main grid side experienced a global transient voltage instability after being subjected to continuous high-frequency alternating power surges from the underlying layers. Before the attack, the main grid node voltage remained in a smooth steady state; however, after the dynamic command tampering was triggered, the main grid voltage waveform underwent severe distortion and dynamic instability, with drastic amplitude fluctuations. The above quantitative assessment results faithfully reproduced and revealed the cross-domain cascading disaster mechanism of the dynamic command tampering attack: it was initiated by a vulnerability in the underlying protocol of the information layer, amplified through cascading control within the inverter's inner loop, and ultimately breached the AC / DC physical boundary, leading to severe voltage oscillations and transient instability on the high-voltage side of the main grid.

[0057] This embodiment provides a quantifiable criterion for cross-domain instability. By synchronously recording the evolution characteristics of AC voltage at the main grid common connection point, DC bus voltage at the source end, and active power at the photovoltaic array side, a quantitative assessment of the cross-domain destructive effect of network attacks is achieved.

[0058] Based on the above embodiments, the present invention achieves high-fidelity quantitative assessment of the penetration and diffusion mechanism of high-risk network threats and the cross-domain instability characteristics of power grids by reconstructing message semantics and implementing dynamic time-varying function injection.

[0059] The following combination Figure 3 , Figure 3 This is a structural block diagram of an attack testing device for a power cyber-physical system provided in an embodiment of the present invention. The device may include: The first module 100 is used to acquire physical side data information and information side data information of the target power information physical system; The second module 200 is used to construct an electromagnetic transient model of the target power information physical system based on physical side data information, and to construct a virtual communication network topology corresponding to the electromagnetic transient model based on information side data information. The third module 300 is used to map the physical communication interface of the electromagnetic transient model to the virtual nodes in the virtual communication network topology, and to build a joint simulation system of the physical side and the information side. The fourth module 400 is used to determine the message containing the target control command in the communication transmission path of the co-simulation system, and to determine the payload field storing the target control command from the message. The fifth module 500 is used to write time-varying disturbance signals into the load field and send the message after writing the time-varying disturbance signals back to the communication transmission path; The sixth module 600 is used to record the state variables of the co-simulation system during the action of time-varying disturbance signals, and to evaluate the cross-domain instability of the target power cyber-physical system based on the state variables.

[0060] Based on the above embodiments, the present invention achieves high-fidelity quantitative assessment of the penetration and diffusion mechanism of high-risk network threats and the cross-domain instability characteristics of power grids by reconstructing message semantics and implementing dynamic time-varying function injection.

[0061] Based on the above embodiments, the third module 300 may include: The first unit is used to allocate the physical domain real-time simulation subsystem corresponding to the electromagnetic transient model and the communication network simulation subsystem corresponding to the virtual communication network topology to run on different processor cores of the same multi-core real-time simulator. The second unit is used to create virtual Ethernet interface pairs through the kernel of the multi-core real-time simulator, and use the virtual Ethernet interface pairs as the connection link between the physical communication interface and the virtual node, so as to establish a bidirectional communication connection between the physical domain real-time simulation subsystem and the communication network simulation subsystem. The third unit is used to perform namespace migration and isolation encapsulation on the virtual Ethernet interface belonging to the communication network simulation subsystem in the virtual Ethernet interface pair, so as to eliminate cross-domain latency and clock jitter between the physical domain real-time simulation subsystem and the communication network simulation subsystem during operation, and to build a joint simulation system of the physical side and the information side.

[0062] Based on the above embodiments, the fourth module 400 may include: The fourth unit is used to configure the network card to promiscuous listening mode. In the communication transmission path of the co-simulation system, the target medium access control address and the Ethernet frame header identifier field are used as filtering conditions to select messages containing target control commands. The fifth unit is used to parse the absolute byte offset of the status sequence number field, the sequence number field, and the payload field storing the target control instructions from the message based on the application layer protocol encoding rules.

[0063] Based on the above embodiments, the fifth module 500 may include: The sixth unit is used to extract the current system's absolute running timestamp to generate a time-varying sinusoidal disturbance with a preset amplitude and preset frequency; The seventh unit is used to process messages based on semantic reconstruction technology. While maintaining the structural compliance of the message, it performs arithmetic increment on the status sequence number field in the message and resets the sequence number field in the message to the initial semantic value of the protocol in order to bypass the security verification mechanism of the communication side. The eighth unit is used to re-encode the generated time-varying sinusoidal disturbance and overwrite it into the payload field of the message, and then transmit the message after recalculation of the protocol checksum back to the communication transmission path.

[0064] Based on the above embodiments, the sixth unit may include: The first sub-unit is used to input the absolute running timestamp into a time-varying disturbance function with a preset amplitude and a preset frequency to obtain the dynamic deviation increment; The second sub-unit is used to determine the dynamic deviation increment as a time-varying sinusoidal disturbance of the reactive current reference command in the load field.

[0065] Based on the above embodiments, the time-varying disturbance function is a sinusoidal waveform function, a continuous function of a swept frequency signal, or a piecewise step time-varying function.

[0066] Based on the above embodiments, the sixth module 600 may include: Unit 9 is used to record the AC voltage at the main grid common connection point, the DC bus voltage at the source end, and the active power at the photovoltaic array side in the co-simulation system. Unit 10 is used to determine the occurrence of cross-domain instability of the target power information physical system when the DC bus voltage at the source end exhibits wide-band oscillations, the active power on the photovoltaic array side exhibits intermittent pulse drops, and the AC voltage on the main grid common connection point side exhibits oscillating instability.

[0067] Based on the above embodiments, the present invention also provides an electronic device, which may include a memory and a processor. The memory stores a computer program, and when the processor calls the computer program in the memory, it can implement the steps provided in the above embodiments. Of course, the device may also include various necessary network interfaces, a power supply, and other components.

[0068] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by an execution terminal or processor, can implement the method provided in the embodiments of the present invention; the storage medium may include various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0069] In this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, without necessarily requiring or implying any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

Claims

1. An attack testing method for a power cyber-physical system, characterized in that, include: Acquire physical-side and information-side data information of the target power information physical system; An electromagnetic transient model of the target power information physical system is constructed based on the physical side data information, and a virtual communication network topology corresponding to the electromagnetic transient model is constructed based on the information side data information. The physical communication interface of the electromagnetic transient model is mapped to the virtual nodes in the virtual communication network topology to construct a joint simulation system of the physical side and the information side. In the communication transmission path of the co-simulation system, a message containing the target control command is identified, and the payload field storing the target control command is determined from the message; A time-varying disturbance signal is written into the payload field, and the message after the time-varying disturbance signal is written is sent back to the communication transmission path; Record the state variables of the co-simulation system during the time-varying disturbance signal, and evaluate the cross-domain instability of the target power cyber-physical system based on the state variables.

2. The attack testing method for a power cyber-physical system according to claim 1, characterized in that, Mapping the physical communication interface of the electromagnetic transient model to virtual nodes in the virtual communication network topology to construct a joint simulation system for the physical and information sides includes: The physical domain real-time simulation subsystem corresponding to the electromagnetic transient model and the communication network simulation subsystem corresponding to the virtual communication network topology are respectively assigned to run on different processor cores of the same multi-core real-time simulator. The kernel of the multi-core real-time simulator creates a virtual Ethernet interface pair and uses the virtual Ethernet interface pair as the connection link between the physical communication interface and the virtual node, thereby establishing a bidirectional communication connection between the physical domain real-time simulation subsystem and the communication network simulation subsystem. Namespace migration and isolation encapsulation are performed on the virtual Ethernet interface belonging to the communication network simulation subsystem in the virtual Ethernet interface pair to eliminate cross-domain latency and clock jitter between the physical domain real-time simulation subsystem and the communication network simulation subsystem during operation, thereby constructing the joint simulation system of the physical side and the information side.

3. The attack testing method for a power cyber-physical system according to claim 1, characterized in that, In the communication transmission path of the co-simulation system, a message containing the target control command is identified, and the payload field storing the target control command is determined from the message, including: Configure the network card to promiscuous monitoring mode, and in the communication transmission path of the co-simulation system, filter the packets containing the target control command by using the preset target medium access control address and Ethernet frame header identifier field as filtering conditions; The absolute byte offsets of the status sequence number field, the sequence number field, and the payload field storing the target control instructions are obtained from the message based on the application layer protocol encoding rules.

4. The attack testing method for a power cyber-physical system according to claim 1, characterized in that, Writing a time-varying perturbation signal to the payload field and then sending the message containing the time-varying perturbation signal back to the communication transmission path includes: Extract the current system's absolute running timestamp to generate a time-varying sinusoidal disturbance with a preset amplitude and preset frequency; The message is processed based on semantic reconstruction technology. While maintaining the structural compliance of the message, the status sequence number field in the message is arithmetically incremented, and the sequence number field in the message is reset to the initial semantic value of the protocol to bypass the security verification mechanism on the communication side. The generated time-varying sinusoidal disturbance is re-encoded and overwritten into the payload field of the message, and the message after recalculation of the protocol checksum is sent back to the communication transmission path.

5. The attack testing method for a power cyber-physical system according to claim 4, characterized in that, Extract the current system's absolute running timestamp to generate a time-varying sinusoidal disturbance with a preset amplitude and frequency, including: The dynamic deviation increment is obtained by inputting the absolute running timestamp into the time-varying disturbance function of the preset amplitude and the preset frequency; The dynamic deviation increment is determined as the time-varying sinusoidal disturbance of the reactive current reference command in the load field.

6. The attack testing method for a power cyber-physical system according to claim 5, characterized in that, The time-varying disturbance function is a sinusoidal waveform function, a continuous function of a swept frequency signal, or a piecewise step time-varying function.

7. The attack testing method for a power cyber-physical system according to claim 1, characterized in that, Record the state variables of the co-simulation system during the time-varying disturbance signal, and evaluate the cross-domain instability of the target power cyber-physical system based on the state variables, including: Record the AC voltage at the main grid common connection point, the DC bus voltage at the source end, and the active power at the photovoltaic array side in the joint simulation system; When the DC bus voltage at the source end exhibits wide-band oscillation, the active power on the photovoltaic array side experiences intermittent pulse drops, and the AC voltage on the main grid common connection point side exhibits oscillating instability, it is determined that the target power information physical system has experienced main grid cross-domain instability.

8. An attack testing device for a power cyber-physical system, characterized in that, include: The first module is used to acquire physical-side data information and information-side data information of the target power information physical system; The second module is used to construct an electromagnetic transient model of the target power information physical system based on the physical side data information, and to construct a virtual communication network topology corresponding to the electromagnetic transient model based on the information side data information. The third module is used to map the physical communication interface of the electromagnetic transient model to the virtual nodes in the virtual communication network topology, and to construct a joint simulation system of the physical side and the information side. The fourth module is used to determine, in the communication transmission path of the co-simulation system, a message containing the target control command, and to determine from the message the payload field storing the target control command; The fifth module is used to write a time-varying disturbance signal into the payload field and send the message after writing the time-varying disturbance signal back to the communication transmission path; The sixth module is used to record the state variables of the co-simulation system during the time-varying disturbance signal, and to evaluate the cross-domain instability of the target power cyber-physical system based on the state variables.

9. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor for executing the computer program to implement the attack testing method for the power cyber-physical system as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, implement the attack testing method for the power cyber-physical system as described in any one of claims 1 to 7.