forked from p15670423/monkey
Agent: Add impacket_user decorator to the zerologon
impacket_user decorator will awoid race conditions with other exploiters using wmi tools
This commit is contained in:
parent
a3eb0bc6f2
commit
a8018a7956
|
@ -18,6 +18,7 @@ from impacket.dcerpc.v5.dtypes import NULL
|
|||
from common.utils.exploit_enum import ExploitType
|
||||
from infection_monkey.credential_collectors import LMHash, NTHash, Username
|
||||
from infection_monkey.exploit.HostExploiter import HostExploiter
|
||||
from infection_monkey.exploit.tools.wmi_tools import WmiTools
|
||||
from infection_monkey.exploit.zerologon_utils.dump_secrets import DumpSecrets
|
||||
from infection_monkey.exploit.zerologon_utils.options import OptionsForSecretsdump
|
||||
from infection_monkey.exploit.zerologon_utils.vuln_assessment import get_dc_details, is_exploitable
|
||||
|
@ -47,6 +48,7 @@ class ZerologonExploiter(HostExploiter):
|
|||
def __del__(self):
|
||||
self._secrets_dir.cleanup()
|
||||
|
||||
@WmiTools.impacket_user
|
||||
def _exploit_host(self) -> ExploiterResultData:
|
||||
self.dc_ip, self.dc_name, self.dc_handle = get_dc_details(self.host)
|
||||
|
||||
|
|
Loading…
Reference in New Issue