From b3e9922d0fcf90ead17561e68c71a151c309fd24 Mon Sep 17 00:00:00 2001 From: VakarisZ Date: Mon, 1 Mar 2021 10:05:18 +0200 Subject: [PATCH] Changed the logic of zerologon password restoration issue overview to be more consistent with the function of issue map. --- monkey/monkey_island/cc/services/reporting/report.py | 6 +++--- .../ui/src/components/report-components/SecurityReport.js | 5 ++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/monkey/monkey_island/cc/services/reporting/report.py b/monkey/monkey_island/cc/services/reporting/report.py index c6cc9b9cf..8b57eaec2 100644 --- a/monkey/monkey_island/cc/services/reporting/report.py +++ b/monkey/monkey_island/cc/services/reporting/report.py @@ -65,7 +65,7 @@ class ReportService: VSFTPD = 13 DRUPAL = 14 ZEROLOGON = 15 - ZEROLOGON_PASSWORD_RESTORED = 16 + ZEROLOGON_PASSWORD_RESTORE_FAILED = 16 class WARNINGS_DICT(Enum): CROSS_SEGMENT = 0 @@ -715,8 +715,8 @@ class ReportService: elif issue['type'] == 'drupal': issues_byte_array[ReportService.ISSUES_DICT.DRUPAL.value] = True elif issue['type'] == 'zerologon': - if issue['password_restored']: - issues_byte_array[ReportService.ISSUES_DICT.ZEROLOGON_PASSWORD_RESTORED.value] = True + if not issue['password_restored']: + issues_byte_array[ReportService.ISSUES_DICT.ZEROLOGON_PASSWORD_RESTORE_FAILED.value] = True issues_byte_array[ReportService.ISSUES_DICT.ZEROLOGON.value] = True elif issue['type'].endswith('_password') and issue['password'] in config_passwords and \ issue['username'] in config_users or issue['type'] == 'ssh': diff --git a/monkey/monkey_island/cc/ui/src/components/report-components/SecurityReport.js b/monkey/monkey_island/cc/ui/src/components/report-components/SecurityReport.js index c1d8e7e0e..3ba443e32 100644 --- a/monkey/monkey_island/cc/ui/src/components/report-components/SecurityReport.js +++ b/monkey/monkey_island/cc/ui/src/components/report-components/SecurityReport.js @@ -44,7 +44,7 @@ class ReportPageComponent extends AuthComponent { VSFTPD: 13, DRUPAL: 14, ZEROLOGON: 15, - ZEROLOGON_PASSWORD_RESTORED: 16 + ZEROLOGON_PASSWORD_RESTORE_FAILED: 16 }; Warning = @@ -367,8 +367,7 @@ class ReportPageComponent extends AuthComponent { generateZerologonOverview() { let zerologonOverview = []; - // TODO finish this by linking to the documentation - if(!this.state.report.overview.issues[this.Issue.ZEROLOGON_PASSWORD_RESTORED]) { + if (this.state.report.overview.issues[this.Issue.ZEROLOGON_PASSWORD_RESTORE_FAILED]) { zerologonOverview.push( Automatic password restoration on a domain controller failed!