From 8da4c024a58d8bc606726c033ac682060b011bfe Mon Sep 17 00:00:00 2001 From: VakarisZ Date: Tue, 9 Jul 2019 18:31:47 +0300 Subject: [PATCH 1/6] Report duplicating issues bugfix --- monkey/monkey_island/cc/services/report.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/monkey/monkey_island/cc/services/report.py b/monkey/monkey_island/cc/services/report.py index 9ceb9662a..593bbfdaf 100644 --- a/monkey/monkey_island/cc/services/report.py +++ b/monkey/monkey_island/cc/services/report.py @@ -373,8 +373,13 @@ class ReportService: @staticmethod def get_exploits(): + query = [{'$match': {'telem_category': 'exploit', 'data.result': True}}, + {'$group': {'_id': {'ip_address': '$data.machine.ip_addr'}, + 'data': {'$first': '$$ROOT'}, + }}, + {"$replaceRoot": {"newRoot": "$data"}}] exploits = [] - for exploit in mongo.db.telemetry.find({'telem_category': 'exploit', 'data.result': True}): + for exploit in mongo.db.telemetry.aggregate(query): new_exploit = ReportService.process_exploit(exploit) if new_exploit not in exploits: exploits.append(new_exploit) From 8367600ab958e4ab50a0b85fdb6e9a4358fee472 Mon Sep 17 00:00:00 2001 From: VakarisZ Date: Tue, 9 Jul 2019 18:34:42 +0300 Subject: [PATCH 2/6] Tunnelling bugfix (tunnel field added to Monkey's model) --- monkey/monkey_island/cc/models/monkey.py | 1 + 1 file changed, 1 insertion(+) diff --git a/monkey/monkey_island/cc/models/monkey.py b/monkey/monkey_island/cc/models/monkey.py index 520b967a0..0b910c84b 100644 --- a/monkey/monkey_island/cc/models/monkey.py +++ b/monkey/monkey_island/cc/models/monkey.py @@ -32,6 +32,7 @@ class Monkey(Document): critical_services = ListField(StringField()) pba_results = ListField() ttl_ref = ReferenceField(MonkeyTtl) + tunnel = ReferenceField("self") # LOGIC @staticmethod From d25609272a6022334065e3e762e86e9a2f14eaa5 Mon Sep 17 00:00:00 2001 From: VakarisZ <36815064+VakarisZ@users.noreply.github.com> Date: Fri, 12 Jul 2019 17:25:04 +0300 Subject: [PATCH 3/6] Update README.md --- deployment_scripts/README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/deployment_scripts/README.md b/deployment_scripts/README.md index 92a2fd76e..de5f55b3e 100644 --- a/deployment_scripts/README.md +++ b/deployment_scripts/README.md @@ -13,9 +13,10 @@ Don't forget to add python to PATH or do so while installing it via this script. ## Linux -You must have root permissions, but there is no need to run the script as root.
+You must have root permissions, but don't run the script as root.
Launch deploy_linux.sh from scripts directory.
-First argument is an empty directory (script can create one) and second is branch you want to clone. +First argument should be an empty directory (script can create one) and second is branch you want to clone (develop by default). +Choose a directory where you have all the relevant permissions, for e.g. /home/your_username Example usages:
./deploy_linux.sh (deploys under ./infection_monkey)
./deploy_linux.sh "/home/test/monkey" (deploys under /home/test/monkey)
From 31ff594bbda9ebf901519c6e8b9fb6ea58fefab5 Mon Sep 17 00:00:00 2001 From: VakarisZ <36815064+VakarisZ@users.noreply.github.com> Date: Fri, 12 Jul 2019 17:26:36 +0300 Subject: [PATCH 4/6] Update README.md --- deployment_scripts/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deployment_scripts/README.md b/deployment_scripts/README.md index de5f55b3e..10027edce 100644 --- a/deployment_scripts/README.md +++ b/deployment_scripts/README.md @@ -15,7 +15,7 @@ Don't forget to add python to PATH or do so while installing it via this script. You must have root permissions, but don't run the script as root.
Launch deploy_linux.sh from scripts directory.
-First argument should be an empty directory (script can create one) and second is branch you want to clone (develop by default). +First argument should be an empty directory (script can create one, default is ./infection_monkey) and second is the branch you want to clone (develop by default). Choose a directory where you have all the relevant permissions, for e.g. /home/your_username Example usages:
./deploy_linux.sh (deploys under ./infection_monkey)
From f895b42b4a4e0df658143628a8595bd4521e7d5a Mon Sep 17 00:00:00 2001 From: Shay Nehmad Date: Sun, 21 Jul 2019 12:03:46 +0300 Subject: [PATCH 5/6] Added target="_blank to link so it opens in a new window --- .../monkey_island/cc/ui/src/components/pages/RunMonkeyPage.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/monkey/monkey_island/cc/ui/src/components/pages/RunMonkeyPage.js b/monkey/monkey_island/cc/ui/src/components/pages/RunMonkeyPage.js index e67b40728..ba4fa4fe4 100644 --- a/monkey/monkey_island/cc/ui/src/components/pages/RunMonkeyPage.js +++ b/monkey/monkey_island/cc/ui/src/components/pages/RunMonkeyPage.js @@ -241,7 +241,7 @@ class RunMonkeyPageComponent extends AuthComponent {

- Not sure what this is? Not seeing your AWS EC2 instances? Read the documentation! + Not sure what this is? Not seeing your AWS EC2 instances?

- Not sure what this is? Not seeing your AWS EC2 instances? Read the documentation!

{