From 52089f5761483a0e442229e2c90e317b2e0122fe Mon Sep 17 00:00:00 2001 From: Stephan Gross Date: Mon, 25 Sep 2017 04:47:17 +0300 Subject: [PATCH 1/2] Fix issue #108 local variable 'links' referenced before assignment, and apply similar fix to functions with similar issue --- sublist3r.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sublist3r.py b/sublist3r.py index e3aeeb3..52c8ecf 100755 --- a/sublist3r.py +++ b/sublist3r.py @@ -278,6 +278,7 @@ class GoogleEnum(enumratorBaseThreaded): return def extract_domains(self, resp): + links_list = list() link_regx = re.compile('(.*?)<\/cite>') try: links_list = link_regx.findall(resp) @@ -378,6 +379,7 @@ class AskEnum(enumratorBaseThreaded): return def extract_domains(self, resp): + links_list = list() link_regx = re.compile('

(.*?)

') try: links_list = link_regx.findall(resp) @@ -421,6 +423,7 @@ class BingEnum(enumratorBaseThreaded): return def extract_domains(self, resp): + links_list = list() link_regx = re.compile('
  • (.*?)') @@ -565,6 +569,7 @@ class NetcraftEnum(enumratorBaseThreaded): url = self.get_next(resp) def extract_domains(self, resp): + links_list = list() link_regx = re.compile('') try: links_list = link_regx.findall(resp) From da4b3fa6eb9ccb186f6f286a64212d6ad8d58074 Mon Sep 17 00:00:00 2001 From: Stephan Gross Date: Mon, 25 Sep 2017 06:41:14 +0300 Subject: [PATCH 2/2] Fix issue #114 argument of type 'int' is not iterable in function check_response_errors --- sublist3r.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sublist3r.py b/sublist3r.py index 52c8ecf..1efdf0e 100755 --- a/sublist3r.py +++ b/sublist3r.py @@ -296,7 +296,7 @@ class GoogleEnum(enumratorBaseThreaded): return links_list def check_response_errors(self, resp): - if 'Our systems have detected unusual traffic' in resp: + if isinstance(resp, basestring) and 'Our systems have detected unusual traffic' in resp: self.print_(R + "[!] Error: Google probably now is blocking our requests" + W) self.print_(R + "[~] Finished now the Google Enumeration ..." + W) return False