Ejemplo n.º 1
0
 def threads(command):
     print(" ")
     try:
         var.threads = int(tools.arg("Threads: ", "threads ", command))
     except Exception as e:
         print("There was an error while executing.", e)
     print(" ")
Ejemplo n.º 2
0
 def channel(command):
     print(" ")
     try:
         var.channel = int(tools.arg("Channel: ", "channel ", command))
     except Exception as e:
         print("There was an error while executing.", e)
     print(" ")
Ejemplo n.º 3
0
 def size(command):
     print("")
     try:
         var.size = int(tools.arg("Size: ", "size ", command))
     except Exception as e:
         print("There was an error while executing.", e)
     print("")
Ejemplo n.º 4
0
 def load(command):
     print("")
     try:
         from_file = tools.arg("Load from file: ", "load ", command)
         if not path.isfile(from_file):
             raise Exception("File does not exist.")
         else:
             new_list = []
             command_list = []
             for item in open(from_file, "r").read().split("\n"):
                 if item != "":
                     new_list.append(item)
                     if item in ["e", "q", "exit", "quit"]:
                         command_list.append(new_list)
                         new_list = []
                     elif item in [
                             "l4", "l3", "l7", "ble", "arp", "scanner",
                             "server"
                     ]:
                         command_list.append(new_list)
                         new_list = []
                     else:
                         pass
             command_list.append(new_list)
             var.session[1][1] = command_list
             var.session[1][0] = True
             print("Repeating actions...")
     except Exception as ex:
         print("An error occured.", ex)
     print("")
Ejemplo n.º 5
0
 def port(command):
     print("")
     try:
         var.port = [int(tools.arg("Port: ", "port ", command))]
     except Exception as e:
         print("There was an error while executing.", e)
     print("")
Ejemplo n.º 6
0
	def targets(command):
		print("")
		var.target = tools.arg("Targets (Seperated by ', '): ", "targets ", command).split(", ")
		for ip in var.target:
			if "." not in ip:
				print("This IP does not exist.")
		print("")
Ejemplo n.º 7
0
 def port(command):
     print("")
     try:
         var.port = int(tools.arg("Port: ", "port ", command))
     except Exception as ex:
         print("An error occured.", ex)
     print("")
Ejemplo n.º 8
0
	def auto_start(command):
		print(" ")
		try:
			var.autostart = int(tools.arg("Delay for attack to start (in Seconds): ", "auto start ", command))
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 9
0
	def auto_stop(command):
		print(" ")
		try:
			var.autostop = int(tools.arg("Stop the attack after x seconds: ", "auto stop ", command))
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 10
0
	def sleep(command):
		print(" ")
		try:
			var.sleep = float(tools.arg("Delay between each thread: ", "sleep ", command))
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 11
0
	def auto_step(command):
		print(" ")
		try:
			var.autostep = int(tools.arg("Delay for next thread to activate (in Seconds): ", "auto step ", command))
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 12
0
	def interval(command):
		print(" ")
		try:
			var.interval = float(tools.arg("Delay between each packet: ", "interval ", command))
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 13
0
	def st_wait(command):
		print("")
		try:
			var.timeforstress = int(tools.arg("Delay in seconds: ", "st wait ", command))
		except Exception as e:
			print("There was an error while executing.", e)
		print("")
Ejemplo n.º 14
0
	def auto_stop(command):
		print(" ")
		try:
			var.auto_stop = int(tools.arg("Time until auto stop: ", "auto stop ", command))
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 15
0
 def sleep(command):
     print("")
     try:
         var.sleep = int(tools.arg("Delay in seconds: ", "sleep ", command))
     except Exception as e:
         print("There was an error while executing.", e)
     print("")
Ejemplo n.º 16
0
	def targets(command):
		print("")
		var.target = tools.arg("URLS (Seperated by ', '): ", "targets ", command).split(", ")
		for url in var.target:
			if "http" not in url:
				print("%s is a invalid URL." % url)
		print("")
Ejemplo n.º 17
0
	def ports_ip(command):
		print("")
		try:
			psi = tools.arg("IP: ", "ports ip ", command)
			self.portscan(psi)
		except Exception as e:
			print("There was an error while executing.", e)
		print("")
Ejemplo n.º 18
0
	def domain_ip(command):
		print("")
		try:
			zw = (tools.arg("Domain: ", "domain ip ", command).replace("https://", "").replace("http://", ""))
			print(self.hbi(zw))
		except Exception as e:
			print("There was an error while executing.", e)
		print("")
Ejemplo n.º 19
0
 def target(command):
     print("")
     var.target = [
         tools.arg("URL (GET Parameters possible): ", "target ", command)
     ]
     if "http" not in var.target[0]:
         print("This URL is invalid.")
     print("")
Ejemplo n.º 20
0
	def ports_web(command):
		print("")
		try:
			psw = tools.arg("Website: ", "ports web ", command)
			psww = socket.gethostbyname(psw.replace("https://", "").replace("http://", ""))
			self.portscan(psww)
		except Exception as e:
			print("There was an error while executing.", e)
		print("")
Ejemplo n.º 21
0
	def ports(command):
		print("")
		try:
			var.port = tools.arg("Ports (Seperated by ', '): ", "ports ", command).split(", ")
			for port in var.port:
				if isinstance(port, int):
					print("Entered ports cannot be used.")
		except Exception as e:
			print("There was an error while executing.", e)
		print("")
Ejemplo n.º 22
0
 def web(command):
     print(" ")
     try:
         webtoip = tools.arg("Website: ", "web ", command)
         webtoip = webtoip.replace("http://", "")
         webtoip = webtoip.replace("https://", "")
         webtoiptxt = str(socket.gethostbyname(webtoip))
         var.ip = [webtoiptxt]
     except Exception as e:
         print("There was an error while executing.", e)
     print(" ")
Ejemplo n.º 23
0
 def mb(command):
     print(" ")
     try:
         setmb = int(tools.arg("Size of Packet in MB: ", "mb ", command))
         setmb = int(setmb / 0.000001)
         var.message = ("r" * setmb)
         var.rtxt = setmb
         var.messagezw = "r"
     except Exception as e:
         print("There was an error while executing.", e)
     print(" ")
Ejemplo n.º 24
0
	def webs(command):
		print(" ")
		try:
			webtoip = tools.arg("Websites (Seperated by ', '): ", "webs ", command).split(", ")
			for pos, web in enumerate(webtoip):
				webtoip[pos] = web.replace("http://", "")
				webtoip[pos] = webtoip[pos].replace("https://", "")
				webtoip[pos] = str(socket.gethostbyname(webtoip[pos]))
			var.ip = webtoip
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 25
0
 def size(command):
     print(" ")
     try:
         sizezw = int(tools.arg("Size in kb: ", "size ", command))
         if sizezw < 5:
             print("Size needs to be more than 4kb.")
         elif sizezw > 65500:
             print("Size needs to be less than 65500kb.")
         else:
             var.size = sizezw
     except Exception as e:
         print("There was an error while executing.", e)
     print(" ")
Ejemplo n.º 26
0
	def repeat(command):
		print(" ")
		try:
			rtxtzw = var.rtxt
			var.rtxt = int(tools.arg("Repeat message x times: ", "repeat ", command))
			if var.rtxt < 1:
				print("There was an error while executing.")
			else:
				if rtxtzw < var.rtxt:
					var.messagezw = var.message
					var.message = (str(var.message) * int(var.rtxt))
				else:
					var.message = (str(var.messagezw) * int(var.rtxt))
		except Exception as e:
			print("There was an error while executing.", e)
		print(" ")
Ejemplo n.º 27
0
 def record(command):
     print("")
     try:
         to_file = tools.arg("Save to file: ", "record ", command)
         if path.isfile(to_file):
             raise Exception("File already exists.")
         else:
             new_file = open(to_file, "w")
             # new_file.write("# -- Session File")
             new_file.close()
             var.session[0][1] = open(to_file, "a")
             var.session[0][0] = True
             print("")
             print("Recording...")
     except Exception as ex:
         print("An error occured.", ex)
     print("")
Ejemplo n.º 28
0
 def run_shell(self, command):
     print("")
     system(tools.arg("Enter shell command: \033[1;32;0m", ". ", command))
     print("")
Ejemplo n.º 29
0
 def debug(self, command):
     print("")
     eval(tools.arg("Enter debug command: \033[1;32;0m", "$ ", command))
     print("")
Ejemplo n.º 30
0
 def target(command):
     print("")
     var.target = tools.arg("Target: ", "target ", command)
     if "." not in var.target:
         print("This IP does not exist.")
     print("")