ELF Payload Staged in a Suspicious Directory

Last updated 17 days ago on 2026-10-07
Created 17 days ago on 2026-10-07

About

Identifies an ELF file created in a temporary, shared-memory, runtime, mail, or web directory by a transfer utility, file-manipulation utility, interpreter, or executable running from a suspicious location. This may indicate an adversary transferring or staging a Linux payload for subsequent execution.
Tags
Domain: EndpointOS: LinuxUse Case: Threat DetectionTactic: Command and ControlData Source: Elastic DefendRule Type: Event Correlation (EQL)Platform: LinuxLanguage: eql
Severity
medium
Risk Score
47
MITRE ATT&CK™

Command and Control (TA0011)(external, opens in a new tab or window)

License
Elastic License v2(external, opens in a new tab or window)

Definition

Rule Type
Event Correlation Rule
Integration Pack
Prebuilt Security Detection Rules
Index Patterns
logs-endpoint.events.file*
Related Integrations

endpoint(external, opens in a new tab or window)

Query
text code block:
file where host.os.type == "linux" and event.action in ("rename", "creation") and file.Ext.header_bytes like "7f454c46*" and ( process.name in ( "curl", "wget", "ftp", "tftp", "scp", "rsync", "busybox", "timeout", "env", "cp", "mv", "install", "dd", "tee", "touch", "tar", "gzip", "gunzip", "bzip2", "bunzip2", "xz", "unxz", "zip", "unzip", "7z", "bun" ) or process.name like (".*", "python*", "perl*", "php*", "ruby*", "lua*", "node*", "deno*") or process.executable like ( "/tmp/*", "/var/tmp/*", "/dev/shm/*", "/run/*", "/var/run/*", "/boot/*", "/sys/*", "*/www/html/*", "/lost+found/*", "/proc/*", "/var/mail/*", "/var/www/*", "/mnt/*", "/media/*", "*/wp-content/*", "*/wp-includes/*", "*/wp-admin/*", "?memfd:*", "memfd:*" ) ) and file.path like ( "/tmp/*", "/var/tmp/*", "/dev/shm/*", "/run/*", "/var/run/*", "/var/mail/*", "*/www/html/*", "*/wp-content/*", "*/wp-includes/*", "*/wp-admin/*" )

Install detection rules in Elastic Security

Detect ELF Payload Staged in a Suspicious Directory in the Elastic Security detection engine by installing this rule into your Elastic Stack.

To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(external, opens in a new tab or window).