forked from p15670423/monkey
Agent: Add interrupt error message to powershell results
This commit is contained in:
parent
02154e38fd
commit
f50f4cf71c
|
@ -70,6 +70,7 @@ class PowerShellExploiter(HostExploiter):
|
|||
try:
|
||||
self._client = self._authenticate_via_brute_force(credentials, auth_options)
|
||||
except self.InterruptError:
|
||||
self.exploit_result.error_message = "Exploiter has been interrupted"
|
||||
return self.exploit_result
|
||||
|
||||
if not self._client:
|
||||
|
@ -84,6 +85,7 @@ class PowerShellExploiter(HostExploiter):
|
|||
self._execute_monkey_agent_on_victim()
|
||||
self.exploit_result.propagation_success = True
|
||||
except self.InterruptError:
|
||||
self.exploit_result.error_message = "Exploiter has been interrupted"
|
||||
return self.exploit_result
|
||||
except Exception as ex:
|
||||
logger.error(f"Failed to propagate to the remote host: {ex}")
|
||||
|
|
Loading…
Reference in New Issue