Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python2
- #Intruder Fuzzer Module version 1 - Red Dragon Productions
- from scapy.all import *
- import sys
- import telnetlib
- import string
- import threading
- target = sys.argv[1]
- port = sys.argv[2]
- logfile = sys.argv[3]
- #Setup banner
- def usage():
- print("Intruder v1.1")
- print("")
- print("Usage:")
- print(" ")
- print(" >> python2 intruder.py (host) (port) (logfile)")
- print(" ")
- #Define the response analysis
- def response_analyse(resp,fuzz):
- if "41" in resp:
- ee = hexdump(resp)
- with open(logfile, "a") as myfile:
- myfile.write("Port "+str(port)+" "+"String: "+str(fuzz)+"\n"+str(ee)+"\n")
- print("Potential vuln")
- print(fuzz)
- hexdump(resp)
- if "PATH=" in resp:
- ee = hexdump(resp)
- with open(logfile, "a") as myfile:
- myfile.write("Port "+str(port)+" "+"String: "+str(fuzz)+"\n"+str(ee)+"\n")
- print("Potential vuln")
- print(fuzz)
- hexdump(resp)
- if "segmentation" in resp:
- ee = hexdump(resp)
- with open(logfile, "a") as myfile:
- myfile.write("Port "+str(port)+" "+"String: "+str(fuzz)+"\n"+str(ee)+"\n")
- print("Potential vuln")
- print(fuzz)
- hexdump(resp)
- #Define the engine
- def engine(target,port,command):
- for i in range(1,1000):
- for g in range(1,10):
- gen = ex+" "
- fuzz = str(c[:])+' '+gen*g+'\n'
- tn = telnetlib.Telnet(target,port)
- #tn.read_until("\r\n") # --uncomment for FTP or any command that sends string when you connect
- print("Sending "+fuzz)
- tn.write(fuzz)
- d = tn.read_until("\r\n")
- print(d)
- response_analyse(d,fuzz)
- if "21" == port:
- command = ["USER ","PASS ", "CDUP ","SMNT ","STOU ","XSEN ","XSEM ,","XRSQ ","XRMD ","XRCP ","XPWD ",
- "XMKD ","XCUP ","LANG ","FEAT ","EPSV ","ADAT ","STRU ","STAT ","SIZE ","SITE ","RNTO ","RNFR ","RMD ",
- "RETR ","REST ","PROT ","PBSZ ","OPTS ","NLST ","MLST ","MLSD ","MIC ","LPRT ", "EPRT ","CCC ","RMD ",
- "MKD ","PWD ","SYST ","REIN ","PORT ","PASV ","TYPE","MODE ","RETR", "STOR ","APPE ","ALLO ","REST ","RNFR ",
- "MDTM ","LPSV ","ENC ","CONF ","CDUP "]
- engine(target,port,command)
- elif "110" == port:
- command = ["POP3: ","USER ","PASS ","QUIT ","STAT ","RETR ","DELE ","NOOP ","LAST ","RSET ","TOP ","RPOP "]
- engine(target,port,command)
- elif "80" == port:
- command = ["HTTP: ","GET /","HEAD /","PUT /","TRACE /","DELETE /","LINK /","UNLINK /", "CONNECT","request-header "]
- engine(target,port,command)
- else:
- command = [""]
- engine(target,port,command)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement