PHPCMS网站管理系统adsclass.php页面过滤不严导致SQL注入漏洞

影响版本:
phpcms2008sp4_UTF8_100510

程序介绍:

Phpcms是一款基于 PHP+Mysql 架构的网站内容管理系统,也是一个开源的 PHP 开发平台。Phpcms 采用模块化方式开发,功能易用便于扩展,可面向大中型站点提供重量级网站建设解决方案。3年来,凭借 Phpcms 团队长期积累的丰富的Web开发及数据库经验和勇于创新追求完美的设计理念,使得 Phpcms 得到了近10万网站的认可,并且越来越多地被应用到大中型商业网站

漏洞分析:

 

ads\include\ads.class.php
function edit($ads, $adsid, $username = ”)  //110行
{
if(!$this->check_form($ads)) return FALSE;
$ads = $this->check_form($ads);
if(defined(‘IN_ADMIN’))
{
$ads[‘fromdate’] = strtotime($ads[‘fromdate’]);
$ads[‘todate’] = strtotime($ads[‘todate’]);
}
$this->adsid = $adsid;
$where = ‘ adsid=’.$this->adsid;
if($username) $where .= " AND username=’$username’";
 
return $this->db->update($this->table, $ads, $where);
}
 
Ads\member.php
if(!$c_ads->edit($info, $adsid, $_username)) showmessage($c_ads->msg(), ‘goback’);  //47行

变量$adsid没有经过处理就直接进入SQL查询,造成SQL注入。 

漏洞利用:

 

1、注册普通会员

2、 预定广告并修改adsid值从而进行SQL注入

解决方案:
厂商补丁:
PHPCMS
——-
目前厂商还没有提供补丁或者升级程序,我们建议使用此软件的用户随时关注厂商的主页以获取最新版本:
http://www.phpcms.cn/

信息来源:
<来源: Bug.Center.Team
链接:
http://wavdb.com/vuln/1641>

发表评论?

0 条评论。

发表评论