mirror of
https://github.com/Ekultek/Zeus-Scanner.git
synced 2026-03-11 08:55:51 +00:00
patches an issue where the sitemap and robots.txt would fail if it hit a certain exception (issue #186, #185, #184)
This commit is contained in:
parent
a96a04a3ad
commit
d949240ab8
3 changed files with 21 additions and 9 deletions
|
|
@ -68,7 +68,7 @@ d41d8cd98f00b204e9800998ecf8427e ./lib/attacks/__init__.py
|
|||
5e5bb575014ebe613db6bf671d008cf8 ./lib/attacks/sqlmap_scan/sqlmap_opts.py
|
||||
7bc7a6f3e85651aab3588f087563eded ./lib/attacks/whois_lookup/__init__.py
|
||||
d2846e039fefee741db24dd64f7bd50e ./lib/attacks/whois_lookup/whois.py
|
||||
d2846e039fefee741db24dd64f7bd50e ./lib/attacks/admin_panel_finder/__init__.py
|
||||
adfde297dd0e875164c8f6fa7e72c4ed ./lib/attacks/admin_panel_finder/__init__.py
|
||||
b5cd5e913cc62112776153bdf0f60fa4 ./lib/attacks/xss_scan/__init__.py
|
||||
e9915cc0bc3de60aaf2accfaea77d059 ./lib/attacks/nmap_scan/__init__.py
|
||||
216999fa0e84866d5c1d96d5676034e4 ./lib/attacks/nmap_scan/nmap_opts.py
|
||||
|
|
@ -76,7 +76,7 @@ e9915cc0bc3de60aaf2accfaea77d059 ./lib/attacks/nmap_scan/__init__.py
|
|||
39221756c132732dbdc2b14772dcab11 ./lib/core/common.py
|
||||
4433353fb5c55578391d8b4006191ee8 ./lib/core/errors.py
|
||||
d41d8cd98f00b204e9800998ecf8427e ./lib/core/__init__.py
|
||||
0320e44e0095889a92d2595f0a3428ca ./lib/core/settings.py
|
||||
98a4639068cbc1b2e849bbafe310b3bd ./lib/core/settings.py
|
||||
d3c1663ff908e10dfb2425bf84d80759 ./lib/core/decorators.py
|
||||
9a02e5b913d210350545ac26510a63c9 ./var/search/__init__.py
|
||||
0545ee54ade186681b25d157fb32f350 ./var/search/selenium_search.py
|
||||
|
|
|
|||
|
|
@ -8,6 +8,10 @@ except ImportError: # Python 3
|
|||
from urllib2 import urlopen, HTTPError
|
||||
|
||||
import requests
|
||||
from requests.exceptions import (
|
||||
ConnectionError,
|
||||
TooManyRedirects
|
||||
)
|
||||
|
||||
import lib.core.common
|
||||
import lib.core.settings
|
||||
|
|
@ -33,11 +37,19 @@ def check_for_externals(url, data_sep="-" * 30, **kwargs):
|
|||
lib.core.settings.logger.debug(lib.core.settings.set_color(
|
||||
"currently searching for a '{}'...".format(currently_searching), level=10
|
||||
))
|
||||
url = lib.core.settings.replace_http(url)
|
||||
full_url = "{}{}{}".format("http://", url, currently_searching)
|
||||
conn = requests.get(full_url)
|
||||
data = conn.content
|
||||
code = conn.status_code
|
||||
|
||||
try:
|
||||
url = lib.core.settings.replace_http(url)
|
||||
full_url = "{}{}{}".format("http://", url, currently_searching)
|
||||
conn = requests.get(full_url)
|
||||
data = conn.content
|
||||
code = conn.status_code
|
||||
except (TooManyRedirects, ConnectionError):
|
||||
lib.core.settings.logger.error(lib.core.settings.set_color(
|
||||
"connection to '{}' failed, assuming does not exist and continuing...", level=40
|
||||
))
|
||||
return False
|
||||
|
||||
if code == 404:
|
||||
lib.core.settings.logger.error(lib.core.settings.set_color(
|
||||
"unable to connect to '{}', assuming does not exist and continuing...".format(
|
||||
|
|
|
|||
|
|
@ -46,7 +46,7 @@ CLONE = "https://github.com/ekultek/zeus-scanner.git"
|
|||
ISSUE_LINK = "https://github.com/ekultek/zeus-scanner/issues"
|
||||
|
||||
# current version <major.minor.commit.patch ID>
|
||||
VERSION = "1.3.7.{}".format(PATCH_ID)
|
||||
VERSION = "1.3.8.{}".format(PATCH_ID)
|
||||
|
||||
# colors to output depending on the version
|
||||
VERSION_TYPE_COLORS = {"dev": 33, "stable": 92, "other": 30}
|
||||
|
|
@ -1048,7 +1048,7 @@ def parse_blacklist(dork, path, batch=False):
|
|||
if not question.lower().startswith("y"):
|
||||
lib.core.common.shutdown()
|
||||
else:
|
||||
lib.core.common.prompt(prompt_msg, opts="yN", default="y")
|
||||
lib.core.common.prompt(prompt_msg, opts="yN", default="n")
|
||||
return True
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue