This detection targets adversaries deploying the Lacy keylogger to capture sensitive user inputs and credentials on endpoints within the Azure environment. Proactively hunting for this low-severity indicator is critical because early identification of keylogging activity can prevent credential theft before attackers escalate privileges or exfiltrate data.
rule lacy_keylogger
{
meta:
author = "@patrickrolsen"
reference = "Appears to be a form of keylogger."
strings:
$s1 = "Lacy.exe" wide
$s2 = "Bldg Chive Duel Rip Query" wide
condition:
uint16(0) == 0x5A4D and all of ($s*)
}
This YARA rule can be deployed in the following contexts:
This rule contains 2 string patterns in its detection logic.
Here are 5 specific false positive scenarios for the Lacy Keylogger detection rule in an enterprise environment, including suggested filters and exclusions:
Endpoint Detection & Response (EDR) Telemetry Agents
falcon.sys or mssec.exe modules as they inject hooks similar to keylogging mechanisms.C:\Program Files\CrowdStrike\, C:\Windows\System32\Microsoft Defender\) and filter out processes with specific digital signatures from the respective vendors.IT Asset Management & Software Inventory Scans
svc_solarwinds) running between 02:00 and 04:00 UTC on weekdays, or exclude file paths under C:\Program Files\Ivanti\ where the process is identified as a scheduled task.Remote Support & Desktop Sharing Sessions