Has checked mount points for Oracle PeopleSoft configurations and has checked the process scheduler configuration file psappsrv.cfg. Additionally, ShinyHunters has read WebLogic server XML configurations files (config.xml).1
File and Directory Discovery T1083
- Tactic
- Discovery
- Platforms
- ESXi, Linux, macOS, Network Devices, Windows
- Version
- 1.7
- Created
- 31 May 2017
- Last modified
- 12 May 2026
- Contributor
- Austin Clark, @c2defense
Adversaries may enumerate files and directories or may search in specific locations of a host or network share for certain information within a file system. Adversaries may use the information from File and Directory Discovery during automated discovery to shape follow-on behaviors, including whether or not the adversary fully infects the target and/or attempts specific actions.
File and Directory Discovery MITRE reference T1083
52 groups have been recorded using this technique. Newest first; each entry carries MITRE’s procedure text and a link to the group’s full record. Click a name to filter the rules below.
Has run commands to check the content of folders on compromised hosts and has specifically targeted files with .doc, .ppt, .xls, .jtd, .eml, .xps, and .pdf extensions.123
Has conducted key word searches within files and directories on a compromised hosts to identify files for exfiltration.12
Has searched for files within the victim environment for encryption and exfiltration.123 Medusa Group has also identified files associated with remote management services.12
Has used vmtoolsd.exe to enumerate files on guest machines.12
Has enumerated local files and folders on victim devices.1
All 52 groups for this technique · 6 newest in this preview
13 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 leveraged Claude Code to identify sensitive data within the victim environment for extraction.1
During SharePoint ToolShell Exploitation, threat actors leveraged commands to locate accessible file shares, backup paths, or SharePoint content.1
During the 2025 Poland Wiper Attacks, the adversaries obtained the contents of users’ directories using dir /s /b C:\Users command.1
Gathers a list of filenames from the following locations during execution of the final botnet stage: \/usr\/sbin\/, \/usr\/bin\/, \/sbin\/, \/pfrm2.0\/bin\/, \/usr\/local\/bin\/.1
During C0015, the threat actors conducted a file listing discovery against multiple hosts to ensure locker encryption was successful.1
During Operation CuckooBees, the threat actors used dir c:\\ to search for files.1
All 13 campaigns for this technique · 6 newest in this preview
308 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 enumerated home directories, file paths and files associated with storing or containing credentials and other secrets.1
Has discovered npm pathways and directories that frequently store .npmrc files to check for _authToken values.1
Can identify files containing environment variables, SSH keys, cloud credentials, access tokens, and cryptocurrency wallets.1234
Can specifically target multiple files by extension including: .rar, .tar.gz, .zip, .7z, .json, .bcp, .bak, .gho, .erf, .edb, .onepkg, .pst, and .ldiff.1
Has used the Microsoft Windows native FindFirstFile() and FindNextFile() to recursively enumerate directories and files on the system.1
Can target directories on victim machines for file collection.12
All 308 software entries for this technique · 6 newest in this preview
Offense vs defense T1083
Is defensive coverage keeping up with adversary use? Eight counts, each ranked against all 697 ATT&CK techniques. Attack sits left, defense right, so a shape leaning left means adversaries are better documented here than defenders are equipped. Hover any spoke for its percentile and the share of techniques that have more. The timeline below shows when each side arrived.
How it got here
Adversary activity (campaign spans) over cumulative rule output. Each source is plotted independently from zero, so neither line includes the other. Campaign dates are year-granularity.
File and Directory Discovery detection strategy DET0370
MITRE names one behaviour worth catching for this technique and breaks it into 5 analytics, one per platform. Each carries the log sources it needs and the fields you tune per environment.
Recursive Enumeration of Files and Directories Across Privilege Contexts
AN1040 · Windows
Execution of file enumeration commands (e.g., 'dir', 'tree') from non-standard processes or unusual user contexts, followed by recursive directory traversal or access to sensitive locations.
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.
| Data component | Name | Channel |
|---|---|---|
| Process CreationDC0032 | WinEventLog:Security | EventCode=4688 |
| File CreationDC0039 | WinEventLog:Sysmon | EventCode=11 |
Tunable fields
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
| Field | What you tune |
|---|---|
| CommandLineRegex | Allows tuning based on tools/scripts used for enumeration (e.g., tree, dir /s /b) |
| UserContext | Scoping for standard vs elevated or service accounts |
| TimeWindow | Defines burst activity over short periods (e.g., >50 directory queries in 30s) |
AN1041 · Linux
Use of file enumeration commands (e.g., 'ls', 'find', 'locate') executed by suspicious users or scripts accessing broad file hierarchies or restricted directories.
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.
| Data component | Name | Channel |
|---|---|---|
| Process CreationDC0032 | auditd:SYSCALL | execve |
| File AccessDC0055 | auditd:PATH | PATH |
Tunable fields
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
| Field | What you tune |
|---|---|
| FilePathDepth | Max depth of recursive access to tune noise vs anomaly |
| UserContext | Helpful to exclude known scripts or automation accounts |
AN1042 · macOS
Execution of file or directory discovery commands (e.g., 'ls', 'find') from terminal or script-based tooling, especially outside normal user workflows.
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.
| Data component | Name | Channel |
|---|---|---|
| Process CreationDC0032 | macos:unifiedlog | log collect --predicate |
| File AccessDC0055 | fs:fsusage | Filesystem Call Monitoring |
Tunable fields
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
| Field | What you tune |
|---|---|
| PredicateScope | Adjust macOS unified log filter to include/exclude system paths |
| TimeWindow | Tune based on burst access patterns |
AN1043 · ESXi
Execution of esxcli commands to enumerate datastore, configuration files, or directory structures by unauthorized or remote users.
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.
| Data component | Name | Channel |
|---|---|---|
| File AccessDC0055 | esxi:hostd | vSphere File API Access |
| Command ExecutionDC0064 | esxi:shell | Shell Access/Command Execution |
Tunable fields
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
| Field | What you tune |
|---|---|
| CLICommandPattern | Match on esxcli storage|filesystem commands |
| AccessSource | Limit alerting to non-vCenter or remote IPs |
AN1044 · Network Devices
Execution of file discovery commands (e.g., 'dir', 'show flash', 'nvram:') from CLI interfaces, especially by unauthorized users or from abnormal source IPs.
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.
| Data component | Name | Channel |
|---|---|---|
| Command ExecutionDC0064 | networkdevice:syslog | CLI Command Logging |
Tunable fields
MITRE calls these the analytic’s mutable elements: the thresholds and filters you set for your own environment.
| Field | What you tune |
|---|---|
| CommandWhitelist | Filter allowed commands by account or IP |
| SessionOrigin | Tunable to restrict detection to remote terminal or Telnet/SSH |
| # | Test | Platform | Executor | Elevation | Prereqs | Cleanup | Ref | |||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 01 | File and Directory Discovery (cmd.exe) | windows | cmd | — | — | Yes | ||||||||||||||||||||||||||
Find or discover files on the file system. Upon successful execution, this test will output the results of all the data discovery commands to a specified file. Input arguments
Attack command dir /s c:\ >> #{output_file}
dir /s "c:\Documents and Settings" >> #{output_file}
dir /s "c:\Program Files\" >> #{output_file}
dir "%systemdrive%\Users\*.*" >> #{output_file}
dir "%userprofile%\AppData\Roaming\Microsoft\Windows\Recent\*.*" >> #{output_file}
dir "%userprofile%\Desktop\*.*" >> #{output_file}
tree /F >> #{output_file}
Cleanup command del #{output_file}
GUID00838107-4f36-4aac-b351-b870e6d53afd | ||||||||||||||||||||||||||||||||
| 02 | File and Directory Discovery (PowerShell) | windows | PowerShell | — | — | — | ||||||||||||||||||||||||||
Find or discover files on the file system. Upon execution, file and folder information will be displayed. Attack command ls -recurse get-childitem -recurse gci -recurse GUIDcab5bd27-4bef-4cd4-94e7-f323c5c9f6d3 | ||||||||||||||||||||||||||||||||
| 03 | Nix File and Directory Discovery | linux, macos | sh | — | — | Yes | ||||||||||||||||||||||||||
Find or discover files on the file system References: http://osxdaily.com/2013/01/29/list-all-files-subdirectory-contents-recursively/ https://perishablepress.com/list-files-folders-recursively-terminal/ Input arguments
Attack command ls -a >> #{output_file}
if [ -d /Library/Preferences/ ]; then ls -la /Library/Preferences/ > #{output_file}; fi;
file */* *>> #{output_file}
cat #{output_file} 2>/dev/null
find . -type f
ls -R | grep ":$" | sed -e 's/:$//' -e 's/[^-][^\/]*\//--/g' -e 's/^/ /' -e 's/-/|/'
locate *
which sh
Cleanup command rm #{output_file}
GUID3b6528bb-f4a9-4e79-8126-25879853c1b5 | ||||||||||||||||||||||||||||||||
| 04 | Nix File and Directory Discovery 2 | linux, macos | sh | — | — | Yes | ||||||||||||||||||||||||||
Find or discover files on the file system Input arguments
Attack command cd $HOME && find . -print | sed -e 's;[^/]*/;|__;g;s;__|; |;g' > #{output_file}
if [ -f /etc/mtab ]; then cat /etc/mtab >> #{output_file}; fi;
find . -type f -iname *.pdf >> #{output_file}
cat #{output_file}
find . -type f -name ".*"
Cleanup command rm #{output_file}GUID810846a6-629d-42de-a4a3-8bb8789a64be | ||||||||||||||||||||||||||||||||
| 05 | Simulating MAZE Directory Enumeration | windows | PowerShell | — | — | Yes | ||||||||||||||||||||||||||
This test emulates MAZE ransomware's ability to enumerate directories using Powershell. Upon successful execution, this test will output the directory enumeration results to a specified file, as well as display them in the active window. See https://www.mandiant.com/resources/tactics-techniques-procedures-associated-with-maze-ransomware-incidents Input arguments
Attack command $folderarray = @("Desktop", "Downloads", "Documents", "AppData/Local", "AppData/Roaming")
Get-ChildItem -Path $env:homedrive -ErrorAction SilentlyContinue | Out-File -append #{File_to_output}
Get-ChildItem -Path $env:programfiles -erroraction silentlycontinue | Out-File -append #{File_to_output}
Get-ChildItem -Path "${env:ProgramFiles(x86)}" -erroraction silentlycontinue | Out-File -append #{File_to_output}
$UsersFolder = "$env:homedrive\Users\"
foreach ($directory in Get-ChildItem -Path $UsersFolder -ErrorAction SilentlyContinue)
{
foreach ($secondarydirectory in $folderarray)
{Get-ChildItem -Path "$UsersFolder/$directory/$secondarydirectory" -ErrorAction SilentlyContinue | Out-File -append #{File_to_output}}
}
cat #{File_to_output}
Cleanup command remove-item #{File_to_output} -ErrorAction SilentlyContinue
GUID4301b98c-56d7-46e5-830e-34ae63855572 | ||||||||||||||||||||||||||||||||
| 06 | Launch DirLister Executable | windows | PowerShell | — | 1 | — | ||||||||||||||||||||||||||
Launches the DirLister executable for a short period of time and then exits. Recently seen used by BlackCat ransomware to create a list of accessible directories and files. Input arguments
Attack command Start-Process "#{dirlister_path}"
Start-Sleep -Second 4
Stop-Process -Name "DirLister"
Prerequisite DirLister.exe must exist in the specified path #{dirlister_path} Check if (Test-Path "#{dirlister_path}") {exit 0} else {exit 1}
Satisfy $parentpath = Split-Path "#{dirlister_path}"
New-Item -ItemType Directory -Force -Path $parentpath | Out-Null
Invoke-WebRequest https://github.com/SanderSade/DirLister/releases/download/v2.beta4/DirLister.v2.beta4.zip -OutFile "PathToAtomicsFolder\..\ExternalPayloads\TDirLister.v2.beta4.zip"
Expand-Archive -Path "PathToAtomicsFolder\..\ExternalPayloads\TDirLister.v2.beta4.zip" -DestinationPath "PathToAtomicsFolder\..\ExternalPayloads\TDirLister.v2.beta4" -Force
Copy-Item "PathToAtomicsFolder\..\ExternalPayloads\TDirLister.v2.beta4\*" "$parentpath" -Recurse
Remove-Item "PathToAtomicsFolder\..\ExternalPayloads\TDirLister.v2.beta4.zip","PathToAtomicsFolder\..\ExternalPayloads\TDirLister.v2.beta4" -Recurse -ErrorAction Ignore
GUIDb3e0f3ca-014b-4e66-b453-2ed00209d230 | ||||||||||||||||||||||||||||||||
| 07 | ESXi - Enumerate VMDKs available on an ESXi Host | windows | cmd | — | 1 | — | ||||||||||||||||||||||||||
An adversary uses the find command to enumerate vmdks on an ESXi host. Reference Input arguments
Attack command echo "" | "#{plink_file}" "#{vm_host}" -ssh -l "#{vm_user}" -pw "#{vm_pass}" -m "#{cli_script}"
Prerequisite Check if plink is available. Check if (Test-Path "#{plink_file}") {exit 0} else {exit 1}
Satisfy New-Item -Type Directory "PathToAtomicsFolder\..\ExternalPayloads\" -ErrorAction Ignore -Force | Out-Null
Invoke-WebRequest "https://the.earth.li/~sgtatham/putty/latest/w64/plink.exe" -OutFile "#{plink_file}"
GUIDd3618d16-f10d-40d0-a645-7199abce6f17 | ||||||||||||||||||||||||||||||||
| 08 | Identifying Network Shares - Linux | linux | sh | — | — | — | ||||||||||||||||||||||||||
If the system uses network file systems (e.g., NFS, CIFS), findmnt can help locate paths to remote shares. Attackers may then attempt to access these shares for lateral movement or data exfiltration. Attack command findmnt -t nfs GUID090373b0-f0be-4f74-84b2-30174e222410 | ||||||||||||||||||||||||||||||||
| 09 | Recursive Enumerate Files And Directories By Powershell | windows | PowerShell | — | — | Yes | ||||||||||||||||||||||||||
Adversary attempting to discover and collect sensitive documents and archives from a user’s system. The test recursively enumerates common user folders (Documents, Downloads, Desktop, OneDrive) for file types of interest such as .pdf, .doc, .docx, .xls, .xlsx, .txt, .zip, .rar, and .7z. This behavior is similar to malware like LOSTKEYS used by COLDRIVER in January 2025, where attackers perform targeted file discovery to support strategic intelligence collection https://www.zscaler.com/blogs/security-research/coldriver-updates-arsenal-baitswitch-and-simplefix. Input arguments
Attack command $out = "#{output_file}"
$dirsFilter = @('Documents','Downloads','Desktop','OneDrive')
$exts = @('.pdf','.doc','.docx','.xls','.xlsx','.txt','.zip','.rar','.7z')
$userProfile = [Environment]::GetFolderPath('UserProfile')
$tr = [System.Collections.Generic.List[string]]::new()
function MatchesExtension($path) {
try {
$e = [System.IO.Path]::GetExtension($path).ToLower()
return $exts -contains $e
} catch { return $false }
}
function Scan-Dir($root) {
try {
$match = $false
foreach ($f in $dirsFilter) { if ($root -like "*$f*") { $match = $true; break } }
if (-not $match) { return }
[System.IO.Directory]::EnumerateFiles($root) | ForEach-Object {
if (MatchesExtension $_) {
$fi = [System.IO.FileInfo]::new($_)
$tr.Add("[File] $_ Size:$($fi.Length) LastWrite:$($fi.LastWriteTime)")
}
}
[System.IO.Directory]::EnumerateDirectories($root) | ForEach-Object {
Scan-Dir $_
}
} catch [System.UnauthorizedAccessException] {
$tr.Add("[AccessDenied] $root")
} catch {
$tr.Add("[Error] $root => $($_.Exception.Message)")
}
}
[System.IO.Directory]::EnumerateDirectories($userProfile) | ForEach-Object { Scan-Dir $_ }
# Ensure output dir exists
$outDir = [System.IO.Path]::GetDirectoryName($out)
if (-not [string]::IsNullOrEmpty($outDir) -and -not (Test-Path $outDir)) {
New-Item -Path $outDir -ItemType Directory -Force | Out-Null
}
# Write results
$tr | Out-File -FilePath $out -Encoding UTF8
Write-Output "Enumeration complete. Results written to: $out"
Cleanup command Remove-Item -Path "#{output_file}" -ErrorAction SilentlyContinue
GUID51dae807-c410-4a20-bc3d-c4a7535586c1 | ||||||||||||||||||||||||||||||||
Tests from Atomic Red Team (MIT licence) · technique definition