### 简要描述: ThinkSNS某功能缺陷可导致用户上传的身份证信息泄漏。 ### 详细说明: 问题发生在 /apps/public/Lib/Action/AccountAction.class.php 行483 ``` public function doAuthenticate(){ .... $data['attach_id'] = t($_POST['attach_ids']); ``` 这里附件ID 是通过post方式传递的 意味着主要修改为别人附件ID 岂不是?? 附件可是有用户认证的身份证。遍历一遍 呵呵 其实导致这个问题还有很多地方。这里我就不一一列举了!你们自己revrew一下把 ### 漏洞证明: 接着看展示的地方 393行 ``` public function authenticate(){ $auType = model('UserGroup')->where('is_authenticate=1')->findall(); $this->assign('auType', $auType); $verifyInfo = D('user_verified')->where('uid='.$this->mid)->find(); if($verifyInfo['attach_id']){ $a = explode('|', $verifyInfo['attach_id']); foreach($a as $key=>$val){ if($val !== "") { $attachInfo = D('attach')->where("attach_id=$a[$key]")->find(); $verifyInfo['attachment'] .= $attachInfo['name'].' <a href="'.getImageUrl($attachInfo['save_path'].$attachInfo['save_name']).'" target="_blank">下载</a><br />'; } } } ``` 接把ID解开 查询出来 看看字段大小!attach_idvarchar(255) 一次遍历50个ID还是可以的
### 简要描述: ThinkSNS某功能缺陷可导致用户上传的身份证信息泄漏。 ### 详细说明: 问题发生在 /apps/public/Lib/Action/AccountAction.class.php 行483 ``` public function doAuthenticate(){ .... $data['attach_id'] = t($_POST['attach_ids']); ``` 这里附件ID 是通过post方式传递的 意味着主要修改为别人附件ID 岂不是?? 附件可是有用户认证的身份证。遍历一遍 呵呵 其实导致这个问题还有很多地方。这里我就不一一列举了!你们自己revrew一下把 ### 漏洞证明: 接着看展示的地方 393行 ``` public function authenticate(){ $auType = model('UserGroup')->where('is_authenticate=1')->findall(); $this->assign('auType', $auType); $verifyInfo = D('user_verified')->where('uid='.$this->mid)->find(); if($verifyInfo['attach_id']){ $a = explode('|', $verifyInfo['attach_id']); foreach($a as $key=>$val){ if($val !== "") { $attachInfo = D('attach')->where("attach_id=$a[$key]")->find(); $verifyInfo['attachment'] .= $attachInfo['name'].' <a href="'.getImageUrl($attachInfo['save_path'].$attachInfo['save_name']).'" target="_blank">下载</a><br />'; } } } ``` 接把ID解开 查询出来 看看字段大小!attach_idvarchar(255) 一次遍历50个ID还是可以的