endpoint(opens in a new tab or window)
system(opens in a new tab or window)
windows(opens in a new tab or window)
auditd_manager(opens in a new tab or window)
m365_defender(opens in a new tab or window)
FROM logs-* metadata _id, _version, _index
| where event.category == "process" and event.type == "start" and event.action != "fork"
// more than 100 spaces in process.command_line
| eval multi_spaces = LOCATE(process.command_line, space(100))
| where multi_spaces > 0
| keep user.name, host.id, host.name, process.command_line, process.executable, process.parent.executable
Install detection rules in Elastic Security
Detect Command Line Obfuscation via Whitespace Padding 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(opens in a new tab or window).