Back to All Events

Assessing and Exploiting Control Systems and IIoT


Course Schedule

4 Day DOJO

IN-PERSON ONLY

*ON-LINE CAN be facilitated if there’s at least 2 weeks notice for equipment shipment to the attendee.

NOTE: This DOJO begins on SUNDAY and ends on WEDNESDAY, so you will miss the FIRST DAY of the conference.

 

Course Abstract

This is not your traditional SCADA/ICS/IIoT security course!  How many courses send you home with lifetime access to course updates and a $500 kit including your own PLC and a set of hardware/RF hacking tools?!?  This course teaches hands-on penetration testing techniques used to test individual components of a control system, including embedded electronic field devices, network protocols, RF communications, Human Machine Interfaces (HMIs), and various forms of master servers and their ICS applications.  Skills you will learn in this course will apply directly to systems such as the Smart Grid, PLCs, RTUs, smart meters, building management, manufacturing, Home Area Networks (HAN), smart appliances, SCADA, substation automation, synchrophasors, and even IoT.  

This course is structured around the formal penetration testing methodology created by UtiliSec for the United States Department of Energy.  Using this methodology and the ControlThings Platform (previously SamuraiSTFU), an open source Linux distribution for pentesting energy sector systems and other critical infrastructure, we will perform hands-on penetration testing tasks on user interfaces (on master servers and field device maintenance interfaces), control system protocols (modbus, DNP3, IEC 60870-5-104), proprietary RF communications (433MHz, 869MHz, 915MHz), and embedded circuit attacks (memory dumping, bus snooping, JTAG, and firmware analysis).  We will tie these techniques and exercises back to control system devices that can be tested using these techniques.  The course exercises will be performed on a mixture of real world and simulated devices to give attendees the most realistic experience possible in a portable classroom setting. 

Advances in modern control systems, including initiatives such as the Smart Grid and Industry 4.0, have brought great benefits for asset owners/operators and customers alike, however these benefits have often come at a cost from a security perspective.  With increased functionality and additional inter-system communication, modern control systems bring a greater risk of compromise that vendors, asset owners/operators, and society in general must accept to realize the desired benefits.  To minimize this risk, penetration testing in conjunction with other security assessment types must be performed to minimize vulnerabilities before attackers can exploit critical infrastructures that exist in all countries around the world.  Ultimately, this is the goal of this course, to help you know how, when, and where this can be done safely in your control systems.  

 

Course Pre-requisites

There’s recommended reading below.

 

About the Instructor: Justin Searle

Justin Searle is the Director of ICS Security at InGuardians, specializing in ICS security architecture design and penetration testing.  He led the Smart Grid Security Architecture group in the creation of NIST Interagency Report 7628 and has played key roles in the Advanced Security Acceleration Project for the Smart Grid (ASAP-SG), National Electric Sector Cybersecurity Organization Resources (NESCOR), and Smart Grid Interoperability Panel (SGIP).  

Justin has taught courses in hacking techniques, forensics, networking, and intrusion detection for multiple universities, corporations, and security conferences.  He is currently a Senior Instructor for the SANS Institute and a faculty member at IANS. In addition to electric power industry conferences, Justin frequently presents at top international security conferences such as Black Hat, DEFCON, OWASP, Nullcon, and AusCERT.  

Justin leads prominent open source projects including the The Control Thing Platform, Samurai Web Testing Framework (SamuraiWTF), Samurai Security Testing Framework for Utilities (SamuraiSTFU).  He has an MBA in International Technology and is a CISSP and SANS GIAC certified Incident Handler (GCIH), Intrusion Analyst (GCIA), Web Application Penetration Tester (GWAPT), and GIAC Industrial Control Security Professional (GICSP).

 
 

Course Agenda

