From 073361339b42d1a60ba1854a0d0487e74c854f48 Mon Sep 17 00:00:00 2001 From: ekultek Date: Sat, 28 Oct 2017 08:25:13 -0500 Subject: [PATCH] bumped the version number and edited the checksums to match the new updates --- etc/checksum/md5sum.md5 | 10 +++++----- lib/core/settings.py | 31 +++++++++++++++++++------------ 2 files changed, 24 insertions(+), 17 deletions(-) diff --git a/etc/checksum/md5sum.md5 b/etc/checksum/md5sum.md5 index 0efc05d..d4890b3 100644 --- a/etc/checksum/md5sum.md5 +++ b/etc/checksum/md5sum.md5 @@ -7,8 +7,8 @@ 66b11aa388ea909de7b212341259a318 ./etc/auths/git_auth 8f686b05c5c5dfc02f0fcaa7ebc8677c ./etc/auths/whois_auth 82cc68f46539d0255f7ce14cd86cd49b ./etc/link_ext.txt -75b485c7a5c6daa22a65794da4109ddc ./etc/dorks.txt -24783774ac3282a3169e35a4ac713b40 ./etc/xss_payloads.txt +a3ee2d4610056c6fe270c2a74dda49f9 ./etc/dorks.txt +b34aacdcb683a2de649c002601f53746 ./etc/xss_payloads.txt d41d8cd98f00b204e9800998ecf8427e ./bin/__init__.py a19ac607db04a68fdbfc81d6c5a000d1 ./bin/unzip_gecko.py dc1eb4ebe0f372af48b5a9c107ebc68d ./bin/drivers/geckodriver-v0.18.0-linux32.tar.gz @@ -36,14 +36,14 @@ d93cf7cdeabe951251f2f4d56687b5f4 ./lib/attacks/sqlmap_scan/__init__.py 5e5bb575014ebe613db6bf671d008cf8 ./lib/attacks/sqlmap_scan/sqlmap_opts.py d41d8cd98f00b204e9800998ecf8427e ./lib/attacks/whois_lookup/__init__.py f27322b9716e1a2b0b0b0487f3149474 ./lib/attacks/whois_lookup/whois.py -2782c48ef762413f0e7ce7392786ce2d ./lib/attacks/admin_panel_finder/__init__.py +08fea2a989329d26774e60b7de3cf07e ./lib/attacks/admin_panel_finder/__init__.py 23c1e5e934029f9acc89d2c95e7748e7 ./lib/attacks/xss_scan/__init__.py 27358f26bda30d7356143c3ea1fa99c5 ./lib/attacks/nmap_scan/__init__.py 216999fa0e84866d5c1d96d5676034e4 ./lib/attacks/nmap_scan/nmap_opts.py -c5ebb0c56c9ae3b9a72a14e3f05afa16 ./lib/attacks/intel_me/__init__.py +f746d2867f493104a78d0540cf50c03f ./lib/attacks/intel_me/__init__.py 1faa2b5dfad6eb538bbfe42942d2a9da ./lib/core/errors.py d41d8cd98f00b204e9800998ecf8427e ./lib/core/__init__.py -d68e0285c6d17335a6f4abeefb689c5c ./lib/core/settings.py +e55e818edff971d82f89e4dbfec1760f ./lib/core/settings.py d41d8cd98f00b204e9800998ecf8427e ./var/google_search/__init__.py b92ee17da90b17a0abb4e07e24fca3e1 ./var/google_search/search.py d41d8cd98f00b204e9800998ecf8427e ./var/__init__.py diff --git a/lib/core/settings.py b/lib/core/settings.py index 266f307..31bd2ba 100644 --- a/lib/core/settings.py +++ b/lib/core/settings.py @@ -19,6 +19,7 @@ except ImportError: import psutil import requests +from lxml import etree import bin.unzip_gecko import lib.core.errors @@ -36,7 +37,7 @@ PATCH_ID = str(subprocess.check_output(["git", "rev-parse", "origin/master"]))[: # clone link CLONE = "https://github.com/ekultek/zeus-scanner.git" # current version -VERSION = "1.1.2.{}".format(PATCH_ID) +VERSION = "1.1.3".format(PATCH_ID) # colors to output depending on the version VERSION_TYPE_COLORS = {"dev": 33, "stable": 92, "other": 30} # version string formatting @@ -79,6 +80,8 @@ LAUNCH_SQLMAP_API_TOOL = "{}/etc/scripts/launch_sqlmap_api.sh".format(os.getcwd( NMAP_INSTALLER_TOOL = "{}/etc/scripts/install_nmap.sh".format(os.getcwd()) # paths to sqlmap and nmap TOOL_PATHS = "{}/bin/paths/path_config.ini".format(os.getcwd()) +# path to the sitemap log file +SITEMAP_FILE_LOG_PATH = "{}/log/sitemap-log".format(os.getcwd()) # log path to the whois results WHOIS_RESULTS_LOG_PATH = "{}/log/whois".format(os.getcwd()) # path to store robot.txt page in @@ -447,18 +450,22 @@ def write_to_log_file(data_to_write, path, filename): ))) + 1) ) with open(full_file_path, "a+") as log: - if isinstance(data_to_write, list): - for item in data_to_write: - item = item.strip() - log.write(str(item) + "\n") - elif isinstance(data_to_write, (tuple, set)): - for item in list(data_to_write): - item = item.strip() - log.write(str(item) + "\n") - elif isinstance(data_to_write, dict): - json.dump(data_to_write, log, sort_keys=True, indent=4) + data = re.sub(r'\s+', '', log.read()) + if re.match(r'^<.+>$', data): + log.write(etree.tostring(data_to_write, pretty_print=True)) else: - log.write(data_to_write + "\n") + if isinstance(data_to_write, list): + for item in data_to_write: + item = item.strip() + log.write(str(item) + "\n") + elif isinstance(data_to_write, (tuple, set)): + for item in list(data_to_write): + item = item.strip() + log.write(str(item) + "\n") + elif isinstance(data_to_write, dict): + json.dump(data_to_write, log, sort_keys=True, indent=4) + else: + log.write(data_to_write + "\n") logger.info(set_color( "successfully wrote found items to '{}'...".format(full_file_path) ))