From e7aaea2b8eac8680a737416b5df059a4ac9a4630 Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Tue, 17 May 2016 14:10:49 +0200 Subject: [PATCH] Update for an Issue #1826 --- lib/core/agent.py | 2 +- lib/core/common.py | 2 +- lib/core/settings.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/core/agent.py b/lib/core/agent.py index 426d7f6ca..ab97cf07a 100644 --- a/lib/core/agent.py +++ b/lib/core/agent.py @@ -168,7 +168,7 @@ class Agent(object): retVal = retVal.replace(CUSTOM_INJECTION_MARK_CHAR, "").replace(REPLACEMENT_MARKER, CUSTOM_INJECTION_MARK_CHAR) elif BOUNDED_INJECTION_MARKER in paramDict[parameter]: _ = "%s%s" % (origValue, BOUNDED_INJECTION_MARKER) - retVal = "%s=%s" % (re.sub(r" \#\d\*\Z", "", parameter), paramString.replace(_, self.addPayloadDelimiters(newValue))) + retVal = "%s=%s" % (re.sub(r" (\#\d\*|\(.+\))\Z", "", parameter), paramString.replace(_, self.addPayloadDelimiters(newValue))) elif place in (PLACE.USER_AGENT, PLACE.REFERER, PLACE.HOST): retVal = paramString.replace(origValue, self.addPayloadDelimiters(newValue)) else: diff --git a/lib/core/common.py b/lib/core/common.py index 63293d55c..0b78274e0 100644 --- a/lib/core/common.py +++ b/lib/core/common.py @@ -623,7 +623,7 @@ def paramToDict(place, parameters=None): current[key] = "%s%s" % (str(value).lower(), BOUNDED_INJECTION_MARKER) else: current[key] = "%s%s" % (value, BOUNDED_INJECTION_MARKER) - candidates["%s #%d%s" % (parameter, len(candidates) + 1, CUSTOM_INJECTION_MARK_CHAR)] = json.dumps(deserialized) + candidates["%s (%s)" % (parameter, key)] = json.dumps(deserialized) current[key] = original deserialized = json.loads(testableParameters[parameter]) diff --git a/lib/core/settings.py b/lib/core/settings.py index 194f2bc0d..e3172f864 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.35" +VERSION = "1.0.5.36" REVISION = getRevisionNumber() STABLE = VERSION.count('.') <= 2 VERSION_STRING = "sqlmap/%s#%s" % (VERSION, "stable" if STABLE else "dev")