forked from p15670423/monkey
Agent: Use == to compare OperatingSystems enum in Log4Shell
This commit is contained in:
parent
fb67586a4c
commit
b605f16c4f
|
@ -129,7 +129,7 @@ class Log4ShellExploiter(WebRCE):
|
||||||
}
|
}
|
||||||
|
|
||||||
def _build_java_class(self, exploit_command: str) -> bytes:
|
def _build_java_class(self, exploit_command: str) -> bytes:
|
||||||
if OperatingSystems.LINUX in self.host.os["type"]:
|
if OperatingSystems.LINUX == self.host.os["type"]:
|
||||||
return build_exploit_bytecode(exploit_command, LINUX_EXPLOIT_TEMPLATE_PATH)
|
return build_exploit_bytecode(exploit_command, LINUX_EXPLOIT_TEMPLATE_PATH)
|
||||||
else:
|
else:
|
||||||
return build_exploit_bytecode(exploit_command, WINDOWS_EXPLOIT_TEMPLATE_PATH)
|
return build_exploit_bytecode(exploit_command, WINDOWS_EXPLOIT_TEMPLATE_PATH)
|
||||||
|
|
Loading…
Reference in New Issue