PHPYUN任意文件上传导致GETSHELL

- AV AC AU C I A
发布: 2025-04-13
修订: 2025-04-13

### 简要描述: 简单到你难以想象,只要网站还可以注册就可以GETSHELL,无视GPC,无视WAF。4.1beta版本,其他版本未测 ### 详细说明: 1.在审计PHPYUN的时候一度对PHPYUN的WAF非常无语,但是在大家都痴迷于寻找SQL注入漏洞的时候,确实忽略了一个很简单的上传漏洞。首先定位到漏洞文件wap/member/model/index.class.php ``` function photo_action(){ if($_POST['submit']){ preg_match('/^(data:\s*image\/(\w+);base64,)/', $_POST['uimage'], $result); $uimage=str_replace($result[1], '', str_replace('#','+',$_POST['uimage'])); $new_file = time().".".$result[2]; if (!file_exists(DATA_PATH."upload/user/".date('Ymd')."/")){ mkdir(DATA_PATH."upload/user/".date('Ymd')."/"); chmod(DATA_PATH."upload/user/".date('Ymd')."/",0777); } $re=file_put_contents(DATA_PATH."upload/user/".date('Ymd')."/".$new_file, base64_decode($uimage)); chmod(DATA_PATH."upload/user/".date('Ymd')."/".$new_file,0777); if($re){ $user=$this->obj->DB_select_once("resume","`uid`='".$this->uid."'","`photo`,`resume_photo`"); if($user['photo']||$user['resume_photo']){ unlink_pic(APP_PATH.$user['photo']); unlink_pic(APP_PATH.$user['resume_photo']); }...

0%
暂无可用Exp或PoC
当前有0条受影响产品信息