Agent: Use ITelemetryMessenger to send telemetries in WebRCE
This commit is contained in:
parent
57eca553a7
commit
67083fe336
|
@ -275,7 +275,9 @@ class WebRCE(HostExploiter):
|
||||||
"monkey_path": dest_path,
|
"monkey_path": dest_path,
|
||||||
"http_path": http_path,
|
"http_path": http_path,
|
||||||
}
|
}
|
||||||
T1197Telem(ScanStatus.USED, self.host, BITS_UPLOAD_STRING).send()
|
self.telemetry_messenger.send_telemtry(
|
||||||
|
T1197Telem(ScanStatus.USED, self.host, BITS_UPLOAD_STRING)
|
||||||
|
)
|
||||||
resp = self.exploit(url, backup_command)
|
resp = self.exploit(url, backup_command)
|
||||||
return resp
|
return resp
|
||||||
|
|
||||||
|
@ -333,10 +335,10 @@ class WebRCE(HostExploiter):
|
||||||
command = CHMOD_MONKEY % {"monkey_path": path}
|
command = CHMOD_MONKEY % {"monkey_path": path}
|
||||||
try:
|
try:
|
||||||
resp = self.exploit(url, command)
|
resp = self.exploit(url, command)
|
||||||
T1222Telem(ScanStatus.USED, command, self.host).send()
|
self.telemetry_messenger.send_telemtry(T1222Telem(ScanStatus.USED, command, self.host))
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logger.error("Something went wrong while trying to change permission: %s" % e)
|
logger.error("Something went wrong while trying to change permission: %s" % e)
|
||||||
T1222Telem(ScanStatus.SCANNED, "", self.host).send()
|
self.telemetry_messenger.send_telemtry(T1222Telem(ScanStatus.SCANNED, "", self.host))
|
||||||
return False
|
return False
|
||||||
# If exploiter returns True / False
|
# If exploiter returns True / False
|
||||||
if isinstance(resp, bool):
|
if isinstance(resp, bool):
|
||||||
|
|
Loading…
Reference in New Issue