Schneider Electric EcoStruxure Control Expert PLC Simulator Modbus message processing remote code execution vulnerability
A stack buffer overflow exists in the Modbus message processing of Schneider Electric EcoStruxure Control Expert PLC Simulator 14.1. An attacker can send a large Modbus request to overwrite the stack and potentially execute arbitrary code.
Originally disclosed on Cisco Talos
A code execution vulnerability exists in the Modbus message-processing functionality of Schneider Electric EcoStruxure Control Expert PLC Simulator 14.1. A specially crafted network request can lead to remote code execution.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The program copies a user-controlled length from the Modbus message into a fixed-size stack buffer without validating that the length is within bounds.
Impact
An attacker could achieve remote code execution by corrupting the exception handler chain, as demonstrated by the crash analysis.
What the attacker needed
Simulator mode is running; Network access to port 502
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
A stack buffer overflow happens when a program copies more data into a fixed-size memory area than it can hold, overwriting nearby data. Here, the simulator reserves a fixed-size buffer for incoming Modbus messages but does not check the message length, so a large message can overwrite the stack and potentially let an attacker run their own code.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.