Multi-Layered Deobfuscation via Unusual Parent
Description
Detects multiple base64/xxd deobfuscation processes spawned by scripting interpreters within 5 seconds. This pattern indicates multi-layered payload decoding commonly used by malware and scripted attacks.
Query · eql
sequence with maxspan=5s
[process where event.type == "start" and event.action == "exec" and (process.name in ("osascript", "bash", "sh", "zsh", "dash", "csh", "tcsh", "ksh", "tclsh", "fish") or process.name like "tclsh*") and
process.args_count <= 3 and
process.args in ("-c", "-e") and
process.args like "echo*" and
not process.Ext.effective_parent.executable like "/Library/Application Support/JAMF/Jamf.app/Contents/MacOS/JamfDaemon.app/Contents/MacOS/JamfDaemon"] by process.entity_id
[process where event.type == "start" and event.action == "exec" and process.name in ("base64", "xxd")] by process.parent.entity_id
[process where event.type == "start" and event.action == "exec" and process.name in ("base64", "xxd")] by process.parent.entity_id