T1003.005: Cached Domain Credentials
Adversaries may attempt to access cached domain credentials used to allow authentication to occur in the event a domain controller is unavailable.
On Windows Vista and newer, the hash format is DCC2 (Domain Cached Credentials version 2) hash, also known as MS-Cache v2 hash. The number of default cached credentials varies and can be altered per system. This hash does not allow pass-the-hash style attacks, and instead requires Password Cracking to recover the plaintext password.
On Linux systems, Active Directory credentials can be accessed through caches maintained by software like System Security Services Daemon (SSSD) or Quest Authentication Services (formerly VAS). Cached credential hashes are typically located at /var/lib/sss/db/cache.[domain].ldb
for SSSD or /var/opt/quest/vas/authcache/vas_auth.vdb
for Quest. Adversaries can use utilities, such as tdbdump
, on these database files to dump the cached hashes and use Password Cracking to obtain the plaintext password.
With SYSTEM or sudo access, the tools/utilities such as Mimikatz, Reg, and secretsdump.py for Windows or Linikatz for Linux can be used to extract the cached credentials.
Note: Cached credentials for Windows Vista are derived using PBKDF2.
Positive Technologies products that cover the technique
MaxPatrol SIEM knowledge base
mitre_attck_cred_access: PT-CR-657: Reading_Registry_Objects: A request from a process to the registry objects containing user credentials is detected
hacking_tools: PT-CR-585: Impacket_Secretsdump: Use of Impacket Secretsdump is detected
hacking_tools: PT-CR-2118: adPEAS_Usage: The adPEAS script for domain reconnaissance was started
hacking_tools: PT-CR-2237: Go_Secdump_Activity: The go-secdump utility was used, which is a tool built to remotely extract hashes from the registry hives without any remote agent and without touching disk
hacking_tools: PT-CR-758: Lazagne_Usage: Use of the LaZagne tool to dump credentials is detected
Detection
ID | DS0017 | Data source and component | Command: Command Execution | Description | Monitor executed commands and arguments that may attempt to access cached domain credentials used to allow authentication to occur in the event a domain controller is unavailable.. Remote access tools may contain built-in features or incorporate existing tools like Mimikatz. PowerShell scripts also exist that contain credential dumping functionality, such as PowerSploit's Invoke-Mimikatz module, which may require additional logging features to be configured in the operating system to collect necessary information for analysis. Detection of compromised Valid Accounts in-use by adversaries may help as well. |
---|
Mitigation
ID | M1015 | Name | Active Directory Configuration | Description | Consider adding users to the "Protected Users" Active Directory security group. This can help limit the caching of users' plaintext credentials. |
---|
ID | M1017 | Name | User Training | Description | Limit credential overlap across accounts and systems by training users and administrators not to use the same password for multiple accounts. |
---|
ID | M1027 | Name | Password Policies | Description | Ensure that local administrator accounts have complex, unique passwords across all systems on the network. |
---|
ID | M1028 | Name | Operating System Configuration | Description | Consider limiting the number of cached credentials (HKLM\SOFTWARE\Microsoft\Windows NT\Current Version\Winlogon\cachedlogonscountvalue) |
---|
ID | M1026 | Name | Privileged Account Management | Description | Do not put user or admin domain accounts in the local administrator groups across systems unless they are tightly controlled, as this is often equivalent to having a local administrator account with the same password on all systems. Follow best practices for design and administration of an enterprise network to limit privileged account use across administrative tiers. |
---|