### 简要描述:
18号更新了程序 所以我们首当其冲的先来检测检测
### 详细说明:
[<img src="https://images.seebug.org/upload/201406/190303524b963bec4f060ea7c4431eaa17fdb1a3.jpg" alt="1.jpg" width="600" onerror="javascript:errimg(this);">](https://images.seebug.org/upload/201406/190303524b963bec4f060ea7c4431eaa17fdb1a3.jpg)
看见木有有个微信登陆功能
漏洞也出现在这里
无截断 所以不鸡肋
接下来看代码
文件在source\plugin\wechat\wechat.class.php
```
static public function redirect($type) {
global $_G;
$hook = unserialize($_G['setting']['wechatredirect']);
if (!$hook || !in_array($hook['plugin'], $_G['setting']['plugins']['available'])) {
return;
}
include_once DISCUZ_ROOT . 'source/plugin/' . $hook['plugin'] . '/' . $hook['include'];
if (!class_exists($hook['class'], false)) {
return;
}
$class = new $hook['class'];
if (!method_exists($class, $hook['method'])) {
return;
}
$return = $class->$hook['method']($type);
if($return) {
return $return;
}
}
```
对discuz有了解的人都知道它的$_G这个变量
他的$hook怎么来的我就不多说了
if判断了$hook['plugin'] 所以$hook['plugin']必须是'wechat','pcmgr_url_safeguard','mobile'其中一个
至于$hook['include']嘛 你懂得~~~~
unserialize($_G['setting']['wechatredirect'])反序列化
所以我们就要填入序列化的值
[<img src="https://images.seebug.org/upload/201406/19031701d4e9af889441f62d27e656758ff9e192.jpg" alt="2.jpg" width="600" onerror="javascript:errimg(this);">](https://images.seebug.org/upload/201406/19031701d4e9af889441f62d27e656758ff9e192.jpg)
### 漏洞证明:
[<img src="https://images.seebug.org/upload/201406/19031817c374dc0ac17138ff2b9c33fabee3933f.jpg" alt="3.jpg" width="600" onerror="javascript:errimg(this);">](https://images.seebug.org/upload/201406/19031817c374dc0ac17138ff2b9c33fabee3933f.jpg)
暂无评论