VeriKQL by Kaushik Saha

T1659 Content Injection

Command and ControlInitial Accesson attack.mitre.org

ATT&CK Enterprise 20.0 · 20.1 released, update in review

How MITRE detects it

DET0349 Detection Strategy for Content Injection

AN0992 Windows

Detect suspicious file creations and process executions triggered by browser activity (e.g., injected payloads written to %AppData% or Temp directories, then executed). Correlate network anomalies with subsequent local process creation or script execution.

MITRE log sourceIn Microsoft Sentinel
WinEventLog:SecurityEventCode=4688
  • Windows Security Events via AMA → SecurityEvent
    SecurityEvent | where EventID in (4688)
  • Security Events via Legacy Agent → SecurityEvent
    SecurityEvent | where EventID in (4688)
  • Windows Forwarded Events → WindowsEvent
    WindowsEvent | where Channel == "Security" | where EventID in (4688)

The same events land in SecurityEvent (Windows Security Events connectors) or WindowsEvent (Windows Event Forwarding); many built-in rules read SecurityEvent only.

WinEventLog:SysmonEventCode=11
  • Windows event logs (Azure Monitor Agent) → Event
    Event | where Source == "Microsoft-Windows-Sysmon" | where EventID in (11)
  • Windows Forwarded Events → WindowsEvent
    WindowsEvent | where Provider == "Microsoft-Windows-Sysmon" | where EventID in (11)

Sysmon has no dedicated Sentinel connector: it is collected as a Windows event log into Event or WindowsEvent.

NSM:FlowUnexpected script or binary content returned in HTTP response bodyNot mapped to Sentinel yet.

AN0993 Linux

Detect curl/wget commands saving executable/script payloads to /tmp or /var/tmp followed by execution. Monitor packet captures or IDS/IPS alerts for injected responses or mismatched content types.

MITRE log sourceIn Microsoft Sentinel
auditd:SYSCALLexecve: Execution of curl or wget writing files to /tmp/* followed by chmod or executionNot mapped to Sentinel yet.
WinEventLog:SysmonFile creation of suspicious scripts/binaries in temporary directories
  • Windows event logs (Azure Monitor Agent) → Event
    Event | where Source == "Microsoft-Windows-Sysmon"
  • Windows Forwarded Events → WindowsEvent
    WindowsEvent | where Provider == "Microsoft-Windows-Sysmon"

Sysmon has no dedicated Sentinel connector: it is collected as a Windows event log into Event or WindowsEvent.

NSM:FlowInjected content responses with unexpected script/malware signaturesNot mapped to Sentinel yet.

AN0994 macOS

Monitor unified logs for processes spawned from Safari or other browsers that immediately load scripts or executables. Detect file drops in ~/Library/Caches or ~/Downloads that execute shortly after being written.

MITRE log sourceIn Microsoft Sentinel
macos:unifiedlogChild processes of Safari, Chrome, or Firefox executing scripting interpretersNot mapped to Sentinel yet.
macos:unifiedlogFile creation of unsigned binaries/scripts in user cache or download directoriesNot mapped to Sentinel yet.
NSM:FlowContent injection observed in HTTPS responses with mismatched certificates or altered payloadsNot mapped to Sentinel yet.

Content Hub rules tagged with it (4)

Rules tagged with this technique (or a sub-technique) in their metadata. Whether one fits your connectors is the coverage view (M2).

How the Content Hub rules for T1659 are built: their tables, filters, joins, schedules and windows.

In Sigma rules

No SigmaHQ rule names it or one of its sub-techniques in their tags outright.

Community rules, not Microsoft's, and not checked by VeriKQL (Sigma is not KQL). From SigmaHQ/sigma at f083329, under the Detection Rule License (DRL) 1.1; each rule is credited to its author.

Mitigations

MITRE ATT&CK® is a registered trademark of The MITRE Corporation. VeriKQL is not affiliated with or endorsed by MITRE. ATT&CK data © The MITRE Corporation, used under its terms of use.