Multiple high-severity vulnerabilities in the CODESYS V3 software development kit (SDK) were recently discovered by Microsoft's cyberphysical system experts. The researchers were able to trigger a buffer overflow in a variety of industrial control system devices, revealing a number of vulnerabilities in the process. These flaws could result in a denial of service (DoS) or remote code execution (RCE) attacks.
The CODESYS V3 software development kit (SDK) is a software development environment used industry-wide to program programmable logic controllers (PLCs) that aids manufacturers to implement IEC 61131-3, which is a vendor independent international standard for programmable controller programming language for industrial automation. To be able to conduct this attack, researchers had to bypass user authentication, which was done by exploiting CVE-2019-9013. This allows for the use of a “replay attack against the PLC using the unsecured username and password’s hash that were sent during the sign-in process, allowing bypass of user authentication process.” They then had to create a new channel for the attack before signing in to the device with the stolen credentials. A malicious packet that triggers buffer overflow is then inserted to exploit the vulnerabilities and gain full control of the device. The complete exploit steps are summarized as follows:
Exploitation of any of the vulnerabilities could lead to either a Denial of Service (DoS) attack or remote code execution (RCE) attack. As these vulnerabilities affect the security of Industrial control systems that are used in critical infrastructure such as power, this could lead to major disruptions and outages. Also, it can allow attackers to create backdoors that can be used to cause mayhem or exfiltrate critical information.
Countermeasures to put into place include: