GGSEC Research · Whitepaper · June 2026

UEFI Attack Surface Research

Bootkits · Secure Boot bypasses · Pre-OS exploitation vectors · Firmware rootkit detection · SMM · DXE

Author: Maciej Gojny Organization: GG Advanced IT Security Web: ggsec.de Classification: TLP:WHITE – Public
01

Executive Summary

The Unified Extensible Firmware Interface (UEFI) has replaced legacy BIOS as the industry-standard firmware interface for x86, x64, and ARM platforms. While UEFI brings significant security improvements — Secure Boot, cryptographic verification, and a standardized architecture — it also introduces a dramatically expanded attack surface.

UEFI firmware executes before the operating system, before any security agent loads, and before most hardware-based attestation begins. A compromise at this layer provides the attacker with:

  • Persistence that survives OS reinstalls, disk replacements, and factory resets
  • Stealth invisible to all OS-level security tools (EDR, AV, HIDS)
  • Privilege equivalent to hypervisor or System Management Mode (SMM)
  • Control over boot process, Secure Boot policy, and hardware initialization
Key Insight: A UEFI bootkit is the cybersecurity equivalent of a building tenant changing the locks and then giving you a key that only works when they allow it. You never truly own your system again.

1.1 Business Impact

Impact AreaConsequences
OperationalPersistent compromise across fleet; remediation requires physical reflashing or motherboard replacement
FinancialFirmware incidents carry materially higher remediation cost than OS-level compromise, driven by per-device physical handling, specialist tooling and possible hardware replacement. GGSEC does not publish a point estimate; scope cost against fleet size and device accessibility.
CompliancePCI DSS, HIPAA, FedRAMP violations due to inability to attest boot integrity
ReputationalLoss of customer trust when bootkits are discovered in production environments
02

UEFI Architecture Overview

2.1 UEFI Boot Phases

UEFI Boot Phases — Attack Surface
SEC Phase
minimal attack surface
PEI Phase
Memory corruption in early heap
DXE Phase
CRITICAL — largest attack surface
BDS Phase
Boot order manipulation
TSL Phase
Secure Boot bypass opportunities
RT Phase
Runtime variable attacks
03

Bootkit Architecture & Capabilities

3.1 What is a UEFI Bootkit?

A UEFI bootkit is malicious code that resides in the SPI flash storage (firmware) and executes during the UEFI boot process, before the OS loads. Unlike traditional bootkits that resided on disk (MBR/VBR) and were removed during OS reinstallation, UEFI bootkits survive all software-based remediation.

3.2 Bootkit Insertion Vectors

Insertion VectorPrivilege RequiredPersistenceDetectability
SPI flash writeKernel/System (Ring 0)Permanent until reflashMedium
UEFI capsule updateAdmin/Platform ownerPermanentLow
Runtime variableKernel (Ring 0)Survives rebootHigh
Option ROMPCIe device vendorPer-deviceMedium
SMM calloutRing 0 + SMI handlerFirmware persistentLow

3.3 Bootkit Capability Matrix

CapabilityMBR BootkitUEFI BootkitUEFI Firmware Bootkit
Survives OS reinstall
Persists after disk format
Survives firmware update✓ (if not properly signed)
Invisible to EDR/AVPartial
Can subvert Secure Boot
Requires physical reflash
OS-level detection possiblePartialLimitedNear impossible
04

Secure Boot Bypass Techniques

4.1 How Secure Boot Works

Secure Boot ensures that only cryptographically signed and trusted software executes during the boot process. The UEFI firmware contains Platform Key (PK) and Key Exchange Keys (KEK). The signature database (db) contains authorized signatures or hashes. The forbidden database (dbx) contains revoked signatures. Each binary (bootloader, driver, option ROM) is verified before execution.

4.2 Known Secure Boot Bypasses

Bypass TechniqueCVEMechanismMitigation
Golden KeyMS16-094 / MS16-100 (2016)Leak of a Microsoft Secure Boot debug/supplemental policy allowing policy enforcement to be disabled. Not a master-key leak and not tracked under CVE-2018-12181.Policy revocation via dbx; boot manager updates
BootHoleCVE-2020-10713Buffer overflow in the GRUB2 grub.cfg flex/bison configuration parser, leading to arbitrary code execution in the boot chainUpdate dbx with vulnerable GRUB hashes
Baton DropCVE-2022-21894Secure Boot Security Feature Bypass in signed copies of the Windows Boot Manager. The bootloader truncates the Secure Boot policy values and continues booting instead of halting on missing DB/DBX data. Not an SMM issue.DBX revocation of vulnerable boot managers (KB5025885 chain)
Secure Boot bypass (follow-on)CVE-2023-24932Further Secure Boot bypass addressed by Microsoft in May 2023; the fix required manual opt-in activation, delaying real-world protectionApply KB5025885 and complete the opt-in enforcement steps
PKfailCVE-2024-8105Hundreds of OEM device models shipped with AMI test Platform Keys explicitly marked “DO NOT TRUST”; the private keys were subsequently leaked publicly. Disclosed by Binarly, July 2024.Replace test PKs with vendor production keys; audit PK/KEK/db provenance
LogoFAILCVE-2023-40238 (and related)Image parser vulnerabilities in DXE boot-logo handling. LogoFAIL is a vulnerability class spanning multiple CVEs across Insyde, AMI and Phoenix.Patch UEFI firmware, driver updates

