diff --git a/misp_stix_converter/stix2misp/converters/stix2_indicator_converter.py b/misp_stix_converter/stix2misp/converters/stix2_indicator_converter.py index 94a597f..3e79544 100644 --- a/misp_stix_converter/stix2misp/converters/stix2_indicator_converter.py +++ b/misp_stix_converter/stix2misp/converters/stix2_indicator_converter.py @@ -1106,13 +1106,13 @@ def _parse_yara_pattern(self, indicator: _INDICATOR_TYPING): def _unknown_pattern_mapping_warning( self, indicator_id: str, pattern_types: GeneratorType): - self._add_warning( + self.main_parser._add_warning( f'Unable to map pattern from the Indicator with id {indicator_id}, ' f"containing the following types: {', '.join(pattern_types)}" ) def _unmapped_pattern_warning(self, indicator_id: str, feature: str): - self._add_warning( + self.main_parser._add_warning( 'Unmapped pattern part in indicator with id ' f'{indicator_id}: {feature}' ) diff --git a/misp_stix_converter/stix2misp/stix2_to_misp.py b/misp_stix_converter/stix2misp/stix2_to_misp.py index 30bb8b9..5c9865f 100644 --- a/misp_stix_converter/stix2misp/stix2_to_misp.py +++ b/misp_stix_converter/stix2misp/stix2_to_misp.py @@ -734,7 +734,7 @@ def _parse_analyst_note(note: Note) -> dict: if hasattr(note, 'abstract'): note_dict['comment'] = note.abstract if hasattr(note, 'authors'): - note_dict['authors'] = note.authors + note_dict['authors'] = ', '.join(note.authors) if hasattr(note, 'lang'): note_dict['language'] = note.lang return note_dict @@ -746,7 +746,7 @@ def _parse_analyst_opinion(opinion: Opinion) -> dict: 'created': opinion.created, 'modified': opinion.modified } if hasattr(opinion, 'authors'): - opinion_dict['authors'] = opinion.authors + opinion_dict['authors'] = ', '.join(opinion.authors) return opinion_dict ############################################################################