Siemens LOGO! Web Server Code Execution Vulnerability
The Siemens LOGO! web server copies a URI directory into a fixed-size stack buffer without checking its length, causing a stack overflow. An unauthenticated attacker can send a crafted HTTP request to corrupt memory and potentially execute code.
Originally disclosed on Cisco Talos
An exploitable code execution vulnerability exists in the Web Server functionality of Siemens LOGO! 1.82.02, 12/24RCE Version 0BA and 230RCE Version 0BA.
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 web server uses a memcpy to copy a user-controlled URI directory into a stack buffer without validating its length.
Impact
An unauthenticated attacker could cause memory corruption, leading to code execution on the PLC.
What the attacker needed
Network access to the device's web server; no authentication required
The fix
The vendor patched the vulnerability.
How it was found
- Send an HTTP request to the device with a URI containing a very long directory name between slashes.
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 buffer overflow happens when a program copies more data into a fixed-size memory area than it can hold, overwriting nearby data. Here, the web server takes a part of the requested web address and copies it without checking its length, so an attacker can send a very long address to crash the device or 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.