Detect unexpected processes connecting out on FTP or SMTP ports
Matches outbound network connections on the classic bulk-transfer and mail ports (FTP control and data, TFTP, SMTP and its submission variants) initiated by a process that has no business speaking those protocols — a script interpreter, a transfer-capable living-off-the-land binary, or `ftp.exe` itself. The protocol is inferred from `DestinationPort` because that is the most specific field this log source carries; `Initiated` restricts the match to connections this host opened. MITRE's DataVolumeThresholdMB and time-of-day knobs are the real discriminators for exfiltration and neither is expressible in Sigma, so this rule fires on the channel rather than on the volume moving through it. UNVERIFIED AS AUTHORED — derived from MITRE ATT&CK DET0131, not hand-written and not tested by its author. Any lab result is on this rule's own page.Full descriptionShow less
The detection
The 2 SIEM queries below are previews produced by Siemphony’s own translator, not pySigma, and none has been executed against a real backend — review before you deploy.
detection.yml
Splunk · SPL
Run this as a search.
index=* ((Initiated="true" AND (DestinationPort="20" OR DestinationPort="21" OR DestinationPort="25" OR DestinationPort="69" OR DestinationPort="465" OR DestinationPort="587")) AND (Image="*\\powershell.exe" OR Image="*\\pwsh.exe" OR Image="*\\cmd.exe" OR Image="*\\wscript.exe" OR Image="*\\cscript.exe" OR Image="*\\mshta.exe" OR Image="*\\rundll32.exe" OR Image="*\\regsvr32.exe" OR Image="*\\certutil.exe" OR Image="*\\curl.exe" OR Image="*\\ftp.exe" OR Image="*\\tftp.exe" OR Image="*\\python.exe"))Wazuh · XML rule
Deploy to your manager — this is a rule, not a search.
<group name="sigma,windows,network_connection,"> <!-- Rule ids must be unique on your manager; 100000+ is the user range. --> <rule id="100000" level="7"> <!-- Set <if_sid> to the decoder/base rule for windows so this only evaluates relevant events. --> <field name="Initiated" type="pcre2">(?i)^true$</field> <field name="DestinationPort" type="pcre2">(?i)(^20$|^21$|^25$|^69$|^465$|^587$)</field> <field name="Image" type="pcre2">(?i)(\\powershell\.exe$|\\pwsh\.exe$|\\cmd\.exe$|\\wscript\.exe$|\\cscript\.exe$|\\mshta\.exe$|\\rundll32\.exe$|\\regsvr32\.exe$|\\certutil\.exe$|\\curl\.exe$|\\ftp\.exe$|\\tftp\.exe$|\\python\.exe$)</field> <description>Detect unexpected processes connecting out on FTP or SMTP ports</description> <mitre> <id>T1048</id> </mitre> </rule></group>
Sentinel · KQL
Run this as a search.
Sentinel cannot express this construct. `Initiated` has no Sentinel column: Defender expresses connection direction in `ActionType`, not as a boolean column, so `Initiated` cannot be renamed — it needs a different predicate. The Sigma source is on the first tab, unchanged.
Elastic · ES|QL
Run this as a search.
Elastic cannot express this construct. `Initiated` has no ECS field: ECS expresses connection direction as `network.direction` with values like `egress`, not as a boolean, so `Initiated` needs a different predicate rather than a rename. The Sigma source is on the first tab, unchanged.
Verdicts · reactions · comments
Community
Verdicts from engineers who actually deployed it, and the conversation around it.
Nobody has run this in a real environment and said what happened.
Verdicts from engineers who deployed it
0 castNo verdicts reported yet. The first one is worth more than the tenth — say what you ran it against.
Log in to report a verdict.
Log in to join the discussion.
No comments yet. Someone who deploys this will have something to say about it.