Merge branch 'main' into sequoia-development

This commit is contained in:
Mykola Grymalyuk
2024-08-20 15:26:26 -06:00
2 changed files with 10 additions and 3 deletions

View File

@@ -24,7 +24,6 @@ from ..volume import (
APPLICATION_SEARCH_PATH: str = "/Applications" APPLICATION_SEARCH_PATH: str = "/Applications"
SFR_SOFTWARE_UPDATE_PATH: str = "SFR/com_apple_MobileAsset_SFRSoftwareUpdate/com_apple_MobileAsset_SFRSoftwareUpdate.xml"
tmp_dir = tempfile.TemporaryDirectory() tmp_dir = tempfile.TemporaryDirectory()
@@ -344,9 +343,15 @@ class LocalInstallerCatalog:
if output.returncode != 0: if output.returncode != 0:
return (detected_build, detected_os) return (detected_build, detected_os)
ss_info = Path(SFR_SOFTWARE_UPDATE_PATH)
if Path(tmpdir / ss_info).exists(): ss_info_files = [
Path("SFR/com_apple_MobileAsset_SFRSoftwareUpdate/com_apple_MobileAsset_SFRSoftwareUpdate.xml"),
Path("com_apple_MobileAsset_MacSoftwareUpdate/com_apple_MobileAsset_MacSoftwareUpdate.xml")
]
for ss_info in ss_info_files:
if not Path(tmpdir / ss_info).exists():
continue
plist = plistlib.load((tmpdir / ss_info).open("rb")) plist = plistlib.load((tmpdir / ss_info).open("rb"))
if "Assets" in plist: if "Assets" in plist:
if "Build" in plist["Assets"][0]: if "Build" in plist["Assets"][0]:

View File

@@ -33,6 +33,8 @@ class KernelCacheSupport:
["teamID"] = Team ID (blank on ad-hoc signed) ["teamID"] = Team ID (blank on ad-hoc signed)
To grab the CDHash of a kext, run 'codesign -dvvv <kext_path>' To grab the CDHash of a kext, run 'codesign -dvvv <kext_path>'
""" """
if not kext_name.endswith(".kext"):
return False
try: try:
aux_cache_path = Path(self.mount_location_data) / Path("/private/var/db/KernelExtensionManagement/AuxKC/CurrentAuxKC/com.apple.kcgen.instructions.plist") aux_cache_path = Path(self.mount_location_data) / Path("/private/var/db/KernelExtensionManagement/AuxKC/CurrentAuxKC/com.apple.kcgen.instructions.plist")