forked from p15670423/monkey
Make both segmentation issues and island segmentation issues present the same warning
This commit is contained in:
parent
74a928cfe7
commit
08995796ef
|
@ -36,10 +36,9 @@ class ReportService:
|
||||||
SAMBACRY = 3
|
SAMBACRY = 3
|
||||||
SHELLSHOCK = 4
|
SHELLSHOCK = 4
|
||||||
CONFICKER = 5
|
CONFICKER = 5
|
||||||
CROSS_SEGMENT = 6
|
|
||||||
|
|
||||||
class WARNINGS_DICT(Enum):
|
class WARNINGS_DICT(Enum):
|
||||||
ISLAND_CROSS_SEGMENT = 0
|
CROSS_SEGMENT = 0
|
||||||
TUNNEL = 1
|
TUNNEL = 1
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
@ -395,8 +394,8 @@ class ReportService:
|
||||||
return ConfigService.get_config_value(['basic_network', 'general', 'local_network_scan'], True)
|
return ConfigService.get_config_value(['basic_network', 'general', 'local_network_scan'], True)
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_issues_overview(issues, cross_segment_issues, config_users, config_passwords):
|
def get_issues_overview(issues, config_users, config_passwords):
|
||||||
issues_byte_array = [False] * 7
|
issues_byte_array = [False] * 6
|
||||||
|
|
||||||
for machine in issues:
|
for machine in issues:
|
||||||
for issue in issues[machine]:
|
for issue in issues[machine]:
|
||||||
|
@ -414,22 +413,22 @@ class ReportService:
|
||||||
elif issue['type'].endswith('_pth') or issue['type'].endswith('_password'):
|
elif issue['type'].endswith('_pth') or issue['type'].endswith('_password'):
|
||||||
issues_byte_array[ReportService.ISSUES_DICT.STOLEN_CREDS.value] = True
|
issues_byte_array[ReportService.ISSUES_DICT.STOLEN_CREDS.value] = True
|
||||||
|
|
||||||
if len(cross_segment_issues) != 0:
|
|
||||||
issues_byte_array[ReportService.ISSUES_DICT.CROSS_SEGMENT.value] = True
|
|
||||||
|
|
||||||
return issues_byte_array
|
return issues_byte_array
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_warnings_overview(issues):
|
def get_warnings_overview(issues, cross_segment_issues):
|
||||||
warnings_byte_array = [False] * 2
|
warnings_byte_array = [False] * 2
|
||||||
|
|
||||||
for machine in issues:
|
for machine in issues:
|
||||||
for issue in issues[machine]:
|
for issue in issues[machine]:
|
||||||
if issue['type'] == 'island_cross_segment':
|
if issue['type'] == 'island_cross_segment':
|
||||||
warnings_byte_array[ReportService.WARNINGS_DICT.ISLAND_CROSS_SEGMENT.value] = True
|
warnings_byte_array[ReportService.WARNINGS_DICT.CROSS_SEGMENT.value] = True
|
||||||
elif issue['type'] == 'tunnel':
|
elif issue['type'] == 'tunnel':
|
||||||
warnings_byte_array[ReportService.WARNINGS_DICT.TUNNEL.value] = True
|
warnings_byte_array[ReportService.WARNINGS_DICT.TUNNEL.value] = True
|
||||||
|
|
||||||
|
if len(cross_segment_issues) != 0:
|
||||||
|
warnings_byte_array[ReportService.WARNINGS_DICT.CROSS_SEGMENT.value] = True
|
||||||
|
|
||||||
return warnings_byte_array
|
return warnings_byte_array
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
@ -465,15 +464,15 @@ class ReportService:
|
||||||
'config_scan': ReportService.get_config_scan(),
|
'config_scan': ReportService.get_config_scan(),
|
||||||
'monkey_start_time': ReportService.get_first_monkey_time().strftime("%d/%m/%Y %H:%M:%S"),
|
'monkey_start_time': ReportService.get_first_monkey_time().strftime("%d/%m/%Y %H:%M:%S"),
|
||||||
'monkey_duration': ReportService.get_monkey_duration(),
|
'monkey_duration': ReportService.get_monkey_duration(),
|
||||||
'issues': ReportService.get_issues_overview(issues, cross_segment_issues, config_users, config_passwords),
|
'issues': ReportService.get_issues_overview(issues, config_users, config_passwords),
|
||||||
'warnings': ReportService.get_warnings_overview(issues)
|
'warnings': ReportService.get_warnings_overview(issues, cross_segment_issues),
|
||||||
|
'cross_segment_issues': cross_segment_issues
|
||||||
},
|
},
|
||||||
'glance':
|
'glance':
|
||||||
{
|
{
|
||||||
'scanned': ReportService.get_scanned(),
|
'scanned': ReportService.get_scanned(),
|
||||||
'exploited': ReportService.get_exploited(),
|
'exploited': ReportService.get_exploited(),
|
||||||
'stolen_creds': ReportService.get_stolen_creds(),
|
'stolen_creds': ReportService.get_stolen_creds()
|
||||||
'cross_segment_issues': cross_segment_issues
|
|
||||||
},
|
},
|
||||||
'recommendations':
|
'recommendations':
|
||||||
{
|
{
|
||||||
|
|
|
@ -26,7 +26,7 @@ class ReportPageComponent extends AuthComponent {
|
||||||
|
|
||||||
Warning =
|
Warning =
|
||||||
{
|
{
|
||||||
ISLAND_CROSS_SEGMENT: 0,
|
CROSS_SEGMENT: 0,
|
||||||
TUNNEL: 1
|
TUNNEL: 1
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -333,7 +333,7 @@ class ReportPageComponent extends AuthComponent {
|
||||||
<div>
|
<div>
|
||||||
The Monkey uncovered the following possible set of issues:
|
The Monkey uncovered the following possible set of issues:
|
||||||
<ul>
|
<ul>
|
||||||
{this.state.report.overview.warnings[this.Warning.ISLAND_CROSS_SEGMENT] ?
|
{this.state.report.overview.warnings[this.Warning.CROSS_SEGMENT] ?
|
||||||
<li>Weak segmentation - Machines from different segments are able to
|
<li>Weak segmentation - Machines from different segments are able to
|
||||||
communicate.</li> : null}
|
communicate.</li> : null}
|
||||||
{this.state.report.overview.warnings[this.Warning.TUNNEL] ?
|
{this.state.report.overview.warnings[this.Warning.TUNNEL] ?
|
||||||
|
@ -603,7 +603,7 @@ class ReportPageComponent extends AuthComponent {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
generateCrossSegmentIssue(issue) {
|
generateIslandCrossSegmentIssue(issue) {
|
||||||
return (
|
return (
|
||||||
<li>
|
<li>
|
||||||
Segment your network and make sure there is no communication between machines from different segments.
|
Segment your network and make sure there is no communication between machines from different segments.
|
||||||
|
|
Loading…
Reference in New Issue