Adversaries may modify file or directory permissions/attributes to evade access control lists (ACLs) and access protected files.[1][2] File and directory permissions are commonly managed by ACLs configured by the file or directory owner, or users with the appropriate permissions. File and directory ACL implementations vary by platform, but generally explicitly designate which users or groups can perform which actions (read, write, execute, etc.).
Modifications may include changing specific access rights, which may require taking ownership of a file or directory and/or elevated permissions depending on the file or directory’s existing permissions. This may enable malicious activity such as modifying, replacing, or deleting specific files or directories. Specific file and directory modifications may be a required step for many techniques, such as establishing Persistence via Accessibility Features, Boot or Logon Initialization Scripts, Unix Shell Configuration Modification, or tainting/hijacking other instrumental binary/configuration files via Hijack Execution Flow.
Adversaries may also change permissions of symbolic links. For example, malware (particularly ransomware) may modify symbolic links and associated settings to enable access to files from local shortcuts with remote paths.[3][4][5][6][7]
Threat groupsNone recorded · 29% of ATT&CK techniques have none either.
0
CampaignsNone recorded
CampaignsNone recorded · 54% of ATT&CK techniques have none either.
1
Tools & malware44th pct
Tools & malware44th percentile · 56% of ATT&CK techniques have more tools implementing them.
9
Detection rules73rd pct
Detection rules73rd percentile · 71% of ATT&CK techniques have fewer detection rules written.
File and Directory Permissions Modification MITRE reference T1222
44th pctamong all ATT&CK techniques for number of tools
1 software entry is documented implementing this technique. MITRE files each as a tool or as malware; newest first, then by how many groups carry them.
File and Directory Permissions Modification detection strategy DET0299
MITRE names one behaviour worth catching for this technique and breaks it into 4 analytics, one per platform. Each carries the log sources it needs and the fields you tune per environment.
Multi-Platform File and Directory Permissions Modification Detection Strategy
Enterprise
4 platforms
AN0834 · Windows
Sequential behavioral chain of privilege escalation through permission modification: (1) Process creation of permission-modifying utilities (icacls, takeown, attrib, cacls), (2) Correlation with unusual user context or timing, (3) DACL modification events targeting sensitive files/directories, (4) Subsequent file access or modification attempts indicating successful privilege bypass
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
Temporal correlation window for linking permission modification with subsequent access attempts (default: 300 seconds)
SensitivePathList
Environment-specific critical file and directory paths requiring permission change monitoring
TrustedUserContext
Administrative accounts authorized to perform legitimate permission modifications
BusinessHoursThreshold
Time-based threshold for elevated alerting on permission changes outside business hours
AN0835 · Linux
Behavioral sequence of unauthorized privilege escalation via permission modification: (1) chmod/chown/setfacl process execution with suspicious parameters, (2) Targeting of critical system files or unusual permission values, (3) Correlation with non-privileged user context or unusual timing patterns, (4) Follow-on file access indicating successful permission bypass
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.
Extended attributes to monitor for unauthorized modifications
UnifiedLogRetention
Log retention period for correlating permission changes with subsequent access
AN0837 · ESXi
ESXi hypervisor permission modification behavioral chain: (1) SSH access to ESXi host, (2) chmod/chown execution on VMFS datastore files or system configuration, (3) Modification of VM configuration files (.vmx) or virtual disk permissions, (4) Hostd service log correlation, (5) vCenter permission change events if centrally managed
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.
Ensure critical system files as well as those known to be abused by adversaries have restrictive permissions and are owned by an appropriately privileged account, especially if access is not required by users nor will inhibit system functionality.
Applying more restrictive permissions to files and directories could prevent adversaries from modifying their access control lists. Additionally, ensure that user settings regarding local and remote symbolic links are properly set or disabled where unneeded.
Tests3Executorscommand_prompt 2 · powershell 1Need elevation3 of 3Have prerequisites0Have cleanup3Platformswindows
#
Test
Platform
Executor
Elevation
Prereqs
Cleanup
Ref
01
Enable Local and Remote Symbolic Links via fsutil
windows
command_prompt
Required
—
Yes
Use fsutil to enable both ‘remote to local’ and ‘remote to remote’ symbolic links. This allows access to files from local shortcuts with local or remote paths.
reference
Attack Commandsrun with command_promptelevation required (root or admin)
fsutil behavior set SymlinkEvaluation R2L:1
fsutil behavior set SymlinkEvaluation R2R:1
Cleanup Commands
fsutil behavior set SymlinkEvaluation R2L:0
fsutil behavior set SymlinkEvaluation R2R:0
GUID6c4ac96f-d4fa-44f4-83ca-56d8f4a55c02
02
Enable Local and Remote Symbolic Links via reg.exe
windows
command_prompt
Required
—
Yes
Use reg.exe to enable both ‘remote to local’ and ‘remote to remote’ symbolic links. This allows access to files from local shortcuts with local or remote paths.
reference
Attack Commandsrun with command_promptelevation required (root or admin)
Enable Local and Remote Symbolic Links via Powershell
windows
powershell
Required
—
Yes
Use Powershell to enable both ‘remote to local’ and ‘remote to remote’ symbolic links. This allows access to files from local shortcuts with local or remote paths.
reference
Attack Commandsrun with powershellelevation required (root or admin)
The following analytic detects instances where an adversary modifies security permissions of a file or directory using commands like "icacls.exe", "cacls.exe", or "xcacls.exe" with deny options. (...)
The following analytic identifies instances where four or more distinct detection analytics are associated with malicious command line behavior on a specific host. (...)