3S-Smart Software Solutions CODESYS GatewayService memory corruption vulnerability
A memory corruption vulnerability in CODESYS GatewayService allows an attacker to send a specially crafted packet that causes an integer underflow, leading to a large memcpy and an access violation, terminating the process. This can be triggered remotely or locally, resulting in a denial of service.
An exploitable memory corruption vulnerability exists in the Name Service Client functionality of 3S-Smart Software Solutions CODESYS GatewayService. A specially crafted packet can cause a large memcpy, resulting in an access violation and termination of the process.
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 calculates a size value from packet fields without checking if they are within bounds, leading to an integer underflow that is used as the size in a memcpy operation.
Impact
An attacker could remotely cause a denial of service by crashing the GatewayService process.
What the attacker needed
Network access to the service
The fix
The vendor patched the vulnerability in version 3.5.16.10.
How it was found
- Connect to the target host and port.
- Send a specially crafted packet to the service.
- The service crashes due to an access violation.
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.
This report describes a flaw in industrial control software that lets an attacker crash a service by sending a malformed network message. The message tricks the program into copying too much data, which crashes it. The attacker can do this remotely, causing the service to stop working.
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.