Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pirvacy dashbord update #478

Merged
merged 3 commits into from
Apr 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion scripts/artifacts/FCMQueuedMessagesDump.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ def get_fcm_dump(files_found, report_folder, seeker, wrap_text, time_offset):
for package, rows in package_tables.items():
report = ArtifactHtmlReport(f"Firebase Cloud Messaging Queued Messages Dump: {package}")
report_name = f"FCM-Dump-{package}"
scripts.ilapfuncs.logfunc(report_name)
report.start_artifact_report(report_folder, report_name)
report.add_script()
data_headers = ["Timestamp", "Originating File", "Record ID", "Key", "Value"]
Expand Down Expand Up @@ -124,7 +125,7 @@ def get_fcm_dump(files_found, report_folder, seeker, wrap_text, time_offset):
try:
datos = json.loads(datos)
except:
logfunc('Error reading json data')
scripts.ilapfuncs.logfunc('Error reading json data')
if (type(datos)) is dict:
data_list_clean.append((fecha, origfile, datos['text'], datos['title']))

Expand Down
6 changes: 4 additions & 2 deletions scripts/artifacts/discreteNative.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import os
import datetime
import pathlib
import xml.etree.ElementTree as ET
from scripts.artifact_report import ArtifactHtmlReport
from scripts.ilapfuncs import logfunc, tsv, timeline, is_platform_windows, abxread, checkabx, logdevinfo
Expand All @@ -25,6 +26,7 @@ def get_discreteNative(files_found, report_folder, seeker, wrap_text, time_offse
data_list = []
for file_found in files_found:
file_found = str(file_found)
filename = str(pathlib.Path(file_found).name)

if os.path.isfile(file_found):
#check if file is abx
Expand Down Expand Up @@ -58,13 +60,13 @@ def get_discreteNative(files_found, report_folder, seeker, wrap_text, time_offse
ndattrib = ''
else:
ndattrib = round(int(ndattrib) / 60, 1)
data_list.append((timestampcalc(ntattrib), ptagattrib, atagattrib, oplist(otagattrib), ndattrib))
data_list.append((timestampcalc(ntattrib), ptagattrib, atagattrib, oplist(otagattrib), ndattrib, filename ))

if data_list:
report = ArtifactHtmlReport('Privacy Dashboard')
report.start_artifact_report(report_folder, 'Privacy Dashboard')
report.add_script()
data_headers = ('Timestamp', 'Bundle', 'Module', 'Operation', 'Usage in Seconds')
data_headers = ('Timestamp', 'Bundle', 'Module', 'Operation', 'Usage in Seconds', 'Source Filename')
report.write_artifact_data_table(data_headers, data_list, file_found)
report.end_artifact_report()

Expand Down