Process hollowing is a technique in which an ordinary process is started and its in-memory content is replaced with foreign code while the process name remains.
Observers see a familiar process, not the file that is actually at work.
The technique is one of the ways malicious code hides behind an allowed name.
Understanding Process Hollowing
Understanding it means seeing the sequence of choosing a host process, hollowing its memory, and starting the replaced content.
The host is often a signed or everyday program.
The deception targets tools that check only the name and the path and do not look at memory.
Selection of Target Process
Selection prefers processes that are normal in the environment, that bring the rights needed, and whose start does not stand out.
A process that otherwise never speaks on the network becomes notable after replacement if it suddenly opens connections.
The choice is therefore a compromise between disguise and the rights the code needs.
Memory Hollowing
During hollowing, the original code in the memory of the process already created is set aside or overwritten and replaced with the foreign content.
The operating system's process object remains, including the name and often the original origin claim.
That gap between object and content is the point of the technique.
Execution of Malicious Code
Afterward the replaced content runs in the host's context, with its rights and its visible name.
The malicious code does not have to sit as its own file in an auto-start location.
Records that only see file names starting show the host and not the replacement.
Stealth and Evasion
Stealth appears because allow lists and superficial process lists know the host and do not compare the exchanged memory.
Evasion succeeds against checks that hash a file before start and never look at memory afterward.
Controls that compare the memory being executed with the file image see the mismatch.
Malicious Activities
The activities after replacement are the same as with other malicious code: loading more code, reading data, encrypting, or opening further access.
They run under the host's name and inherit its network and file rights.
They become notable when the host contacts destinations that do not belong to its ordinary job.
Prevention and Detection of Process Hollowing
Prevention stops untrusted code from being written into trusted processes, and detection compares running memory with the expected image.
Application control, limited debug rights, and logging of process creation belong with that.
A pure name match does not recognize the technique.
Behavioral Analysis
Behavioral analysis watches for processes that heavily change their memory shortly after start, create unusual child processes, or contact destinations that do not fit the application.
It needs a picture of the host's normal behavior, or every update becomes an alert.
Confirmed departures lead to isolating the system and capturing the memory.
Memory Forensics
Memory forensics captures the content of the suspicious process and compares it with the file it was supposed to come from.
Differing sections, a missing match to the image, and unexpected loaded modules show the replacement.
The capture has to happen before the process ends, or the evidence in memory is gone.
Conclusion
Process hollowing replaces the content of a trustworthy-looking process and deceives checks that see only the name.
Detection compares behavior and memory with the expected image.
Prevention means limiting writes into other processes, not only allowing the start file.
