From 1b44668094c08a4aa226d259dc6623dcd0984575 Mon Sep 17 00:00:00 2001 From: chrisr3d Date: Thu, 15 Nov 2018 19:44:43 +0100 Subject: [PATCH] fix: Added hostname attribute support as it is intended --- misp_modules/modules/expansion/countrycode.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/misp_modules/modules/expansion/countrycode.py b/misp_modules/modules/expansion/countrycode.py index 9f22c40..fb38fe4 100755 --- a/misp_modules/modules/expansion/countrycode.py +++ b/misp_modules/modules/expansion/countrycode.py @@ -29,12 +29,12 @@ def handler(q=False): if q is False: return False request = json.loads(q) - domain = request["domain"] + domain = request["domain"] if "domain" in request else request["hostname"] # Get the extension ext = domain.split(".")[-1] - # Check if if's a common, non country one + # Check if it's a common, non country one if ext in common_tlds.keys(): val = common_tlds[ext] else: