A Practical Methodology for ML-Based EM Side Channel Disassemblers

César N. Arguello, Hunter Searle, Sara Rampazzi, Kevin R. B. ButlerarXiv 2022

Abstract

Providing security guarantees for embedded devices with limited interface capabilities is an increasingly crucial task. Although these devices don't have traditional interfaces, they still generate unintentional electromagnetic signals that correlate with the instructions being executed. By collecting these traces using our methodology and leveraging a random forest algorithm to develop a machine learning model, we built an EM side channel based instruction level disassembler. The disassembler was tested on an Arduino UNO board, yielding an accuracy of 88.69% instruction recognition for traces from twelve instructions captured at a single location in the device; this is an improvement compared to the 75.6% (for twenty instructions) reported in previous similar work.

Introduction

Embedded devices—found in everything from medical pumps to industrial sensors—are often "black boxes." They frequently lack traditional user interfaces, run proprietary firmware, and are rarely updated, making them prime targets for cyberattacks. Securing these devices is difficult because traditional security software cannot be installed directly on them.

Side-channel analysis offers a solution by monitoring physical outputs like power consumption or electromagnetic (EM) radiation to infer internal states. While power analysis is highly accurate, it requires a physical, wired connection to the device's power rail. EM monitoring is more attractive because it is non-contact, but it is notoriously difficult due to signal noise and the complexity of mapping "invisible" waves to specific CPU instructions. This research presents a non-invasive methodology to "read" instructions by combining strategic probe placement with a Random Forest machine learning model.

Methodology

The proposed methodology bridges the gap between raw EM noise and readable code through a three-stage process:

  1. Leakage Identification: Researchers performed an 80-point grid search across an Arduino UNO’s PCB using an EMI probe. They discovered that the "loudest" signal wasn't directly over the CPU, but near the operational amplifier connected to the crystal oscillator, which acted as a secondary radiator for the CPU's internal logic.
  2. Signal Extraction: Rather than relying on time-series data, a spectrum analyzer identified specific frequency bands (31.3–31.6 MHz) where the voltage difference between instructions was most pronounced. A Fast Fourier Transform (FFT) converted raw signals into frequency-domain features.
  3. Classification: Several machine learning models were tested, with the Random Forest algorithm proving most effective at classifying the FFT-derived features into specific instructions.
Figure 1: Leakage identification heatmap on the Arduino board (left) and frequency-domain signal extraction showing differences between NOP and MUL instructions (right).

Key Results and Insights

The study utilized two primary datasets: an Instruction Template Set of 12 distinct AVR instructions (e.g., ADD, MUL, NOP) and a Real-World Case Study involving a simulated "SyringePump" medical device.

  • High Accuracy: The system achieved 88.69% accuracy in recognizing 12 different instructions, a significant leap over previous work that achieved 75.6% on a slower processor.
  • Single-Point Sufficiency: Unlike previous methods requiring multiple measurement points, this methodology proves that one well-placed probe is sufficient for high-granularity disassembly.
  • Frequency vs. Time: The magnitude of specific frequencies (via FFT) provides a more robust feature set for machine learning classifiers than time-domain wave shapes when dealing with EM noise.
Figure 5: Confusion matrices for instruction classification across different cross-validation folds, demonstrating the high precision of the Random Forest model.

In the syringe pump case study, the model successfully identified instructions within the SerialRead function—a common target for buffer overflow attacks—with 77.4% accuracy, demonstrating real-world viability.

Limitations and Future Work

While promising, the current model was tested on a subset of the AVR instruction set. A full disassembler would need to account for the entire Instruction Set Architecture (ISA). Furthermore, while the ATMega328P is a standard 8-bit processor, future work must determine if this methodology scales to complex 32-bit or 64-bit architectures (like ARM or x86) with deeper pipelines. The ultimate goal is to evolve this system into a real-time intrusion detection tool that flags when instruction sequences deviate from normal firmware execution.

Summary updated

BibTeX
@misc{arguello2022practical,
  author = {César N. Arguello and Hunter Searle and Sara Rampazzi and Kevin R. B. Butler},
  title = {{A Practical Methodology for ML-Based EM Side Channel Disassemblers}},
  year = {2022},
  eprint = {2206.10746},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2206.10746},
}
Figure