# Windows Credentials ## Attack • Mitigation • Defense Chad Tilbury ###### @chadtilbury ----- ###### 15+ YEARS Computer Crime Investigations CrowdStrike • Mandiant • US Air Force OSI Special Agent SANS INSTITUTE Senior Instructor and Co-Author: FOR500: Windows Forensics FOR508: Advanced Forensics and Incident Response CONNECT E-mail: chad.tilbury@crowdstrike.com CHAD TILBURY LinkedIn: Chad Tilbury TECHNICAL ADVISOR **CROWDSTRIKE SERVICES** ----- ###### Credentials ###### • Priority #1 post-exploitation • Domain admin is ultimate goal • Nearly everything in Windows is tied to an account • Difficult to move without one • Easy and relatively stealthy means to traverse the network • Account limitations are rare • “Sleeper” credentials can provide access after remediation ----- ######  User Access Control (UAC)  Managed Service Accounts  KB2871997 ######  SSP plaintext password mitigations  Local admin remote logon restrictions  Protected Processes  Restricted Admin  Domain Protected Users Security Group  LSA Cache cleanup  Group Managed Service ######  Credential Guard  Remote Credential Guard  Device Guard (prevent execution of untrusted code) ----- ### Hashes ###### Tokens Cached Credentials LSA Secrets Tickets NTDS.DIT |Col1|The password for each user account in Windows is stored in multiple formats: LM and NT hashes are most well known. TsPkg, WDigest, and LiveSSP can be decrypted to provide plaintext passwords (prior to Win8.1) How are they acquired and used? Hashes are available in the LSASS process and can be extracted with admin privileges. Once dumped, hashes can be cracked or used immediately in a Pass the Hash attack. Common tools: Mimikatz • fgdump • gsecdump • Metasploit • SMBshell • PWDumpX • creddump • WCE| |---|---| ----- |Admin Action|Logon Type|Credentials on Target?|Notes| |---|---|---|---| |Console logon|2|Yes*|*Except when Credential Guard is enabled| |Runas|2|Yes*|*Except when Credential Guard is enabled| |Remote Desktop|10|Yes*|*Except for enabled Remote Credential Guard| |Net Use|3|No|Including /u: parameter| |PowerShell Remoting|3|No|Invoke-Command; Enter-PSSession| |PsExec alternate creds|3 + 2|Yes|-u -p