Skip to content

Commit

Permalink
Merge pull request #974 from snoop168/idstatuscache
Browse files Browse the repository at this point in the history
detect proper file based on ios version comments
  • Loading branch information
snoop168 authored Dec 13, 2024
2 parents a4c4c13 + 1f4202b commit 1fd80a2
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions scripts/artifacts/idstatuscache.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
import plistlib
from scripts.artifact_report import ArtifactHtmlReport
from scripts.ilapfuncs import logfunc, tsv, timeline, convert_ts_int_to_utc, convert_utc_human_to_timezone
import scripts.artifacts.artGlobals
from packaging import version

# service type and partner
def get_service_type_and_partner(value : str):
Expand Down Expand Up @@ -333,7 +335,13 @@ def get_idstatuscache(files_found, report_folder, seeker, wrap_text, timezone_of

for file_found in files_found:
# com.apple.identityservices.idstatuscache.plist (until iOS 14.6.0)
# idstatuscache.plist (from iOS 14.7.0)
if file_found.endswith('com.apple.identityservices.idstatuscache.plist') or file_found.endswith('idstatuscache.plist'):
get_identity_services(file_found, identifiers, report_folder, timezone_offset)
break
# idstatuscache.plist (from iOS 14.7.0)
iosversion = scripts.artifacts.artGlobals.versionf
if version.parse(iosversion) < version.parse("14.7.0"):
if file_found.endswith('com.apple.identityservices.idstatuscache.plist'):
get_identity_services(file_found, identifiers, report_folder, timezone_offset)
break
elif version.parse(iosversion) >= version.parse("14.7.0"):
if not file_found.endswith('com.apple.identityservices.idstatuscache.plist') and file_found.endswith('idstatuscache.plist'):
get_identity_services(file_found, identifiers, report_folder, timezone_offset)
break

0 comments on commit 1fd80a2

Please sign in to comment.