The browser refreshed. Instead of the login screen, a wall of text appeared—the server's /etc/passwd file. He was in. But LFI wasn't enough; he needed a shell. He remembered a specific trick from the HackTricks documentation
Before exploiting, you must identify the version and configuration. Often listed on the login page.
Once inside phpMyAdmin (with any user-level access), the attack escalates rapidly.
. From here, they can download tools, pivot through the internal network, or escalate privileges to Summary of the HackTricks "Verified" Checklist: Check Credentials: Test defaults like authentication. Verify Permissions: privileges are enabled for the current user. Find the Path: command to find where the website files are stored. Write the shell and take control. phpmyadmin hacktricks verified
If the MySQL user has the FILE privilege and you know the absolute path of the webroot, you can write a PHP shell directly to the server.
SHOW VARIABLES LIKE 'secure_file_priv';
In phpMyAdmin 4.8.0–4.8.4, an LFI vulnerability allowed attackers to read arbitrary files without logging in. The browser refreshed
auxiliary/scanner/http/phpmyadmin_login (still reliable)
Hunt for wp_users (WordPress) or users tables to dump hashes for other services.
Requires plugin directory write access. Most shared hosting disables this. But LFI wasn't enough; he needed a shell
Look for publicly accessible setup or documentation files. Check paths like /README , /ChangeLog , or /Documentation.html .
The application uses a whitelist check for the page parameter but fails to properly sanitize input before processing it through include . Verification Payload:
MySQL 5.x, MariaDB 10.x.