Shared Server (ine)
In this lab, we are given access to a server which is being used as a place for web app developer students to serve their projects.
Knowing the purpose of the compromised machine, we navigate to the /var/www/html directory and start to enumerate sensitive strings.
It is always a good idea to have a look on the system for strings such as:
password
username
db_username
db_password
db_user
db_pass
passwd
This can be done in various ways - I like to color the discovered strings in red. The command I used to find the creds on this box is:
find . -type f -exec grep --color=auto -ie "db_password" --color=always {} /dev/null \;
It was logical to next have a look inside the file of interest.
Now it was a simple matter to check for password reuse.
This lab shows us the importance of enumerating sensitive strings and checking for easy wins such as password reuse.
The web-root directory and its child directories are a good place to look for sensitive creds being leaked.
I hope this was of use.
puzz00