Once established within a system or network, an adversary may use automated techniques for collecting internal data. Methods for performing this technique could include use of a Command and Scripting Interpreter to search for and copy information fitting set criteria such as file type, location, or name at specific time intervals.
In cloud-based environments, adversaries may also use cloud APIs, data pipelines, command line interfaces, or extract, transform, and load (ETL) services to automatically collect data.[1]
This functionality could also be built into remote access tools.
Delivered a PowerShell script capable of recursively scanning victim machines looking for various file types before exfiltrating identified files via HTTP.1
Has used a file stealer to steal documents and images with the following extensions: txt, pdf, png, jpg, doc, xls, xlm, odp, ods, odt, rtf, ppt, xlsx, xlsm, docx, pptx, and jpeg.1
created 2021-12-261 referenceaka Confucius APT
All 21 groups for this technique · 6 newest in this preview
7 campaigns have been recorded using this technique. Listed newest first; dates are year-granularity and attribution is MITRE’s.
During the Anthropic AI-orchestrated Campaign, the adversary used Claude Code to automatically collect and process large volumes of data from without human direction.1
During SharePoint ToolShell Exploitation, threat actors used a command shell to automatically iterate through web.config files to expose and collect machineKey settings.12
During Frankenstein, the threat actors used Empire to automatically gather the username, domain name, machine name, and other system information.1
2019
All 7 campaigns for this technique · 6 newest in this preview
50 software entries are documented implementing this technique. MITRE files each as a tool or as malware; newest first, then by how many groups carry them.
Has the ability to automatically compile gathered credentials from configuration files and password vaults within an archive and exfiltrate stolen data leveraging both a primary and fallback C2.1
Pick your platform, collect the listed log sources, then tune the fields to your environment.
Automated File and API Collection Detection Across Platforms
Enterprise
4 platforms
AN0531 · Windows
Automated execution of native utilities and scripts to discover, enumerate, and exfiltrate files and clipboard content. Focus is on detecting repeated file access, scripting engine use, and use of command-line utilities commonly leveraged by collection scripts.
Log sources
The data this analytic draws on. You do not need every component — each one you already collect covers part of it. Each links to its ATT&CK record.
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
Field
What you tune
TimeWindow
Defines the lookback period for identifying burst activity or patterns in process/file events.
SuspiciousFileExtensions
Tunable list of file extensions associated with collection (e.g., .pdf, .docx).
ProcessCountThreshold
The number of times a process executes before considered anomalous.
AN0532 · Linux
Repeated or automated access to user document directories or clipboard using shell scripts or utilities like xclip/pbpaste. Detectable via auditd syscall logs or osquery file events.
Log sources
The data this analytic draws on. You do not need every component — each one you already collect covers part of it. Each links to its ATT&CK record.
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
Field
What you tune
AccessPath
Tunable location for sensitive files like /home/*/Documents.
ScriptInterpreterList
Shells or scripting engines to monitor (e.g., bash, python, perl).
AN0533 · macOS
Use of pbpaste, AppleScript, or third-party automation frameworks (e.g., Automator) to collect clipboard or file content in bursts. Observable via unified logs.
Log sources
The data this analytic draws on. You do not need every component — each one you already collect covers part of it. Each links to its ATT&CK record.
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
Field
What you tune
AutomationTool
Detectable script interpreters or clipboard tools (pbpaste, osascript).
ClipboardCheckRate
Threshold for how often clipboard access occurs within a given time window.
AN0534 · SaaS
Suspicious sign-ins to Graph API or sensitive resources using non-browser scripting agents (e.g., Python, PowerShell), often for programmatic access to mailbox or OneDrive content.
Log sources
The data this analytic draws on. You do not need every component — each one you already collect covers part of it. Each links to its ATT&CK record.
Encryption and off-system storage of sensitive information may be one way to mitigate collection of files, but may not stop an adversary from acquiring the information if an intrusion persists over a long period of time and the adversary is able to discover and access the data through other means. Strong passwords should be used on certain encrypted documents that use them to prevent offline cracking through Brute Force techniques.
Encryption and off-system storage of sensitive information may be one way to mitigate collection of files, but may not stop an adversary from acquiring the information if an intrusion persists over a long period of time and the adversary is able to discover and access the data through other means.
Tests5Executorspowershell 3 · command_prompt 2Need elevation0 of 5Have prerequisites0Have cleanup5Platformswindows
#
Test
Platform
Executor
Elevation
Prereqs
Cleanup
Ref
01
Automated Collection Command Prompt
windows
command_prompt
—
—
Yes
Automated Collection. Upon execution, check the users temp directory (%temp%) for the folder T1119_command_prompt_collection
to see what was collected.
Attack Commandsrun with command_prompt
mkdir %temp%\T1119_command_prompt_collection >nul 2>&1
dir c: /b /s .docx | findstr /e .docx
for /R c:\ %f in (*.docx) do copy /Y %f %temp%\T1119_command_prompt_collection
Cleanup Commands
del %temp%\T1119_command_prompt_collection /F /Q >nul 2>&1
GUIDcb379146-53f1-43e0-b884-7ce2c635ff5b
02
Automated Collection PowerShell
windows
powershell
—
—
Yes
Automated Collection. Upon execution, check the users temp directory (%temp%) for the folder T1119_powershell_collection
to see what was collected.
collect information for exfiltration. Upon execution, check the users temp directory (%temp%) for files T1119_*.txt
to see what was collected.
Attack Commandsrun with command_prompt
sc query type=service > %TEMP%\T1119_1.txt
doskey /history > %TEMP%\T1119_2.txt
wmic process list > %TEMP%\T1119_3.txt
tree C:\AtomicRedTeam\atomics > %TEMP%\T1119_4.txt
Cleanup Commands
del %TEMP%\T1119_1.txt >nul 2>&1
del %TEMP%\T1119_2.txt >nul 2>&1
del %TEMP%\T1119_3.txt >nul 2>&1
del %TEMP%\T1119_4.txt >nul 2>&1
GUIDaa1180e2-f329-4e1e-8625-2472ec0bfaf3
05
Enumerate Active Directory Users via PowerShell with csvde
windows
powershell
—
—
Yes
Leverages the native Windows administration tool csvde.exe executed via PowerShell to export Active Directory user objects and properties to a custom staging directory with a timestamped filename.
This technique replicates "Living off the Land" discovery, automated collection, and staging tactics historically utilized by the menuPass threat group (G0045) to profile target domains.
The following analytic detects the use of Windows command-line copy utilities, such as xcopy, to systematically collect files from user directories and consolidate them into a centralized location on the system. (...)