From 018748f52e4e0adc2a9eee2a421df55d4fdf5ad5 Mon Sep 17 00:00:00 2001 From: Bernardo Damele Date: Tue, 1 Jul 2014 00:34:09 +0100 Subject: [PATCH] increase the timeout for the Metasploit session initialization to 5 minutes, better on slow speed connections --- lib/core/settings.py | 2 +- lib/takeover/metasploit.py | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/core/settings.py b/lib/core/settings.py index 6965ac57a..863d9c970 100644 --- a/lib/core/settings.py +++ b/lib/core/settings.py @@ -572,7 +572,7 @@ FORM_SEARCH_REGEX = r"(?si)" MIN_ENCODED_LEN_CHECK = 5 # Timeout in seconds in which Metasploit remote session has to be initialized -METASPLOIT_SESSION_TIMEOUT = 180 +METASPLOIT_SESSION_TIMEOUT = 300 # Reference: http://www.cookiecentral.com/faq/#3.5 NETSCAPE_FORMAT_HEADER_COOKIES = "# Netscape HTTP Cookie File." diff --git a/lib/takeover/metasploit.py b/lib/takeover/metasploit.py index 36fac0120..e5d18935d 100644 --- a/lib/takeover/metasploit.py +++ b/lib/takeover/metasploit.py @@ -529,7 +529,6 @@ class Metasploit: time.sleep(2) initialized = True - elif timeout: proc.kill() errMsg = "timeout occurred while attempting "