漏洞概要 关注数(24) 关注此漏洞
缺陷编号:wooyun-2015-0104337
漏洞标题:某政府建站系统通用型漏洞打包
相关厂商:宁夏电通物联网技术有限公司
漏洞作者: 路人甲
提交时间:2015-03-30 17:42
修复时间:2015-07-02 15:36
公开时间:2015-07-02 15:36
漏洞类型:文件上传导致任意代码执行
危害等级:高
自评Rank:20
漏洞状态:已交由第三方合作机构(cncert国家互联网应急中心)处理
漏洞来源: http://www.wooyun.org,如有疑问或需要帮助请联系 [email protected]
Tags标签: 无
漏洞详情
披露状态:
2015-03-30: 细节已通知厂商并且等待厂商处理中
2015-04-03: 厂商已经确认,细节仅向厂商公开
2015-04-06: 细节向第三方安全合作伙伴开放
2015-05-28: 细节向核心白帽子及相关领域专家公开
2015-06-07: 细节向普通白帽子公开
2015-06-17: 细节向实习白帽子公开
2015-07-02: 细节向公众公开
简要描述:
1#任意文件上传
2#目录浏览+SVN/CVS泄漏
3#大量管理页面未授权访问
详细说明:
首先这个厂商有前人提过的一个漏洞, WooYun: 某通用型政府建站系统由一个越权页面+恶意修改导致网站瞬间出错 ,文中提到存在越权的页面为
http://www.cn-dt.com.cn/cms/template/templateList.jsp
其实不止是该页面,通过系统的目录浏览,我们能发现更多的问题
以官网为例
2#目录浏览(非所有案例都存在,大部分)
http://www.cn-dt.com.cn//common/
http://www.cn-dt.com.cn/cms/
http://www.cn-dt.com.cn/extfile/
http://www.cn-dt.com.cn/conf/
http://www.cn-dt.com.cn/stat/
3#大量管理页面未授权访问
也就是说只要你猜得到目录名,目录底下的所有文件你都可以尝试是否存在越权访问
我举几个明显的例子(非所有案例都存在,大部分)
http://www.cn-dt.com.cn/stat/leftbar.jsp
http://www.cn-dt.com.cn/conf/ConfInputList.jsp#
http://www.cn-dt.com.cn/conf/leftbar.jsp
http://www.cn-dt.com.cn/conf/mqueryDetail.jsp?link=cms_td_info_history
http://www.cn-dt.com.cn/common/acc/leftbar.jsp
其实说白了就是根据 leftbar.jsp里的导航地址与主体地址一个个去尝试
1#任意文件上传
在该系统中我发现了CVS信息,在浏览http://www.cn-dt.com.cn/common/sweditor/时,我发现目录没有出来,我就http://www.cn-dt.com.cn/common/sweditor/CVS/Entries
然后我就发现了这个
http://www.cn-dt.com.cn/common/sweditor/ewebeditor.htm
一直不懂为什么高版本的ie打不开上传窗口.....换ie6
打开后和我想的完全不一样啊。目前看来是官网做了限制,我们试试在非官网上获取到的上传点http://jsgl.nxsl.gov.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
抓包修改文件后缀之后,得到POC
http://www.cn-dt.com.cn/extfile/20150327/2015032710354433.jsp
上传个一句话http://www.cn-dt.com.cn:80/extfile/20150327/2015032710373033.jsp
为了不引起厂商滴警觉,我把jsp删除了~
上传直接用poc更快
以下几个案例供复现
宁夏建筑业信用网
http://61.133.208.18:8085/CVS/
http://61.133.208.18:8085/cms/
http://61.133.208.18:8085/common/toHtmlEdit.do?fld=icontent&mode=&id=
一句话地址http://61.133.208.18:8085/extfile/20150327/2015032710593833.jsp
密码woo11yun
在测试这个站的时候,我又发现了一处上传点,但该点官网已做了处理,不明白为何修复的补丁没有全部下发(该上传点少数站有效)
http://*/common/bas/uploadfile.jsp?mode=start
抓包,修改上传后的文件名newfilename,
http://61.133.208.18:8085/extfile/20150327/2010361252-wooyun.jsp
还有以下案例:
http://jsgl.nxsl.gov.cn/CVS/
http://jsgl.nxsl.gov.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
利用poc
http://jsgl.nxsl.gov.cn/extfile/20150327/2015032711234333.jsp
http://www.nxzj.org.cn/common
http://www.nxzj.org.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
http://www.nxzj.org.cn/extfile/20150327/2015032711332933.jsp
http://12366.nxds.gov.cn/common
http://12366.nxds.gov.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
http://12366.nxds.gov.cn:80/common/sweditor/uploadfile/2015032711330133.jsp
http://www.nxnc.gov.cn/common/CVS/Entries
http://www.nxnc.gov.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
http://www.nxnc.gov.cn:80/common/sweditor/uploadfile/2015032711473333.jsp
http://www.nxgczl.com.cn/common/CVS/Entries
http://www.nxgczl.com.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
http://www.nxgczl.com.cn/common/sweditor/uploadfile/2015032710452933.jsp
http://www.nxzb.com.cn//common/CVS/Entries
http://www.nxzb.com.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
http://www.nxzb.com.cn:80/extfile/20150327/2015032710501333.jsp
http://gxj.yinchuan.gov.cn/common/CVS/Entries
http://gxj.yinchuan.gov.cn//common/toHtmlEdit.do?fld=icontent&mode=&id=
http://gxj.yinchuan.gov.cn:80/extfile/20150328/2015032812105733.jsp
http://dfz.yinchuan.gov.cn/common/CVS/Entries
http://dfz.yinchuan.gov.cn/common/toHtmlEdit.do?fld=icontent&mode=&id=
http://dfz.yinchuan.gov.cn:80/extfile/20150328/2015032812163733.jsp
漏洞证明:
http://dfz.yinchuan.gov.cn:80/extfile/20150328/2015032812163733.jsp
http://gxj.yinchuan.gov.cn:80/extfile/20150328/2015032812105733.jsp
http://www.nxzb.com.cn:80/extfile/20150327/2015032710501333.jsp
http://www.nxgczl.com.cn/common/sweditor/uploadfile/2015032710452933.jsp
http://www.nxnc.gov.cn:80/common/sweditor/uploadfile/2015032711473333.jsp
http://12366.nxds.gov.cn:80/common/sweditor/uploadfile/2015032711330133.jsp
修复方案:
删除不正确的SVN、CVS配置
控制权限
上传点过滤
版权声明:转载请注明来源 路人甲@乌云
漏洞回应
厂商回应:
危害等级:高
漏洞Rank:17
确认时间:2015-04-03 15:35
厂商回复:
CNVD确认并复现所述情况,已经转由CNCERT下发给宁夏分中心,由其后续协调网站管理单位处置。
最新状态:
暂无