This detection rule identifies adversaries conducting reconnaissance by scanning open TCP ports to map network topology and identify potential entry points. Proactive hunting in Azure Sentinel is essential to uncover stealthy enumeration activities that may precede lateral movement or initial compromise attempts before they escalate into higher-severity incidents.
rule wineggdrop : portscanner toolkit
{
meta:
author = "Christian Rebischke (@sh1bumi)"
date = "2015-09-05"
description = "Rules for TCP Portscanner VX.X by WinEggDrop"
in_the_wild = true
family = "Hackingtool/Portscanner"
strings:
$a = { 54 43 50 20 50 6f 72 74 20 53 63 61 6e 6e 65 72
20 56 3? 2e 3? 20 42 79 20 57 69 6e 45 67 67 44
72 6f 70 0a }
$b = "Result.txt"
$c = "Usage: %s TCP/SYN StartIP [EndIP] Ports [Threads] [/T(N)] [/(H)Banner] [/Save]\n"
condition:
//check for MZ Signature at offset 0
uint16(0) == 0x5A4D
and
//check for wineggdrop specific strings
$a and $b and $c
}
This YARA rule can be deployed in the following contexts:
This rule contains 3 string patterns in its detection logic.
Here are 5 specific false positive scenarios for the Rules for TCP Portscanner VX.X by WinEggDrop detection rule, along with suggested filters and exclusions:
Scenario: Scheduled Network Inventory via Lansweeper or PDQ Inventory
Source Port is consistent with the known agent service (e.g., Lansweeper often uses a specific high-numbered ephemeral port) and the scan duration exceeds 60 seconds.Scenario: Vulnerability Assessment Scans by Nessus or Qualys
10.20.30.5). Furthermore, apply a time-based exclusion to suppress alerts during known maintenance windows (e.g., “Exclude events occurring between 02:00 and 06:00 UTC on Sundays”).Scenario: Active Directory Health Checks via Microsoft SCCM or Intune