ID | Name |
---|---|
T2039.001 | Bash History |
T2039.002 | Credentials In Files |
T2039.003 | Private Keys |
T2039.004 | VPN Credential |
Adversaries may search the bash command history on compromised systems for insecurely stored credentials. Bash keeps track of the commands users type on the command-line with the "history" utility. Once a user logs out, the history is flushed to the user’s .bash_history
file. For each user, this file resides at the same location: ~/.bash_history
. Typically, this file keeps track of the user’s last 500 commands. Users often type usernames and passwords on the command-line as parameters to programs, which then get saved to this file when they log out. Adversaries can abuse this by looking through the file for potential credentials.
This type of attack technique cannot be easily mitigated with preventive controls since it is based on the abuse of system features.