Detection rules › Splunk
Microsoft Diagnostic Tool "DogWalk" Package Path Traversal (Windows Event Log)
The vulnerability lies in the Microsoft Diagnostic Tool's sdiageng.dll library, which takes the attacker-supplied folder path from the package configuration XML file inside the diagcab archive, and copies all files from that folder to a local temporary folder. During this process, it enumerates files in attacker's folder, gets the file name for each of them, then glues together the local temporary path and that file name to generate the local path on the computer where the file is to be created.
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Execution | T1204 User Execution |
References
Event coverage
| Provider | Event | Title |
|---|---|---|
| Security-Auditing | Event ID 4688 | A new process has been created. |
Rule body yaml
id: '11280.15742'
title: Microsoft Diagnostic Tool "DogWalk" Package Path Traversal
description: The vulnerability lies in the Microsoft Diagnostic Tool's sdiageng.dll
library, which takes the attacker-supplied folder path from the package configuration
XML file inside the diagcab archive, and copies all files from that folder to a
local temporary folder. During this process, it enumerates files in attacker's folder,
gets the file name for each of them, then glues together the local temporary path
and that file name to generate the local path on the computer where the file is
to be created.
logic_format: Splunk
logic: '`get_endpoint_data` `get_endpoint_data_winevent` (TERM(EventCode=4688) OR
"<EventID>4688<" OR Type=Process) ("msdt.exe" OR TERM(msdt)) AND ("/cab" OR ".diagcab")
| table _time, host, user process, process_*, parent_*, signature_id, trun_cmd |
bin span=1s | stats values(*) as * by _time, host | where match(process, "(?i)cab|diagcab") '
techniques:
- execution:user execution
technique_id:
- T1204
data_category:
- Windows event logs
references:
- https://blog.0patch.com/2022/06/microsoft-diagnostic-tools-dogwalk.html
Stages and Predicates
Stage 1: search
`get_endpoint_data` `get_endpoint_data_winevent` (TERM(EventCode=4688) OR "<EventID>4688<" OR Type=Process) ("msdt.exe" OR TERM(msdt)) AND ("/cab" OR ".diagcab")
Stage 2: table
| table _time, host, user process, process_*, parent_*, signature_id, trun_cmd
Stage 3: bucket
| bin span=1s
Stage 4: stats
| stats values(*) as * by _time, host
Stage 5: where
| where match(process, "(?i)cab|diagcab")
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.
Search terms
Bare-string tokens in the SPL search body. Splunk matches each token against _raw (the untyped raw event text) anywhere it appears, not against a specific field. These don't surface in the Indicators table because they aren't predicates on a known field.
| Stage | Term |
|---|---|
| 1 | TERM |
| 1 | "<EventID>4688<" |
| 1 | "msdt.exe" |
| 1 | TERM |
| 1 | msdt |
| 1 | "/cab" |
| 1 | ".diagcab" |