def run(): while True: if len(threads) < int(config['spider']['size']): urls = helper.get_urls(config['spider']['size']) for url in urls: thread = Spider(name='Spiderman', url=url, dumpster=dumpster) thread.start() threads.append(thread) print(url) else: del threads[:]
def execute(**kwargs): print ("+ Searching Exploits for {0}...".format(kwargs["keywords"])) router = Router() if (dict(kwargs).has_key("spider")): router.words = "Exploit" else: router.words = kwargs["keywordsformated"] dict_all_results = router.search_in_bots() if (dict(kwargs).has_key("get")): try: s = Spider() s.run(dict_all_results) except Exception, ex: print "ERROR -> {0}".format(ex.message)
def execute(**kwargs): print("+ Searching Exploits for {0}...".format(kwargs["keywords"])) router = Router() if (dict(kwargs).has_key("spider")): router.words = "Exploit" else: router.words = kwargs["keywordsformated"] dict_all_results = router.search_in_bots() if (dict(kwargs).has_key("get")): try: s = Spider() s.run(dict_all_results) except Exception, ex: print "ERROR -> {0}".format(ex.message)