diff --git a/monkey/infection_monkey/exploit/tools/wmi_tools.py b/monkey/infection_monkey/exploit/tools/wmi_tools.py index 30ae59107..976e462e5 100644 --- a/monkey/infection_monkey/exploit/tools/wmi_tools.py +++ b/monkey/infection_monkey/exploit/tools/wmi_tools.py @@ -24,11 +24,12 @@ class AccessDeniedException(Exception): class WmiTools(object): - @staticmethod def impacket_user(func): def _wrapper(*args, **kwarg): + logger.debug("Waiting for impacket lock") with lock: + logger.debug("Acquired impacket lock") return func(*args, **kwarg) return _wrapper @@ -93,8 +94,10 @@ class WmiTools(object): def dcom_wrap(func): def _wrapper(*args, **kwarg): try: + logger.debug("Running function from dcom_wrap") return func(*args, **kwarg) finally: + logger.debug("Running dcom cleanup") WmiTools.dcom_cleanup() return _wrapper