4.3 Secure Boot Bypass Attack Flow

Secure Boot Bypass — Baton Drop (CVE-2022-21894)
Admin / physical access
Prerequisite — not an initial access vector
Drop vulnerable bootmgfw.efi to ESP
Validly Microsoft-signed, still trusted by db
Exploit policy truncation
Secure Boot policy stripped, boot continues
Enroll attacker MOK
Persistence via Machine Owner Key
Unsigned bootkit executes
HVCI / BitLocker / Defender disabled
Kernel driver + HTTP downloader
Ring 0 persistence and C2
Scope note: Baton Drop is a downgrade attack against the Windows Boot Manager. Every stage above executes in the normal boot path — no SMI is raised and SMM is not involved at any point. Persistence lives on the EFI System Partition, not in SPI flash.

4.4 Detection of Secure Boot Bypass

IndicatorDetection MethodTooling
Secure Boot disabled unexpectedlyUEFI variable monitoringsbctl, bootinfoscript
Unexpected certificates in dbCertificate inventory comparisonsbctl, mokutil
Missing expected certificatesBaseline comparisonCustom inventory scripts
Forged SetupMode variableVariable integrity checkTPM attestation
SMI handler corruptionSMI handler validationChipsec, SMM detection tools
05

Pre-OS Exploitation Vectors

5.1 DXE Driver Injection

The Driver Execution Environment (DXE) loads hundreds of UEFI drivers during boot. Each driver represents a potential attack surface.

Attack Method: Compromise running OS (kernel privilege), write malicious DXE driver to SPI flash or EFI System Partition (ESP), modify boot order or driver load order, then malicious driver loads during next boot before any security software.

Detection: Firmware integrity scanning (e.g., CHIPSEC), driver hash verification against golden images, boot-time driver enumeration logging.

5.2 UEFI Runtime Variable Attacks

UEFI variables store configuration data in NVRAM. Attackers can modify BootOrder to load malicious bootloader first, set SetupMode=1 to allow unsigned code, inject Boot#### variables pointing to attacker-controlled binaries, or overwrite SecureBoot=Disabled in variable storage.

Forensic Artifacts: Unexpected BootOrder values, unknown Boot#### variables, SecureBoot state changes without authorized update, AuditMode or DeployedMode transitions.

5.3 Option ROM Attacks

PCIe devices (NICs, storage controllers, GPUs) can ship with Option ROMs containing UEFI drivers. Attackers can flash malicious Option ROM to PCIe device, leverage DMA capabilities to read/write system memory, and execute code in UEFI context during device initialization.

Detection: Option ROM scanning and hash verification against vendor database.

5.4 ACPI Table Manipulation

ACPI tables provide power management and hardware configuration. Malicious modifications can inject code via DSDT (Differentiated System Description Table), manipulate FACP (Fixed ACPI Description Table) for SMM abuse, or add malicious SSDT (Secondary System Description Table) entries.

Tooling: acpiexec, iasl for table inspection.

5.5 SMM (System Management Mode) Subversion

SMM is the highest privilege execution environment (Ring -2). SMM code executes in response to System Management Interrupts (SMIs) and can access all system memory.

Attack Vectors: SMI handler buffer overflow leading to SMM code execution, SMM callout via runtime service, SMM cache poisoning, and software-generated SMI with attacker-controlled parameters.

Detection: SMM integrity monitoring via CHIPSEC module common.smm, SMI handler enumeration and analysis, memory scanning for SMM-resident implants.

06

Known UEFI Firmware Rootkits & Malware

6.1 Comprehensive Malware Database

MalwareDiscoveredTargetMechanismPersistence
BlackLotus2022 (ESET analysis Mar 2023)Windows 10/11Bypasses Secure Boot via CVE-2022-21894 (Baton Drop) using a validly-signed but vulnerable boot managerESP (bootkit, not a firmware implant)
MoonBounce2021/2022WindowsModifies the pre-existing CORE_DXE component in AMI firmware rather than adding a new moduleSPI flash (firmware implant)
FinSpy / FinFisher2021 disclosureWindowsCommercial surveillance suite; UEFI bootkit variant replacing the Windows Boot ManagerESP
LoJax (Sednit / APT28)2018WindowsFirst UEFI rootkit confirmed in the wild; built on a repurposed Absolute Computrace/LoJack moduleSPI flash
MosaicRegressor2020WindowsBased on the leaked Hacking Team Vector-EDK implant framework; drops a multi-stage downloader at each bootSPI flash
CosmicStrand2022WindowsKernel hook injected via the CSMCORE driver; targets GIGABYTE/ASUS H81 consumer boardsSPI flash
ESPecter2021WindowsMalicious bootloader on ESPEFI System Partition
Bootkitty2024Linux (Ubuntu)Proof-of-concept UEFI bootkit for Linux. Self-signed — requires the operator to enroll their own MOK; it is not trusted by default Secure Boot.ESP

