Detectionhightest

Powershell DNSExfiltration

DNSExfiltrator allows for transferring (exfiltrate) a file over a DNS request covert channel

Open in Detection LabConvert ruleBuild Package
François HubautCreated 2022-01-07d59d7842-9a21-4bc6-ba98-64bfe0091355windows
Log Source
WindowsPowerShell Script
ProductWindows← raw: windows
CategoryPowerShell Script← raw: ps_script

Definition

Requirements: Script Block Logging must be enabled

Detection Logic
Detection Logic1 selector
detection:
    selection_cmdlet:
        - ScriptBlockText|contains: 'Invoke-DNSExfiltrator'
        - ScriptBlockText|contains|all:
              - ' -i '
              - ' -d '
              - ' -p '
              - ' -doh '
              - ' -t '
    condition: selection_cmdlet
False Positives

Legitimate script

Testing & Validation

Regression Tests

by frack113
Positive Detection Test1 matchevtx

Microsoft-Windows-PowerShell

Rule Metadata
Rule ID
d59d7842-9a21-4bc6-ba98-64bfe0091355
Status
test
Level
high
Type
Detection
Created
2022-01-07
Path
rules/windows/powershell/powershell_script/posh_ps_invoke_dnsexfiltration.yml
Raw Tags
attack.exfiltrationattack.t1048
View on GitHub