def do_run(self, command): """ Specs: Run one of the tools by their hyphened name Usage: run [tool-hyphen] """ if len(command) == 0: print("You have not supplied any command, available commands: {}". format(', '.join(TOOL_LIST))) elif command.lower() == "-s": from lib.pointers import run_sqli_scan host = raw_input("Enter a host to scan for SQLi vulnerabilities: ") run_sqli_scan(host) elif command.lower() == "-d": from lib.pointers import run_dork_checker dork = raw_input("Enter a dork to scan with: ") run_dork_checker(dork) elif command.lower() == "-x": from lib.pointers import run_xss_scan host = raw_input("Enter a host to check XSS vulnerabilities on: ") proxy = raw_input("Enter a proxy to user (enter for none): ") user_agent = raw_input( "Enter a user agent to spoof (enter for none): ") if proxy == "": proxy = None if user_agent == "": user_agent = None run_xss_scan(host, proxy=proxy, user_agent=user_agent) elif command.lower() == "-v": from lib.pointers import run_hash_verification h = raw_input("Enter a hash to verify: ") run_hash_verification(h) elif command.lower() == "-h": from lib.pointers import run_hash_cracker h = raw_input("Enter a hash to crack: ") t = raw_input("Enter what type (all for none): ") if t is None or t == "": t = "all" full_data = h + ":" + t run_hash_cracker(full_data) elif command.lower() == "-p": from lib.pointers import run_port_scan host = raw_input("Enter a host to scan open ports on: ") run_port_scan(host) elif command.lower() == "-f": from lib.pointers import run_proxy_finder run_proxy_finder() elif command.lower() == "-hh": self.help_menu() else: print("{}".format(self.help_menu()))
if args.verifyHashFile is not None: run_hash_verification(None, hash_ver_file=args.verifyHashFile) if args.sqliscan is not None: # SQLi scanning run_sqli_scan(args.sqliscan) if args.sqliList is not None: # SQLi file scanning run_sqli_scan(None, url_file=args.sqliList) if args.dorkcheck is not None: # Dork checker, check if your dork isn't shit run_dork_checker(args.dorkcheck, dork_file=args.dorkList, proxy=args.configProxy) if args.dorkList is not None: run_dork_checker(None, dork_file=args.dorkList, proxy=args.configProxy) if args.hash is not None: # Try and crack a hash run_hash_cracker(args.hash) if args.portscan is not None: # Scan a given host for open ports run_port_scan(args.portscan) if args.xssScan is not None: # Scan a URL for XSS vulnerabilities run_xss_scan(args.xssScan, args.configProxy, args.randomUserAgent) if args.xssList is not None: # Run a through a file list for XSS vulns run_xss_scan(None, url_file=args.xssList) except KeyboardInterrupt: # Why you abort me?! :c LOGGER.error("User aborted.")
def do_run(self, command): """ Specs: Run one of the tools by their hyphened name Usage: run [tool-hyphen] """ if len(command) == 0: print("You have not supplied any command, available commands: {}". format(', '.join(TOOL_LIST))) elif command.lower() == "-s" or command.lower().startswith("sqli"): from lib.pointers import run_sqli_scan host = raw_input("Enter a host to scan for SQLi vulnerabilities: ") run_sqli_scan(host) elif command.lower() == "-d" or command.lower().startswith("dork"): from lib.pointers import run_dork_checker dork = raw_input("Enter a dork to scan with: ") run_dork_checker(dork) elif command.lower() == "-x" or command.lower().startswith("xss"): from lib.pointers import run_xss_scan host = raw_input("Enter a host to check XSS vulnerabilities on: ") proxy = raw_input("Enter a proxy to user (enter for none): ") user_agent = raw_input( "Enter a user agent to spoof (enter for none): ") if proxy == "": proxy = None if user_agent == "": user_agent = None run_xss_scan(host, proxy=proxy, user_agent=user_agent) elif command.lower() == "-v" or command.lower().startswith("verify"): from lib.pointers import run_hash_verification h = raw_input("Enter a hash to verify: ") run_hash_verification(h) elif command.lower() == "-h" or command.lower().startswith("crack"): from lib.pointers import run_hash_cracker h = raw_input("Enter a hash to crack: ") t = raw_input("Enter what type (all for none): ") if t is None or t == "": t = "all" full_data = h + ":" + t run_hash_cracker(full_data) elif command.lower() == "-p" or command.lower().startswith("port"): from lib.pointers import run_port_scan host = raw_input("Enter a host to scan open ports on: ") run_port_scan(host) elif command.lower() == "-f" or command.lower().startswith("proxy"): from lib.pointers import run_proxy_finder run_proxy_finder() elif command.lower() == "-hh" or command.lower().startswith("help"): self.help_menu() elif command.lower() == "-u" or command.lower().startswith("update"): update_pybelt() elif command.lower() == "-sl" or command.lower().startswith( "sql list"): from lib.pointers import run_sqli_scan file_path = raw_input("Enter the full path to the SQLi file: ") run_sqli_scan(None, url_file=file_path) elif command.lower() == "-xl" or command.lower().startswith( "xss file"): from lib.pointers import run_xss_scan file_path = raw_input("Enter the full path to the XSS file: ") run_xss_scan(None, url_file=file_path) elif command.lower() == "-vhl" or command.lower().startswith( "verify hash list"): from lib.pointers import run_hash_verification hash_file = raw_input("Enter full path of hash file: ") run_hash_verification(None, hash_file) elif command.lower == "-dl" or command.lower().startswith("dork list"): from lib.pointers import run_dork_checker dork_file_path = raw_input("Enter full path to dork file: ") proxy = raw_input("Enter a proxy (enter for none): ") if proxy is "": proxy = None else: proxy = proxy run_dork_checker(None, dork_file=dork_file_path, proxy=proxy) elif command.lower() == "quit": self.do_quit(None) else: print("{}".format(self.help_menu()))