This detection identifies anomalous TLS Client Hello packet generation patterns that may indicate early-stage reconnaissance or the use of custom encryption libraries by an adversary. Proactively hunting for these signatures in Azure Sentinel allows the SOC team to distinguish legitimate traffic from stealthy command-and-control communications before they evolve into high-severity incidents.
rule GenerateTLSClientHelloPacket_Test: sharedcode
{
meta:
copyright = "2015 Novetta Solutions"
author = "Novetta Threat Research & Interdiction Group - [email protected]"
Source = "eff542ac8e37db48821cb4e5a7d95c044fff27557763de3a891b40ebeb52cc55.ex_"
strings:
/*
25 07 00 00 80 and eax, 80000007h
79 05 jns short loc_405EC8; um, nope.. this will always happen
48 dec eax
83 C8 F8 or eax, 0FFFFFFF8h
40 inc eax
*/
$a = {25 07 00 00 80 79 ?? 4? 83 ?? F8 4? }
condition:
$a in ((pe.sections[pe.section_index(".text")].raw_data_offset)..(pe.sections[pe.section_index(".text")].raw_data_offset + pe.sections[pe.section_index(".text")].raw_data_size))
}
This YARA rule can be deployed in the following contexts:
This rule contains 1 string patterns in its detection logic.
Here are 5 specific false positive scenarios for the GenerateTLSClientHelloPacket_Test detection rule in an enterprise environment, including suggested filters or exclusions:
Endpoint Management Agent Heartbeats
ClientHello packets with unique extensions (e.g., specific ALPN protocols or custom SNI values) that may not match the standard baseline expected by the test rule, triggering alerts for “anomalous” handshake behavior.*.microsoft.com, *.crowdstrike.com).Scheduled Software Update Scanners
ClientHello packets that may lack the full session context (e.g., missing subsequent Application Data) if the rule is looking for complete sessions rather than initial probes.Internal API Gateway Health Checks