Process Control through Counterfeit Comms: using and abusing built-in functionality to own a PLC
Jared Rittle (Security Researcher · Cisco Talos)
BruCON 0x0A · Day 3
Overview
In this BruCON 2018 talk, Cisco Talos security researcher Jared Rittle delves into the intricate process of remotely compromising a Programmable Logic Controller (PLC), specifically focusing on the Allen-Bradley MicroLogix 1400. The presentation meticulously details how an attacker can leverage built-in, albeit often misunderstood or misconfigured, functionalities and obscure protocol behaviors to achieve complete control over an industrial control system (ICS) device. The research demonstrates a multi-stage attack that progresses from initial remote access to modifying device configuration, achieving persistent changes, and ultimately flashing custom, malicious firmware onto the PLC.

Key moments
- 1:50 Project goals: remote control, config modification, firmware flash
- 5:15 Introduction to PCCC communication protocol structure
- 10:45 Reverse-engineering channel config: protocol control byte & CRC
- 15:00 Unconventional crash exploit using 24-byte TCP payload
- 17:00 Overcoming config reset using memory module & programming routine
- 21:00 Custom firmware flashing via SNMP backdoor for device compromise
- 29:45 Live demo: 'HACKED' message displayed on PLC screen
- 30:00 Broader impact of compromise and recommended mitigations
Process Control through Counterfeit Comms: using and abusing built-in functionality to own a PLC
Speakers: Jared Rittle, Security Researcher, Cisco Talos
Conference: BruCON
YouTube: https://www.youtube.com/watch?v=SK86Ih1OP2Y
Overview
In this BruCON 2018 talk, Cisco Talos security researcher Jared Rittle delves into the intricate process of remotely compromising a Programmable Logic Controller (PLC), specifically focusing on the Allen-Bradley MicroLogix 1400. The presentation meticulously details how an attacker can leverage built-in, albeit often misunderstood or misconfigured, functionalities and obscure protocol behaviors to achieve complete control over an industrial control system (ICS) device. The research demonstrates a multi-stage attack that progresses from initial remote access to modifying device configuration, achieving persistent changes, and ultimately flashing custom, malicious firmware onto the PLC.
Rittle, a member of Cisco Talos's detection research and vulnerability groups, outlines the journey of discovering and chaining these vulnerabilities, which originated from an internal team project involving an ICS-powered kegerator. The talk highlights the critical importance of understanding proprietary industrial protocols like Ethernet/IP and PCCC (Process Control Command and Control), revealing how seemingly innocuous commands or undocumented behaviors can be abused. The work builds upon prior research, taking it several steps further to illustrate a comprehensive attack chain that culminates in the ability to implant a persistent backdoor or arbitrary code at the firmware level, fundamentally undermining the trustworthiness of the compromised device.
This research is particularly significant for the industrial control systems sector, where PLCs are foundational components governing critical infrastructure and manufacturing processes. By demonstrating the ability to alter firmware and maintain control, Rittle underscores the severe implications for operational integrity, safety, and supply chain security. The talk serves as a stark reminder that even hardened industrial devices, when not properly secured or updated, can be vulnerable to sophisticated attacks that exploit underlying design choices and communication protocols.
Background
▶ Watch: Project goals: remote control, config modification, firmware flash (1:50)
The genesis of this research stems from two primary sources: an internal Cisco Talos project involving a kegerator built using ICS/SCADA network equipment, and a previous Def Con talk by Rittle's teammate, Patrick, which explored initial vulnerabilities in industrial protocols. The kegerator project provided a hands-on environment to experiment with industrial protocols and devices, leading to the selection of the Allen-Bradley MicroLogix 1400 Series B PLC as the primary target for deeper investigation. This particular PLC model was chosen for its compact, all-in-one design, making it suitable for demonstrations.
A PLC, at its core, is a specialized computer designed for harsh industrial environments. It takes inputs (e.g., switches, sensors) and, based on programmed logic, produces outputs (e.g., lights, motor controls). Unlike general-purpose computers, PLCs often feature key switch states (or modes) that dictate the level of access and functionality. The three primary states discussed are:
- Program: Allows full control over configuration and logic, but no operational outputs.
- Run: Executes programmed logic and produces outputs, but typically restricts configuration changes.
- Remote: A hybrid state that allows external access and some sub-states, making it a common target for attackers seeking to manipulate operations without physical presence. This attack primarily focuses on the Remote state, although some aspects could be applicable to Run mode.
The communication protocol central to this research is Ethernet/IP, with PCCC (Process Control Command and Control) acting as the application layer command structure. PCCC is described as a relatively simple protocol, structured around a command, transaction, value, function code, and data. Understanding and dissecting this protocol was crucial for crafting custom commands. Rittle highlights the utility of manufacturer specifications and publicly available protocol documentation for reverse engineering efforts. The initial attack setup assumes a PLC running firmware version 21.003 or below, with SNMP (Simple Network Management Protocol) disabled by default, a standard memory module without write-protect, and the CPU in the Remote key switch state. These default or common configurations set the stage for the subsequent exploitation chain.
Key Findings
▶ Watch: Reverse-engineering channel config: protocol control byte & CRC (10:45)
The research uncovered a series of critical findings that, when chained together, allowed for a comprehensive compromise of the Allen-Bradley MicroLogix 1400 PLC. These findings represent significant contributions to understanding the security posture of common industrial control systems:
- Remote Configuration Modification (SNMP Enablement): Rittle discovered that the PLC's channel configuration file, which controls various services like SNMP, could be read and written to remotely via custom PCCC commands, even when SNMP was disabled. This was achieved by dissecting the PCCC traffic generated by the legitimate RSLogix programming software. The key was identifying the protocol control byte within the configuration data, a bit field that governed the on/off state of services.
- CRC-16 Validation Bypass: A significant hurdle in modifying the configuration was the presence of a CRC-16 checksum covering a large portion of the configuration data. Any attempt to write modified data without a correctly calculated CRC would result in an error. Rittle identified the specific bytes responsible for the CRC and developed a method to calculate and insert the correct CRC-16 value, enabling successful configuration writes.
- Unauthenticated Denial-of-Service/Reboot Vulnerability: Through a simple fuzzing approach, a critical vulnerability was discovered where sending a specific 24-byte malformed TCP data packet (specifically containing
E8FFfollowed by nulls) to the PLC would cause it to crash and reboot. This vulnerability did not require authentication or specific protocol encapsulation, making it highly impactful. - Persistence through Memory Module Manipulation: A major challenge was that the crash/reboot caused by the DoS vulnerability would trigger the loading of a "default program," which would revert any configuration changes (like enabling SNMP). Rittle found a way to configure the PLC to load its program from an installed memory module instead of the default program upon an unexpected reboot. This involved another PCCC write, after which the current online program (with the SNMP-enabled configuration queued) could be stored to the memory module, ensuring persistence.
- Leveraging an Unpatched SNMP Backdoor for Firmware Flashing: The ultimate goal was to flash custom firmware. The research leveraged a previously known but unpatched SNMP backdoor—a replica of the private SNMP community string that could not be changed. This backdoor provided the necessary write access via SNMP to trigger the firmware update process. By sending specific SNMP
SETcommands for a TFTP server IP address and firmware filename, followed by a reboot command, the PLC could be coerced into pulling and flashing modified firmware. - Firmware Checksum Manipulation: To successfully flash modified firmware, Rittle demonstrated how to alter the firmware file (e.g., changing "REMOTE" text to "HACKED" on the LCD) while maintaining the correct internal checksum. This was achieved by making balanced byte changes, ensuring the overall checksum remained valid.
These findings collectively illustrate a powerful attack chain that allows an unauthenticated attacker to remotely gain control over a PLC's configuration, achieve persistence across reboots, and ultimately implant malicious firmware, fundamentally compromising the device's integrity and functionality.
Technical Deep Dive
▶ Watch: Overcoming config reset using memory module & programming routine (17:00)
The attack chain begins with the objective of enabling SNMP (Simple Network Management Protocol) on the target PLC, the Allen-Bradley MicroLogix 1400. By default, SNMP is disabled, and while it can be enabled via the legitimate RSLogix programming software, this usually requires a physical key switch change or a power cycle. The goal was to achieve this remotely without physical access.
The initial step involved observing the network traffic generated by RSLogix when enabling SNMP. This was a complex task, as the proprietary PCCC (Process Control Command and Control) protocol within Ethernet/IP is not easily deciphered by standard tools. To overcome this, the team developed a Wireshark dissector for PCCC, which is now publicly available. This dissector proved invaluable in breaking down the PCCC commands and data.
Analysis revealed that SNMP enablement was tied to a channel configuration file on the PLC. To modify this, an attacker first needed to read its current state. Due to device or protocol limitations, this required two separate PCCC read commands, each retrieving approximately 50 bytes of data. The critical discovery within this data was the protocol control byte. This single byte functioned as a bit field, where individual bits corresponded to the on/off state of various services, including SNMP. By identifying the specific bit for SNMP, an attacker could flip it to 'on'.
However, simply modifying this bit and writing the data back was insufficient. The PLC would reject the write with an error response. Further investigation revealed a CRC-16 (Cyclic Redundancy Check) calculation performed across a significant portion of the channel configuration data. Any changes to the data required a re-calculation of this CRC and an update of the corresponding CRC bytes within the payload. Once the correct SNMP bit was set and the new CRC-16 was calculated and inserted, the modified configuration could be written back to the PLC using a PCCC write command. At this point, SNMP was "queued" to be enabled, but a power cycle was explicitly required for the change to take effect, as indicated on the PLC's LCD screen and in RSLogix.
The next challenge was to remotely force a power cycle. Standard reboot commands were not accessible through normal PCCC functionality. Rittle's team resorted to a fuzzing approach, sending streams of random TCP data to the PLC to try and crash it. This led to the discovery of a critical, unauthenticated denial-of-service (DoS) vulnerability. Sending precisely 24 bytes of malformed TCP data, specifically containing the byte sequence E8FF followed by nulls, consistently caused the PLC to crash and reboot. This was a significant finding as it provided a remote, unauthenticated way to force a power cycle.
However, a new problem emerged: after the crash and reboot, SNMP was found to be disabled again. The unexpected reboot triggered the PLC to load its "default program," which effectively wiped all recent configuration changes. To overcome this, the team leveraged the PLC's memory module functionality. The MicroLogix 1400 supports an optional memory module where programs and configurations can be stored. Crucially, the device could be configured to load its program from this memory module whenever an error or unexpected reboot occurred, rather than loading the default program.
To enable this "load from memory module on error" feature, another configuration change was required, specifically to the information backup settings (part of the status file). This write operation, like any privileged configuration change, necessitated the use of a programming routine. This routine is a sequence of PCCC commands that must be sent before and after the desired write command to gain and release appropriate privileges. The sequence involves: execute command list, get edit resource, the actual write command (modifying the information backup data to set the "load from memory module" bit), apply, and finally return edit resource. Once this bit was set, the entire online program (which now included the SNMP-enabled configuration queued for the next boot) could be stored to the memory module using another PCCC command. With these steps completed, crashing the device would now cause it to reboot, load the SNMP-enabled configuration from the memory module, and fully enable SNMP.
With SNMP successfully enabled, the final stage of the attack—flashing custom firmware—became possible. This leveraged a previously identified, but unpatched, SNMP backdoor. This backdoor was effectively a hardcoded, unchangeable replica of the private SNMP community string, granting full write access. The firmware flashing process involved three key SNMP SET commands:
- Set the TFTP server IP address (where the custom firmware file is hosted).
- Set the firmware file name.
- Trigger a reboot (this specific reboot command, unlike the DoS, directly put the device into firmware update mode).
The custom firmware itself was created by taking a legitimate firmware file from the vendor and making small, targeted modifications. For the demonstration, the text "REMOTE" displayed on the LCD was changed to "HACKED." A crucial technical detail here was maintaining the firmware's integrity by ensuring that any byte changes were balanced to preserve the overall checksum of the firmware file. For example, changing a capital 'D' to a lowercase 'b' might be offset by another minute change elsewhere to ensure the sum of bytes remained the same, thus passing the device's internal checks. Once these SNMP commands were sent, the PLC would connect to the specified TFTP server, pull the modified firmware file, perform internal checks, flash the device, and then reboot, displaying the custom message.
Demo / Proof of Concept
▶ Watch: Custom firmware flashing via SNMP backdoor for device compromise (21:00)
Jared Rittle provided a compelling live demonstration of the multi-stage attack, showcasing the theoretical concepts in a practical, real-world scenario. The demonstration utilized the Allen-Bradley MicroLogix 1400 PLC, running firmware version 21.003, with SNMP initially disabled.
The first phase of the demo focused on enabling SNMP and ensuring its persistence across reboots. Rittle initiated a script that performed the following actions:
- Reads the channel configuration file from the PLC using PCCC commands.
- Modifies the protocol control byte to set the SNMP bit to 'on'.
- Calculates and inserts the correct CRC-16 checksum for the modified data.
- Writes the updated channel configuration back to the PLC using the PCCC programming routine.
- Modifies the information backup data (via the PCCC programming routine) to enable "load from memory module on error."
- Stores the current online program (which now contains the SNMP-enabled configuration queued for reboot) to the memory module.
After these commands were sent, the PLC's LCD display still showed SNMP as disabled and indicated "power cycle required." This confirmed that the configuration changes were queued but not yet active.
Next, Rittle demonstrated the unauthenticated denial-of-service vulnerability. He sent the specific 24-byte malformed TCP data to the PLC. The PLC immediately reacted, with its fault light flickering, indicating a crash, followed by a reboot. Once the PLC came back online, the LCD screen was checked. This time, SNMP was visibly enabled, confirming that the memory module successfully loaded the persistent configuration.
With SNMP fully operational, the demonstration moved to the final, most impactful stage: flashing custom firmware. Rittle executed another set of commands, this time leveraging the SNMP backdoor:
- An SNMP
SETcommand was sent to configure the PLC's internal TFTP server IP address to point to the attacker's machine. - Another SNMP
SETcommand specified the custom firmware filename to be pulled. - A final SNMP
SETcommand triggered a special reboot that put the PLC into firmware update mode.
The PLC's lights changed, indicating it was actively pulling the firmware file via TFTP from the attacker's server. The LCD screen then displayed a progress bar as the firmware was being flashed. Once the flashing process completed, the PLC performed a final reboot. Upon coming back online, the LCD screen prominently displayed the word "HACKED" in the top right corner, replacing the original "REMOTE" text. This visually confirmed that the custom, modified firmware had been successfully installed and was now running on the device.
The demonstration powerfully illustrated that these were not mere superficial changes but deep, firmware-level modifications. Rittle emphasized that this capability could be extended beyond a simple text change to implant persistent backdoors, alter operational logic, or compromise the device's integrity in any desired manner, highlighting the severe security implications for industrial systems.
Defensive Implications
▶ Watch: Broader impact of compromise and recommended mitigations (30:00)
The detailed attack chain against the Allen-Bradley MicroLogix 1400 PLC presented by Jared Rittle offers crucial insights for industrial control system defenders. The primary takeaway is that PLCs, despite their specialized nature, are fundamentally computers and are susceptible to sophisticated software exploits that leverage both documented and undocumented protocol behaviors.
Here are the key defensive implications:
- Network Segmentation is Paramount: The most critical defense is robust network segmentation. Industrial control networks (OT networks) should be strictly isolated from enterprise IT networks and, especially, from the internet. PLCs should only communicate with necessary devices within their operational context. As Rittle succinctly put it, "these types of devices often don't need to talk to Google." Proper segmentation makes it significantly harder for attackers to reach PLCs and initiate such multi-stage attacks.
- Active Network Monitoring: Beyond segmentation, organizations must implement active network monitoring within their OT environments. Understanding baseline network traffic, including proprietary protocols like PCCC and Ethernet/IP, is essential. Detecting anomalous traffic patterns, such as unexpected PCCC write commands, malformed TCP packets (like the 24-byte DoS payload), or unusual SNMP activity, could indicate an ongoing attack. Cisco offers Snort rules that can detect some of the specific traffic patterns identified in this research.
- Leverage Key Switch Modes (Where Applicable): While some vulnerabilities were shown to be exploitable even in the "Run" mode, physically placing PLCs in the "Run" key switch mode (where physical controls permit) can still reduce the attack surface by limiting certain remote configuration capabilities. However, this is not a panacea, as the talk demonstrated how to bypass some of these logical restrictions.
- Prompt Firmware Updates: The research specifically targeted firmware versions 21.003 or below. Rockwell Automation has released patches addressing many of the vulnerabilities discussed. Defenders must ensure their PLCs are updated to firmware version 21.004 or newer to mitigate these specific attack vectors, particularly those exploitable in Run mode. A robust patch management program for OT devices is non-negotiable.
- Enable Memory Module Write Protection: For PLCs utilizing memory modules, enabling the write-protect feature (if available) is strongly recommended. This feature prevents logical write access to the memory module, thwarting attempts to store malicious configurations or programs that could persist across reboots, as demonstrated in the persistence phase of the attack. Without write protection, an attacker can leverage the memory module to ensure their changes survive unexpected reboots.
- Supply Chain Security and Firmware Integrity: The ability to flash custom firmware underscores the critical importance of firmware integrity and supply chain security. Organizations must have mechanisms to verify the authenticity and integrity of firmware before it is deployed. Post-compromise, it becomes challenging to trust the device, as malicious firmware could embed backdoors or alter operational logic in undetectable ways.
By implementing these defensive measures, organizations can significantly raise the bar for attackers and protect their critical industrial assets from sophisticated compromise attempts like the one detailed in this talk.
Key Takeaways
- PLCs are just specialized computers, not inherently secure: Despite their hardened casings and industrial settings, PLCs run software and communicate via protocols that can be reverse-engineered and exploited, similar to traditional IT systems.
- Deep protocol analysis is crucial for ICS security: Understanding proprietary protocols like PCCC and Ethernet/IP at a byte level, aided by tools like custom Wireshark dissectors, is essential for uncovering hidden functionalities and vulnerabilities.
- Chaining simple vulnerabilities leads to full compromise: The attack demonstrated how seemingly minor vulnerabilities (unauthenticated config write, DoS, persistence mechanism, unpatched backdoor) can be chained to achieve complete control, including custom firmware flashing.
- Firmware integrity is paramount: The ability to modify and flash custom firmware means an attacker can embed persistent backdoors, alter operational logic, and compromise the trustworthiness of the device at its deepest level.
- Robust ICS defenses are non-negotiable: Network segmentation, active network monitoring, prompt firmware patching (specifically to version 21.004+ for MicroLogix 1400), and enabling physical/logical write protection on memory modules are critical to protect against such attacks.
- Even "built-in functionality" can be abused: Features intended for maintenance or configuration, when not properly secured or understood, can become powerful tools for attackers to gain unauthorized access and control.
About the Speaker(s)
Jared Rittle is a Security Researcher at Cisco Talos. His work primarily focuses on detection research and vulnerability analysis within the Cisco Talos group. Rittle's role involves actively exploring how various devices function, identifying methods to compromise them, and subsequently developing strategies to help organizations protect against these discovered vulnerabilities and other threats. He enjoys the process of "getting to kind of play with stuff, you know, figure out how devices work, find out how to break them, and then try to find ways to help people, you know, protect against those things that we find and the things that people find."
Reviews
- Dr. Zero (Offensive Security Researcher) — MUST SEE ★★★★★
- Heather Calloway (CISO) — MUST SEE ★★★★★