Skip to content

Commit

Permalink
#66 fix typos and bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
jeromeleonard committed Jun 28, 2017
1 parent 21ac80f commit 34bed33
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 46 deletions.
2 changes: 1 addition & 1 deletion analyzers/File_Info/fileinfo_analyzer.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ def summary(self, fullReport):
level = 'suspicious'
taxonomies.append(self.build_taxonomy(level, namespace, predicate, value))
else:
value = fullReport['filetype']
value = "\"{}\"".format(fullReport['filetype'])
level = 'info'
taxonomies.append(self.build_taxonomy(level, namespace, predicate, value))

Expand Down
2 changes: 1 addition & 1 deletion analyzers/FireHOLBlocklists/firehol_blocklists.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def __init__(self):

# Check if directory exists
if not os.path.exists(self.path):
os.mkdir(self.path, mode=0o700)
os.mkdir(self.path, 0700)
# Downloading/updating the list is implemented with an external cronjob which git pulls the repo

# Read files in the given path and prepare file lists for ip- and netsets
Expand Down
2 changes: 1 addition & 1 deletion analyzers/JoeSandbox/JoeSandbox_File_Analysis_Inet.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "JoeSandbox_File_Analysis_Inet",
"version": "1.1",
"version": "2.0",
"author": "CERT-BDF",
"url": "https://github.com/CERT-BDF/Cortex-Analyzers",
"license": "AGPL-V3",
Expand Down
2 changes: 1 addition & 1 deletion analyzers/JoeSandbox/JoeSandbox_File_Analysis_Noinet.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "JoeSandbox_File_Analysis_Noinet",
"version": "1.1",
"version": "2.0",
"author": "CERT-BDF",
"url": "https://github.com/CERT-BDF/Cortex-Analyzers",
"license": "AGPL-V3",
Expand Down
2 changes: 1 addition & 1 deletion analyzers/JoeSandbox/JoeSandbox_Url_Analysis.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "JoeSandbox_Url_Analysis",
"version": "1.1",
"version": "2.0",
"author": "CERT-BDF",
"url": "https://github.com/CERT-BDF/Cortex-Analyzers",
"license": "AGPL-V3",
Expand Down
6 changes: 3 additions & 3 deletions analyzers/JoeSandbox/joesandbox_analyzer.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@ def summary(self, raw):

r = raw['detection']

taxonomy["value"] = "\"{}/{}\"".format(r["score"], r["maxscore"])
value = "\"{}/{}\"".format(r["score"], r["maxscore"])

if r["clean"]:
level = "safe"
elif r["suspicious"]:
level = "suspicious"
value = "Suspicious"
elif r["malicious"]:
level = "malicious"
value = "Malicious"



else:
Expand Down
2 changes: 1 addition & 1 deletion analyzers/MISP/misp.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def summary(self, raw):

# return number of unique events
if data == []:
value = "\"0\""
value = "\"0\event\""
taxonomies.append(self.build_taxonomy(level, namespace, predicate, value))
else:
value = "\"{} event(s)\"".format(len(list(set(data))))
Expand Down
6 changes: 2 additions & 4 deletions analyzers/Yara/yara_analyzer.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ def __init__(self):
if isinstance(self.rulepaths, str):
self.rulepaths = [self.rulepaths]

print(self.rulepaths)

self.ruleset = []
for rulepath in self.rulepaths:
if os.path.isfile(rulepath):
Expand Down Expand Up @@ -55,14 +53,14 @@ def summary(self, raw):
namespace = "Yara"
predicate = "Match"

value = "\"{} rules\"".format(len(raw["results"]))
value = "\"{} rule(s)\"".format(len(raw["results"]))
if len(raw["results"]) == 0:
level = "safe"
else:
level = "malicious"

taxonomies.append(self.build_taxonomy(level, namespace, predicate, value))
return {"taxomonies": taxonomies}
return {"taxonomies": taxonomies}

def run(self):
if self.data_type == 'file':
Expand Down
33 changes: 0 additions & 33 deletions thehive-templates/Abuse_Finder_1_0/long.html

This file was deleted.

0 comments on commit 34bed33

Please sign in to comment.