Skip to content

Commit 219a2cb

Browse files
committed
feat(rules): Add Process execution from remote memory section rule
Detects execution of a process image originating from a memory section mapped without a backing file, a strong indicator of advanced process injection techniques such as ghostly hollowing. In this pattern, a malicious image is mapped directly into memory, loaded into a remote process, and subsequently executed without ever being written to disk. This allows attackers to evade file-based detection and forensic recovery.
1 parent 1ccb7b3 commit 219a2cb

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Process execution from remote memory section
2+
id: 6e4cc918-a30e-4167-ba26-6356d6384f30
3+
version: 1.0.0
4+
description: |
5+
Detects execution of a process image originating from a memory section
6+
mapped without a backing file, a strong indicator of advanced process
7+
injection techniques such as ghostly hollowing. In this pattern, a malicious
8+
image is mapped directly into memory, loaded into a remote process, and
9+
subsequently executed without ever being written to disk.
10+
This allows attackers to evade file-based detection and forensic recovery.
11+
labels:
12+
tactic.id: TA0005
13+
tactic.name: Defense Evasion
14+
tactic.ref: https://attack.mitre.org/tactics/TA0005/
15+
technique.id: T1055
16+
technique.name: Process Injection
17+
technique.ref: https://attack.mitre.org/techniques/T1055/
18+
references:
19+
- https://captain-woof.medium.com/ghostly-hollowing-probably-the-most-bizarre-windows-process-injection-technique-i-know-bf833c96663a
20+
21+
condition: >
22+
sequence
23+
maxspan 1m
24+
|map_view_file and
25+
ps.sid != 'S-1-5-18' and
26+
file.view.size > 50000 and file.path = '' and file.view.type = 'IMAGE'
27+
| as e1
28+
|load_module and
29+
evt.pid != module.pid and
30+
module.base = $e1.file.view.base and
31+
(thread.callstack.summary = '' or thread.callstack.summary imatches '*ntoskrnl.exe!NtMapViewOfSection*')
32+
| as e2
33+
|load_executable and thread.callstack.summary imatches concat('*', base($e2.module.path), '*')|
34+
action:
35+
- name: kill
36+
37+
output: >
38+
Process %3.ps.exe executed from a remotely mapped memory section with no backing file
39+
severity: high
40+
41+
min-engine-version: 3.0.0

0 commit comments

Comments
 (0)