Skip to content

Commit

Permalink
fix: report module for 4.17
Browse files Browse the repository at this point in the history
  • Loading branch information
98jfran committed Jan 4, 2021
1 parent 6ea549b commit bf626d7
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
10 changes: 8 additions & 2 deletions autopsy.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
from psy.report import ReportOutput
from psy.processor import DataSourcesPanelSettings
from psy.settings import ProjectIngestSettingsPanel, ProjectReportSettingsPanel
from psy.psyutils import PsyUtils

#3 Modules - Ingest, Report, DatasourceProcessor
class ProjectIngestModuleFactory(IngestModuleFactoryAdapter):
Expand Down Expand Up @@ -66,9 +67,14 @@ def getName(self):
def getDescription(self):
return "Forensic Analysis for Mobile Apps Framework Report Generator"

def generateReport(self, baseReportDir, progressBar):
def generateReport(self, settings, progressBar):
autopsy_version = PsyUtils.get_autopsy_version()
baseReportDir = settings
if (autopsy_version["major"] == 4 and autopsy_version["minor"] >= 16):
baseReportDir = settings.getReportDirectoryPath()

self.report.generateReport(baseReportDir, progressBar)

def getConfigurationPanel(self):
self.configPanel = ProjectReportSettingsPanel()
return self.configPanel
Expand Down
2 changes: 1 addition & 1 deletion modules/autopsy/tiktok.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def process_report(self, datasource_name, file, report_number, path):

data = Utils.read_json(path)

self.uid = data.get("profile").get("uid")
self.uid = data.get("profile").get("uid") if data.get("profile").get("uid") else ""

self.process_messages(data.get("messages"), file)
self.process_user_profile(data.get("profile"), file)
Expand Down
2 changes: 1 addition & 1 deletion psy/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def initComponents(self):

autopsy_version = PsyUtils.get_autopsy_version()

if ((autopsy_version["major"] == 4 and autopsy_version["minor"] <= 16) or autopsy_version["major"] < 4):
if ((autopsy_version["major"] == 4 and autopsy_version["minor"] <= 17) or autopsy_version["major"] < 4):
self.p_info.add(self.lb_info)
self.p_info.add(self.lb_info2, BorderLayout.SOUTH)

Expand Down

0 comments on commit bf626d7

Please sign in to comment.