mirror of
https://github.com/mandiant/capa-rules
synced 2026-06-08 15:41:20 +00:00
40 lines
1.1 KiB
YAML
40 lines
1.1 KiB
YAML
rule:
|
|
meta:
|
|
name: create reverse shell
|
|
namespace: communication/c2/shell
|
|
authors:
|
|
- moritz.raabe@mandiant.com
|
|
scopes:
|
|
static: function
|
|
dynamic: process
|
|
att&ck:
|
|
- Execution::Command and Scripting Interpreter::Windows Command Shell [T1059.003]
|
|
mbc:
|
|
- Impact::Remote Access::Reverse Shell [B0022.001]
|
|
examples:
|
|
- C91887D861D9BD4A5872249B641BC9F9:0x401A77
|
|
features:
|
|
- or:
|
|
- and:
|
|
- match: create pipe
|
|
- api: kernel32.PeekNamedPipe
|
|
- api: kernel32.CreateProcess
|
|
- api: kernel32.ReadFile
|
|
- api: kernel32.WriteFile
|
|
- and:
|
|
- match: host-interaction/process/create
|
|
- match: read pipe
|
|
- match: write pipe
|
|
- and:
|
|
- match: create pipe
|
|
- match: host-interaction/process/create
|
|
- or:
|
|
- basic block:
|
|
- and:
|
|
- count(api(SetHandleInformation)): 2 or more
|
|
- number: 1 = HANDLE_FLAG_INHERIT
|
|
- thread:
|
|
- and:
|
|
- count(api(SetHandleInformation)): 2 or more
|
|
- number: 1 = HANDLE_FLAG_INHERIT
|