Enable BPF Kprobes Tracing

Detects common command used to enable bpf kprobes tracing

Sigma rule (View on GitHub)

 1title: Enable BPF Kprobes Tracing
 2id: 7692f583-bd30-4008-8615-75dab3f08a99
 3status: test
 4description: Detects common command used to enable bpf kprobes tracing
 5references:
 6    - https://embracethered.com/blog/posts/2021/offensive-bpf-bpftrace/
 7    - https://bpftrace.org/
 8    - https://www.kernel.org/doc/html/v5.0/trace/kprobetrace.html
 9author: Nasreddine Bencherchali (Nextron Systems)
10date: 2023-01-25
11tags:
12    - attack.execution
13    - attack.defense-evasion
14logsource:
15    category: process_creation
16    product: linux
17detection:
18    selection:
19        CommandLine|contains|all:
20            - 'echo 1 >'
21            - '/sys/kernel/debug/tracing/events/kprobes/'
22        CommandLine|contains:
23            - '/myprobe/enable'
24            - '/myretprobe/enable'
25    condition: selection
26falsepositives:
27    - Unknown
28level: medium

References

Related rules

to-top