Assessing and Exploiting Control System Architectures

  • Examples when to use

  • Overview of methodology

  • Different security assessment types and their respective benefits and risks

    • Passive vs active assessments

    • Manual vs automated

    • Reasons why architecture reviews should always be performed first

  • Basic control system concepts, systems, and devices

    • Control system architectures

    • PLCs, RTUs, and IEDs

    • Understanding RTOS

    • Industrial and non-Industrial

    • What is IIoT and how it differs from IoT

    • Field devices, buses, and loops

  • DCS vs SCADA

    • Plant neworks

    • SCADA networks

    • Purdue model and IEC 62443

 

Assessing and Exploiting Control Network Captures

  • Examples when to use

  • Overview of methodology

  • Traffic Capture

    • Hardware and software to use

    • Suggested configurations

  • Endpoint and Flow Analysis

    • Common TCP/IP based ICS protocols

    • Exercise: Using Wireshark for endpoint and flow analysis

    • Exercise: Using GrassMarlin

  • Known Protocol Analysis

    • Deepdive into Modbus TCP

    • Exercise: Analyzing Modbus TCP captures

    • Exercise: Using zeek with Modbus TCP

    • Exercise: Using strings on control protocols

    • Overview of ProfiNet, EnternetIP/CIP, OPC, DNP3, IEC 104, IEC 61850, ICCP

  • Unknown Protocol Analysis

    • Exercise: Finding unknown protocols with Wireshark

    • Exercise: Entropy analysis of network payloads

    • Exercise: Using GrassMarlin on unknown protocols

  • Gap Analysis with Security Architecture Review

 

Assessing and Exploiting Production Control Networks

  • Examples when to use

  • Overview of methodology

  • DNS interrogation

    • When DNS is and when it is not available

    • Using but not abusing DNS

  • Port Scanning

    • How and why control systems break on port scans

    • Nmap options to avoid

    • General Nmap recommendations

    • Recommended Nmap scans from low to high risk

  • Technology Fingerprinting

    • Safe and unsafe fingerprinting technologies

    • Alternatives to traditional fingerprinting

  • Protocol Enumeration

    • Common IT protocols that are generally safe to enumerate on control systems

    • Avoiding automatic enumerating of web interfaces on control systems

    • Dangers of enumeration control protocols in production

  • Vulnerability Scanning

    • Plugins and configuration that break control systems

    • Recommended settings for Nessus

    • Using audits

    • Again, the dangers of automated tools on web apps and services

  • Vulnerability validation

  • Exploitation

  • Post Exploitation / Cleanup

 

Assessing and Exploiting Controller Logic

  • Examples when to use

  • Overview of methodology

  • Understanding controller logic

    • Exercise: Understanding tags

    • Exercise: Understanding ladder logic

    • Exercise: Understanding sequential function charts

  • Velocio PLCs vs other PLCs

    • Exercise: Programming a PLC

    • Exercise: Debugging a PLC

  • Testing business logic flaws

    • Exercise: Leveraging the HMI for proof of concept attacks

 

Assessing and Exploiting Control Protocols

  • Examples when to use

  • Overview of methodology

  • Traffic Capture

    • Communication mediums vs communication protocols

    • Serial communications like RS-232, TIA-422, and TIA-485 

    • Fieldbus Protocols and Protocol Families

    • Understanding USB and serial interfaces on Windows

    • Methods to capture serial traffic in Windows and Linux

    • Exercise: Capturing serial traffic

    • Exercise: Manual decode of Modbus RTU

    • Understanding the common 1-off address issue of ICS protocols

    • Exercise: Using Wireshark to decode Modbus RTU

  • Protocol Enumeration

    • The severe lack of availability of ICS protocol tools

    • Repurposing an engineer's troubleshooting tools

    • Exercise: Using Python to interact with Modbus RTU on our PLC

    • Exercise: Enumeration with ctmodbus on our PLC

    • Understanding data types and 2's complement

  • Protocol Fuzzing

    • Reasons to avoid fuzzing protocols on embedded devices

    • Exercise: Writing protocol fuzzers with boofuzz

    • Exercise: Fuzzing Modbus TCP on our PLC

    • Exercise: Manual fuzzing with ctmodbus

  • Protocol Exploitation

 

Assessing and Exploiting Proprietary Serial Protocols

  • Examples when to use

  • Overview of methodology

  • Functional analysis

    • Using ICS vendor maintenance software and hardware

    • Exercise: Functional analysis of PLC's vendor tools

  • Communication capture

    • Capturing USB with hardware, software, and virtualization layers

    • Understanding USB and serial interfaces on Windows

    • Exercise: Capture of our vendor tool interactions with our PLC

  • Capture analysis

    • Exercise: Analysis of our vendor's proprietary protocol

    • Exercise: Reverse engineering our vendor's proprietary protocol

    • Exercise: Using Wireshark's column, comment, and coloring rules for RE

  • Testing harness creation

    • Exercise: Creating serial connections with Python

    • Exercise: Using ctserial to impersonate our vendor tools

  • Endpoint fuzzing

    • Exercise: Using ctserial for manual fuzzing on our PLC

  • Exploitation

 

Assessing and Exploiting Proprietary RF Protocols

  • Examples when to use

  • Overview of methodology

  • Capturing RF Signals

    • Hardware used for different RF protocols

    • When to use SDR vs rfcat

    • Comparison of different SDR hardware

    • Finding the right frequencies

    • Using the right antenna and using it correctly

    • Exercise: RF spectrum analysis with RTL-SDR and GQRX

    • Exercise: RF signal capture with RTL-SDR and  Universal Radio Hacker (URH)

    • Basic analysis of the captured signal

  • Spread Spectrum types and strategies

    • Strategies for recovering frequency hopping

  • Modulation and Demodulation

    • Visual identification of basic modulation types

    • Online samples of basic and complex modulation types

    • Exercise: ASK-OOK demodulation with RTL-SDR and URH

    • Exercise: 2FSK demodulation with RTL-SDR and URH

    • Exercise: Using rfcat and Yardstick One to generate our own RF packets

  • Bitstream to Packets

    • Understanding how data streams are assembled

    • Exercise: Analysis of packets URH

    • Exercise: Defining a protocol inside URH

  • RF Transmission

    • Traffic transmission and exploitation

    • Hardware needed for transmission

    • Signal transmission with URH

    • Exercise: Replaying captured packets with URH and rfcat

 

Assessing and Exploiting Embedded Memory

  • Examples when to use

    • Local attack through physically exposed devices

    • Expanding physical attacks to remote attacks

    • Cryptographic keys and firmware

  • Overview of methodology

  • Device disassembly

    • Component analysis on embedded circuits

  • Datasheet acquisition and analysis

    • Understanding engineer speak

    • Exercise: Reading an EEPROM datasheet

  • Dumping data at rest 

    • Tools and software to use

    • Overview of SPI serial protocol

    • How SPI is generally used on EEPROMs

    • Exercise: Using GreatFET to interact with SPI EEPROMs

    • Exercise: Writing Python functions for SPI in GreatFET software

  • Capturing bus data

    • Tools and software to use

    • Dangers of voltage and current to your tool and attached computer

    • Exercise: Using GreatFET to capture SPI traffic

  • Analyzing data obtained from data dumping and bus snooping

    • Exercise: Doing string analysis of datasets

    • Exercise: Doing entropy analysis of datasets

    • Exercise: Doing systematic key searches through datasets

    • Exercise: Doing file carving from datasets

  • Bonus material in the appendix (not covered in class)

    • Exercise: Dumping I2C EEPROMs with buspirate

    • Exercise: I2C bus capture with buspirate

    • Exercise: I2C bus capture with Saleae Logic

    • Exercise: Dumping SPI EEPROMs with buspriate

    • Exercise: SPI bus capture with buspriate

    • Exercise: SPI bus capture with Saleae Logic

 

