From f06e9ecb581d0029b0d358352b17b5ebeea45c03 Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Thu, 18 Jul 2019 11:58:40 +0200 Subject: [PATCH] Minor update for #3833 --- lib/core/settings.py | 2 +- lib/parse/cmdline.py | 3 +++ lib/techniques/union/use.py | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/core/settings.py b/lib/core/settings.py index 155458b40..57e53bb8a 100644 --- a/lib/core/settings.py +++ b/lib/core/settings.py @@ -18,7 +18,7 @@ from lib.core.enums import OS from thirdparty.six import unichr as _unichr # sqlmap version (...) -VERSION = "1.3.7.31" +VERSION = "1.3.7.32" TYPE = "dev" if VERSION.count('.') > 2 and VERSION.split('.')[-1] != '0' else "stable" TYPE_COLORS = {"dev": 33, "stable": 90, "pip": 34} VERSION_STRING = "sqlmap/%s#%s" % ('.'.join(VERSION.split('.')[:-1]) if VERSION.count('.') > 2 and VERSION.split('.')[-1] == '0' else VERSION, TYPE) diff --git a/lib/parse/cmdline.py b/lib/parse/cmdline.py index 0d51f5d0d..073142032 100644 --- a/lib/parse/cmdline.py +++ b/lib/parse/cmdline.py @@ -745,6 +745,9 @@ def cmdLineParser(argv=None): parser.add_argument("--force-dns", dest="forceDns", action="store_true", help=SUPPRESS) + parser.add_argument("--force-partial", dest="forcePartial", action="store_true", + help=SUPPRESS) + parser.add_argument("--force-pivoting", dest="forcePivoting", action="store_true", help=SUPPRESS) diff --git a/lib/techniques/union/use.py b/lib/techniques/union/use.py index 29e72d7a9..640c66874 100644 --- a/lib/techniques/union/use.py +++ b/lib/techniques/union/use.py @@ -241,7 +241,7 @@ def unionUse(expression, unpack=True, dump=False): # SQL limiting the query output one entry at a time # NOTE: we assume that only queries that get data from a table can # return multiple entries - if value is None and (kb.injection.data[PAYLOAD.TECHNIQUE.UNION].where == PAYLOAD.WHERE.NEGATIVE or kb.forcePartialUnion or (dump and (conf.limitStart or conf.limitStop)) or "LIMIT " in expression.upper()) and " FROM " in expression.upper() and ((Backend.getIdentifiedDbms() not in FROM_DUMMY_TABLE) or (Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and not expression.upper().endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]))) and not re.search(SQL_SCALAR_REGEX, expression, re.I): + if value is None and (kb.injection.data[PAYLOAD.TECHNIQUE.UNION].where == PAYLOAD.WHERE.NEGATIVE or kb.forcePartialUnion or conf.forcePartial or (dump and (conf.limitStart or conf.limitStop)) or "LIMIT " in expression.upper()) and " FROM " in expression.upper() and ((Backend.getIdentifiedDbms() not in FROM_DUMMY_TABLE) or (Backend.getIdentifiedDbms() in FROM_DUMMY_TABLE and not expression.upper().endswith(FROM_DUMMY_TABLE[Backend.getIdentifiedDbms()]))) and not re.search(SQL_SCALAR_REGEX, expression, re.I): expression, limitCond, topLimit, startLimit, stopLimit = agent.limitCondition(expression, dump) if limitCond: