forked from p15670423/monkey
Check status using mongo
This commit is contained in:
parent
d9d8c813aa
commit
e6b3613db2
|
@ -26,11 +26,11 @@ class T1154(AttackTechnique):
|
||||||
|
|
||||||
trap_command_info = list(mongo.db.telemetry.aggregate(T1154.query))
|
trap_command_info = list(mongo.db.telemetry.aggregate(T1154.query))
|
||||||
|
|
||||||
status = []
|
status = ScanStatus.UNSCANNED.value
|
||||||
for pba_node in trap_command_info:
|
if trap_command_info:
|
||||||
status.append(pba_node['result'][1])
|
successful_PBAs = mongo.db.telemetry.count({'data.name': POST_BREACH_TRAP_COMMAND,
|
||||||
status = (ScanStatus.USED.value if any(status) else ScanStatus.SCANNED.value)\
|
'data.result.1': True})
|
||||||
if status else ScanStatus.UNSCANNED.value
|
status = ScanStatus.USED.value if successful_PBAs else ScanStatus.SCANNED.value
|
||||||
|
|
||||||
data.update(T1154.get_base_data_by_status(status))
|
data.update(T1154.get_base_data_by_status(status))
|
||||||
data.update({'info': trap_command_info})
|
data.update({'info': trap_command_info})
|
||||||
|
|
Loading…
Reference in New Issue