diff --git a/discovery/intelxsearch.py b/discovery/intelxsearch.py index 7eb7502e..03d9fb93 100644 --- a/discovery/intelxsearch.py +++ b/discovery/intelxsearch.py @@ -31,6 +31,7 @@ def do_search(self): uuid = r.json()['id'] url = f'{self.database}phonebook/search/result?id={uuid}&offset=0&limit={self.limit}' r = requests.get(url, headers=headers) + time.sleep(1) # to add in future grab status from r.text and check if more results can be gathered if r.status_code != 200: raise Exception('Error occurred while searching intelx.') diff --git a/parsers/intelxparser.py b/parsers/intelxparser.py index 8448ffe9..8d0dbb39 100644 --- a/parsers/intelxparser.py +++ b/parsers/intelxparser.py @@ -16,6 +16,12 @@ def parse_dictionaries(self, results): if '@' in field: self.emails.add(field) else: - self.hosts.add(str(field).replace(')', '')) + field = str(field) + if 'http' in field or 'https' in field: + if field[:5] == 'https': + field = field[8:] + else: + field = field[7:] + self.hosts.add(field.replace(')', '').replace(',', '')) return self.emails, self.hosts return None, None