6.2 BlackLotus Deep Dive

BlackLotus (2022-2023) is the most sophisticated publicly documented UEFI bootkit.

AttributeDetail
DiscoveryAdvertised on underground forums from October 2022; first public analysis published by ESET Research, March 2023
CVECVE-2022-21894 — “Baton Drop”, a Secure Boot Security Feature Bypass in the Windows Boot Manager
TargetWindows 10/11 x64 with Secure Boot enabled
PrerequisiteNot an initial access vector — requires prior privileged or physical access to the device
CapabilitiesDisables HVCI, BitLocker and Microsoft Defender Antivirus; loads an unsigned kernel driver and a user-mode HTTP downloader for C2
PersistenceEFI System Partition (ESP) plus enrollment of the attacker’s Machine Owner Key (MOK). BlackLotus does not write to SPI flash — it is a bootkit, not a firmware implant.
Detection evasionKernel driver protects bootkit files on the ESP from removal
Forensic artifactsUnexpected paths under \EFI\Microsoft\Boot\; mismatched ESP file modification timestamps versus C:\Windows\Boot\EFI
RemediationESP wipe and OS reinstall are sufficient. Physical SPI reflash is not required for BlackLotus alone.
DistributionUnderground forums, approximately US$5,000 per license
Mitigation: Apply Microsoft KB5025885 (2023) and subsequent patches and complete the opt-in enforcement steps — the initial release did not enforce revocation automatically. Update DBX to revoke the vulnerable boot managers, and enable HVCI plus TPM-backed measured boot.

6.3 MoonBounce Deep Dive

MoonBounce (discovered by Kaspersky, 2021) targeted AMI UEFI firmware on enterprise laptops.

AttributeDetail
TargetAMI UEFI firmware on enterprise laptops
InsertionModification of the pre-existing CORE_DXE component in AMI firmware. No new module is added — this is what makes MoonBounce substantially harder to detect than LoJax.
PersistenceFirmware-level; survives disk replacement
DetectionByte-level comparison of CORE_DXE against a known-good vendor image; no new files appear on the ESP, so ESP-based detection fails entirely
AttributionAPT41 (suspected)

6.4 OEM Persistence Modules — The Legitimate Backdoor Class

A category distinct from malware deserves separate treatment: vendor-supplied firmware modules that implement the same technical primitives as an implant, but ship from the factory. They are legitimate by intent and indistinguishable from an implant by behaviour. Threat actors have repurposed them directly.

ModuleVendorMechanismSecurity relevance
Computrace / LoJackAbsolute SoftwareUEFI module drops rpcnetp.exe to System32 by replacing AUTOCHK.EXE; installs a Windows service; C2 to vendor infrastructureRepurposed by APT28 as LoJax — the first in-the-wild UEFI rootkit. Factory-embedded on a reported 600M+ devices.
Lenovo Service Engine (LSE)LenovoWPBT-based; replaces autochk.exe to reinstate LenovoUpdate.exe / LenovoCheck.exe after a clean OS installWithdrawn 2015 after buffer overflow disclosure; required a BIOS update to remove
App Center Download & InstallGIGABYTEWpbtDxe.efi drops an embedded Windows native binary that fetches payloads over plain HTTP with no signature validation271 board models, ~7M devices (Eclypsium, 2023). MITM-exploitable by design.
Vendor password recoveryVarious (ASUS, HP)Undocumented service paths permitting UEFI setup or HDD password reset without authenticationPatched individually; illustrates the class rather than any single case
Detection guidance: the reliable structural signal is a Windows-subsystem PE (Subsystem 1 = Native, or 2 = GUI) embedded inside a UEFI-subsystem module (Subsystem 10–12). GGSEC’s ggfw toolkit (§13.1) flags this pattern regardless of vendor attribution. Supporting indicators: references to the WPBT ACPI table; the strings autochk.exe, AUTOCHK.BAK, BootExecute; and plain-HTTP update URLs inside DXE modules.
Assessment note: a dormant OEM module is not an active compromise, but it is not zero-risk either. Where SPI descriptor access control permits host writes to the BIOS region, an attacker with local privilege can reactivate or replace such a module. Report the descriptor permission finding as the primary issue and the OEM module as context.
07

Detection Methodologies

7.1 Firmware Integrity Scanning Tools

