Anatomy of an .ipsw
Context
An .ipsw is the restore archive for an Apple device. Underneath, it is a ZIP archive. It holds everything needed to reinstall the iOS system.
This article takes the archive apart, components by components. It also covers how to analyze the contents, with the tools most researchers use.
The running example here is the IPSW of an iPhone 16 Pro Max, on iOS 26.5, build 23F77.
The document is built to grow, subject to evolve.
One last detail. Every file carries the same date, 9 January 2007 at 09:41. The build does not record each file's real write time. It sets them all to one fixed value. That keeps the archive reproducible, byte for byte, and leaks no real build dates. The value itself is a nod: 9 January 2007 was the Macworld keynote where the first iPhone was unveiled, and 9:41 is the time its clock showed at the reveal, the time Apple's ads still use.
The five components
The thirteen items in the archive fall into five components. What sets them apart first is whether they are encrypted.
- System images (
.dmg.aea). The system itself, encrypted. Covered in chapter 1. - Ramdisks (
.dmg). Restore and update RAM disks, in the clear. Chapter 2. - Kernel (
kernelcache). The XNU kernel and its extensions. Chapter 3. - Firmware (folder). The low level: boot chain, SEP, baseband. Chapter 4.
- Manifests (
.plist). The metadata.BuildManifestdrives the restore. Chapter 5.
Seeing the five
Two commands turn the diagram into something on screen. The first reads the archive and prints it as a table.
ipsw info iPhone17,2_26.5_23F77_Restore.ipsw
ipsw info on the archive. The system images first (FileSystem, SystemOS, AppOS, ExclaveOS), then the two restore ramdisks, then the device the build is cut for: an iPhone 16 Pro Max, A18 Pro, chip t8140.Every component is named by its role and matched to the image that carries it. FileSystem is the root volume. SystemOS and AppOS are cryptexes, ExclaveOS a newer one. The two RestoreRamDisk entries are the ramdisks from chapter 2. The header reads the build, 26.5 / 23F77, and lists the boot chain it ships, iBEC, iBoot, iBSS, LLB, sep-firmware, each an Image4 from chapter 4.
The second view is the same set unzipped, as a directory.
.dmg.aea system images, the plain .dmg ramdisks, the Firmware folder, the lone kernelcache, and the .plist manifests. The diagram's five components, now as files.The sizes track the architecture from chapter 1. The 8.12 GB .aea is the root volume; the 2.01 GB one is the OS cryptex that holds the dyld shared cache; the smaller images are the other cryptexes. And every file carries the same timestamp, 9 January 2007 at 09:41, the signature from the start of this document, made literal.
The logic behind restore
The layout of the archive follows the restore. Each family serves one step.
The device enters DFU mode. iBoot loads the second-stage bootloaders, iBSS then iBEC. The kernel and the ramdisk then mount a minimal environment in memory. ASR decrypts the system image there and writes it to storage. The firmware components are "flashed".
The last lock is the signature. Each component must be signed by Apple's signing server, it is called the TSS. The host sends the device ECID and a nonce. Apple returns an APTicket, valid only while the version is signed. This signing window is what stops you from installing, or rolling back to, a version Apple no longer signs over TSS.
Chapter 1: System images (root + cryptex)
The four .dmg.aea files, once decrypted, are the operating system. But modern iOS is not a single volume. It is a sealed root volume, with cryptexes grafted on at boot. Understanding this split is knowing where to look for what.
Architecture
The root volume, the ~8.12 GB file, becomes the Signed System Volume (SSV) on the device: a sealed APFS snapshot the system boots from. It is the classic Unix tree: /System, /usr, /bin, the daemons, the dyld loader, the base system apps. The seal is a hash tree anchored in the boot chain. Change one byte and the seal breaks.
A sealed volume is safe, but honestly still rigid. You cannot patch it without rebuilding it. Hence the cryptexes. A cryptex is a disk image, itself sealed, grafted on top of the SSV at boot, with its own hash in the chain of trust. The mechanism comes from Apple's Security Research Device, then served the Rapid Security Responses.
Two cryptexes matter here. The OS cryptex holds the dyld shared caches and a few libraries. The App cryptex carries Safari, WebKit, and JavaScriptCore. The point is clear: Apple can patch WebKit by swapping the App cryptex, without touching the SSV or forcing a full update.
On the file side, the four .dmg.aea map to the root (8.12 GB), the OS cryptex (~2.01 GB, most of the dyld cache), and likely the App cryptex with a smaller companion image (155 and 235 MB). Recent versions add cryptexes for Apple Intelligence. The exact mapping is labeled in BuildManifest.plist, under names like Cryptex1,SystemOS and Cryptex1,AppOS.
The AEA layer
The .aea extension is an encryption wrapper around the DMG. AEA1 encrypts the images in IPSWs and OTAs. Decryption rests on FCS keys and an HPKE key unwrap.
The important point: this wrapper does not hide the firmware. The keys are publicly retrievable, from Apple's WKMS service or a community database like AppleDB. It exists to control distribution, not to block analysis. Decrypting to study is routine.
The analysis method
The principle is simple. You extract the image, decrypt it, mount the volume, explore, extract the dyld shared cache, then analyze the binaries.
The real prize is the dyld shared cache, in the OS cryptex (System/Library/Caches/com.apple.dyld/ once mounted). It is a single file, actually split into subcaches, that bundles most public and private frameworks, pre-linked. Why it matters: since iOS 8, the SDK no longer ships the extracted frameworks. The only way to get the real library code from the device is to pull it from the cache. To reverse a private framework, you extract it from there first.
macOS and Linux are not equal here. On macOS, a decrypted APFS DMG mounts natively. On Linux, you need apfs-fuse, but since iOS 16 Apple compresses some cryptex files with LZBITMAP, which older versions cannot read. So most research happens on Apple Silicon Macs.
To get started:
ipsw mount fs <IPSW>. Mounts the system. AEA decryption is automatic.ipsw extract --dyld <IPSW>. Pulls out the dyld shared cache.ipsw extract --dmg fs|sys|app <IPSW>. Pulls out a specific image (root, OS cryptex, App cryptex).ipsw dyld splitandipsw dyld info. Split the cache into dylibs and inspect it.ipsw ent <IPSW>. Extracts entitlements. A good starting point for mapping attack surface.
The method, run on this archive
That is the method in the abstract. Here it is, command by command, on the iPhone17,2 image.
Mount first. The AEA is decrypted inside the command; there is no key to pass by hand.
ipsw mount fs iPhone17,2_26.5_23F77_Restore.ipsw
ipsw decrypts the AEA, turns the root image into a plain DMG, and mounts it. The volume is 094-54688-098.dmg, the 8.12 GB FileSystem image from ipsw info. Ctrl+C unmounts it when you are done.The mounted volume is the system itself, now a filesystem to walk.
/System, /usr, /bin, the daemons, the loader. Disk Utility names it, a sealed APFS system volume, case-sensitive, macOS 26.5 (23F77), mounted at /private/tmp/094-54688-098.dmg.mount. The archive has become a tree.The prize sits in the OS cryptex. Pull the dyld shared cache out for study.
ipsw extract --dyld iPhone17,2_26.5_23F77_Restore.ipsw
ipsw writes the cache out. It is not one file but many: numbered subcaches, the .dylddata, .dyldreadonly, and .dyldlinkedit splits, then .atlas and .symbols to close.On disk the shape is plain. One logical cache, split across dozens of files.
.01 upward, each a subcache. Eighty-nine items here. The large ones are framework code, the small ones metadata.The names say what each piece is.
dyld_shared_cache, the architecture arm64e, then the subcache index. One slice of the system frameworks, pre-linked.From here the method finishes as listed above: ipsw dyld split recovers the individual frameworks as separate Mach-O files, then a disassembler reads them. This cache is the only place that code exists off the device, which is why the extraction is the gate to everything inside it.
Chapter 2: Ramdisks and ASR
Before any system is written, the device needs somewhere to run from. The target storage is about to be erased or rewritten, so the restore cannot run from there. It runs from memory instead. That is the ramdisk: a small, complete environment, loaded into RAM, that drives the install.
Two ship in the archive. They look almost identical. What separates them is what they are allowed to touch.
The restore ramdisk is the clean slate. It erases the device, recreates the partitions, and writes a fresh system. User data does not survive. This is the path a full restore takes, the one labeled Erase. The control program on it is restored_external.
The update ramdisk is the careful path. It applies a new system without wiping the data volume. The system volume is replaced, the data is left in place. Its control program is restored_update. This is the Update path, the one that runs when a device takes a normal software update.
On a modern arm64e device the two ship as arm64eCustomerRamDisk and arm64eUpdateRamDisk. The BuildManifest points each restore behavior at the right one. Chapter 5 covers how that selection is made.
What ASR does
The control program orchestrates. It does not do the copy itself. For the actual writing of the system it hands off to one tool: asr, Apple Software Restore, at /usr/sbin/asr inside the ramdisk. ASR is the part that moves the bytes.
Its job is narrow and it is the heart of the restore. Read the decrypted system image, verify it, write it to the target volume. The verification is not a formality. ASR checksums each block as it goes and refuses anything that does not match. A corrupt or tampered image fails here, not on first boot.
This places the ramdisk in the restore sequence from the start of the document. The kernel and ramdisk step is where this environment comes up. The ASR step that follows, the amber box that writes the system, is ASR running inside this ramdisk, reading the decrypted .aea image and writing it to storage. On modern devices the same environment also updates the Secure Enclave through seputil.
Why they stay in the clear
The firmware components are AES-encrypted, each with its own key. The ramdisks are not. They are plain disk images, mountable as they are. The reason is structural, and it is worth seeing precisely.
Both sit inside the same container, the Image4 format covered in chapter 4. Image4 carries a signature. That signature is what the boot chain checks: the device runs this ramdisk only because Apple signed it, and the signature is bound to the device through personalization. Encryption is a separate question.
Firmware payloads add an encryption layer on top of the signature. The ramdisk payload does not. Its DMG is in the clear. The integrity guarantee is identical, it comes from the signature either way, but the contents of the ramdisk are open to read. There is no key to recover. This was not always so. Older iOS encrypted the ramdisks too, and recovering their keys was a step in any analysis. Since roughly iOS 10 they ship decrypted. Today you mount and read them directly.
This matters for analysis. The ramdisk is one of the easiest parts of the archive to study, and one of the most useful. It is a working install environment: asr, restored_external, the personalization helpers, the partition tooling. The logic of the restore is right here, in plain binaries, with nothing to decrypt first.
Mounting and inspecting them
There is one catch, and it trips people up. The files named like 044-XXXXX-XXX.dmg in the archive are not mountable DMGs. They are Image4 payloads (im4p) with a DMG inside. Double-clicking fails. You extract the payload first, then mount the DMG that comes out.
With ipsw, the whole thing is one command:
ipsw mount rdisk <IPSW>. Mounts a restore ramdisk. It extracts theim4ppayload and mounts the inner DMG for you.ipsw mount rdisk <IPSW> --ident Erase. Selects which ramdisk to mount when the archive holds more than one. Without it, the first is used.
The manual route shows what is happening underneath, and is worth doing once:
ipsw extract --pattern '044-.*\.dmg' <IPSW>. Pulls the ramdisk file out of the archive.ipsw img4 im4p extract --output ramdisk.dmg 044-XXXXX-XXX.dmg. Unwraps the Image4 payload into a real DMG. On older tooling,img4 -i in -o outdoes the same.open ramdisk.dmg, orhdiutil attach ramdisk.dmg. Mounts it on macOS. It appears under/Volumes/.
Once mounted, it is a small Unix tree. The parts worth a look:
/usr/sbin/asr. The restore engine. The binary to read if you want to understand how the system is written and verified./usr/local/bin/restored_externalorrestored_update. The control program. It speaks to the host over USB and drives the sequence./usr/local/share/restore/. Restore options and behavior, including the per-device sizing the install relies on.- The other helpers.
seputilfor the Secure Enclave, the APFS and partition tools, the personalization pieces.
From there the methods from chapter 1 apply unchanged. Run ipsw macho info on a binary to read its structure, ipsw ent to pull entitlements, then a disassembler for the logic. The ramdisk binaries are small and self-contained, which makes them a clean place to start before the larger system.
A note on platform. The inner DMG here is usually HFS+ or a simple APFS image, lighter than the LZBITMAP-compressed cryptex images from chapter 1, so Linux with apfs-fuse tends to handle it without trouble. Even so, the rest of the pipeline leans on macOS, so an Apple Silicon Mac stays the path of least friction.
Chapter 3: kernelcache
The system images from chapter 1 are what the device runs. The kernelcache is what runs them. It is the executable core: the part that schedules processes, manages memory, talks to the hardware, and decides what every other piece is allowed to do. One file in the archive, around 22 MB, and the most concentrated code in the whole image.
The name is precise. It is not just the kernel. It is the kernel and its drivers, compiled and linked ahead of time into one ready-to-run unit, so the device does not assemble them at every boot. Cache, in the sense of precomputed.
What is inside
Open a desktop operating system and the kernel is one file, the drivers are many, loaded as needed. iOS does not work that way. The kernel and every built-in driver are fused into a single file, sharing one address space.
XNU is the kernel itself: the Mach core for scheduling and memory, the BSD layer for the Unix system calls and the file system, IOKit for the driver framework, libkern for the runtime. Around it sit the kexts, the kernel extensions, which are the drivers. There are several hundred. They run the GPU, the storage, the radios, and, more interesting to a researcher, the security machinery: AppleMobileFileIntegrity, the sandbox, the code-signing enforcement.
The other two pieces are metadata, and they matter for analysis. __PRELINK_INFO records every kext's identity and where it loads. The symbol sets, the KPI, define the narrow set of kernel functions a kext is permitted to call. A kext that reaches outside that set will not link. This is the seam an analyst follows to tell one driver from another inside the merged file.
Three eras of one format
The kernelcache has not always looked the same. Its format moved through three stages, and the difference is not cosmetic. It decides whether you can pull a single driver out of the file at all. This trips people up, because a guide written for one era gives steps that simply fail on another.
In the early era the kexts were loosely packed beside the kernel, each its own Mach-O. Old tools could lift one out directly. Through iOS 9 the whole thing was also encrypted, so recovering keys came first.
Then came the monolithic era. Kext code was interleaved with the kernel's own and the file was stripped of symbols. There was no clean way to separate a driver anymore. This is the era that earned the kernelcache its reputation for being hard.
The modern era reversed that, and improved on it. Since iOS 12 the kernelcache is an MH_FILESET: a Mach-O container type whose job is to hold many Mach-O binaries and map them into memory together. Each entry, the kernel and every kext, keeps its own segments and its own identity inside the container. The boot loader reads a table of entries to place each one. For an analyst, that table is a gift. The drivers are bundled but no longer blended, so a good tool can hand you a single kext as a clean, standalone binary. The iPhone 16 Pro Max on iOS 26.5 is squarely here.
Why it is in the clear
The firmware components in chapter 4 are AES-encrypted, each behind its own key. You might expect the kernel, the most sensitive code on the device, to be the most locked. On a current device it is not. It ships in the clear.
The file is wrapped in Image4 and signed, like everything else in chapter 4. The signature is what the boot chain checks. It guarantees the code is Apple's and unmodified. That is integrity, and the device enforces it strictly. Encryption is a different question, and the answer here is no. The payload is type krnl, and inside the wrapper it is only compressed, with LZSS. Decompress it and you have a plain Mach-O, recognizable by its magic bytes, 0xfeedfacf for 64-bit. There is no key to recover.
This was not always the case. Through iOS 9 the kernelcache was encrypted as well, and a generation of jailbreak work went into pulling those keys off the hardware. From iOS 10 on, Apple stopped encrypting it. The reasoning is sound: encryption was protecting code that researchers and attackers could read on the device anyway, at the cost of real friction for legitimate study. The signature, not the secrecy, is what actually protects the system. For you, the result is direct. Decompress and read.
Plain at rest does not mean unprotected at runtime. Once the kernel is loaded, the silicon guards it. On the A18 in this device, the Secure Page Table Monitor, with the Trusted Execution Monitor, runs at a higher privilege than the kernel and protects the page tables even against an attacker who already has kernel write. On older chips this role was filled by the Page Protection Layer. The kernelcache you read on disk and the kernel as it runs live under very different rules.
Extracting and reading it
The pipeline mirrors chapter 1: get the file out, get past the wrapper, then explore. The wrapper here is simpler, since there is nothing to decrypt.
The fast path is one command. ipsw extract --kernel <IPSW> pulls the kernelcache out and decompresses it in the same step, leaving a Mach-O fileset ready to read. If you ever have a raw im4p in hand, ipsw kernel dec decompresses it on its own.
From there the useful commands:
ipsw kernel version <kernelcache>. Reads the build string. It tells you the XNU version, the build date, and the target chip, for exampleRELEASE_ARM64_T8140on this device. A quick way to confirm you have the right file.ipsw kernel kexts <kernelcache>. Lists every kext in the fileset with its bundle ID and version. This is your index into the file.ipsw kernel extract <kernelcache> <bundle-id> --imports. Pulls one kext out as a standalone Mach-O. The--importsflag is the important part: it scans the other entries and writes the resolved names back into the symbol table, so calls into the kernel show as names rather than bare addresses. The result loads cleanly in IDA Pro or Ghidra.ipsw kernel kexts --diff <old> <new>. Lists which kexts changed between two builds. Paired with the version diffing from the appendix, this is how you find what a security update actually touched, without reading the whole kernel.
A concrete path makes it real. To study how the sandbox is enforced, list the kexts, find com.apple.security.sandbox, extract it with --imports, and open it in a disassembler. You are now reading the policy engine that decides what every app on the device may do, as a single clean binary, with nothing decrypted along the way.
One platform note carries over from chapter 1. The disassembly itself is portable, but the surrounding workflow, the symbol resolution and the version diffing, leans on macOS. An Apple Silicon Mac stays the smoother path.
Chapter 4: Firmware
So far the archive has opened up. The system images mounted. The ramdisks mounted. The kernel decompressed and read. This chapter is the part that mostly does not open. The firmware is the lowest layer, the code that runs before the kernel and beside it, and on a modern device it is the one family you cannot read.
It is also where the format the whole document keeps naming finally gets explained. Every component here, and in truth every signed component in the archive, is wrapped in Image4. Start there.
The Image4 container
Image4 is the wrapper. It replaced the older IMG3 on every 64-bit Apple device, and unlike IMG3's custom layout, it is a standard ASN.1 structure in DER encoding. The same container holds the bootloaders, the kernel from chapter 3, the ramdisks from chapter 2, and the firmware here. Learn it once and the whole archive reads the same way.
Three parts. The IM4P is the payload, the actual thing being shipped, tagged with a four-character type so the device knows what it is: ibot for iBoot, krnl for the kernel, sepi for the Secure Enclave, and so on. If the payload is encrypted, the IM4P also carries a KBAG, a keybag holding the key, itself wrapped so only the right chip can open it. This is the im4p you met in chapter 2, when a ramdisk DMG would not mount and you had to extract the payload first.
The IM4M is the manifest, and it is the only signed part. It holds hashes of the components it vouches for and the certificate chain back to Apple. This is what the boot chain actually checks. It is the modern form of the APTicket from the glossary, the device-bound ticket the TSS produces. The IM4R is the smallest piece and usually the only optional one. It carries the boot nonce, a fresh value per restore, which ties a given signature to a single boot and stops an old signed image from being replayed later.
The chain of trust
The firmware components are not a pile of files. They are an ordered chain, and the order is the security. Each stage verifies the next, by its Image4 signature, before it hands over control. Break any link and the next stage refuses to run.
It begins in the BootROM, code burned into the silicon at manufacture. It cannot be changed, so it is the root: whatever it trusts, the chain trusts. On a modern device the BootROM loads iBoot directly. Older devices had a separate first stage, the LLB, the Low Level Bootloader, but on recent silicon one iBoot image handles every phase, so the LLB no longer ships as its own file. iBoot initializes the hardware, then verifies and runs the kernelcache. That is the link back to chapter 3: the kernel runs only because iBoot checked its signature first. Alongside the bootloaders sits iBootData, a small data blob iBoot consumes, not code of its own.
The restore path is a branch off the same trunk. When the device is in DFU, the BootROM loads iBSS, the single-stage iBoot, which loads iBEC, the restore-mode iBoot. These are the signed bootloaders the restore sequence named at the start of the document, and the ones that bring up the environment chapter 2's ramdisk runs in. Off to the side, the Secure Enclave boots in parallel. It has its own boot ROM and its own signed operating system, sepOS, and the main processor never sees inside it.
Why you cannot read it
Here the firmware breaks from everything before it. The kernel was wrapped and signed but not encrypted, so you decompressed it and read it. The firmware is wrapped, signed, and encrypted, each component behind its own key. And on this device, those keys are out of reach.
The mechanism is the KBAG in the IM4P. The key for the payload sits there, but wrapped, encrypted to the chip's GID key, a key fused into the silicon that never leaves it. To unwrap it you must run the GID key, and the GID key only runs inside the hardware AES engine. So decryption is not a matter of finding a file. It needs code execution on the chip itself, in the narrow window before the kernel loads and the GID engine is switched off. The boot-chain components are keyed to the application processor's GID key. The SEP firmware has its own, keyed to the Secure Enclave's GID, a separate lock again.
That window is exactly what a bootrom exploit opened. On A11 and earlier, checkm8 gave researchers code execution in the BootROM, which let them run the GID key and recover the firmware keys. That is why old firmware can be decrypted and why community key databases exist. But checkm8 does not reach A12 and later. This device is an A18. There is no public BootROM exploit for it, the GID key stays sealed, and the firmware keys cannot be pulled. The diagrams in this document call the firmware family AES-encrypted, and on this hardware that is the end of the story for the public side. It stays opaque.
This is the exact mirror of chapter 3. The kernel is the most sensitive code, shipped in the clear, because the signature is what protects it. The firmware is lower still, shipped encrypted, with keys you cannot reach. Same archive, opposite postures, and worth holding both in mind: signing is about integrity, encryption is about secrecy, and Apple applies them independently. The history is a steady retreat of secrecy. Early devices encrypted nearly everything and the keys leaked. Then the kernel was left in the clear. The firmware kept its encryption, and from A12 on the keys finally became unreachable rather than merely undiscovered.
Signing and personalization
The signature is checked at every step, but a plain signature would be replayable: capture one signed image, install it forever. Apple closes that with personalization. The signature is bound to one specific device, and granted only while Apple still signs that version. This is the personalization step the restore sequence named at the very start of the document.
The host reads two things off the device: the ECID, a unique chip identifier, and a fresh nonce. It sends them to Apple's signing server, the TSS, with the build manifest from chapter 5. The TSS signs, but only for components it still signs at that moment, and returns a manifest, the APTicket, valid for that ECID and that nonce alone. At boot, each stage checks the ticket: the component hashes must match, the ECID must match, and the nonce must be current. If any is off, it refuses.
Two consequences fall out of this. The image is not portable: a manifest signed for one phone is useless on another, because the ECID will not match. And there is no downgrade: once Apple stops signing a version, the signing window closes, the TSS will not produce a ticket for it, and you cannot install it even with every file in hand. The personalization box in the restore sequence is this handshake. The IM4M from the first section of this chapter is the APTicket that comes out of it.
What is in the folder
Even where you cannot decrypt it, it is worth knowing what the Firmware folder holds, because the shape of it tells you how the device is built.
The boot chain lives in dfu/ and all_flash/: LLB where present, iBoot, iBSS, iBEC, iBootData, and the small images shown at boot. The coprocessor firmware is the Secure Enclave (sepi), the always-on processor that listens for "Hey Siri" while the device sleeps, and the firmware for the GPU and Neural Engine. The baseband is the cellular modem's own software, running on its own processor and signed on its own track, which is why a baseband update is a separate event. Each of these is an Image4, signed, and on this device mostly encrypted.
The device trees are the exception, and the one part here you can actually read. A device tree is the hardware map handed to the kernel at boot: which chips exist, at which addresses, on which buses. It is not encrypted, because it is configuration rather than code. ipsw fw devicetree parses it, and reading it is a quiet way to see what hardware the system expects.
What you can still do
The firmware resists analysis on this hardware, but not completely, and knowing where the edges are saves wasted effort.
- Inspect the wrappers.
ipsw img4 im4p info <file>reads the Image4 metadata: the type tag, the description, whether a KBAG is present. You learn what a component is, and whether it is encrypted, without decrypting anything. - Read the manifest. The IM4M is not encrypted.
ipsw img4 im4m info <file>shows what a build vouches for. Paired with the version diffing from the appendix, it tells you which firmware components changed between builds, even when you cannot read inside them. - Read the device trees. Unencrypted, and a clean view of the hardware.
ipsw fw devicetree <file>. - Decrypt only old, exposed firmware. For A11 and earlier, keys exist.
ipsw img4 im4p extract --iv <iv> --key <key> <file>decrypts with a known key, and the--lookupflag will fetch one from the community database. Useful for studying how the boot chain worked, on hardware where it is open. Not this device. Other parsers do the same:pyimg4andimg4tool.
The honest summary: on a current iPhone the firmware is the wall at the bottom of the archive. You can map it, name its parts, read the manifests and the device trees, and watch it change between versions. You cannot, for the most part, read what it does. That boundary is not a gap in tooling. It is the security model holding.
Chapter 5: Manifests
BuildManifest.plist as the conductor. Update and Erase behaviors. The link to personalization and the chain of trust. Reading the other .plist files.Appendix A: Methodology and tooling
Main tool: ipsw (blacktop). It consolidates the whole pipeline and handles AEA decryption automatically.
- Install (macOS):
brew install blacktop/tap/ipsw. - Decryption keys:
ipsw dl appledbbuilds and updatesfcs-keys.json, reusable offline. - Ecosystem:
apfs-fuse(Linux),hdiutiloropen(macOS), DyldExtractor, class-dump, then Hopper, Ghidra, IDA, or radare2 for disassembly.
One practice that changes everything: version diffing. ipsw compares two IPSWs and lists what changed, binaries added, removed, modified. That is how you target what a security fix touched, without guessing.
Discipline: work read-only, keep the originals, keep fcs-keys.json up to date, go from broad to specific.
Glossary
- SSV (Signed System Volume). Sealed snapshot of the system volume, verified at boot.
- Cryptex. Sealed disk image, grafted onto the system at boot, updatable on its own.
- AEA (Apple Encrypted Archive). Encryption wrapper for DMGs, in IPSWs and OTAs.
- FCS. Keys used to decrypt AEA, retrieved from Apple (WKMS).
- dyld shared cache. Large file bundling the system frameworks, pre-linked.
- ASR (Apple Software Restore). Tool that writes the system image to storage.
- APTicket / SHSH. Device-bound signing ticket, produced by the TSS.
- ECID. Unique identifier of the device chip.
- kernelcache. XNU kernel and its extensions, precompiled.
- BuildManifest. Manifest listing the components and driving personalization.
References
- The Apple Wiki: Apple Encrypted Archive
- blacktop/ipsw: documentation and DeepWiki
- The Eclectic Light Company: cryptexes
- The Apple Wiki: dyld shared cache
- sgan81/apfs-fuse: LZBITMAP compression
- Wikipedia: IPSW
- EveryMac: iPhone 16 Pro Max (iPhone17,2)