Detect Firmware Corruption in Google Chronicle
Adversaries may overwrite or corrupt the flash memory contents of system BIOS or other firmware in devices attached to a system in order to render them inoperable or unable to boot, thus denying the availability to use the devices and/or the system. Firmware is software that is loaded and executed from non-volatile memory on hardware devices in order to initialize and manage device functionality. These devices may include the motherboard, hard drive, or video cards. Real-world examples include TrickBot's 'Trickboot' module (2020), which can write or erase UEFI/BIOS firmware of a compromised device, and Bad Rabbit ransomware, which installed a modified bootloader to prevent normal boot-up. Firmware corruption often results in permanent hardware denial-of-availability and may be combined with data destruction for maximum impact.
MITRE ATT&CK
- Tactic
- Impact
- Technique
- T1495 Firmware Corruption
- Canonical reference
- https://attack.mitre.org/techniques/T1495/
YARA-L Detection Query
rule t1495_firmware_corruption {
meta:
author = "Detection Engineering"
description = "Detects T1495 Firmware Corruption via known firmware tools, write/erase operations, suspicious driver loads, and UEFI/BCD tampering"
mitre_attack_tactic = "Impact"
mitre_attack_technique = "T1495"
severity = "CRITICAL"
confidence = "HIGH"
version = "1.0"
created = "2026-04-13"
events:
(
$e.metadata.event_type = "PROCESS_LAUNCH"
and (
re.regex($e.principal.process.file.full_path, `(?i)\\(rw\.exe|rw64\.exe|rweverything\.exe|chipsec\.exe|chipsec_main\.exe|flashrom\.exe|fpt\.exe|fptw\.exe|fptw64\.exe|afuwin\.exe|afuwin64\.exe|afudos\.exe|meinfo\.exe|meinfowin\.exe|meinfowin64\.exe|amidewin\.exe|amidewin64\.exe|h2offt\.exe|h2offt-w\.exe|winphlash\.exe|winphlash64\.exe|ubuild\.exe|ubu\.exe)$`)
or re.regex($e.target.process.command_line, `(?i)(--write|--erase|--flash|spi[._]write|bios.write|uefi.write|flash.write|nvram.write|WRITESPI|flashrom\s+-w|chipsec_util.spi.write)`)
or (
re.regex($e.principal.process.file.full_path, `(?i)\\(powershell|pwsh)\.exe$`)
and re.regex($e.target.process.command_line, `(?i)(Set-SecureBootUEFI|Set-UEFIVariable|bcdedit.*/set|bcdedit.*/delete|bcdedit.*/deletevalue)`)
)
)
)
or
(
$e.metadata.event_type = "DRIVER_LOAD"
and re.regex($e.target.file.full_path, `(?i)\\(rw\.sys|rwdrv\.sys|winio\.sys|winio32\.sys|winio64\.sys|physmem\.sys|pmem\.sys|dbutil_2_3\.sys|rtcore64\.sys)$`)
)
condition:
$e
} Chronicle YARA-L 2.0 rule detecting T1495 Firmware Corruption. Matches process launch events for known firmware manipulation tools (RWEverything, Chipsec, flashrom, AFU tools), command lines containing write/erase/flash arguments, PowerShell-based UEFI variable or BCD modification, and driver load events for known vulnerable or firmware-access kernel drivers. Uses UDM fields for process paths and command lines.
Data Sources
Required Tables
False Positives & Tuning
- Legitimate OEM firmware update utilities bundled with endpoint management platforms that match firmware tool names but execute from trusted vendor paths under authorized service accounts
- Penetration testing or red team engagements using Chipsec or RWEverything on isolated lab systems — correlate with change management records and authorized testing schedules
- Windows Subsystem for Linux or virtualization software that loads memory access drivers (physmem.sys, pmem.sys) for legitimate hardware abstraction purposes
Other platforms for T1495
Testing Methodology
Validate this detection against 5 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.
- Test 1CHIPSEC UEFI Variable Enumeration — Read-Only Firmware Reconnaissance
Expected signal: Sysmon Event ID 1: Process Create with Image=python.exe, CommandLine containing 'chipsec_util.py uefi var-list'. Sysmon Event ID 6: Driver load for chipsec.sys (or chipsec_hlpr.sys) from a temp or install directory. Security Event ID 7045: New service installed for the CHIPSEC kernel driver. Windows may prompt for UAC on driver installation.
- Test 2RW-Everything Hardware Access Tool Execution with Ring-0 Driver Load
Expected signal: Sysmon Event ID 1: Process Create with Image=Rw.exe and CommandLine containing '/Command="PCI 0 0 0 0 10"'. Sysmon Event ID 6: Driver load for rw.sys from tool directory or System32\drivers\. Security Event ID 7045: New service named 'RW' registered pointing to rw.sys. Service exits after tool completes but driver load telemetry persists.
- Test 3PowerShell BCD Store Modification — Bad Rabbit Bootloader Tamper Simulation
Expected signal: Sysmon Event ID 1: Process Create for powershell.exe with CommandLine containing 'bcdedit /set' and ExecutionPolicy Bypass. Two additional Sysmon EventCode=1 events for bcdedit.exe child processes. Security Event ID 4688 (if command-line auditing enabled) for both bcdedit invocations. PowerShell ScriptBlock Log Event ID 4104 capturing the full command.
- Test 4Linux flashrom SPI Flash Probe — Non-Destructive Hardware Reconnaissance
Expected signal: Linux auditd EXECVE record with a=flashrom, argv containing '-p', 'internal', '--no-action', '-V'. Syslog entry capturing sudo invocation and flashrom execution. On systems with Sysmon for Linux (EventID 1): Process Create event for flashrom. /var/log/auth.log entry recording sudo authentication for the flashrom command.
- Test 5Intel Flash Programming Tool (FPT) Flash Descriptor Read
Expected signal: Sysmon Event ID 1: Process Create with Image=fptw64.exe, CommandLine containing '-DESC -d'. Sysmon Event ID 11: File Create event for df00tech_flashdesc.bin in %TEMP%. Security Event ID 7045 may appear if FPT installs a kernel service for hardware access. The .bin file size will reflect the flash descriptor region size (typically 4KB).
References (8)
- https://attack.mitre.org/techniques/T1495/
- https://securelist.com/bad-rabbit-ransomware/82851/
- https://eclypsium.com/research/trickbot-now-offers-trickboot-persist-brick-profit/
- https://www.cisa.gov/uscert/ncas/alerts/aa22-057a
- https://cyber.dhs.gov/assets/report/ar-16-20173.pdf
- https://chipsec.github.io/
- https://www.flashrom.org/
- https://web.archive.org/web/20190508170055/https://www.symantec.com/security-center/writeup/2000-122010-2655-99
Unlock Pro Content
Get the full detection package for T1495 including response playbook, investigation guide, and atomic red team tests.