mirror of https://github.com/MISP/misp-modules
Bug fix
parent
80dba63a8b
commit
4e00e60951
|
@ -336,7 +336,7 @@ def apiosintParserHover(ispersistent, response, import_related, stix):
|
|||
urlHover = "URL => "+urls
|
||||
retHover.append({"types": ["text"], "values": [urlHover]})
|
||||
else:
|
||||
notfound = item["item"] + " IS NOT listed by OSINT.digitalside.it. Date list: " + item[key]["list"]["date"]
|
||||
notfound = item["item"] + " IS NOT listed by OSINT.digitalside.it. Date list: " + response[key]["list"]["date"]
|
||||
ret.append({"types": ["comment"], "values": [notfound]})
|
||||
|
||||
if ispersistent == 0:
|
||||
|
|
|
@ -74,12 +74,13 @@ class TestExpansions(unittest.TestCase):
|
|||
return data['results'][0]['values']
|
||||
|
||||
def test_apiosintds(self):
|
||||
query = {'module': 'apiosintds', 'ip-dst': '185.255.79.90'}
|
||||
query = {'module': 'apiosintds', 'ip-dst': '10.10.10.10'}
|
||||
response = self.misp_modules_post(query)
|
||||
|
||||
try:
|
||||
self.assertTrue(self.get_values(response).startswith('185.255.79.90 IS listed by OSINT.digitalside.it.'))
|
||||
self.assertTrue(self.get_values(response).startswith('IoC 10.10.10.10'))
|
||||
except AssertionError:
|
||||
self.assertTrue(self.get_values(response).startswith('185.255.79.90 IS NOT listed by OSINT.digitalside.it.'))
|
||||
self.assertTrue(self.get_values(response).startswith('10.10.10.10 IS NOT listed by OSINT.digitalside.it.'))
|
||||
|
||||
def test_apivoid(self):
|
||||
module_name = "apivoid"
|
||||
|
|
Loading…
Reference in New Issue