Assessing and Exploiting Embedded Firmware

  • Examples when to use

  • Overview of methodology

  • Obtaining the firmware

    • Overview of JTAG

    • Exercise: Using OpenOCD to debug our ARM Cortex m4 Launchpad

    • Exercise: Using OpenOCD to dump our ARM Cortex Launchpad memory

    • Exercise: Identifying where the firmware is in the dump

  • Firmware disassembly

    • Code object analysis

  • Code functional analysis

  • Firmware exploitation

    • Exploiting firmware flaws

  • Bonus material in the appendix (not covered in class)

    • Exercise: Dumping memory and firmware from MSP430 LaunchPad

    • Exercise: Firmware encoding types and converting between them

    • Exercise: Disassembling MSP430 firmware

    • Exercise: MSP430 firmware crypto challenge

 

Resources Provided

The following items (or rough equivalents depending on availability) are provided to each attendee to use in class and keep after course completion:

  • Velocio Ace 1600 PLC (Programmable Logic Controller)

  • vBuilder software to program the PLC to keep (non-expiring)

  • vFactory software to program an HMI for the PLC (non-expiring)

  • RTL-SDR (Software Defined Radio)

  • Great Scott Gadgets Yardstick sub-GHz Radio

  • Great Scott Gadgets GreatFET

  • Breadboard with SPI and I2C EEPROMs

  • TivaC Launchpad (ARM m4) for Firmware exercises

  • Latest version of the ControlThings Platform on USB

  • PDF version of the course slide deck

  • Lifetime access to future updates to the course modules presented in class, restricted to the individual that attended the course

Internet connectivity may or may not be available depending on the facility hosting the course, so plan accordingly.

 

Attendee Computer Requirements

Each attendee must bring a computer that meets the following requirements:

  • 64-bit processor with 64-bit operating system

  • VT or other 64-bit virtualization settings enabled in your BIOS to run 64-bit VMs

  • At least eight (8) GB of RAM, recommended sixteen (16) GB if possible

  • At least fifty (50) GB of free hard drive space 

  • Intel VT or AMD-V virtualization hardware extensions ENABLED in BIOS

  • Windows 10.x installed on your host laptop or inside a VM

  • Virtualization software, which must be installed and tested with ControlThings Platform VM BEFORE CLASS!

    • Windows Users: Recent version of VirtualBox is the ONLY option, a version released within the last year.  VMware Workstation (Pro or Player) is NOT compatible with one of our hardware components needed on the last day.

    • Mac Users: Recent version of VirtualBox or VMware Fusion (released within the last year)

    • Linux Users: Recent version of Gnome Boxes, Libvirt, VirtualBox, or VMware Workstation (released within the last year)

  • Access to a local account with administrative permissions that can install software and disable any security services that interferes with course exercises

  • Access to and ability to change BIOS settings if needed in class

Attendees taking LiveOnline courses will need access to a stable Internet connection with enough bandwidth to maintain a 720p video stream.  We will be using a Discord server in class for chat and to ask questions before, during, and after class sessions, so all attendees will need the ability to connect to public Discord servers.  As for video streaming software, this may vary based on the organization hosting the class, but Discord is the preferred method suggested to those organizations since it is already being used for classroom chat.

Additional laptop configuration will be provided to attendees via email approximately one week before the course begins.  Attendees should plan on about 1-2 hours to complete the laptop configurations before class begins.

 

Recommended Reading before the Course

For those with little or no ICS experience, these Wikipedia articles provide a brief introduction to the concepts and history of control systems that will be helpful to know for class.

NIST 800-82 is a great introduction to industrial control systems, the security issues surrounding them, and basic cyber defenses

Since this course will be getting very deep into the technical weeds of communications, it would be helpful to have a basic understanding of the following encoding methods: ASCII, Unicode, UTF-8, UTF-16, and UTF-32

 
 
Previous
Previous
May 14

C/C++ Implementation Vulnerabilities

Next
Next
May 16

Introduction to Reverse Engineering with Ghidra