Compromise Hardware Supply Chain
Adversaries may manipulate hardware components in products prior to receipt by a final consumer for the purpose of data or system compromise. By modifying hardware or firmware in the supply chain, adversaries can insert a backdoor into consumer networks that may be difficult to detect and give the adversary a high degree of control over the system. Hardware backdoors may be inserted into various devices such as servers, workstations, network infrastructure, or peripherals. Real-world examples include UEFI firmware implants (LoJax, CosmicStrand, BlackLotus), compromised network interface card firmware (Equation Group capabilities), and server baseboard management controller (BMC) implants. Detection is inherently constrained because the compromise predates the device's arrival, often manifesting as unexpected kernel-mode drivers, firmware modification activity, anomalous out-of-band management traffic, or covert network channels established through compromised NIC or BMC firmware. Defenders should focus on firmware integrity monitoring, hardware inventory baselining, driver signing verification, and anomalous network activity from system-level processes.
// T1195.003 — Hardware Supply Chain Compromise
// Detects OS-observable artifacts: unsigned drivers from suspicious paths,
// firmware flash utility execution, unexpected PCI device registration, and
// anomalous System process network activity (NIC firmware beaconing)
let LookbackWindow = ago(24h);
let FirmwareFlashTools = dynamic([
"afuwin.exe", "afuwin64.exe", "afudos.exe", "fpt.exe", "fptw64.exe",
"h2offt.exe", "h2offt-wx64.exe", "h2offt-wx86.exe", "flashrom.exe",
"winphlash.exe", "phlash16.exe", "amifldrv64.sys", "meinfo.exe",
"meinfowin.exe", "meinfowin64.exe", "fwupdmgr.exe", "chipsec_main.exe"
]);
let SuspiciousDriverPaths = dynamic([
"\\Temp\\", "\\AppData\\", "\\ProgramData\\",
"\\Users\\Public\\", "\\Windows\\Temp\\"
]);
let KnownGoodSigners = dynamic([
"Microsoft Windows", "Microsoft Corporation", "Intel Corporation",
"Intel(R) Corporation", "Advanced Micro Devices", "NVIDIA Corporation",
"Realtek Semiconductor", "Broadcom Corporation", "Qualcomm Atheros",
"Marvell Semiconductor", "Dell Inc", "HP Inc", "Hewlett Packard",
"Lenovo", "ASUSTek Computer"
]);
union isfuzzy=true
(
// Branch 1: Kernel drivers loaded from non-standard paths (implant payload delivery)
DeviceImageLoadEvents
| where Timestamp > LookbackWindow
| where FolderPath has_any (SuspiciousDriverPaths)
| where SignatureState !in~ ("SignedValid")
| extend DetectionBranch = "Unsigned Driver From Non-Standard Path"
| extend RiskDetail = strcat("Driver: ", FileName, " | Signer: ", iif(isempty(Signer), "UNSIGNED", Signer), " | State: ", SignatureState, " | Path: ", FolderPath)
| project Timestamp, DeviceName, AccountName, DetectionBranch, FileName, FolderPath, Signer, SignatureState, SHA256, RiskDetail
),
(
// Branch 2: Firmware flash utilities executing outside vendor update processes
DeviceProcessEvents
| where Timestamp > LookbackWindow
| where FileName has_any (FirmwareFlashTools)
or ProcessCommandLine has_any (FirmwareFlashTools)
| where InitiatingProcessFileName !in~ ("msiexec.exe", "setup.exe", "install.exe", "Update.exe", "DellUpdate.exe", "HPFirmwareUpdRec.exe")
| extend DetectionBranch = "Firmware Flash Utility Execution"
| extend RiskDetail = strcat("Tool: ", FileName, " | CmdLine: ", ProcessCommandLine, " | Parent: ", InitiatingProcessFileName)
| project Timestamp, DeviceName, AccountName, DetectionBranch, FileName, FolderPath, Signer = "", SignatureState = "", SHA256, RiskDetail
),
(
// Branch 3: New PCI device registry keys created by unexpected processes
DeviceRegistryEvents
| where Timestamp > LookbackWindow
| where ActionType == "RegistryKeyCreated"
| where RegistryKey matches regex @"HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Enum\\PCI\\VEN_[A-F0-9]{4}&DEV_[A-F0-9]{4}"
| where InitiatingProcessFileName !in~ ("services.exe", "drvinst.exe", "setuphost.exe", "DrvInst.exe", "svchost.exe", "msiexec.exe", "TrustedInstaller.exe")
| extend DetectionBranch = "Unexpected PCI Device Registration"
| extend RiskDetail = strcat("New PCI key: ", RegistryKey, " | Process: ", InitiatingProcessFileName, " | PID: ", tostring(InitiatingProcessId))
| project Timestamp, DeviceName, AccountName = "", DetectionBranch, FileName = InitiatingProcessFileName, FolderPath = RegistryKey, Signer = "", SignatureState = "", SHA256 = "", RiskDetail
),
(
// Branch 4: Kernel driver service installation (Event ID 7045) with kernel type
SecurityEvent
| where TimeGenerated > LookbackWindow
| where EventID == 7045
| extend ServiceName = tostring(EventData.ServiceName)
| extend ServiceType = tostring(EventData.ServiceType)
| extend ImagePath = tostring(EventData.ImagePath)
| where ServiceType has_any ("kernel mode driver", "file system driver")
| where ImagePath has_any (SuspiciousDriverPaths)
| extend DetectionBranch = "Kernel Driver Service Installed From Suspicious Path"
| extend RiskDetail = strcat("Service: ", ServiceName, " | Type: ", ServiceType, " | Path: ", ImagePath)
| project Timestamp = TimeGenerated, DeviceName = Computer, AccountName = SubjectUserName, DetectionBranch, FileName = ServiceName, FolderPath = ImagePath, Signer = "", SignatureState = "", SHA256 = "", RiskDetail
)
| sort by Timestamp desc Data Sources
Required Tables
False Positives
- Hardware vendor management software (Dell SupportAssist, HP Support Assistant, Lenovo Vantage) legitimately executes firmware flash utilities and installs drivers during scheduled updates — filter by known vendor parent processes and scheduled maintenance windows
- Windows Update and Windows Driver Framework (drvinst.exe, setuphost.exe, TrustedInstaller.exe) legitimately create PCI registry keys and install drivers during OS updates — these processes are explicitly excluded but verify parent process chains
- IT administrators running firmware audit tools (chipsec, flashrom in read-only mode, MEInfo) for inventory or security assessments — coordinate with asset management teams to identify authorized audit activity
- New hardware installations (RAM, PCIe NIC, GPU, storage controllers) added by IT staff post-deployment legitimately trigger PCI device registration events — correlate with IT change tickets
- Pre-production hardware validation labs where firmware is legitimately flashed as part of manufacturing QA processes — these environments may need separate detection policies
- Third-party hardware management agents (Dell OMSA, HPE iLO Amplifier, Lenovo XClarity) may load drivers from non-standard installation paths during their own setup procedures
References (10)
- https://attack.mitre.org/techniques/T1195/003/
- https://attack.mitre.org/techniques/T1195/
- https://www.welivesecurity.com/2018/09/27/lojax-first-uefi-rootkit-found-wild-courtesy-sednit-group/
- https://www.kaspersky.com/blog/cosmicstrand-uefi-rootkit/45292/
- https://www.binarly.io/posts/Black_Lotus_Unlocking_UEFI_Secure_Boot_Bypass/index.html
- https://github.com/chipsec/chipsec
- https://uefi.org/sites/default/files/resources/UEFI_Spec_2_9_2021_03_18.pdf
- https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1195.003/T1195.003.md
- https://eclypsium.com/blog/supply-chain-security-hardware-firmware/
- https://www.nsa.gov/portals/75/documents/what-we-do/cybersecurity/professional-resources/csi-defending-against-hardware-supply-chain-threats.pdf
Unlock Pro Content
Get the full detection package for T1195.003 including response playbook, investigation guide, and atomic red team tests.