From d46f74c4212ffd7d879d366fe43b2076da73bce3 Mon Sep 17 00:00:00 2001 From: gopackgo90 Date: Sun, 16 Feb 2025 22:02:14 -0600 Subject: [PATCH] fix #68 Use UUID from MISP ObjectReference if available --- misp_stix_converter/misp2stix/misp_to_stix2.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/misp_stix_converter/misp2stix/misp_to_stix2.py b/misp_stix_converter/misp2stix/misp_to_stix2.py index eedbb38..628c156 100644 --- a/misp_stix_converter/misp2stix/misp_to_stix2.py +++ b/misp_stix_converter/misp2stix/misp_to_stix2.py @@ -4369,6 +4369,8 @@ def _parse_object_relationships( 'relationship_type': reference['relationship_type'], 'allow_custom': True, 'interoperability': True } + if reference.get('uuid'): + relationship['id'] = f"reference--{reference['uuid']}" if reference.get('timestamp'): reference_timestamp = self._datetime_from_timestamp( reference['timestamp']