MySql 3306
1. Nmap MySQL Scanning:
2. Bruteforcing MySQL Credentials:
Hydra (for password brute-forcing):
Medusa (alternative to Hydra):
3. Internal MySQL Database Enumeration:
Once you gain access to a MySQL database, you can run the following commands to enumerate users and databases:
List Databases:
Select a Database (example:
textpattern
):List Tables in the Database:
Enumerate Users:
List Specific User Information (e.g., username, email, password):
4. MySQL to System Root:
Refer to the following guide for methods of privilege escalation from MySQL to system root on Linux: Recipe for Root - MySQL to System Root
5. Resetting a MySQL Admin Password:
If you have access to the database and can see the hash of the password for the admin user, you can update the password hash as follows:
Example for WordPress:
Generate an MD5 hash of the new password (
redcliff
in this case):Update the password in the MySQL database (assuming you are using MariaDB/MySQL):
Example for CMS Made Simple 2.2.13:
6. Connecting Remotely to MySQL:
Dedicated Sections for SQL Injection/Privilege Escalation:
Last updated