T1074.001 Google Chronicle · YARA-L

Detect Local Data Staging in Google Chronicle

Adversaries may stage collected data in a central location or directory on the local system prior to exfiltration. Data may be kept in separate files or combined into one file through archiving techniques. Adversaries commonly use temp directories, hidden folders, or application data paths to aggregate stolen files, credentials, screenshots, keylogger output, and memory dumps before transferring them out. Interactive command shells (cmd.exe, bash) and scripting languages are frequently used to copy and consolidate data into staging locations.

MITRE ATT&CK

Tactic
Collection
Technique
T1074 Data Staged
Sub-technique
T1074.001 Local Data Staging
Canonical reference
https://attack.mitre.org/techniques/T1074/001/

YARA-L Detection Query

Google Chronicle (YARA-L)
yaral
rule t1074_001_local_data_staging {
  meta:
    author = "Detection Engineering"
    description = "Detects T1074.001 Local Data Staging - adversaries aggregating collected data in staging directories prior to exfiltration using bulk copy tools, archive utilities, or output redirection"
    mitre_attack_tactic = "Collection"
    mitre_attack_technique = "T1074.001"
    severity = "HIGH"
    confidence = "MEDIUM"
    created = "2026-04-13"

  events:
    (
      // Detection 1: Bulk file copy into staging paths
      (
        $e.metadata.event_type = "PROCESS_LAUNCH"
        and (
          re.regex($e.principal.process.command_line,
            `(?i)(xcopy|robocopy|\bcopy\b|\bmove\b|cp\s|mv\s)`)
        )
        and (
          re.regex($e.principal.process.command_line,
            `(?i)(\\temp\\|\\tmp\\|\\programdata\\|\\users\\public\\|\\appdata\\local\\temp\\|\\windows\\temp\\|\\appdata\\roaming\\)`)
        )
      )
      or
      // Detection 2: Archive/temp file creation in staging paths
      (
        $e.metadata.event_type = "FILE_CREATION"
        and re.regex($e.target.file.full_path,
          `(?i)(\\temp\\|\\tmp\\|\\programdata\\|\\users\\public\\|\\appdata\\local\\temp\\|\\windows\\temp\\)`)
        and re.regex($e.target.file.full_path,
          `(?i)\.(zip|rar|7z|tar|gz|tmp|dat|db|bak)$`)
        and not re.regex($e.principal.process.file.full_path,
          `(?i)(msmpeng|svchost|tiworker|wuauclt|msiexec|onedrive|teams|slack)\.exe`)
      )
      or
      // Detection 3: Output redirection into staging directories
      (
        $e.metadata.event_type = "PROCESS_LAUNCH"
        and re.regex($e.principal.process.file.full_path,
          `(?i)(cmd\.exe|powershell\.exe|pwsh\.exe|bash|sh)$`)
        and re.regex($e.principal.process.command_line, `(>>|>\s)`)
        and re.regex($e.principal.process.command_line,
          `(?i)(\\temp\\|\\tmp\\|\\programdata\\|\\users\\public\\)`)
      )
    )

  condition:
    $e
}
high severity medium confidence

Chronicle YARA-L 2.0 rule detecting T1074.001 Local Data Staging across three behavioral patterns: bulk file copy operations by shell/copy utilities targeting staging paths, archive or temp file creation in staging directories by non-system processes, and output redirection from interactive shells into staging locations. Uses UDM fields for process and file event types.

Data Sources

Google Chronicle SIEMWindows endpoint telemetry via Chronicle forwarderSysmon events normalized to UDM

Required Tables

UDM events (process_launch, file_creation)

False Positives & Tuning

  • Windows operating system components including Windows Installer (msiexec.exe), CBS (TrustedInstaller.exe), and Windows Update frequently create .cab, .tmp, and .dat files in Windows\Temp during system update and component servicing operations
  • Enterprise backup agents (Veeam, Commvault, Acronis) execute robocopy and xcopy as child processes during incremental backup jobs, copying data to staging areas before off-site transfer
  • Application packaging tools (MSIX tooling, InstallShield, NSIS) create intermediate archive files in temp directories during the build and packaging process on developer workstations and build servers
Download portable Sigma rule (.yml)

Other platforms for T1074.001


Testing Methodology

Validate this detection against 4 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.

  1. Test 1Stage Files to Temp Directory Using CMD Copy

    Expected signal: Sysmon Event ID 1: Process Create for cmd.exe with CommandLine containing 'copy' and '%TEMP%\staging_test'. Sysmon Event ID 11: Multiple FileCreate events in the staging directory. Security Event ID 4688 (if command-line auditing enabled) showing the copy commands.

  2. Test 2Stage Collected Output Using Append Redirect Operator

    Expected signal: Sysmon Event ID 1: Multiple Process Create events for cmd.exe with CommandLine containing '>>' and the staging file path in %TEMP%. Sysmon Event ID 11: FileCreate/FileModify events for collected_data.tmp. The file grows with each command execution.

  3. Test 3Stage Files with Hostname-Username Naming Convention

    Expected signal: Sysmon Event ID 1: Process Create for powershell.exe with CommandLine referencing %COMPUTERNAME%_%USERNAME%.txt. Sysmon Event ID 11: FileCreate event in %TEMP% with filename matching Hostname_Username.txt pattern. PowerShell ScriptBlock Log Event ID 4104 with full script content.

  4. Test 4Stage Data in Windows Registry (DarkWatchman Pattern)

    Expected signal: Sysmon Event ID 1: Process Create for powershell.exe. Sysmon Event ID 13 (RegistryValueSet): Registry value CachedData set under HKCU\SOFTWARE\Microsoft\Notepad with large Base64-encoded data. DeviceRegistryEvents: RegistryValueSet event visible in MDE.

Unlock Pro Content

Get the full detection package for T1074.001 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections