From 71f0ad222b55d50948ff80b2c851b42f78818982 Mon Sep 17 00:00:00 2001 From: Jeremy Cloarec Date: Mon, 11 Aug 2025 17:31:04 +0200 Subject: [PATCH] [client] fix handling of external reference delete for delete operation --- pycti/utils/opencti_stix2.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pycti/utils/opencti_stix2.py b/pycti/utils/opencti_stix2.py index 18189a802..060d8adbf 100644 --- a/pycti/utils/opencti_stix2.py +++ b/pycti/utils/opencti_stix2.py @@ -2651,6 +2651,8 @@ def element_operation_delete(self, item, operation): force_delete = operation == "delete_force" if item["type"] == "relationship": self.opencti.stix_core_relationship.delete(id=item["id"]) + elif item["type"] == "external-reference": + self.opencti.external_reference.delete(item["id"]) elif item["type"] == "sighting": self.opencti.stix_sighting_relationship.delete(id=item["id"]) elif item["type"] in STIX_META_OBJECTS: