Process Hollowing

From enterprise
Jump to: navigation, search
Process Hollowing
Technique
ID T1093
Tactic Defense Evasion
Platform Windows
Permissions Required User
Data Sources API monitoring, Process monitoring
Defense Bypassed Process whitelisting, Anti-virus, Whitelisting by file name or path, Signature-based detection

Process hollowing occurs when a process is created in a suspended state then its memory is unmapped and replaced with malicious code. Similar to Process Injection, execution of the malicious code is masked under a legitimate process and may evade defenses and detection analysis.12

Examples

  • A Patchwork payload uses process hollowing to hide the UAC bypass vulnerability exploitation inside svchost.exe.3
  • BADNEWS has a command to download an .exe and use process hollowing to inject it into a new process.4
  • BBSRAT has been seen loaded into msiexece.exe through process hollowing to hide its execution.5
  • Cobalt Strike can use process hollowing for execution.6
  • Duqu is capable of loading executable code via process hollowing.7
  • ISMInjector hollows out a newly created process RegASM.exe and injects its payload into the hollowed process.8
  • Some Orz versions have an embedded DLL known as MockDll that uses process hollowing and Regsvr32 to execute another payload.9
  • Smoke Loader spawns a new copy of c:\windows\syswow64\explorer.exe and then replaces the executable code in memory with malware. 1011

Mitigation

This type of attack technique cannot be easily mitigated with preventive controls since it is based on the abuse of operating system design features. For example, mitigating specific API calls will likely have unintended side effects, such as preventing legitimate software (i.e., security products) from operating properly. Efforts should be focused on preventing adversary tools from running earlier in the chain of activity and on identifying subsequent malicious behavior.

Although process hollowing may be used to evade certain types of defenses, it is still good practice to identify potentially malicious software that may be used to perform adversarial actions and audit and/or block it by using whitelisting12 tools, like AppLocker,1314 or Software Restriction Policies15 where appropriate.16

Detection

Monitoring API calls may generate a significant amount of data and may not be directly useful for defense unless collected under specific circumstances for known bad sequences of calls, since benign use of API functions may be common and difficult to distinguish from malicious behavior. API calls that unmap process memory, such as ZwUnmapViewOfSection or NtUnmapViewOfSection, and those that can be used to modify memory within another process, such as WriteProcessMemory, may be used for this technique.2

Analyze process behavior to determine if a process is performing actions it usually does not, such as opening network connections, reading files, or other suspicious actions that could relate to post-compromise behavior.

References