Detect Indicator Removal in Google Chronicle
Adversaries may delete or modify artifacts generated within systems to remove evidence of their presence or hinder defenses. Various artifacts may be created by an adversary or something that can be attributed to an adversary's actions. Typically these artifacts are used as defensive indicators related to monitored events, such as strings from downloaded files, logs that are generated from user actions, and other data analyzed by defenders. Removal of these indicators may interfere with event collection, reporting, or other processes used to detect intrusion activity. This may compromise the integrity of security solutions by causing notable events to go unreported. This activity may also impede forensic analysis and incident response, due to lack of sufficient data to determine what occurred.
MITRE ATT&CK
- Tactic
- Defense Evasion
- Technique
- T1070 Indicator Removal
- Canonical reference
- https://attack.mitre.org/techniques/T1070/
YARA-L Detection Query
rule T1070_Indicator_Removal {
meta:
author = "Argus Detection Engineering"
description = "Detects MITRE T1070 Indicator Removal via registry key deletion at persistence paths or process-based cleanup commands including reg delete, Remove-ItemProperty, and self-deletion of executables."
mitre_attack_tactic = "Defense Evasion"
mitre_attack_technique = "T1070"
severity = "HIGH"
confidence = "MEDIUM"
version = "1.0"
events:
(
$e.metadata.event_type = "REGISTRY_DELETION" and
(
re.regex($e.target.registry.registry_key, `(?i)\\(Run|RunOnce)\\`) or
re.regex($e.target.registry.registry_key, `(?i)\\Services\\`) or
re.regex($e.target.registry.registry_key, `(?i)\\Scheduled Tasks`) or
re.regex($e.target.registry.registry_key, `(?i)\\AppInit_DLLs`) or
re.regex($e.target.registry.registry_key, `(?i)\\NetworkProvider\\Order`) or
re.regex($e.target.registry.registry_key, `(?i)\\Image File Execution`) or
re.regex($e.target.registry.registry_key, `(?i)TESTSIGNING`)
)
) or
(
$e.metadata.event_type = "PROCESS_LAUNCH" and
(
re.regex($e.target.process.command_line, `(?i)reg(\.exe)?\s+delete`) or
re.regex($e.target.process.command_line, `(?i)Remove-ItemProperty`) or
re.regex($e.target.process.command_line, `(?i)Remove-Item.+(HKLM|HKCU)`) or
re.regex($e.target.process.command_line, `(?i)cmd(\.exe)?\s+/c\s+del\s+.*\.exe`) or
re.regex($e.target.process.command_line, `(?i)del\s+/[fF]`) or
re.regex($e.target.process.command_line, `(?i)erase\s+/[fF]`)
)
)
outcome:
$hostname = $e.principal.hostname
$username = $e.principal.user.userid
$process_cmd = $e.target.process.command_line
$registry_key = $e.target.registry.registry_key
$parent_cmd = $e.principal.process.command_line
$event_type = $e.metadata.event_type
condition:
$e
} Chronicle YARA-L 2.0 rule detecting T1070 Indicator Removal using UDM field model. Covers two behavioral patterns: REGISTRY_DELETION events targeting known persistence key paths (Run, RunOnce, Services, AppInit_DLLs, Scheduled Tasks, Image File Execution), and PROCESS_LAUNCH events with registry cleanup or self-deletion command patterns. The outcome section enriches matches with hostname, username, command line, and registry key for downstream SOAR enrichment or alert triage.
Data Sources
Required Tables
False Positives & Tuning
- Enterprise software deployment platforms such as Intune or SCCM removing configuration or persistence registry keys during device compliance remediation cycles
- IT support scripts using reg delete or Remove-Item to clean up stale application entries or disable legacy features during authorized troubleshooting
- Application self-update mechanisms deleting older executable versions using del /f after replacing binaries with newer releases
Other platforms for T1070
Testing Methodology
Validate this detection against 5 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.
- Test 1Registry Key Self-Cleanup — Delete Run Key
Expected signal: Sysmon Event ID 12 (RegistryEvent - Object Create/Delete): TargetObject=HKCU\Software\Microsoft\Windows\CurrentVersion\Run\df00tech-test, EventType=DeleteValue. Sysmon Event ID 1: two cmd/reg.exe process creation events. Security Event ID 4657 (if object access auditing is enabled): ObjectName matching the Run key path.
- Test 2Executable Self-Deletion via cmd.exe
Expected signal: Sysmon Event ID 1: Process creation for df00tech-cleanup-test.exe. Sysmon Event ID 1: cmd.exe with CommandLine containing 'del /f /q' and the .exe path. Sysmon Event ID 11: file create for df00tech-cleanup-test.exe. Sysmon Event ID 23 (if configured): FileDelete event for df00tech-cleanup-test.exe showing the file was archived by Sysmon before deletion.
- Test 3PowerShell Registry Key Deletion
Expected signal: Sysmon Event ID 12 (RegistryEvent - Create/Delete): EventType=DeleteKey, TargetObject=HKCU\Software\Microsoft\Internet Explorer\notes. Sysmon Event ID 1: powershell.exe with CommandLine containing 'Remove-Item' and 'Internet Explorer\notes'. PowerShell ScriptBlock Log Event ID 4104 with full script content showing the create and delete sequence.
- Test 4Drop-Execute-Delete Pattern in Temp Directory
Expected signal: Sysmon Event ID 11: file creation of svcupdate32.exe in C:\Users\Public\. Sysmon Event ID 1: execution of svcupdate32.exe. Sysmon Event ID 1: cmd.exe with del command. Sysmon Event ID 23 (FileDelete, if configured): svcupdate32.exe deletion. KQL hunting query matches execution in Public directory followed by file deletion within 60 minutes.
- Test 5Simulate BPFDoor Environment Variable Clearing
Expected signal: Auditd syscall event for open(2) with flags O_WRONLY on /proc/<PID>/environ path. Syslog entry if auditd is configured to watch /proc/*/environ with inode watches. Linux audit event type=PATH with name matching /proc/[0-9]+/environ.
References (12)
- https://attack.mitre.org/techniques/T1070/
- https://www.sentinelone.com/labs/operation-bleeding-bear/
- https://www.proofpoint.com/us/threat-insight/post/ta505-distributes-new-sdbbot-remote-access-trojan-get-installer-tool
- https://sandfly.io/linux-threat-hunting-with-bpfdoor/
- https://securelist.com/shadowpad-in-corporate-networks/81432/
- https://www.crowdstrike.com/blog/how-crowdstrike-falcon-protects-against-wiper-malware-used-in-ukraine-attacks/
- https://www.welivesecurity.com/en/eset-research/a-journey-to-the-darkside-the-hermetic-wiper-malware/
- https://github.com/redcanaryco/atomic-red-team/tree/master/atomics/T1070
- https://github.com/SigmaHQ/sigma/tree/master/rules/windows/builtin
- https://learn.microsoft.com/en-us/sysinternals/downloads/sysmon
- https://docs.microsoft.com/en-us/windows/security/threat-protection/auditing/audit-registry
- https://github.com/TheWover/donut
Unlock Pro Content
Get the full detection package for T1070 including response playbook, investigation guide, and atomic red team tests.
Related Detections
Sub-techniques (10)
- T1070.001Clear Windows Event Logs
- T1070.002Clear Linux or Mac System Logs
- T1070.003Clear Command History
- T1070.004File Deletion
- T1070.005Network Share Connection Removal
- T1070.006Timestomp
- T1070.007Clear Network Connection History and Configurations
- T1070.008Clear Mailbox Data
- T1070.009Clear Persistence
- T1070.010Relocate Malware