From b5c87073239d1f2a485afcd52edfae8f8f277f69 Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Thu, 6 Dec 2012 15:55:33 +0100 Subject: [PATCH] Infinite loop fix when 'SELECT DB_NAME(...)' method used for --dbs in MsSQL --- plugins/generic/databases.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/generic/databases.py b/plugins/generic/databases.py index e72eeff07..605eb156c 100644 --- a/plugins/generic/databases.py +++ b/plugins/generic/databases.py @@ -148,11 +148,11 @@ class Databases: kb.data.cachedDbs = [] while True: query = rootQuery.inband.query2 % count - value = inject.getValue(query, blind=blind) - if not value: + value = unArrayizeValue(inject.getValue(query, blind=blind)) + if not (value or "").strip(): break else: - kb.data.cachedDbs.append(unArrayizeValue(value)) + kb.data.cachedDbs.append(value) count += 1 if kb.data.cachedDbs: break