mirror of
https://github.com/laramies/theHarvester.git
synced 2025-02-25 23:13:24 +08:00
Fix dogpile from crashing theharvester.py
This commit is contained in:
parent
b6f250baeb
commit
995568177f
1 changed files with 6 additions and 3 deletions
|
@ -17,14 +17,17 @@ def __init__(self, word, limit):
|
|||
|
||||
def do_search(self):
|
||||
# Dogpile is hardcoded to return 10 results.
|
||||
url = 'http://' + self.server + "/search/web?qsi=" + str(self.counter) \
|
||||
url = 'https://' + self.server + "/search/web?qsi=" + str(self.counter) \
|
||||
+ "&q=\"%40" + self.word + "\""
|
||||
headers = {
|
||||
'Host': self.hostname,
|
||||
'User-agent': Core.get_user_agent()
|
||||
}
|
||||
h = requests.get(url=url, headers=headers)
|
||||
self.total_results += h.text
|
||||
try:
|
||||
h = requests.get(url=url, headers=headers)
|
||||
self.total_results += h.text
|
||||
except requests.exceptions.ConnectionError:
|
||||
pass
|
||||
|
||||
def process(self):
|
||||
while self.counter <= self.limit and self.counter <= 1000:
|
||||
|
|
Loading…
Reference in a new issue