Linux Docker Container Discovery via .dockerenv File Listing or Reads

Detects Linux process executions using common utilities to read or list .dockerenv, indicating potential container environment discovery.

FreeReviewedSigma · Low · v2
Product
linux
Category
process_creation
Author
Seth Hanford (SigmaHQ), DRL 1.1
Published
2023-08-23
Updated
2026-07-31

ATT&CK techniques

Discovery
  1. Recon

  2. Resource Dev

  3. Initial Access

  4. Execution

  5. Persistence

  6. Priv Esc

  7. Defense Evasion

  8. Cred Access

  9. Lateral Movement

  10. Collection

  11. C2

  12. Exfiltration

  13. Impact

What it detects

Identifies process executions where the command line ends with “.dockerenv” and is invoked via common file discovery or inspection utilities (e.g., cat/ls/find/stat/test/grep). This behavior can indicate an attacker is determining whether a process is running inside a Docker container by probing for the special “.dockerenv” file. The rule relies on Linux process creation telemetry, matching both the invoked image/utility name and the command line ending pattern.

Related detections9 linkedT1082 — drag to rearrange
Malicious Turla Kopiluwak Reconnaissance Output to Windows Temp via process_creation
Suspicious Windows Defender Support Directory Enumeration via Process Creation
Suspicious System Reconnaissance via Windows Script Host
Suspicious Host Reconnaissance Command Chain via cmd
Malicious DinodasRAT Hidden Config File Creation on Linux (via file_event)
Suspicious System Discovery via WMIC Query Commands (via process_creation)
Suspicious PowerShell Host and Locale Reconnaissance via MuddyWater Tsundere Botnet
Suspicious System Reconnaissance Output Redirected to Temp rad File
Suspicious System Profiler Hardware Reconnaissance via BANSHEE
Linux Docker Container Discovery via .dockerenv File Listing or Reads
Pivot detection · T1082 · 9 related

Changelog

v2
  1. v2
    Candidate ingested via manual entry.2026-07-31
  2. v1
    No changelog recorded for this version.2026-07-30

Detection content is published as a reviewed draft. Tune thresholds and exclusions against your own telemetry before enabling this rule for alerting.