========================================
Beating so called "secured" PMA servers
By: Ian Cummings aka d2mmn
=======================================
iNLiZE CreW
=======================================
Say we come across a site running phpmyadmin with default user. We get inside, and click PHP-Information, and we get a 421 error. Or perhaps PHP-Information isn't even present. Lets see if we can get around that. Click on "Databases". Then once the screen loads click the "Variables" tab on top. Scroll down a little ways until you come across this line:
basedir:
Here it tells us where the mysql is running (ex. basedir c:\wamp\mysql\) Now, lets say we wanted to exploit this. Our only reason to gather the directory of PMA is to write our shell to a .php file. So lets take a couple guesses:
c:\wamp\phpmyadmin\
c:\wamp\www\phpmyadmin\
We use those directories when trying to write our shell, and we get success! A little bit of luck and guessing and we are in. This will not work on all PMA's and probably won't work on many. However, just another vulnerability involved if you leave your PMA with default root user.
-d2
p.s. Sorry if this is in the wrong forum, wasn't exactly sure where to put it.