mirror of https://github.com/MISP/misp-modules
Update hyasinsight.py
parent
66eb82cf1a
commit
d00fee3ba0
|
@ -719,9 +719,7 @@ class HyasInsightParser:
|
||||||
data_items: List[str] = self.c2_attribution_data_items
|
data_items: List[str] = self.c2_attribution_data_items
|
||||||
data_items_friendly_names = self.c2_attribution_data_items_friendly_names
|
data_items_friendly_names = self.c2_attribution_data_items_friendly_names
|
||||||
|
|
||||||
loop = 1
|
|
||||||
for result in flatten_json_response:
|
for result in flatten_json_response:
|
||||||
if loop <= 3:
|
|
||||||
hyas_object = misp_object(endpoint, attribute_value)
|
hyas_object = misp_object(endpoint, attribute_value)
|
||||||
for data_item in result.keys():
|
for data_item in result.keys():
|
||||||
if data_item in data_items:
|
if data_item in data_items:
|
||||||
|
@ -729,7 +727,6 @@ class HyasInsightParser:
|
||||||
data_item_value = str(result[data_item])
|
data_item_value = str(result[data_item])
|
||||||
hyas_object.add_attribute(
|
hyas_object.add_attribute(
|
||||||
**parse_attribute(hyas_object.comment, data_item_text, data_item_value))
|
**parse_attribute(hyas_object.comment, data_item_text, data_item_value))
|
||||||
loop = loop + 1
|
|
||||||
hyas_object.add_reference(self.attribute['uuid'], 'related-to')
|
hyas_object.add_reference(self.attribute['uuid'], 'related-to')
|
||||||
self.misp_event.add_object(hyas_object)
|
self.misp_event.add_object(hyas_object)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue