Detection rules › Sigma

C# IL Code Compilation Via Ilasm.EXE

Severity
medium
Author
frack113, Nasreddine Bencherchali (Nextron Systems)
Source
upstream

Detects the use of "Ilasm.EXE" in order to compile C# intermediate (IL) code to EXE or DLL.

MITRE ATT&CK coverage

TacticTechniques
Defense EvasionT1127 Trusted Developer Utilities Proxy Execution

Event coverage

ProviderEvent IDTitle
Sysmon1Process creation

Stages and Predicates

Stage 1: all of selection_img

or:
Image|endswith: '\ilasm.exe'
OriginalFileName: ilasm.exe

Stage 2: all of selection_cli

or:
CommandLine|contains: ' /dll'
CommandLine|contains: ' /exe'

Indicators

Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.

FieldKindValues
CommandLinematch
  • /dll
  • /exe
Imageends_with
  • \ilasm.exe
OriginalFileNameeq
  • ilasm.exe