From 0bb08d09d2ef9a2c5ac4cda34843c5db20d7046b Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Thu, 24 Mar 2011 08:43:40 +0000 Subject: [PATCH] fix for a bug reported by Kirill (value is None in attack table phase) and minor fix for loading request file --- doc/THANKS | 1 + lib/core/option.py | 2 +- lib/utils/hash.py | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/doc/THANKS b/doc/THANKS index 3b4a53eab..be18f2691 100644 --- a/doc/THANKS +++ b/doc/THANKS @@ -268,6 +268,7 @@ Anastasios Monachos for suggesting a feature Kirill Morozov + for reporting a bug for suggesting a feature Alejo Murillo Moya diff --git a/lib/core/option.py b/lib/core/option.py index d78a5a8ea..13de9cfba 100644 --- a/lib/core/option.py +++ b/lib/core/option.py @@ -215,7 +215,7 @@ def __feedTargetsDict(reqFile, addedTargetUrls): for line in lines: if len(line) == 0 or line == "\n": - if method == HTTPMETHOD.POST: + if method == HTTPMETHOD.POST and data is None: data = "" params = True diff --git a/lib/utils/hash.py b/lib/utils/hash.py index a9d697766..4f1bd75b8 100644 --- a/lib/utils/hash.py +++ b/lib/utils/hash.py @@ -261,7 +261,7 @@ def attackDumpedTable(): value = table[column]['values'][i] - if value.lower() == hash_.lower(): + if all(map(lambda x: x, [value, hash_])) and value.lower() == hash_.lower(): table[column]['values'][i] += " (%s)" % password table[column]['length'] = max(table[column]['length'], len(table[column]['values'][i]))