mirror of https://github.com/MISP/misp-modules
Bugfix for "sources" ; do not include as IDS for "access" registry keys
- Bugfix to query "operations" in files, mutex, registry - Do not set IDS flag for registry 'access' operationspull/300/head
parent
559ed786ba
commit
1cd60790fd
|
@ -127,6 +127,11 @@ def handler(q=False):
|
|||
misperrors['error'] = "No vti_results returned or jobs not finished"
|
||||
return misperrors
|
||||
else:
|
||||
if "result" in data:
|
||||
if data["result"] == "ok":
|
||||
return vmray_results
|
||||
|
||||
# Fallback
|
||||
misperrors['error'] = "Unable to fetch sample id %u" % (sample_id)
|
||||
return misperrors
|
||||
except Exception as e: # noqa
|
||||
|
@ -337,7 +342,7 @@ def vmrayArtifacts(patterns):
|
|||
for el in patterns[pattern]:
|
||||
values = el["mutex_name"]
|
||||
types = ["mutex"]
|
||||
if "sources" in el:
|
||||
if "operations" in el:
|
||||
sources = el["operations"]
|
||||
comment = "Operations: " + ", ".join(str(x) for x in sources)
|
||||
else:
|
||||
|
@ -348,18 +353,21 @@ def vmrayArtifacts(patterns):
|
|||
for el in patterns[pattern]:
|
||||
values = el["reg_key_name"]
|
||||
types = ["regkey"]
|
||||
if "sources" in el:
|
||||
include_static_to_ids_tmp = include_static_to_ids
|
||||
if "operations" in el:
|
||||
sources = el["operations"]
|
||||
if sources == ["access"]:
|
||||
include_static_to_ids_tmp = False
|
||||
comment = "Operations: " + ", ".join(str(x) for x in sources)
|
||||
else:
|
||||
comment = ""
|
||||
|
||||
r['results'].append({'types': types, 'values': values, 'comment': comment, 'to_ids': include_static_to_ids})
|
||||
r['results'].append({'types': types, 'values': values, 'comment': comment, 'to_ids': include_static_to_ids_tmp})
|
||||
if pattern == "urls":
|
||||
for el in patterns[pattern]:
|
||||
values = el["url"]
|
||||
types = ["url"]
|
||||
if "sources" in el:
|
||||
if "operations" in el:
|
||||
sources = el["operations"]
|
||||
comment = "Operations: " + ", ".join(str(x) for x in sources)
|
||||
else:
|
||||
|
|
Loading…
Reference in New Issue