MITRE ATT&CK™ Credentials from Password Stores: Credentials from Web Browsers - Technique T1555.003
Theory
Adversaries may acquire credentials from web browsers by reading files specific to the target browser.[1] Web browsers commonly save credentials such as website usernames and passwords so that they do not need to be entered manually in the future. Web browsers typically store the credentials in an encrypted format within a credential store; however, methods exist to extract plaintext credentials from web browsers.
Practice
Firefox
On UNIX-type systems, stored credentials are kept in firefox profile folders such as :
/home/<Username>/.mozilla/firefox/xxxx.default
We may download the entire ~/.mozilla/firefox folder to our attacking machine and use firefox_decrypt to decrypt passwords.
python3firefox_decrypt.py<Victime_ProfileFolder>
On Windows, stored credentials are kept in firefox profile folders such as :
We may download the entire Profiles folder to our attacking machine and use firepwd to decrypt passwords.
# Decryptpythonfirepwd.py-d<Victime_ProfileFolder># Provide user's password (if secrests are encrypted using DPAPI)pythonfirepwd.py-d<Victime_ProfileFolder>-p<Password>
LaZagne
The LaZagne (Python) project is a go-to reference from browser credentials dumping (among other awesome dumping features).
PS>laZagne.exe browsers [-passwordP@ssword!]
LaZagneForensic
Alternatively, the LaZagneForensic (Python) project can be used to decrypt passwords from a linux hosst, using a mounted file system (/tmp/disk).
On UNIX-type systems, stored credentials are kept in Google Chrome profile folders such as :
/home/<Username>/.config/google-chrome/default
We may download the entire Default folder to our attacking machine and use chrome_password_grabber to decrypt passwords. Not that the default script profile folder path should be edited.
pythonchrome.py
On Windows, stored credentials are kept in Google Chrome profile folders such as :