diff --git a/monkey/monkey_island/cc/services/attack/technique_reports/__init__.py b/monkey/monkey_island/cc/services/attack/technique_reports/__init__.py index 61c1f89bd20..f3e552ab25f 100644 --- a/monkey/monkey_island/cc/services/attack/technique_reports/__init__.py +++ b/monkey/monkey_island/cc/services/attack/technique_reports/__init__.py @@ -83,7 +83,7 @@ def get_message_and_status(cls, status): :param status: Enum from common/attack_utils.py integer value :return: Dict with message and status """ - return {'message': cls.get_message_by_status(status), 'status': status} + return {'message_string': cls.get_message_by_status(status), 'status': status} @classmethod def get_message_by_status(cls, status): @@ -112,14 +112,14 @@ def technique_title(cls): def get_tech_base_data(cls): """ Gathers basic attack technique data into a dict. - :return: dict E.g. {'message': 'Brute force used', 'status': 2, 'title': 'T1110 Brute force'} + :return: dict E.g. {'message_string': 'Brute force used', 'status': 2, 'title': 'T1110 Brute force'} """ data = {} status = cls.technique_status() title = cls.technique_title() data.update({'status': status, 'title': title, - 'message': cls.get_message_by_status(status)}) + 'message_string': cls.get_message_by_status(status)}) data.update(cls.get_mitigation_by_status(status)) return data diff --git a/monkey/monkey_island/cc/ui/src/components/report-components/AttackReport.js b/monkey/monkey_island/cc/ui/src/components/report-components/AttackReport.js index 8e715e20bf3..f374348b041 100644 --- a/monkey/monkey_island/cc/ui/src/components/report-components/AttackReport.js +++ b/monkey/monkey_island/cc/ui/src/components/report-components/AttackReport.js @@ -157,11 +157,9 @@ class AttackReport extends React.Component { } } } - // modify techniques' messages + // compiles techniques' message string from markdown to HTML for (const tech_id in techniques){ - if (typeof techniques[tech_id]['message'] === 'string') { - techniques[tech_id]['message'] =
; - } + techniques[tech_id]['message'] = ; } return techniques