This detection identifies the execution of specialized C# Red and Black team security tools by analyzing unique TypeLibGUID signatures within Azure Sentinel logs. Proactive hunting for these artifacts is essential to distinguish legitimate security testing activities from potential adversary use of custom C# utilities that may mimic trusted tooling behavior.
rule HKTL_NET_GUID_SharpCookieMonster {
meta:
description = "Detects c# red/black-team tools via typelibguid"
reference = "https://github.com/m0rv4i/SharpCookieMonster"
author = "Arnim Rupp"
date = "2020-12-28"
strings:
$typelibguid0 = "566c5556-1204-4db9-9dc8-a24091baaa8e" ascii nocase wide
condition:
(uint16(0) == 0x5A4D and uint32(uint32(0x3C)) == 0x00004550) and any of them
}
This YARA rule can be deployed in the following contexts:
This rule contains 1 string patterns in its detection logic.
Here are 4 specific false positive scenarios for the rule “Detects c# red/black-team tools via typelibguid”, including suggested filters and exclusions:
Scenario: Automated CI/CD Pipeline Execution
ComputerName of known CI/CD agents (e.g., Jenkins-Agent-01, AzureDevOps-Build-Node) from the alert logic, or filter out events where the parent process is msbuild.exe or dotnet.exe.Scenario: Scheduled Endpoint Security Scans
C:\Program Files\CrowdStrike\fsqa.exe) and exclude events occurring during defined maintenance windows (e.g., 02:00–04:00 daily) where these scans are triggered.Scenario: Office Add-in Deployment via Group Policy