Detect Archive Collected Data in Google Chronicle
Adversaries may compress and/or encrypt data that is collected prior to exfiltration. Compressing the data can help to obfuscate collected data and minimize the amount of data sent over the network. Encryption can be used to hide information that is being exfiltrated from detection or make exfiltration less conspicuous upon inspection by a defender. Both compression and encryption are done prior to exfiltration and can be performed using a utility, third-party library, or custom method. Common tools include 7-Zip, WinRAR, the Windows built-in compact and certutil utilities, PowerShell Compress-Archive and .NET IO.Compression classes, and tar/gzip/openssl on Linux and macOS. Threat actors including Dragonfly, Lazarus Group, Ember Bear, BlackByte, and Axiom have all used archiving and encryption as a pre-exfiltration staging step. Sub-techniques cover archive via utility (T1560.001), archive via library (T1560.002), and archive via custom method (T1560.003).
MITRE ATT&CK
- Tactic
- Collection
- Technique
- T1560 Archive Collected Data
- Canonical reference
- https://attack.mitre.org/techniques/T1560/
YARA-L Detection Query
rule t1560_archive_collected_data {
meta:
author = "Argus Detection Engineering"
description = "Detects T1560 Archive Collected Data - password-protected archive creation, Office/script spawned archivers, PowerShell .NET compression, and CertUtil encoding used as pre-exfiltration data staging"
mitre_attack_tactic = "Collection"
mitre_attack_technique = "T1560"
mitre_attack_subtechniques = "T1560.001, T1560.002, T1560.003"
severity = "HIGH"
risk_score = "75"
reference = "https://attack.mitre.org/techniques/T1560/"
events:
$e.metadata.event_type = "PROCESS_LAUNCH"
(
(
re.regex($e.target.process.file.full_path, `(?i)(7z[ar]?\.exe|rar\.exe|winrar\.exe)$`) and
(
re.regex($e.target.process.command_line, `(?i)\s-hp`) or
strings.contains(strings.to_lower($e.target.process.command_line), "-pass") or
strings.contains(strings.to_lower($e.target.process.command_line), "-password")
)
) or
(
re.regex($e.target.process.file.full_path, `(?i)(7z[ar]?\.exe|rar\.exe|winrar\.exe)$`) and
re.regex($e.principal.process.file.full_path, `(?i)(winword|excel|outlook|powerpnt|mshta|wscript|cscript|mmc|regsvr32|rundll32)\.exe$`)
) or
(
re.regex($e.target.process.file.full_path, `(?i)(powershell|pwsh)\.exe$`) and
(
strings.contains(strings.to_lower($e.target.process.command_line), "compress-archive") or
strings.contains(strings.to_lower($e.target.process.command_line), "io.compression") or
strings.contains(strings.to_lower($e.target.process.command_line), "gzipstream") or
strings.contains(strings.to_lower($e.target.process.command_line), "deflatestream") or
strings.contains(strings.to_lower($e.target.process.command_line), "ziparchive")
)
) or
(
re.regex($e.target.process.file.full_path, `(?i)certutil\.exe$`) and
(
strings.contains(strings.to_lower($e.target.process.command_line), "-encode") or
strings.contains(strings.to_lower($e.target.process.command_line), "-encodehex")
)
)
)
condition:
$e
} Google Chronicle YARA-L 2.0 rule detecting T1560 Archive Collected Data across all four sub-technique patterns using UDM PROCESS_LAUNCH events. Evaluates target process path and command line for password-protected archive flags, suspicious parent-child relationships involving Office applications and scripting engines, PowerShell .NET IO.Compression namespace usage, and CertUtil encoding invocations. Maps directly to the KQL/SPL detection logic using UDM principal (parent) and target (child) process fields.
Data Sources
Required Tables
False Positives & Tuning
- Automated certificate renewal processes on IIS or Exchange servers where certutil.exe performs encoding as part of certificate export workflows — scope the rule to exclude known certificate server hostnames or service account principals
- Legitimate macro-enabled Office documents used in HR or Finance that call authorized PowerShell backup scripts for local archive creation — build allowlists on specific document hashes or trusted OU paths in principal.user.department
- Red team or penetration testing exercises using the same archive tooling against authorized targets — cross-reference with planned engagement windows from a reference list or suppress by authorized tester accounts
Other platforms for T1560
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 17-Zip Password-Protected Archive of Sensitive Directory
Expected signal: Sysmon Event ID 1: Process Create with Image ending in 7z.exe, CommandLine containing '-hp' and 'staged_exfil.zip'. Sysmon Event ID 11: File Create event for C:\Windows\Temp\staged_exfil.zip with InitiatingProcessFileName=7z.exe. Security Event ID 4688 (if process command line auditing enabled) with same details.
- Test 2PowerShell Compress-Archive Staging in Temp Directory
Expected signal: Sysmon Event ID 1: Process Create with Image=powershell.exe, CommandLine containing 'Compress-Archive' and 'C:\Windows\Temp\recent_files_staged.zip'. Sysmon Event ID 11: File Create for the zip archive. PowerShell ScriptBlock Log Event ID 4104 in Microsoft-Windows-PowerShell/Operational with full cmdlet and path.
- Test 3certutil Base64 Encode Binary File
Expected signal: Sysmon Event ID 1: Process Create with Image=certutil.exe, CommandLine containing '-encode' and 'encoded_payload.txt'. Sysmon Event ID 11: File Create for C:\Windows\Temp\encoded_payload.txt. Security Event ID 4688 with the same certutil command line if process auditing is enabled.
- Test 4Linux tar + gzip Collection and Staging
Expected signal: Auditd execve record: type=EXECVE with argv containing 'tar' 'czf' '/tmp/sys_backup_...' '/etc/passwd' '/etc/shadow'. Syslog process creation record (if auditd not deployed). File creation event for /tmp/sys_backup_*.tar.gz. If using a SIEM with Linux file integrity monitoring, alert on new file creation in /tmp matching *.tar.gz by root or privileged account.
- Test 5WinRAR Archive with Password and Locked Headers
Expected signal: Sysmon Event ID 1: Process Create with Image ending rar.exe, CommandLine containing '-hp' and 'staging.rar'. Sysmon Event ID 11: File Create for C:\ProgramData\Microsoft\staging.rar with InitiatingProcessFileName=rar.exe. Security Event ID 4688 with full command line.
References (13)
- https://attack.mitre.org/techniques/T1560/
- https://attack.mitre.org/techniques/T1560/001/
- https://attack.mitre.org/techniques/T1560/002/
- https://attack.mitre.org/techniques/T1560/003/
- https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1560/T1560.md
- https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1560.001/T1560.001.md
- https://cdn.cnn.com/cnn/2018/images/07/13/gru.indictment.pdf
- https://learn.microsoft.com/en-us/defender-endpoint/advanced-hunting-deviceprocessevents-table
- https://learn.microsoft.com/en-us/defender-endpoint/advanced-hunting-devicefileevents-table
- https://www.cisa.gov/sites/default/files/publications/AA18-074A_MAR-10135536-G.PDF
- https://securelist.com/toddycat-check-logs/110696/
- https://www.cybereason.com/blog/threat-analysis-report-bumblebee-loader-the-high-road-to-enterprise-domain-control
- https://github.com/SigmaHQ/sigma/tree/master/rules/windows/process_creation
Unlock Pro Content
Get the full detection package for T1560 including response playbook, investigation guide, and atomic red team tests.