Exfiltration (TA0010)(external, opens in a new tab or window)
Command and Control (TA0011)(external, opens in a new tab or window)
text code block:any where host.os.type in ("linux", "macos", "windows") and ( ( event.action in ("lookup_requested", "lookup_result") and dns.question.name regex """.*[A-Za-z0-9+/]{2,}={1,6}\.[A-Za-z0-9\-]+.*""" and not dns.question.name : "*.local" ) or ( event.category == "process" and event.type == "start" and event.action in ("exec", "start") and process.name : ("dig", "nslookup", "nslookup.exe", "host", "drill") and process.args regex """.*[A-Za-z0-9+/]{2,}={1,6}\.[A-Za-z0-9\-]+.*""" ) )
Install detection rules in Elastic Security
Detect DNS Query with Padded Encoded Label 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).