Defense evasion · Windows
wevtutil.exe
Windows Events command line
Manages event logs. Used in incidents to clear logs and to change log settings, both of which destroy or limit evidence. Clearing a log is high-signal anti-forensics.
Legitimate use
Admins use it to query, export, back up and configure event logs.
Subcommands
Clears all records from a log. Destroys evidence in that log.
HighChanges log settings, for example disabling a log or shrinking its size so records roll off fast.
HighExports a log to a file. Benign for backup, but also used to collect logs before clearing.
LowReads events from a log, which can be used to find traces to remove.
LowShows a log's configuration.
InfoLists the available logs.
InfoCommand lines to worry about
- High
Event log cleared
Clearing a log deletes its records. Security, System and PowerShell logs are common targets. Correlate with 1102 and 104 and the surrounding activity.
Detection regex
wevtutil(\.exe)?\s+(cl|clear-log)\b - High
Event log disabled
Disabling a log stops it recording, which blinds detection for that channel. Rare in normal administration.
Detection regex
wevtutil(\.exe)?\s+(sl|set-log)\b.*\/e(nabled)?:false
Where it is recorded
- Security4688Process creation with the full command line, when command-line auditing is enabled.
- Sysmon1Process creation with command line, hashes and parent process.
- Security1102The Security log was cleared. Written even as the log is cleared, so it survives.
- System104An event log was cleared, naming the log and the user.
Community detections
7 SigmaHQ rules for wevtutil.exe. The explainer checks every pasted command line against all of them.
- HighETW Trace Evasion Activity
Detects command line activity that attempts to tamper with Event Tracing for Windows (ETW) by clearing or disabling trace logs or providers. Adversaries may target ETW to blind security tooling and evade detection by removing visibility into process activity, network connections, and other telemetry sources.
T1070T1685by @neu5ron, Florian Roth (Nextron Systems), Jonhnathan Ribeiro, oscd.community
- HighSuspicious Eventlog Clearing or Configuration Change Activity
Detects the clearing or configuration tampering of EventLog using utilities such as "wevtutil", "powershell" and "wmic". This technique were seen used by threat actors and ransomware strains in order to evade defenses.
T1685.005T1685.001by Ecco, Daniil Yugoslavskiy, oscd.community, D3F7A5105, Swachchhanda Shrawan Poudel (Nextron Systems)
- HighSuspicious Spool Service Child Process
Detects suspicious print spool service (spoolsv.exe) child processes.
T1203T1068by Justin C. (@endisphotic), @dreadphones (detection), Thomas Patzke (Sigma rule)
- HighWebshell Detection With Command Line Keywords
Detects certain command line parameters often used during reconnaissance activity via web shells
T1505.003T1018T1033T1087by Florian Roth (Nextron Systems), Jonhnathan Ribeiro, Anton Kutepov, oscd.community, Chad Hudson, Matt Anderson
- MediumPotential Defense Evasion Via Binary Rename
Detects the execution of a renamed binary often used by attackers or malware leveraging new Sysmon OriginalFileName datapoint.
T1036.003by Matthew Green @mgreen27, Ecco, James Pemberton @4A616D6573, oscd.community, Andreas Hunkeler (@Karneades)
- MediumPotentially Suspicious EventLog Recon Activity Using Log Query Utilities
Detects execution of different log query utilities and commands to search and dump the content of specific event logs or look for specific event IDs. This technique is used by threat actors in order to extract sensitive information from events logs such as usernames, IP addresses, hostnames, etc.
T1552T1087by Nasreddine Bencherchali (Nextron Systems), X__Junior (Nextron Systems)
- MediumRemote Access Tool - ScreenConnect Potential Suspicious Remote Command Execution
Detects potentially suspicious child processes launched via the ScreenConnect client service.
T1219.002by Florian Roth (Nextron Systems), Nasreddine Bencherchali (Nextron Systems), @Kostastsale
Rules from SigmaHQ (rules/windows/process_creation), Detection Rule License (DRL) 1.1. Each rule links to its source and credits its authors.