ToolMethodStrengthsLimitations
CHIPSECPlatform analysis frameworkComprehensive SMM, variable, SPI checksRequires technical expertise
BinWalkFirmware binary analysisExtracts and parses UEFI volumesLabor-intensive, no automation
UEFIToolUEFI image manipulation/analysisGUI for firmware explorationManual analysis only
FwhuntUEFI module analysisDetects known malicious patternsSignature-based
ggfw (GGSEC)Automated offline SPI analysis and platform posture assessmentSingle-pass descriptor, FV, variable-store and PE/DXE analysis with confidence-scored findings; PE extraction for YARA triage; live MEI fallback where offline evidence is insufficientHeuristic triage rather than a signature engine; in beta

7.2 CHIPSEC Audit Modules

# Basic system audit
python chipsec_main.py -a -l chipsec.log

# Critical UEFI audit modules
python chipsec_util.py uefi scan
python chipsec_util.py spi dump firmware.bin
python chipsec_util.py smi scan
python chipsec_util.py vars list

# Secure Boot verification
python chipsec_util.py uefi secureboot

# SMM integrity check
python chipsec_util.py smm info
python chipsec_util.py smm compress

7.3 Detection Analytics (MITRE ATT&CK)

TechniqueIDDetection Method
System FirmwareT1542.001Firmware version monitoring; SPI flash hash comparison
BootkitT1542.003UEFI variable monitoring; boot order baseline
Secure Boot BypassT1553.001Signature verification events; db/dbx modification audit
SMM AbuseT1055 (variant)SMI handler integrity; SMM communication monitoring
UEFI Variable ManipulationT1612Runtime variable audit logging

7.4 Enterprise Detection Controls

ControlImplementationCoverage
Firmware inventoryPeriodic SPI flash hash collection (PowerShell + WMI)Baseline deviation
Secure Boot monitoringEvent ID 1035 (Secure Boot validation failure)Windows Event Log
UEFI variable auditGet-UEFIVariable PowerShell loggingVariable changes
Boot order baselineCentralized boot order registryUnexpected changes
TPM attestationPCR 0-7 measurements; remote attestationHardware-backed integrity

7.5 Windows-Specific Detection

# Check Secure Boot status
Confirm-SecureBootUEFI
Get-SecureBootPolicy

# Enumerate UEFI variables
Get-UEFIVariable -Name "BootOrder"
Get-UEFIVariable -Name "SecureBoot"

# Check for unexpected boot entries
bcdedit /enum all

# Review Code Integrity events
Get-WinEvent -FilterHashtable @{LogName='Microsoft-Windows-CodeIntegrity/Operational'; ID=3076}

7.6 Linux-Specific Detection

# Check Secure Boot status
sbctl status
mokutil --sb-state

# Enumerate UEFI variables
ls /sys/firmware/efi/efivars/
efivar -l

# Verify kernel signature
kmodsign --verify /boot/vmlinuz-$(uname -r)

# Firmware detection (fwupd)
fwupdmgr get-devices
fwupdmgr get-updates
08

Mitigation Strategies

8.1 Architectural Controls

ControlDescriptionPriority
Secure Boot enforcementMandatory signature verification; UEFI 2.3.1+Critical
Firmware write protectionSPI flash write protect via hardware jumper or BIOS settingCritical
Measured Boot (TPM)Boot measurements in PCRs 0-7; remote attestation capabilityCritical
UEFI capsule updates signedRequire manufacturer-signed firmware updatesHigh
SMM isolationSMM page table protection; restricted SMI sourcesHigh
Runtime variable protectionCritical variables locked after EndOfDxeMedium
Option ROM verificationSignature check for PCIe Option ROMsMedium

8.2 Microsoft Recommended Mitigations for BlackLotus / Baton Drop

KBDateMitigationDeployment
KB5025885Apr 2023Initial BlackLotus mitigationWindows 10/11
KB5027455Jun 2023Enhanced dbx updateWindows 10/11
KB5025885 (update)Aug 2023Final revocations; full BlackLotus blockingAll supported Windows
# Deployment verification
reg query HKLM\SYSTEM\CurrentControlSet\Control\SecureBoot\Changes
reg query HKLM\SYSTEM\CurrentControlSet\Control\SecureBoot\Updated

8.3 Vendor Firmware Update Best Practices

  • Enable automatic firmware updates from trusted vendors for timely security patch deployment
  • Verify checksums before flashing to prevent corrupted/malicious updates
  • Use hardware-backed update verification to prevent rollback attacks
  • Maintain recovery image for rapid restoration if compromise detected
  • Disable legacy BIOS compatibility (CSM) to reduce attack surface

8.4 Incident Response for Bootkit Compromise

When bootkit is suspected, follow these steps:

  1. Isolate affected system – Assume all data is compromised
  2. Capture forensic artifacts – SPI flash dump (hardware programmer preferred), UEFI variable export, TPM event log, Secure Boot event logs
  3. Determine persistence mechanism – SPI flash vs. ESP vs. Option ROM
  4. Remediate – For SPI flash compromise: physical reflash with verified image or motherboard replacement. For ESP compromise: secure wipe and OS reinstall. For Option ROM compromise: replace affected PCIe device
  5. Verify remediation – CHIPSEC audit, Secure Boot re-verification
  6. Root cause analysis – How did initial compromise occur?
09

Forensic Analysis

9.1 SPI Flash Acquisition

Physical acquisition (preferred): Identify SPI flash chip (Winbond, Macronix, etc.), connect programmer (CH341A, Dediprog, Bus Pirate), dump full flash contents (8MB-32MB typical).

Software acquisition (limited): CHIPSEC (chipsec_main.py -a -l log.txt) and UEFITool for runtime extraction. Note that a host-side dump may return a blank ME region where descriptor permissions deny the read — full image size does not imply full image content.

Analysis: Binary diff against known-good image, UEFITool volume extraction, disassemble suspicious DXE or SMM modules, check for unexpected PEI or DXE drivers.

9.2 Forensic Artifacts

ArtifactLocationForensic Value
SPI flash imagePhysical flash chipComplete firmware; all modifications visible
UEFI variablesNVRAM (part of SPI flash)Boot order, Secure Boot state, db/dbx
EFI System Partition (ESP)Disk partition (FAT32)Bootloaders, boot applications, drivers
TPM event logTPM hardware / OS logBoot measurements; attestation failures
Secure Boot event logWindows Event LogSignature failures; revoked binaries

9.3 Signature-Based Detection (Blacklist)

IndicatorTypeSource
BlackLotus SPI patternsHashESET, Microsoft
MoonBounce DXE moduleHashKaspersky
Compromised GRUB versions (BootHole)Hash listMicrosoft dbx, US-CERT
Test PK certificatesCertificateCVE-2023-24932
9.4

Practical Firmware Analysis – Real‑World Artifacts

📸 UEFITool NE – Volume 000: DXE Drivers (DxeCore, AprioriDxe, SecurityStubDxe)
UEFITool Volume 000

🔍 DxeCore, AprioriDxe, SecurityStubDxe – key modules for analysis

📸 UEFITool NE – Complete DXE driver list (AMI firmware)
DXE Drivers List

🔍 25+ drivers: AprioriDxe, DxeCore, Bds, CpuDxe, NbDxe, SbDxe

📸 ME Analyzer – FTPR partition: kernel, crypto, ptt (Platform Trust Technology)
ME Analyzer FTPR

🔍 kernel (76KB), crypto (216KB), ptt (164KB – software TPM), fwupdate, heci

📸 Ghidra – DxeCoreEntryPoint + FindBootServices.py (GG SEC hook detector)
Ghidra FindBootServices

🔍 GG SEC custom script: FindBootServices – scans DxeCore for EFI_BOOT_SERVICES hooks

📸 Ghidra – DxeCoreEntryPoint (FindBootServices.py scan results – offsets)
FindBootServices scan results

🔍 FindBootServices.py output – detected potential hooks in EFI_BOOT_SERVICES table (offsets: RaiseTPL, AllocatePages, ExitBootServices, LocateProtocol, CreateEventEx, GetVariable)

📸 Ghidra – DxeCoreEntryPoint (FindBootServices.py scan – function analysis)
FindBootServices function analysis

🔍 FindBootServices.py detailed scan – DxeCoreEntryPoint analysis, GetVariable, GetNextVariableName calls

10

DXE Driver Deep Dive – BiosGuard, Hooking & Boot Services Manipulation

10.1 DXE Driver Loading Order – AprioriDxe

DriverPurposeSecurity Relevance
DataHubDxeData hub for system informationLow – info gathering
CpuDxeCPU initialization, SMM setupHIGH – SMM entry point
PciHostBridgeDxePCI host bridgeMedium – DMA attack surface

10.2 BiosGuardDxe – Critical Security Driver

Attack surface: BiosGuardDxe mediates authenticated flash writes. Research has demonstrated Boot Guard / BIOS Guard bypasses achieved by manipulating the Hand-Off Blocks (HOBs) that carry verification state between boot phases. Citation caution: CVE-2017-5706 is sometimes associated with this class in secondary sources, but it belongs to INTEL-SA-00086 (buffer overflows in Intel Server Platform Services firmware). Confirm any HOB bypass CVE against the primary vendor advisory before citing it.

10.3 Critical DXE Drivers for Security Research

DriverWhy Important
DxeCorePRIME TARGET – CosmicStrand, MosaicRegressor hook DxeCore
SmmCore / *Smm*HIGHEST PRIVILEGE (Ring -2) — target of SMI handler vulnerability classes such as CVE-2020-24489. Not a BlackLotus target; BlackLotus does not interact with SMM.
BiosGuardDxeBypass = unrestricted flash write

10.4 EFI Boot Services Hooking

