From 3a2d9a9cc275b67f4fb8cadb763912327aa2ef15 Mon Sep 17 00:00:00 2001 From: "maor.rayzin" Date: Mon, 29 Oct 2018 15:25:30 +0200 Subject: [PATCH] Excluded the name Administrator from the shared admin issue, it spams the report --- monkey/monkey_island/cc/services/pth_report.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/monkey/monkey_island/cc/services/pth_report.py b/monkey/monkey_island/cc/services/pth_report.py index 9a862f212..edb882561 100644 --- a/monkey/monkey_island/cc/services/pth_report.py +++ b/monkey/monkey_island/cc/services/pth_report.py @@ -98,7 +98,10 @@ class PTHReportService(object): # This mongo queries users the best solution to figure out if an array # object has at least two objects in it, by making sure any value exists in the array index 1. - admins = mongo.db.groupsandusers.find({'type': 1, 'admin_on_machines.1': {'$exists': True}}, + # Excluding the name Administrator - its spamming the lists and not a surprise the domain Administrator account + # is shared. + admins = mongo.db.groupsandusers.find({'type': 1, 'name': {'$ne': 'Administrator'}, + 'admin_on_machines.1': {'$exists': True}}, {'admin_on_machines': 1, 'name': 1, 'domain_name': 1}) return [ {