Created
September 22, 2013 21:01
-
-
Save yesecurity/5fb47f44e289e8bc9c35 to your computer and use it in GitHub Desktop.
SecurityTube WAP_Challenge 7
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import itertools , md5 | |
listp = [] | |
a = list(itertools.product(['x','y','z','1','2','3'], repeat = 6)) | |
for e in a: | |
a = ''.join(e) | |
listp.append(a) | |
nonce = "X95LDujmBAA=9c8ec8a0aeee0ddf7f24a5a75c57d0f90245d0f5" | |
uri = '/' | |
username = "webadmin" | |
method = "GET" | |
nc = "00000001" | |
qop = "auth" | |
cnonce="89b024ea3adb54ec" | |
response = "0fd7c603fdf61e89bfc9c95fb73e343a" | |
realm="Pentester-Academy" | |
for password in listp: | |
h1 = (username+":"+realm+":"+password) | |
ha1 = (md5.md5(h1).hexdigest()) | |
h2 = (method+":"+uri) | |
ha2 = (md5.md5(h2).hexdigest()) | |
resp = (ha1+":"+nonce+":"+nc+":"+cnonce+":"+qop+":"+ha2) | |
response2 = (md5.md5(resp).hexdigest()) | |
if response2 == response: | |
print "Big Thanks To Pentester Academy !" | |
print "Username = webadmin " | |
print "Password = " + password |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment