Dynamic CSharp Compile Artefact

 Original Source: [Sigma source]
Title: Dynamic CSharp Compile Artefact
Status: test
Description:When C# is compiled dynamically, a .cmdline file will be created as a part of the process. Certain processes are not typically observed compiling C# code, but can do so without touching disk. This can be used to unpack a payload for execution
References:
  -https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1027.004/T1027.004.md#atomic-test-2---dynamic-c-compile
Author: frack113
Date: 2022-01-09
modified:2023-02-17
Tags:
  • -'attack.stealth'
  • -'attack.t1027.004'
Logsource:
  • product: windows
  • category: file_event
Detection:
  selection:
    TargetFilename|endswith: '.cmdline'
  condition:selection
Falsepositives:
  -Unknown
Level: low