IceBB开源论坛系统含有$username参数SQL注入漏洞
受影响系统:
XAOS Interactive IceBB <= 1.0-RC9.2
不受影响系统:
XAOS Interactive IceBB 1.0-rc9.3
描述:
IceBB是一个基于PHP+Mysql的开源论坛系统。
IceBB的modules/members.php文件没有正确地验证对username参数的输入便用在了SQL查询中:
$fleh = $icebb->input; <==
...
foreach($fleh as $k => $g)
{
...
$where_clauses[] = "{$k}='{$g}'"; <==
...
}
...
$this->qwhere = implode(' AND ',$where_clauses);
$total = $db->fetch_result("SELECT COUNT(*) as total FROM icebb_users{$this->qwhere}{$qextra}"); <==
这个查询中可以包含有更多的GET/POST输入,如$username和$url。如果设置username=\的话,则之后的句法会成为字符串的一部分,而下一个引号开始($url之前)会成为SQL。例如,
# GET /index.php?act=members&username=a\&url=OR+1#
会变为
# "SELECT COUNT(*) as total FROM icebb_users WHERE user_group='a\' AND username='OR 1#' AND id!=0 ORDER BY username ASC"
因此远程攻击者可以通过$username参数执行SQL注入攻击。
厂商补丁:
XAOS Interactive
----------------
目前厂商已经发布了升级补丁以修复这个安全问题,请到厂商的主页下载:
http://icebb.net/
Posted in : by : YullinJuly 31, 20080 CommentsTag : 漏洞, sql, 注入, 论坛, Ubuntu Linux