Threat Huntmediumexperimental

Mail Forwarding/Redirecting Activity Via ExchangePowerShell Cmdlet

Detects email forwarding or redirecting activity via ExchangePowerShell Cmdlet

Convert In Phoenix Studio

Open this Sigma rule in the converter with the YAML preloaded and ready for backend selection.

Launch
Nasreddine Bencherchali (Nextron Systems), Marco Pedrinazzi (InTheCyber)Created Sun Mar 010c7686d5-c74e-4292-b224-2a08e956ebc4windows
Hunting Hypothesis
Log Source
WindowsPowerShell Script
ProductWindows← raw: windows
CategoryPowerShell Script← raw: ps_script

Definition

Requirements: Script Block Logging must be enabled

Detection Logic
Detection Logic2 selectors
detection:
    selection_cmdlet:
        ScriptBlockText|contains:
            - 'New-InboxRule'
            - 'Set-InboxRule'
            - 'Set-Mailbox'
    selection_params:
        ScriptBlockText|contains:
            - 'ForwardAsAttachmentTo'
            - 'ForwardingAddress'
            - 'ForwardingSmtpAddress'
            - 'ForwardTo'
            - 'RedirectTo' # Also covers "RedirectToRecipients"
    condition: all of selection_*
False Positives

Legitimate mail forwarding rules created by users or administrators to forward email to designated internal or external recipients for business or operational purposes.

Rule Metadata
Rule ID
0c7686d5-c74e-4292-b224-2a08e956ebc4
Status
experimental
Level
medium
Type
Threat Hunt
Created
Sun Mar 01
Path
rules-threat-hunting/windows/powershell/powershell_script/posh_ps_email_forwarding_activity.yml
Raw Tags
attack.collectionattack.t1114.003attack.defense-evasionattack.t1564.008attack.exfiltrationattack.t1020detection.threat-hunting
View on GitHub