From b41b07ddd81613c8aee75b4a9b24a71d793b35d6 Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Fri, 27 May 2016 11:02:05 +0200 Subject: [PATCH] Updates for 360 and jiasule WAF scripts --- lib/core/settings.py | 2 +- waf/360.py | 3 ++- waf/jiasule.py | 4 +++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/core/settings.py b/lib/core/settings.py index a8ce362fd..b498576d7 100644 --- a/lib/core/settings.py +++ b/lib/core/settings.py @@ -19,7 +19,7 @@ from lib.core.enums import OS from lib.core.revision import getRevisionNumber # sqlmap version (...) -VERSION = "1.0.5.80" +VERSION = "1.0.5.82" REVISION = getRevisionNumber() STABLE = VERSION.count('.') <= 2 VERSION_STRING = "sqlmap/%s#%s" % (VERSION, "stable" if STABLE else "dev") diff --git a/waf/360.py b/waf/360.py index f14814b9b..bc6918763 100644 --- a/waf/360.py +++ b/waf/360.py @@ -15,8 +15,9 @@ def detect(get_page): retval = False for vector in WAF_ATTACK_VECTORS: - _, headers, _ = get_page(get=vector) + page, headers, code = get_page(get=vector) retval = re.search(r"wangzhan\.360\.cn", headers.get("X-Powered-By-360wzb", ""), re.I) is not None + retval |= code == 493 and "/wzws-waf-cgi/" in (page or "") if retval: break diff --git a/waf/jiasule.py b/waf/jiasule.py index ecafcc986..631d08e30 100644 --- a/waf/jiasule.py +++ b/waf/jiasule.py @@ -16,10 +16,12 @@ def detect(get_page): retval = False for vector in WAF_ATTACK_VECTORS: - page, headers, _ = get_page(get=vector) + page, headers, code = get_page(get=vector) retval = re.search(r"jiasule-WAF", headers.get(HTTP_HEADER.SERVER, ""), re.I) is not None retval |= re.search(r"__jsluid=", headers.get(HTTP_HEADER.SET_COOKIE, ""), re.I) is not None + retval |= re.search(r"jsl_tracking", headers.get(HTTP_HEADER.SET_COOKIE, ""), re.I) is not None retval |= re.search(r"static\.jiasule\.com/static/js/http_error\.js", page, re.I) is not None + retval |= code == 403 and "notice-jiasule" in (page or "") if retval: break