Skip to content

Process Hollowing

How Malware Hides in a Process

Process hollowing leaves a genuine program running whose image in memory is no longer the file it started from. Windows maps a program from its file when the process starts and keeps that image for its whole life, so the two always match. A mismatch usually means the genuine program was started only to carry other code, which then runs under its trusted name, path and command line. Check the region at the image base first, because a genuine process has its own file mapped there as an image.

What It Is

Before, the process has its own executable file mapped at its image base as an image, and the code there is the code in that file. After, the name, path, parent and command line still point at the genuine file, but the code at the image base no longer matches it.

The change shows in memory in one of three ways. No region may start at the image base, or the region there was created with a protection other than Execute, write copy, which images get. The process environment block (PEB), the process's own record, can also give a base that differs from the kernel's.

MITRE ATT&CK files it as T1055.012 Process Hollowing. A process whose file on disk was swapped, deleted or rolled back around its start is a different change, which ATT&CK files as T1055.013 Process Doppelgänging.

What Changes Inside the Process

The process is shown before and after, and the pointer marks what changed.

Before

A clean Windows 11 install

A service host on a clean install, with its own file mapped at its image base, as every image is.
  • Image

    • Type
      Image (MEM_IMAGE)
      Protection When Created
      Execute, write copy (PAGE_EXECUTE_WRITECOPY)
      Mapped File
      C:\Windows\System32\svchost.exe
    • Type
      Image (MEM_IMAGE)
      Protection When Created
      Execute, write copy (PAGE_EXECUTE_WRITECOPY)
      Mapped File
      C:\Windows\System32\ntdll.dll

After

ws-017,

A service host on ws-017, dana's workstation, on 21 Oct 2026, which is not part of the ws-042 incident. Example values.
TypeProtection When CreatedMapped File
No region starts at the image baseNoneNone (no region)
Mapped FileNo region starts at the image base: a process has its own file mapped there as an image. Process Hollowing
Image (MEM_IMAGE)Execute, write copy (PAGE_EXECUTE_WRITECOPY)C:\Windows\System32\ntdll.dll

Look Inside

What It Leaves Behind

The process is a genuine program, often started by a parent that never starts it, but its image in memory no longer matches its file on disk. Sysmon event 25 reports the change, and Microsoft's description names hollowing among the techniques it detects. In a memory image, windows.malware.hollowprocesses finds the main image region missing, created without the protection an image gets, or at a base the PEB and the kernel disagree on.

Why It Matters

Its name, path and command line all point at a genuine file, so most listings pass it. Only comparing the image in memory with the file, or the kernel's records with the process's own, shows the swap.

Which Evidence Can See It

Each tile says whether that kind of evidence can see it, and what it shows.

  • Memory

    Sees it

    A memory image shows the region at the image base missing, created with the wrong protection, or at a base the PEB and the kernel disagree on.

  • EDR Telemetry

    Partly

    DeviceProcessEvents in Defender XDR records the start and its odd parent. Microsoft documents no column there for an image replaced in memory.

  • Disk

    Cannot see

    The file on disk is genuine and unchanged, so a hash or signature check passes it. Only a dump of the process, compared with the file, shows the change.

  • Logs

    Partly

    Sysmon event 25 in Microsoft-Windows-Sysmon/Operational reports the replaced image, on machines running Sysmon. Event 4688 in the Security log shows only the odd parent.

How to Confirm It

Work through these in order. Each step names the page that shows how.

  1. Read its parent and command line from the creation record. A system program started by a user program, or with missing arguments, often comes with it, and where Sysmon runs, event 25 with Type Image is replaced follows.Process Trees and Call Chains
  2. In a memory image, read the region at the image base with windows.vadinfo, since a genuine image is mapped from its file. Then windows.malware.hollowprocesses reports a region that is missing, created with a protection other than Execute, write copy, or at a base the PEB and the kernel disagree on.Memory Regions
  3. Compare its code with the file live with Windows.Memory.Mem2Disk, which reads only memory mapped from a file. Pair it with Windows.System.VAD, which lists executable memory no file backs.Checking for Injected Code
  4. Agree it with whoever runs the response first, then extract the executable from memory with windows.pedump or Windows.Memory.PEDump and compare it with the file. A dump differs from the file where Windows adjusted addresses as it loaded it, so compare its code, not its hash.Dumping a Process and Memory

Investigation Steps With Named Tools

Each question has the tools that answer it on a running machine, and in a memory image, a copy of its memory saved to a file.

  • Does the image in memory still match its file on disk?

    On a Running Machine

    In a Memory Image

  • What is mapped at the image base?

    On a Running Machine

    In a Memory Image

  • Which program started it?

    On a Running Machine

    In a Memory Image

What Defenders See

Each record names its log and what must be switched on to get it.

Record and Where It LandsWhat to ReadHow to Turn It On
25 ProcessTampering (Process image change) (opens in a new tab)Microsoft-Windows-Sysmon/OperationalIt is written on any Windows computer running Sysmon.Type Image is replaced means the process's image in memory no longer matches its file. SigmaHQ's rule leaves out Program Files and a few known programs.Checking for Injected Code shows how to read it.Run Sysmon with ProcessTampering events in its configuration.
1 Process creation (opens in a new tab)Microsoft-Windows-Sysmon/OperationalIt is written on any Windows computer running Sysmon.ParentImage and CommandLine show a system program started by a user program, or with missing arguments, which often comes first.Process Trees and Call Chains shows how to read it.Run Sysmon with ProcessCreate events in its configuration.
4688 A new process has been created (opens in a new tab)SecurityIt is written on the computer the process ran on.Creator Process Name and New Process Name show the same odd pairing, where process creation auditing is on.Process Trees and Call Chains shows how to read it.Turn on Audit Process Creation. For the command line, also turn on Include command line in process creation events.
DeviceProcessEvents (opens in a new tab)Each row is a process creation or a related event, naming the new process, the process that created it and that creator's parent.Defender XDR, advanced huntingInitiatingProcessFileName and ProcessCommandLine show the same start, where Defender for Endpoint runs.The Defender for Endpoint sensor on the device

What It Looks Like

This record is decoded field by field, with what each value means.

25 ProcessTampering (Process image change) (opens in a new tab)On ws-017, . Sysmon event 25 for the service host on ws-017, 21 Oct 2026.
Field, as the Record Writes ItWhat It Tells You
UtcTime2026-10-21 11:37:54.106Two seconds after this svchost.exe started, by its own event 1. Pair the two records, since the start names the parent that made it.
ImageC:\Windows\System32\svchost.exeThe genuine service host file, in its own folder. The name and path are right, but the memory behind them is not.
TypeImage is replacedSysmon's verdict that the image in memory no longer matches the file on disk. Outside Program Files, SigmaHQ's rule raises it straight away.
UserCORP\danaRunning as dana, as per-user service hosts do, but under a parent no service host has. The account fits, but the parent does not.
False Positives

SigmaHQ's rule leaves out programs under Program Files, WMIADAP.exe and two browsers, so expect Sysmon event 25 from software like them. Review those events against what is installed instead of dropping them.

Blind Spots

windows.malware.hollowprocesses skips processes with fewer than three DLLs or five memory regions, treating them as exited or garbled in the capture, so check those by hand.

Only a process alive at capture still has its memory in an image. One that has already exited survives only in creation records and Sysmon event 25.

Hunt It

The same hunt is written for four tools, so pick the one you use. Defender XDR and Sentinel queries are in KQL, which you paste into Advanced hunting in the Defender portal or into Sentinel's Logs page. Splunk queries are in SPL, for its Search page, and Velociraptor queries are in VQL, which you run as a hunt.

Needs Defender for Endpoint, which documents no column for an image replaced in memory, so this finds the odd start that often comes with it. A hit is a core host with a parent it never has, not proof of hollowing, so confirm it in memory.

KQLDefender XDR, Advanced hunting
// Core Windows hosts started by a program in a user, temporary or ProgramData folderDeviceProcessEvents| where Timestamp > ago(30d)| where FileName in~ ("svchost.exe", "dllhost.exe", "RuntimeBroker.exe", "taskhostw.exe", "sihost.exe", "spoolsv.exe", "lsass.exe", "services.exe")| where InitiatingProcessFolderPath has_any ("Users", "Temp", "ProgramData")| summarize Starts = count(), Devices = dcount(DeviceId), FirstSeen = min(Timestamp), LastSeen = max(Timestamp)    by FileName, ProcessCommandLine, InitiatingProcessFileName, InitiatingProcessFolderPath| order by Devices asc, Starts asc

In a Memory Image

Volatility 3 reads a memory image, and each of its plugins below shows part of this sign.

Rules to Compare With

Security vendors publish detection rules anyone can read. These look for the same thing, so compare your own with them.

Show the 3 Public Rules

How to Prevent It

Each control helps prevent it, and its line says what it does here.

Sources

MITRE ATT&CK is a free public catalogue of the techniques attackers use. Each technique has an ID, such as T1055 for Process Injection, so defenders can name the same behaviour the same way. This page covers these techniques.