From 79f0b3a92ad9f74aa3d1b6d2ba273d300e28c070 Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Thu, 26 May 2011 15:16:57 +0000 Subject: [PATCH] adding support for --start and --stop for __pivotDumpTable --- plugins/generic/enumeration.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/plugins/generic/enumeration.py b/plugins/generic/enumeration.py index 644911ad3..cbe80ce06 100644 --- a/plugins/generic/enumeration.py +++ b/plugins/generic/enumeration.py @@ -1402,6 +1402,13 @@ class Enumeration: else: pivotValue = safechardecode(value) + if all([conf.limitStart, conf.limitStop]): + if (i + 1) < conf.limitStart: + break + elif (i + 1) > conf.limitStop: + breakRetrieval = True + break + lengths[column] = max(lengths[column], len(value) if value else 0) entries[column].append(value) @@ -1518,7 +1525,7 @@ class Enumeration: query = rootQuery.inband.query % (colString, tbl) elif Backend.getIdentifiedDbms() in (DBMS.SYBASE, DBMS.MSSQL): # Partial inband and error - if not (isTechniqueAvailable(PAYLOAD.TECHNIQUE.UNION) and kb.injection.data[PAYLOAD.TECHNIQUE.UNION].where == PAYLOAD.WHERE.ORIGINAL) and not any([conf.limitStart, conf.limitStop]): + if not (isTechniqueAvailable(PAYLOAD.TECHNIQUE.UNION) and kb.injection.data[PAYLOAD.TECHNIQUE.UNION].where == PAYLOAD.WHERE.ORIGINAL): table = "%s.%s" % (conf.db, tbl) retVal = self.__pivotDumpTable(table, colList, blind=False)