Add nursery rules for Linux kernel rootkit techniques (#1136)

* Add nursery rules for Linux kernel rootkit techniques

* Address review comments: update scopes, namespace, and authors
This commit is contained in:
Aryan Khandhadiya
2026-03-27 11:03:16 -06:00
committed by GitHub
parent 03a20f69ae
commit 7bb186f6d6
2 changed files with 41 additions and 0 deletions
@@ -0,0 +1,20 @@
rule:
meta:
name: escalate privileges via commit_creds on Linux
namespace: host-interaction/process/modify
authors:
- aryanyk
description: detect Linux kernel modules that escalate privileges using prepare_kernel_cred and commit_creds, a technique commonly used by rootkits
scopes:
static: function
dynamic: span of calls
att&ck:
- Privilege Escalation::Exploitation for Privilege Escalation [T1068]
references:
- https://inferi.club/post/the-art-of-linux-kernel-rootkits
- https://www.kernel.org/doc/html/latest/security/credentials.html
features:
- and:
- os: linux
- api: prepare_kernel_cred
- api: commit_creds
@@ -0,0 +1,21 @@
rule:
meta:
name: register Netfilter hook on Linux
namespace: host-interaction/network
authors:
- aryanyk
description: kernel rootkits can register Netfilter hooks to inspect or modify packet flow
scopes:
static: instruction
dynamic: call
att&ck:
- Defense Evasion::Impair Defenses [T1562]
references:
- https://inferi.club/post/the-art-of-linux-kernel-rootkits
- https://www.kernel.org/doc/html/latest/networking/netfilter.html
features:
- and:
- os: linux
- or:
- api: nf_register_net_hook
- api: nf_register_hook