ServiceWhen HookedKnown Malware
ExitBootServicesExecute payload before OSCosmicStrand
AllocatePagesAllocate hidden memoryMoonBounce
CreateEventExSchedule malicious callbackMosaicRegressor

10.5 Indicators of Compromise (IoC) – DXE Level

IndicatorTypical of
Write to gBS→ExitBootServices pointerCosmicStrand
CreateEventEx with unknown GUIDMosaicRegressor
Jump to address outside PE rangeGeneric implant indicator (MoonBounce, MosaicRegressor)
11

SMM Deep Dive – Ring -2 & System Management Mode

System Management Mode (SMM) is the highest privilege level in x86/x64 – Ring -2, beyond hypervisor (Ring -1) and kernel (Ring 0). SMM code executes in response to System Management Interrupts (SMIs) and can access all system memory, including hypervisor and kernel space.

Why SMM matters: If an attacker compromises SMM, no software-based detection (EDR, AV, hypervisor) can see or stop them. SMM is invisible from the OS.

11.1 SMM Architecture – Attack Surface

ComponentAttack Surface
SMI (System Management Interrupt)Malicious SMI generation → forced entry
SMI HandlerBuffer overflow → arbitrary SMM code
SMRAM (SMM RAM)SMRAM cache poisoning, lock bypass
SMM Communication ProtocolBuffer manipulation → SMM memory corruption
SW SMI (I/O port 0xB2)Unprivileged SMI generation → DoS / code execution

11.2 Documented SMI Handler Vulnerability Classes

Scope note: SMM attack classes are frequently conflated with Secure Boot bypasses in public reporting. They are distinct. Boot manager bypasses such as CVE-2022-21894 execute in the normal boot path and never enter SMM. The classes below describe genuine Ring -2 attack surface.
ClassMechanismRepresentative CVE
SMI handler buffer overflowAttacker-controlled data in the SMM communication buffer overruns handler-local storage, yielding code execution in SMRAMCVE-2020-24489
SMM calloutAn SMI handler dereferences a pointer into memory outside SMRAM that the attacker controls, executing non-SMRAM code at Ring -2Multiple vendor-specific
SMRAM lock bypassD_LCK / SMRR left unset, permitting direct SMRAM access from Ring 0Configuration weakness
SMM cache poisoningMTRR manipulation causes SMRAM fetches to resolve from attacker-controlled cache linesLegacy platforms

11.3 SMM Detection Methodology

# CHIPSEC SMM detection
python chipsec_util.py smi scan
python chipsec_util.py smm info
python chipsec_util.py smm compress
python chipsec_main.py -m common.smm
python chipsec_util.py smm smram_lock
Znane podatności w SMI handlerach:
  • CVE-2020-24489 – Intel – SMI handler buffer overflow
  • CVE-2025-4275 – “Hydroph0bia” – Insyde H2O firmware; relevant to OEM notebook fleets
  • Vendor-specific SMM callout issues – track via INTEL-SA / AMD-SB advisories per platform

11.4 SMM Indicators of Compromise (IoC)

IndicatorDetection
Unexpected SMI handlerSMI handler enumeration
SMRAM cache poisoningSMM integrity check (CHIPSEC)
SW SMI from unprivileged codeI/O port 0xB2 monitoring
SMRAM lock bypassRegister check (SMRR, SMM_ACCESS)
SMM Mitigation:
  • Enable SMM page table protection (BIOS setting)
  • Lock SMRAM after initialization (D_LCK bit)
  • Limit SMI sources (USB, PCIe hotplug)
  • Use CHIPSEC to verify SMM integrity regularly
11.5

The 2026 Secure Boot Trust Anchor Transition

Microsoft’s Secure Boot certificates issued in 2011 reach expiry in June 2026. This is the first refresh of the Secure Boot chain of trust since its introduction, and it changes the operational picture for every fleet in scope of this paper.

Why it matters operationally

CertificateRoleConsequence of expiry without replacement
Microsoft Corporation KEK CA 2011Key Exchange Key — authorises DB and DBX updatesDevice can no longer receive new revocations. The DBX freezes at its current state permanently.
Microsoft Windows Production PCA 2011Signs the Windows boot chainNewly signed boot components will not validate on un-updated firmware
Microsoft Corporation UEFI CA 2011Third-party signing (shim, option ROMs, vendor tooling)Third-party boot components affected on the same timeline
The core risk is not boot failure — it is revocation freeze. A device whose KEK has expired still boots normally. What it silently loses is the ability to accept future DBX entries. Every bootkit revocation published after that point never reaches the device. The failure mode is invisible from the endpoint.

Assessment checklist

# Windows — inspect current trust anchors
[System.Text.Encoding]::ASCII.GetString((Get-SecureBootUEFI KEK).Bytes) -match "2011|2023"
Get-SecureBootUEFI db | Select-Object -ExpandProperty Bytes | Measure-Object -Line
Confirm-SecureBootUEFI

# Linux
efi-readvar -v KEK
efi-readvar -v dbx | wc -l
mokutil --list-enrolled

Recommended actions

  • Inventory KEK certificate issue year across the fleet — 2011 versus 2023 — before the expiry window closes
  • Compare each device’s DBX against the current published UEFI revocation list; missing entries indicate a device that stopped receiving updates
  • Verify firmware update availability per model; OEM support status determines whether a device can receive the 2023 trust anchors at all
  • Treat end-of-support hardware that cannot accept new anchors as a separate, tracked risk population
  • Note that TPM presence and BitLocker enrollment do not imply correct Secure Boot configuration — verify independently
Interaction with PKfail (CVE-2024-8105): devices shipped with leaked AMI test Platform Keys are compromised at the root of the chain. For those models the anchor transition is an opportunity to replace the PK with a genuine production key, not merely to refresh the KEK.
12

Enterprise Implementation Roadmap

12.1 Phase 1: Assessment (Week 1-2)

  • Inventory UEFI versions across fleet – Firmware version report
  • Secure Boot status audit – Compliance dashboard
  • Identify non-Secure Boot systems – Remediation list
  • CHIPSEC scan on high-value systems – Baseline report

12.2 Phase 2: Hardening (Week 3-8)

  • Enable Secure Boot enterprise-wide – Critical
  • Update dbx with all known revocations – Critical
  • Enable TPM + BitLocker (with PCR 0-7) – Critical
  • Configure firmware write protection – High
  • Disable legacy boot (CSM) – High
  • Implement UEFI variable monitoring – Medium

12.3 Phase 3: Continuous Monitoring (Ongoing)

  • Firmware version drift detection – Monthly
  • Secure Boot attestation – Continuous (via MDE/CrowdStrike)
  • CHIPSEC full audit – Quarterly (critical systems)
  • UEFI variable baseline comparison – Weekly
  • Option ROM scanning – Upon new device enrollment
13

Why GGSEC – Threat Research & Firmware Specialization

GGSEC is a specialized security research laboratory focused exclusively on firmware-level threats, embedded systems auditing, and supply chain risk assessment.

13.1 GGSEC Firmware Toolkit (ggfw)

ggfw is GGSEC’s in-house firmware analysis platform, covering SPI acquisition, offline image analysis, and platform security assessment in a single tool. It was developed after the first release of this paper and now serves as the primary instrument behind GGSEC’s firmware engagements. The analyses reproduced in §9.4 and §10 were produced with it.

ModuleCapability
Offline SPI image analysisFull-chip image parsing with dump scope assessment — distinguishes a true full-chip dump from a BIOS-region-only capture, and reports which descriptor-declared regions are actually covered
Intel Flash Descriptor decodeFLMAP0/1/2, FCBA/FRBA/FMBA/FISBA decode; per-master read/write permission expansion for Host CPU/BIOS, ME and GbE; automated equivalent of the common.spi_desc access-control check
UEFI firmware volume walkerTop-level and nested FV enumeration with header checksum and bounds validation; FFS inventory including deleted, opaque and executable file counts; NVRAM volumes routed to variable-store analysis rather than an FFS walk
PE/DXE anomaly heuristicsScores executables on host-API imports, W+X sections, entropy and packaging anomalies. Detects the Windows-subsystem PE embedded in a UEFI-subsystem module pattern common to OEM persistence modules and firmware implants (see §6.4)
PE/TE extractionExtracts flagged modules for offline YARA/AV triage with CSV and JSON manifests; interesting modules are written with a .HIT extension for filtering
Bounded disassemblyZydis-backed reachable-code analysis of extracted hits. Resolves string cross-references, so a suspicious string with no reachable XREF is reported as low-confidence rather than as a finding
UEFI variable store analysisVSS/VSS2 store parsing, record state accounting, offline attribute policy checks, and inventory of Secure Boot targets (PK, KEK, db, dbx, SetupMode, DeployedMode)
ME region assessment$FPT detection and blank-ratio analysis; identifies host-denied ME reads (FRAP/BRRA) and blocks reporting of an ME version that cannot be established offline
Live MEI / MKHIHost-side ME/CSE version query where the offline image is unreadable — ggfw --mei --mei-live-only
Region hash inventoryPer-region SHA-256 across Descriptor, BIOS, ME, GbE, PDR plus content-inferred UEFI payload — the baseline unit for fleet drift detection
Firmware family & CSM analysisVendor family inference (AMI, InsydeH2O, Phoenix) with confidence scoring; legacy reset-vector and boot-block inspection for CSM-capable platforms
Design principle — heuristics are triage, not verdicts. ggfw separates what it observed from what it concluded. A flagged module is ranked for manual review; the tool does not assert that firmware is clean or malicious. Where offline evidence cannot settle a question — runtime Secure Boot state, ME version behind a blocked read — ggfw says so and points at the live check instead of guessing. Findings state their own confidence.

Current release: v0.8.0 Beta. GUID identification uses an LVFS-derived bundled database.

