From 85f1a9bd9157c527e23585b34a463e6cc2aa44a6 Mon Sep 17 00:00:00 2001 From: Robert Nixon Date: Mon, 8 Jan 2018 12:09:23 -0500 Subject: [PATCH] Update threatStream_misp_export.py --- .../modules/export_mod/threatStream_misp_export.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/misp_modules/modules/export_mod/threatStream_misp_export.py b/misp_modules/modules/export_mod/threatStream_misp_export.py index 2729de1..3fd88c8 100644 --- a/misp_modules/modules/export_mod/threatStream_misp_export.py +++ b/misp_modules/modules/export_mod/threatStream_misp_export.py @@ -20,10 +20,10 @@ moduleinfo = { } -moduleconfig = ["Default_Source"] +moduleconfig = [] -# Map of MISP fields => ThreatStream itypes +# Map of MISP fields => ThreatStream itypes, you can modify this to your liking fieldmap = { "domain": "mal_domain", "hostname": "mal_domain", @@ -49,10 +49,9 @@ def handler(q=False): if q is False or not q: return False - # Check if we were given a configuration + request = json.loads(q) - config = request.get("config", {"Default_Source": ""}) - logging.info("Setting config to: %s", config) + response = io.StringIO() writer = csv.DictWriter(response, fieldnames=["value", "itype", "tags"])