The Undying Ghost: What LoJax Proved About Bare Metal

Reinstall Windows. Replace the drive. A firmware implant can still be there at the next boot. LoJax made that persistence concrete in 2018. Checking it takes more than a clean process list or one reassuring register bit.

Reinstall Windows. Replace the drive. Boot the machine and find the unwanted software back where it was.

A firmware implant can survive both operations. The storage you replaced was never the only storage in the machine.

ESET's 2018 LoJax investigation documented a malicious UEFI module written to SPI flash, with persistence that could restore malware onto the Windows partition during boot. ESET attributed the campaign to Sednit. Its original report describes the first UEFI rootkit it had found in the wild, rather than the first UEFI attack anyone had conceived.

The persistence mechanism

The campaign used modified LoJack userland agents and tools using the signed RwDrv.sys driver from RWEverything to access low-level platform state. The firmware-writing path depended on vulnerable or misconfigured platform protections. That finding does not establish that most enterprise systems leave their flash unprotected.

The commercial anti-theft lineage makes the story particularly unpleasant. Surviving a missing drive was a feature. The unwanted copy needed the same persistence.

One register bit cannot clear the machine

On supported lab hardware, with CHIPSEC installed and its platform access configured, the documented check is:

sudo chipsec_main -m common.bios_wp

CHIPSEC's module documentation describes both SMM-based protection and SPI protected ranges. A cleared BIOS write-enable bit alone is insufficient. Locking behavior, SMM write protection, and coverage of the BIOS region all matter. A protected boot block with writable code elsewhere is a different result from coverage of the full region.

The command above was not run on this Mac. No CHIPSEC output is supplied. Keep the tool version, platform, complete module output, and any unsupported or failed reads with the evidence. A configuration check reports the protections it can observe; it does not establish that the firmware is clean.

The bytes in the evidence folder

Before comparing firmware, preserve the acquisition method, platform model, firmware version, region boundaries, and baseline provenance. A vendor update capsule and a raw SPI dump can contain different packaging and regions. Mutable settings can also change bytes between acquisitions. Hashing unlike objects produces a difference without explaining it.

This Python code hashes acquired files without accessing hardware. It compares the complete files supplied by the operator:

import hashlib
import json
from pathlib import Path


def sha256_file(path):
    digest = hashlib.sha256()
    with Path(path).open('rb') as source:
        for chunk in iter(lambda: source.read(1024 * 1024), b''):
            digest.update(chunk)
    return digest.hexdigest()


def compare_files(baseline, observed):
    before = sha256_file(baseline)
    after = sha256_file(observed)
    return {
        'baseline_sha256': before,
        'observed_sha256': after,
        'byte_match': before == after,
        'baseline_trust_verified': False,
        'implant_detected': None,
    }

The complete command-line script includes four offline checks: a known SHA-256 vector, matching files, changed files, and a missing acquisition. All four passed locally on October 25, 2026. Save the download as firmware_file_compare.py and run:

python3 firmware_file_compare.py --self-test

For two files you have acquired, supply their actual paths through --baseline and --observed. Add --platform, --firmware-version, --acquisition-method, and --baseline-source to preserve the context in the JSON report. Use --chipsec-log with a saved UTF-8 log to attach its complete text and SHA-256. Missing metadata is listed explicitly. The report creation time is not the acquisition time, and operator-entered provenance remains a claim to verify. The output carries both hashes. A match means the bytes match the supplied baseline. A mismatch means the bytes differ. Neither result establishes baseline trust or detects LoJax; the JSON leaves those claims explicitly unverified.

The boot partition is another place

BlackLotus belongs in the comparison, with its storage location attached. Microsoft's 2023 investigation guidance describes exploitation of CVE-2022-21894 and malicious files on the EFI System Partition. That differs from LoJax's SPI-flash persistence. A claim about fully patched machines in the original BlackLotus reporting is not a permanent verdict on current Windows installations.

Nor does early execution make all detection impossible. An implant can leave firmware modifications, disk artifacts, and later activity. Which sensor sees which artifact depends on the product and acquisition path. A kernel driver is one vantage point. Firmware inspection and separately trusted acquisition provide others.

The protections have different jobs

ESET corrected its original LoJax remediation advice in October 2018: Secure Boot would not have prevented the SPI-flash implant described in that research. Firmware write protections and a correctly configured hardware root of trust address a different part of the chain. Keep Secure Boot in the design while checking what it actually verifies.

For current Windows memory-integrity state, the rootkit companion article includes a PowerShell collector. HVCI constrains kernel code execution. It does not repair already compromised firmware.

The drive can be new. The process list can look quiet. The firmware still needs its own evidence.

Correction and local build, October 25, 2026: removed fabricated CHIPSEC output and incomplete DXE code. Corrected write-protection interpretation, BlackLotus storage, and universal detection claims. Added tested offline file comparison; no hardware scan, firmware acquisition, or rootkit execution was performed.

GhostInThePrompt.com // Root is deep. Firmware is deeper.