Created
January 21, 2014 02:24
-
-
Save dave5623/8533417 to your computer and use it in GitHub Desktop.
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 socket | |
numAs = 10 | |
try: | |
while True: | |
# open a connection to vulnserver | |
s = socket.socket (socket.AF_INET, socket.SOCK_STREAM) | |
s.connect (("localhost", 9999)) | |
# receive the banner for vulnserver | |
s.recv (1024) | |
print "[*] Sending " + str(numAs) + " As" | |
# send the number of As to fuzz the HTER command | |
s.send ("HTER " + "A" * numAs + " \r\n") | |
# receive the response from vulnserver | |
s.recv (1024) | |
# close the connection | |
s.close () | |
# increase the number of As we send next time | |
numAs += 10 | |
except: | |
# if we get to here then something happened to vulnserver because the connection is closed | |
print "Socket closed after sending " + str(numAs - 10) + " As" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment