Skip to content

Commit

Permalink
remove timeliner custom
Browse files Browse the repository at this point in the history
  • Loading branch information
Davide Arcuri committed Jan 19, 2024
1 parent fcd59a1 commit e54ae37
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 38 deletions.
1 change: 1 addition & 0 deletions orochi/templates/website/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ <h5 class="offcanvas-title" id="leftNoteLabel">History Log</h5>
table = $("#example").DataTable({
scrollY: 600,
scrollX: true,
ordering: false,
ajax: {
url: "{% url 'website:generate' %}",
data: function (d) {
Expand Down
39 changes: 1 addition & 38 deletions orochi/website/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ def generate(request):
settings.MEDIA_ROOT, item_index, plugin.name
)

if plugin.name == "windows.dlllist.dlllist":
if plugin.name.lower() == "windows.dlllist.dlllist":
glob_path = "{}/pid.{}.{}.*.{}.dmp".format(
base_path,
item["PID"],
Expand Down Expand Up @@ -516,37 +516,7 @@ def generate(request):
item["reports"] = ""
item["actions"] = ""

# TIMELINER PAINT ROW BY TYPE
if plugin.name == "timeliner.timeliner":
columns = [x for x in item.keys() if x.find("Date") != -1]
other_columns = [x for x in item.keys() if x.find("Date") == -1]

parsed = False
for column in columns:
if item[column]:
parsed = True
row = {
"__children": [],
"Date": item[column],
"Type": column,
"row_color": COLOR_TIMELINER[column],
}
for oc in other_columns:
row[oc] = item[oc]

if not parsed:
row = {
"__children": [],
"Date": None,
"Type": None,
"row_color": None,
}
for oc in other_columns:
row[oc] = item[oc]
item = row

item.update({"color": COLOR_TEMPLATE.format(colors[item_index])})

list_row = []
for column in ui_columns:
if column in item.keys():
Expand Down Expand Up @@ -635,13 +605,6 @@ def analysis(request):
):
columns += ["reports"]

# TIMELINER HAS SOME CUSTOM RENDERED COLUMS
if res.plugin.name.lower() == "timeliner.timeliner":
columns += ["Date", "Type", "row_color"]
columns = [
x for x in columns if x not in COLOR_TIMELINER.keys()
]

# DEFAULT COLUMN ADDED
columns += ["hashes", "color", "actions"]
except elasticsearch.NotFoundError:
Expand Down

0 comments on commit e54ae37

Please sign in to comment.