mirror of https://github.com/MISP/misp-modules
fix: Fixed config parsing and the associated error message
parent
4f70011edf
commit
4411166b43
|
@ -29,8 +29,8 @@ def handler(q=False):
|
||||||
misperrors['error'] = "Unsupported attributes type"
|
misperrors['error'] = "Unsupported attributes type"
|
||||||
return misperrors
|
return misperrors
|
||||||
|
|
||||||
if not request.get('config') and not (request['config'].get('apikey') and request['config'].et('url')):
|
if not request.get('config') or (not request['config'].get('server') and not request['config'].get('port')):
|
||||||
misperrors['error'] = 'EUPI authentication is missing'
|
misperrors['error'] = 'Whois local instance address is missing'
|
||||||
return misperrors
|
return misperrors
|
||||||
|
|
||||||
uwhois = Uwhois(request['config']['server'], int(request['config']['port']))
|
uwhois = Uwhois(request['config']['server'], int(request['config']['port']))
|
||||||
|
|
Loading…
Reference in New Issue