Overview
The logins command searches for Chromium-based browser ‘Login Data’ files and decrypts saved login credentials including usernames and passwords. This command targets the SQLite databases where browsers store encrypted authentication credentials for websites. SharpChrome uses lockless SQLite database access, meaning target browsers don’t need to be closed during credential extraction. The command automatically handles both legacy DPAPI-protected credentials and newer Chrome 80+ AES-encrypted credentials.Key Features
- Extracts saved website login credentials from browser databases
- Supports multiple decryption methods (CryptUnprotectData, DPAPI masterkeys, domain backup keys)
- Handles Chrome 80+ AES state key encryption automatically
- Works while browser is running (lockless database access)
- Supports local and remote credential extraction
- Filters output to show only entries with passwords by default
Basic Usage
Command Arguments
- Decryption
- Targeting
- Output
- Filtering
Decryption Arguments
Force use of CryptUnprotectData() for decryption. This is the default behavior when running in an unprivileged context. Works only from the user context that saved the credentials.
Use a DPAPI domain backup key to decrypt user masterkeys first, then use those to decrypt login credentials.Accepts two formats:
- Base64-encoded key:
/pvk:HvG1sAAAAAABAAAAAAAAAAAAAAACU... - File path:
/pvk:key.pvk
One or more DPAPI masterkey GUID:SHA1 mappings for decryption.Obtain these with Mimikatz:
sekurlsa::dpapiFile containing one or more GUID:SHA1 masterkey mappings (one per line).
Decrypt target user’s masterkeys using plaintext password. Works remotely when combined with
/server.Decrypt target user’s masterkeys using NTLM hash. Works remotely when combined with
/server.Decrypt target user’s masterkeys using DPAPI prekey (domain or local SHA1). Works remotely.
- Domain users: Use
dpapifield from Mimikatzsekurlsa::msvoutput - Local users: Use
sha1field from Mimikatzsekurlsa::msvoutput
Decrypt target user’s masterkeys by asking the domain controller to decrypt them via RPC.
Provide a pre-decrypted AES state key for Chrome 80+ credential decryption.Obtain the state key first using the
statekeys command.Chrome 80+ State Key Encryption
Starting with Chrome version 80, Google introduced a new encryption mechanism for cookies and login data using AES encryption with a state key stored in the browser’s Local State file.How It Works
- State Key Storage: An AES key is stored in
AppData\Local\Google\Chrome\User Data\Local State - DPAPI Protection: The state key itself is encrypted with DPAPI
- Credential Encryption: New login entries are encrypted with this AES state key instead of directly with DPAPI
Decryption Process
SharpChrome handles this automatically:State Key Location
- Chrome:
%LOCALAPPDATA%\Google\Chrome\User Data\Local State - Edge:
%LOCALAPPDATA%\Microsoft\Edge\User Data\Local State - Brave:
%LOCALAPPDATA%\BraveSoftware\Brave-Browser\User Data\Local State
Supported Browsers
Google Chrome
Default target browser. Decrypts Login Data from Chrome’s default profile and all additional profiles.Location:
%LOCALAPPDATA%\Google\Chrome\User Data\Default\Login DataMicrosoft Edge
Chromium-based Edge browser. Use
/browser:edge to target.Location: %LOCALAPPDATA%\Microsoft\Edge\User Data\Default\Login DataBrave Browser
Privacy-focused Chromium browser. Use
/browser:brave to target.Location: %LOCALAPPDATA%\BraveSoftware\Brave-Browser\User Data\Default\Login DataSlack Desktop
Slack desktop application uses Chromium for credential storage. Use
/browser:slack to target.Location: %APPDATA%\Slack\CookiesExample Workflows
Scenario 1: Local Credential Extraction (Unprivileged)
Extract your own saved credentials without administrative rights:Scenario 2: Domain-Wide Credential Extraction
As domain admin, extract credentials from all domain workstations:Scenario 3: Targeted User Extraction with Mimikatz
Combine with Mimikatz for targeted user credential extraction:Scenario 4: Remote Credential Extraction with Password
Extract credentials from a remote system using a user’s password:Scenario 5: Chrome 80+ with Pre-Extracted State Key
For Chrome 80+, first extract state keys then use them:Example Output
CSV Format (Default)
Table Format
Detection Considerations
EDR/AV Detection Vectors
-
Process Activity
- SharpChrome.exe spawning and accessing browser SQLite databases
- Unusual access patterns to Login Data files
- Multiple user profile enumeration
-
File Access Patterns
- Reading Login Data files from multiple user profiles
- Accessing Local State files for state key extraction
- Lockless SQLite database access
-
Network Activity
- Remote file access to UNC paths for credential databases
- SMB connections to multiple workstations
- Domain controller communication for RPC decryption
-
API Calls
- CryptUnprotectData API calls
- DPAPI-related LSA functions
- SQLite database operations
OPSEC Recommendations
Log Sources
- Windows Event Logs: Look for DPAPI-related Event IDs (4692-4694)
- Sysmon: File access events to Login Data files (Event ID 11)
- EDR Telemetry: Process creation, file access, and API call monitoring
- Network Logs: SMB traffic patterns indicating lateral credential harvesting
Related Commands
SharpChrome Cookies
Extract and decrypt browser cookies for session hijacking
SharpChrome State Keys
Extract AES state keys for Chrome 80+ decryption
Backup Key Retrieval
Retrieve domain DPAPI backup key from domain controller
SharpChrome Overview
Complete SharpChrome documentation and workflows
Tips and Troubleshooting
Common Issues
No credentials extracted
No credentials extracted
Possible causes:
- Browser hasn’t saved any credentials
- Running as wrong user (credentials are user-specific)
- Chrome 80+ requires state key decryption
- Incorrect decryption method selected
- Verify Login Data file exists and contains data
- Run as the user who saved the credentials
- For Chrome 80+, extract and use state key
- Try alternative decryption methods (/pvk, /password)
CryptUnprotectData fails
CryptUnprotectData fails
Possible causes:
- Not running as the user who encrypted the data
- User profile is unloaded
- DPAPI masterkey not available
- Run in the correct user context
- Use
/pvkwith domain backup key instead - Use extracted GUID:SHA1 masterkeys
- Ensure user is logged in locally
Remote extraction fails
Remote extraction fails
Possible causes:
- No administrative access to remote system
- Firewall blocking SMB/RPC
- Missing decryption key (/pvk or /password not provided)
- Verify local admin rights on remote system
- Check firewall rules for SMB (445) and RPC
- Always use
/pvkor/passwordwith/server
Chrome 80+ credentials show as encrypted
Chrome 80+ credentials show as encrypted
Possible causes:
- State key not automatically decrypted
- Missing AES state key for decryption
- Run
statekeyscommand first to extract state key - Use
/statekeyparameter with extracted key - Ensure DPAPI decryption method is working
Best Practices
Performance Considerations
- Local extraction: Very fast, typically completes in seconds
- Remote extraction: Depends on network latency and number of users
- Lockless access: Browser can remain open during extraction
- Multi-user systems: Processing time scales with number of user profiles