### 简要描述: 验证了一处 却没有验证另一处。 已打20140618补丁。 ### 详细说明: ecmall在注册的时候 您输入的邮件地址不正确,请重新输入 >> 返回上一页 是验证了邮件地址是否正确。 可是在 修改email的时候却没有验证。 ``` /** * 修改电子邮箱 * * @author Hyber * @usage none */ function email(){ $user_id = $this->visitor->get('user_id'); if (!IS_POST) { /* 当前位置 */ $this->_curlocal(LANG::get('member_center'), 'index.php?app=member', LANG::get('edit_email')); /* 当前用户中心菜单 */ $this->_curitem('my_profile'); /* 当前所处子菜单 */ $this->_curmenu('edit_email'); $this->import_resource(array( 'script' => 'jquery.plugins/jquery.validate.js', )); $this->display('member.email.html'); } else { $orig_password = $_POST['orig_password']; $email = isset($_POST['email']) ? trim($_POST['email']) : ''; if (!$email) { $this->show_warning('email_required'); return; } /* 原始密码校对 */ $model_user =& m('member'); $profile = $model_user->find(intval($user_id)); $profile = current($profile); if (md5($orig_password) != $profile['password']) { $this->show_warning('orig_pass_not_right'); return; } $data = array( 'email'...
### 简要描述: 验证了一处 却没有验证另一处。 已打20140618补丁。 ### 详细说明: ecmall在注册的时候 您输入的邮件地址不正确,请重新输入 >> 返回上一页 是验证了邮件地址是否正确。 可是在 修改email的时候却没有验证。 ``` /** * 修改电子邮箱 * * @author Hyber * @usage none */ function email(){ $user_id = $this->visitor->get('user_id'); if (!IS_POST) { /* 当前位置 */ $this->_curlocal(LANG::get('member_center'), 'index.php?app=member', LANG::get('edit_email')); /* 当前用户中心菜单 */ $this->_curitem('my_profile'); /* 当前所处子菜单 */ $this->_curmenu('edit_email'); $this->import_resource(array( 'script' => 'jquery.plugins/jquery.validate.js', )); $this->display('member.email.html'); } else { $orig_password = $_POST['orig_password']; $email = isset($_POST['email']) ? trim($_POST['email']) : ''; if (!$email) { $this->show_warning('email_required'); return; } /* 原始密码校对 */ $model_user =& m('member'); $profile = $model_user->find(intval($user_id)); $profile = current($profile); if (md5($orig_password) != $profile['password']) { $this->show_warning('orig_pass_not_right'); return; } $data = array( 'email' => $email, ); $model_user->edit($user_id , $data); ``` 修改email的时候没有验证 且函数内也没有验证。 [<img src="https://images.seebug.org/upload/201406/281109204381bd77187684ef67134dfd1ad4389a.jpg" alt="[OKDX~Q$V9$DAU)RW%OF]BT.jpg" width="600" onerror="javascript:errimg(this);">](https://images.seebug.org/upload/201406/281109204381bd77187684ef67134dfd1ad4389a.jpg) 看似验证了 直接提交一下看看。 [<img src="https://images.seebug.org/upload/201406/28111015f93d07db1a4d7caccf01bc392fd96e83.jpg" alt="@QR7VMG`(PK4R4}12V4I89V.jpg" width="600" onerror="javascript:errimg(this);">](https://images.seebug.org/upload/201406/28111015f93d07db1a4d7caccf01bc392fd96e83.jpg) 修改成功。。 找出库的地方。 (出库的地方太多了) [<img src="https://images.seebug.org/upload/201406/221641074a311bde8bf66bb5b14143e9a8037ad4.jpg" alt="e4.jpg" width="600" onerror="javascript:errimg(this);">](https://images.seebug.org/upload/201406/221641074a311bde8bf66bb5b14143e9a8037ad4.jpg) ### 漏洞证明: [<img src="https://images.seebug.org/upload/201406/221641074a311bde8bf66bb5b14143e9a8037ad4.jpg" alt="e4.jpg" width="600" onerror="javascript:errimg(this);">](https://images.seebug.org/upload/201406/221641074a311bde8bf66bb5b14143e9a8037ad4.jpg)