13.2 Supporting Tooling

ToolPurpose
FindBootServices.py (Ghidra)Scans DxeCore for EFI Boot/Runtime Services hooks – detects CosmicStrand, MoonBounce and MosaicRegressor style hooking
UEFI Volume ExtractorDXE driver extraction, hash baseline generation, anomaly detection
ME Analyzer AutomationME region integrity validation, checksum verification, manifest signature validation
SMM Integrity ScannerSMI handler enumeration and SMM memory analysis
13.5

Methodology & Limitations

13.5.1 Methodology

This paper draws on vendor advisories, peer-reviewed and industry security research, conference proceedings, and first-party firmware analysis conducted by GGSEC. CVE identifiers, malware attributions and persistence mechanisms have been cross-checked against primary vendor and researcher sources rather than secondary reporting. Where the research community has not reached consensus on attribution, that uncertainty is stated rather than resolved editorially.

13.5.2 Limitations

  • Offensive implementation detail — exploit code, SPI write procedures, bootkit loader internals — is deliberately omitted. This document is written for defenders, firmware auditors and security architects.
  • Firmware-level attribution is technically difficult. Attributions reflect community consensus at the time of writing and should be treated as provisional.
  • Heuristic detection findings, including those produced by GGSEC tooling, indicate items warranting manual review. They are not malware verdicts.
  • Offline firmware analysis cannot establish runtime state. Secure Boot enablement, ME/CSE version and active service status require live host queries.
  • CVE status information is time-sensitive. Verify against vendor advisories before operational use.
14

Appendix & References

14.1 Quick Reference Card – Windows Detection Commands

Confirm-SecureBootUEFI
Get-UEFIVariable -Name "BootOrder"
Get-WinEvent -FilterHashtable @{LogName='Microsoft-Windows-CodeIntegrity/Operational'} | Where-Object {$_.Id -eq 3076}
Get-WmiObject -Class Win32_BIOS

14.2 Quick Reference Card – Linux Detection Commands

sbctl status
mokutil --sb-state
ls /sys/firmware/efi/efivars/
dmesg | grep -i "secure boot\|uefi"

14.3 Critical CVEs to Track

CVEDescriptionStatus
CVE-2022-21894Baton Drop — Secure Boot bypass in Windows Boot Manager (exploited by BlackLotus)Patched Jan 2022; revocation via KB5025885 chain
CVE-2023-24932Secure Boot bypass; Microsoft fix required manual opt-in activationPatched May 2023 — verify enforcement is actually enabled
CVE-2020-10713BootHole — GRUB2 grub.cfg parser buffer overflowPatched (dbx update)
CVE-2024-8105PKfail — leaked AMI test Platform Keys across 800+ device modelsVendor-dependent; audit PK provenance per device
CVE-2023-40238LogoFAIL — boot logo image parser flaws in DXE (class of CVEs)Patch pending (vendor dependent)
CVE-2024-7344Signed UEFI application permitting unsigned code execution; abused by HybridPetyaRevoked Microsoft Patch Tuesday, Jan 2025
CVE-2025-4275Hydroph0bia — Insyde H2O UEFI firmwareVendor advisory; relevant to OEM notebooks

14.4 References

  1. ESET Research / Smolár, M. (2023). "BlackLotus UEFI bootkit: Myth confirmed." WeLiveSecurity, 1 March 2023.
  2. Microsoft Security Response Center. (2023). "Guidance for investigating attacks using CVE-2022-21894: The BlackLotus campaign."
  3. NSA. (2023). "BlackLotus Mitigation Guide" (CSI, June 2023).
  4. Binarly REsearch. (2024). "PKfail: Untrusted Platform Keys undermine Secure Boot" (CVE-2024-8105).
  5. Kamluk, V., Belov, S., Sacco, A. (2014). "Absolute Backdoor Revisited." Black Hat USA.
  6. Eclypsium. (2023). "Supply Chain Risk from Gigabyte App Center Backdoor."
  7. Kaspersky. (2021). "MoonBounce: the dark side of UEFI firmware."
  8. Microsoft Security Response Center. (2023). "CVE-2022-21894 Secure Boot Security Feature Bypass Vulnerability."
  9. MITRE ATT&CK. (2024). "Bootkit (T1542.003)" and "System Firmware (T1542.001)."
  10. Binarly Research. (2023). "LogoFAIL: Image parser vulnerabilities in UEFI DXE drivers."
  11. Quarkslab. (2020). "The BootHole vulnerability: GRUB2 bootloader compromise."
  12. Google Project Zero. (2020). "CVE-2020-10713: GRUB2 BootHole."
  13. Intel Corporation. (2023). "CHIPSEC: Platform Security Assessment Framework."
  14. National Institute of Standards and Technology. (2018). "NIST SP 800-193: Platform Firmware Resiliency Guidelines."
  15. US-CERT. (2023). "AA23-165A: BlackLotus UEFI Bootkit."