This rule identifies the execution of a known code crypter, indicating an adversary is likely employing obfuscation techniques to hide malicious payloads from static analysis tools. Proactively hunting for this behavior in Azure Sentinel allows the SOC to detect early-stage intrusion attempts where attackers use crypters to bypass initial security controls and establish a foothold in the environment.
rule codeCrypter031
{
meta:
author="malware-lu"
strings:
$a0 = { 50 58 53 5B 90 BB [2] 40 00 FF E3 90 CC CC CC 55 8B EC 5D C3 CC CC CC CC CC CC CC CC CC CC CC }
condition:
$a0
}
This YARA rule can be deployed in the following contexts:
This rule contains 1 string patterns in its detection logic.
Scenario: Execution of the dotnet CLI tool during a continuous integration/continuous deployment (CI/CD) pipeline or local developer build process. The dotnet binary often contains obfuscated or packed code segments that can match generic crypter signatures, especially if the rule targets common .NET packing algorithms or string encryption patterns.
dotnet.exe, msbuild.exe, or vstest.console.exe, and the image path resides in standard development directories (e.g., C:\Program Files\dotnet\, C:\Users\<user>\.nuget\, or project-specific bin\ folders).Scenario: Running the 7z (7-Zip) or WinRAR executable to compress or decompress archives containing encrypted or packed executables. Some crypters use standard compression algorithms (like LZMA or Deflate) that may be misidentified by YARA rules looking for specific byte patterns or entropy thresholds if the rule is not strictly limited to executable file types.
7z.exe, 7zG.exe, WinRAR.exe, or WinRAR.exe and the command line arguments include verbs such as a (add), x (extract), or t (test).Scenario: Execution of the Electron framework-based applications (e.g., Slack, Discord, VS Code, or internal enterprise apps) where the node.exe or electron.exe process loads packed JavaScript bundles or native modules. These applications frequently use code packing or minification techniques that can trigger generic crypter detections.
node_modules, resources/app, or if the parent process is electron.exe and