diff --git a/infection_monkey/utils.py b/infection_monkey/utils.py index baef2372a..e2f66bd03 100644 --- a/infection_monkey/utils.py +++ b/infection_monkey/utils.py @@ -15,7 +15,11 @@ def get_dropper_log_path(): else WormConfiguration.dropper_log_path_linux -def is_64bit_os(): +def is_64bit_windows_os(): + ''' + Checks for 64 bit Windows OS using environment variables. + :return: + ''' return 'PROGRAMFILES(X86)' in os.environ diff --git a/infection_monkey/windows_upgrader.py b/infection_monkey/windows_upgrader.py index 38cb3a479..cbd879c15 100644 --- a/infection_monkey/windows_upgrader.py +++ b/infection_monkey/windows_upgrader.py @@ -10,7 +10,7 @@ from config import WormConfiguration from control import ControlClient from exploit.tools import build_monkey_commandline_explicitly from model import MONKEY_CMDLINE_WINDOWS -from utils import is_windows_os, is_64bit_os, is_64bit_python +from utils import is_windows_os, is_64bit_windows_os, is_64bit_python __author__ = 'itay.mizeretz' @@ -27,7 +27,7 @@ class WindowsUpgrader(object): @staticmethod def should_upgrade(): - return is_windows_os() and is_64bit_os() \ + return is_windows_os() and is_64bit_windows_os() \ and not is_64bit_python() @staticmethod