From 79563906316f2573dbbfbaee08714a0ea9e74056 Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Tue, 11 Oct 2011 22:27:49 +0000 Subject: [PATCH] minor update --- lib/techniques/error/use.py | 2 +- lib/techniques/union/use.py | 3 ++- lib/utils/hashdb.py | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/techniques/error/use.py b/lib/techniques/error/use.py index bcd3436db..07b13e7cb 100644 --- a/lib/techniques/error/use.py +++ b/lib/techniques/error/use.py @@ -53,7 +53,7 @@ def __oneShotErrorUse(expression, field): threadData = getCurrentThreadData() - retVal = conf.hashDB.retrieve(expression) if not conf.freshQueries else None + retVal = conf.hashDB.retrieve(expression) if not any([conf.flushSession, conf.freshQueries]) else None offset = 1 chunk_length = None diff --git a/lib/techniques/union/use.py b/lib/techniques/union/use.py index b1d65793e..bf30e2957 100644 --- a/lib/techniques/union/use.py +++ b/lib/techniques/union/use.py @@ -46,11 +46,12 @@ from lib.request.connect import Connect as Request from lib.utils.resume import resume reqCount = 0 +resumed = False def __oneShotUnionUse(expression, unpack=True, limited=False): global reqCount - retVal = conf.hashDB.retrieve(expression) if not conf.freshQueries else None + retVal = conf.hashDB.retrieve(expression) if not any([conf.flushSession, conf.freshQueries]) else None if retVal is None: check = "(?P%s.*%s)" % (kb.chars.start, kb.chars.stop) diff --git a/lib/utils/hashdb.py b/lib/utils/hashdb.py index bfeba3415..20efcef3c 100644 --- a/lib/utils/hashdb.py +++ b/lib/utils/hashdb.py @@ -46,7 +46,7 @@ class HashDB(object): def retrieve(self, key): retVal = None - if key and not any([conf.flushSession, conf.freshQueries]): + if key: hash_ = self.hashKey(key) while True: try: