[New Rule] Potential Fileless Execution via Unusual memfd Create Call - #6748
Conversation
|
⛔️ Test failed Results
|
There was a problem hiding this comment.
🟡 Changes recommended
The new rule’s description is incomplete/misaligned with the new-terms fields and the tags are missing a required tactic tag for the included Execution mapping.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR adds a new Linux Elastic Defend detection rule intended to replace a deprecated diagnostic endpoint rule by detecting potentially fileless execution activity via unusual memfd_create usage.
Changes:
- Introduces a new Linux new_terms rule that alerts on newly observed combinations of host + process lineage when
memfd_createactivity is seen. - Adds rule metadata, MITRE ATT&CK mappings (Defense Evasion + Execution), and Elastic Defend setup guidance.
File summaries
| File | Description |
|---|---|
| rules/linux/defense_evasion_fileless_execution_via_unusual_memfd_create.toml | New Elastic Defend new_terms rule for detecting potentially fileless execution via unusual memfd_create activity. |
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 2
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
|
⛔️ Test failed Results
|
|
⛔️ Test failed Results
|
bryans3c
left a comment
There was a problem hiding this comment.
Some comments, otherwise LGTM!
|
|
||
| [[rule.new_terms.history_window_start]] | ||
| field = "history_window_start" | ||
| value = "now-10d" |
There was a problem hiding this comment.
Maybe decrease it to 5d for performance?
| host.os.type:"linux" and event.category:process and event.type:start and event.action:memfd_create and | ||
| process.executable:( | ||
| *memfd\:* or /tmp/* or /var/tmp/* or /dev/shm/* or ./* or /run/user/* or /var/run/user/* or | ||
| /boot/* or /sys/* or /lost+found/* or /proc/* or /var/mail/* or /root/* or *\(deleted\)* or | ||
| /proc/*/fd/* | ||
| ) and process.parent.executable:* |
There was a problem hiding this comment.
Should we add exclusions for the rule? The deprecated rules contained some exclusions on it
There was a problem hiding this comment.
I bumped up the new_terms to 10d to avoid the exclusions; if necessary I will only add common binary FPs. For initial push I think new_terms on 10d should suffice.
Added detailed investigation and response guidelines for detecting potential fileless execution via unusual memfd_create calls in Linux processes.
|
⛔️ Test failed Results
|
Results |
|
⛔️ Test failed Results
|
shashank-elastic
left a comment
There was a problem hiding this comment.
Overall query logic is clean
Summary
This rule comes in favor of a deprecated diagnostic endpoint rule that was too noisy to promote.