This hypothesis posits that adversaries are leveraging known .NET-based Red and Black team tools to establish a foothold or conduct internal reconnaissance within the environment. A proactive hunt is essential in Azure Sentinel to identify these specific tool executions early, distinguishing legitimate security operations from potential adversary activity that mimics standard administrative behavior.
rule HKTL_NET_NAME_RemoteProcessInjection {
meta:
description = "Detects .NET red/black-team tools via name"
reference = "https://github.com/Mr-Un1k0d3r/RemoteProcessInjection"
author = "Arnim Rupp"
date = "2021-01-22"
strings:
$name = "RemoteProcessInjection" ascii wide
$compile = "AssemblyTitle" ascii wide
condition:
(uint16(0) == 0x5A4D and uint32(uint32(0x3C)) == 0x00004550) and all of them
}
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 rule “Detects .NET red/blue-team tools via name,” along with suggested filters or exclusions:
Scenario: Automated Backup and Maintenance Scripts
Veeam.Backup.Service.exe or similar .NET wrappers that match the naming convention of security tools.^Veeam\., ^Commvault\.) and restrict detection to non-maintenance windows (e.g., exclude alerts between 02:00–06:00 local time).Scenario: Endpoint Detection and Response (EDR) Self-Defense
ParentProcessName IN ('FalconSensor.exe', 'MsMpEng.exe')) to prevent the EDR from triggering alerts against its own components.Scenario: Internal DevOps and CI/CD Pipeline Execution
BuildAgent.exe or DotNetCore.Tasks.dll which can be misidentified as active red-team reconnaissance tools during a sprint cycle.