iOS sysdiagnose Analysis: Logs, shutdown.log and More
Collect and analyse an iPhone sysdiagnose: archive layout, unified logs, shutdown.log, PowerLog copies, crash reports, Wi-Fi data and the tools that parse them.
A sysdiagnose is the diagnostic archive Apple engineers ask for when something goes wrong. For an examiner, it is a snapshot of the device's logs and state at a known moment, obtainable without any exploit, agent or jailbreak. It holds the Unified Logs, shutdown.log, recent PowerLog databases, crash reports, process lists, network and Wi-Fi state, and dozens of configuration files.
The acquisition guide places the sysdiagnose among the other acquisition levels. This guide goes into it: how to collect it cleanly, what is inside, which files answer which questions, and which tools parse them.
Why collect one
- Volatile evidence. Unified logs keep days, crash reports weeks. A sysdiagnose taken today preserves what a full file system extraction next month would not find.
- Low impact. It uses a built-in mechanism. The only change to the device is the archive itself and whatever the triggering writes to the logs.
- Compromise checks. shutdown.log, process lists and crash reports are key sources in spyware triage.
- Pattern of life without extraction. Recent PowerLog copies are included.
It does not contain user content such as messages or photos, and it is no substitute for a backup or an extraction.
Triggering and retrieving
- Note the exact time from a reference clock.
- Press and briefly hold both volume buttons and the side button together for about one to one and a half seconds, until a short vibration. On some models a screenshot is also taken; that is expected.
- Wait. Generation takes several minutes. Do not lock and unlock repeatedly or reboot.
- Retrieve the archive: on the device under Settings > Privacy & Security > Analytics & Improvements > Analytics Data (share it by AirDrop or cable), or from a trusted computer with
pymobiledevice3:
pymobiledevice3 crash ls | grep sysdiagnose
pymobiledevice3 crash pull ./case/diag # copies diagnostic files without erasing them (no --erase)
pymobiledevice3 crash sysdiagnose ./case/diag # waits for a new sysdiagnose, then pulls it
The crash sysdiagnose command still needs the sysdiagnose to be triggered on the device; its help text says it requires user interaction. Record the method you used. Hash the .tar.gz immediately:
shasum -a 256 ./case/diag/sysdiagnose_*.tar.gz > ./case/diag/sysdiagnose.sha256
File names follow sysdiagnose_<YYYY.MM.DD_HH-MM-SS><offset>_iPhone-OS_iPhone_<build>.tar.gz, which gives the local time of generation and the iOS build.
What is inside
Extract a working copy (tar -xzf). The layout varies by release, but the main parts are stable:
| Path in the archive | Content | Use |
|---|---|---|
system_logs.logarchive/ | Unified Logs | Detailed event history of the last days |
system_logs.logarchive/Extra/shutdown.log | Processes delaying each shutdown | shutdown.log analysis |
logs/powerlogs/ | PowerLog databases | PowerLog app runtime, screen, camera |
crashes_and_spins/ | Crash, hang and JetsamEvent reports | Crash logs |
ps.txt, ps_thread.txt, taskinfo.txt | Processes at collection time | Running processes, parents, start times |
logs/MobileInstallation/, app installation logs | Install and uninstall events | Installed apps |
WiFi/ and Wi-Fi plists | Known networks, scans, Wi-Fi logs | Known networks |
logs/Accessibility/TCC.db | Copy of TCC | TCC.db |
remotectl_dumpstate.txt, SystemVersion.plist | Device and OS information | Identification |
security-sysdiagnose.txt | Keychain metadata (not secrets) | Accounts and services in use |
logs/MobileActivation/, logs/MobileLockdown/ and others | Activation, pairing and service logs | Device history, trusted computers |
List the contents of your archive (tar -tzf) and keep the list in your notes: absent files are findings too.
Unified logs
The system_logs.logarchive bundle holds the device's Unified Logging data. On a Mac, read it with the built-in log command:
log show --archive system_logs.logarchive --info --debug \
--start '2026-09-12 20:00:00' --end '2026-09-12 23:00:00' \
--predicate 'process == "SpringBoard"' > springboard.txt
log show --archive system_logs.logarchive --style ndjson \
--predicate 'subsystem == "com.apple.locationd.Core"' > locationd.ndjson
On Linux, Mandiant's macos-UnifiedLogs library and its example parser read the same archives. Times printed by log show are in the examiner machine's time zone unless you set TZ=UTC; do that.
Useful searches depend on the case: lock and unlock events from SpringBoard and the keybag, app launches from runningboardd, Wi-Fi associations from wifid, Bluetooth connections, location authorisations, and network connections from nesessionmanager or symptomsd. Message and subsystem wording changes between releases, so validate any predicate against a test device.
Retention is the constraint. Most detail is gone within days. Report the earliest and latest log entries in the archive.
shutdown.log
Each shutdown appends a block listing processes that did not exit in time, with PID and path, closed by a SIGTERM: [<unix time>] line. Kaspersky's 2024 research showed Pegasus and other implants delaying reboots from paths under /private/var/db/ and /private/var/tmp/, and published iShutdown to parse it.
Researchers reported in late 2025 that iOS 26 rewrites the file at reboot rather than appending, which would keep only the latest shutdown. Verify on your build. Either way, the order is: collect a sysdiagnose first, and only then consider a controlled reboot followed by a second sysdiagnose, knowing that the reboot returns the device to BFU. Details are on the shutdown.log page.
Processes
ps.txt and related files list processes running at collection time with their paths, users and start times. Look for executables outside the usual system paths, unexpected processes running as root, and names that match leads from DataUsage, JetsamEvent reports or shutdown.log. The EC-DIGIT-CSIRC analyser has a ps_everywhere analyser that collects process names from every source in the archive and a ps_matrix that compares them.
PowerLog and crash reports
The PowerLog databases in logs/powerlogs/ can be parsed exactly like those from a file system extraction, with the same time offset correction. Crash and JetsamEvent reports in crashes_and_spins/ are .ips files with a JSON metadata line; see crash logs for the fields. Both are frequently duplicated in later sysdiagnoses and in a full file system; deduplicate by incident ID or content before counting.
Tools
- EC-DIGIT-CSIRC sysdiagnose (Sysdiagnose Analysis Framework). Case-based:
saf create <archive>, thensaf -c <id> parse allandsaf -c <id> analyse <name>. Parsers cover shutdown logs, crash logs, PowerLog, processes, Wi-Fi, TCC, app installation and more; analysers produce app lists, process matrices, Wi-Fi geolocation files, YARA scans and a Timesketch-ready timeline. Tested on iOS 15 to 26 according to the project. - iLEAPP. Reads packed sysdiagnose archives directly for shutdown logs, PowerLog, installation logs and more, alongside other evidence.
- iShutdown. Focused on shutdown.log.
- iOS sysdiagnose forensic scripts. Older scripts for specific files (network interfaces, mobile activation, app state); check them against current layouts.
logon macOS, or macos-UnifiedLogs on Linux, for the log archive.
A workflow
- Collect and hash the archive. Record the trigger time and method.
- Extract a working copy. List its contents.
- Run the SAF parsers or iLEAPP for a broad first pass.
- Review
shutdown.log, processes and crash reports for compromise leads. - Query the unified logs for the time window of interest, in UTC.
- Add PowerLog and Wi-Fi data to the timeline.
- Compare with a sysdiagnose from a clean reference device on the same build if you have leads.
Other files worth opening
Beyond the headline sources, a sysdiagnose carries many small files that answer specific questions. Names and locations vary by release, so search the extracted tree rather than relying on a fixed path:
- Wi-Fi. Copies of known networks plists, recent scan results and Wi-Fi logs. The EC-DIGIT-CSIRC framework parses them and can turn geolocated scans into GPX or KML files. Treat scan-based locations with the same caution as locationd caches.
- Mobile activation and lockdown logs. Activation history, pairing and trust events. Useful to see when the device was set up, restored or paired with a computer.
- Network state. Interface configuration, VPN and network extension caches (
networkextensioncache), which complement configuration profiles. - iCloud Drive state (
brctloutput) and associated domains (swcutil), which show synced containers and app associated domains. - Keychain metadata in
security-sysdiagnose.txt: item classes and services, never the secrets themselves. - Spindumps and stackshots, for hangs and for process lists at the time of the dump.
When a file answers your question, note its exact path inside the archive and the archive hash: that is the locator a reviewer needs.
When to take more than one
One sysdiagnose is a snapshot. Two or more, taken deliberately, can show change:
- Before and after a reboot, when shutdown.log history matters and the device state allows a reboot. The second archive records the processes running at that shutdown.
- At seizure and at extraction, to preserve volatile logs early and document the device's state when the extraction started.
- During an active incident, to capture logs while suspicious behaviour is ongoing, for example after the user receives an unexpected message.
Name archives consistently, keep each hash, and note what happened between them. Older sysdiagnose archives that the owner generated for Apple Support, or that remain in Analytics Data, are also evidence: collect them all.
Privacy considerations
A sysdiagnose contains less user content than a backup, but it is not anonymous. Unified logs can hold contact identifiers, Wi-Fi network names, app names, location-related messages and, depending on apps, fragments of user data. Treat the archive as sensitive case material, limit sharing to what the mandate allows, and when a user sends one to a helpline for a spyware check, explain beforehand what it contains.
Reporting a sysdiagnose
A sysdiagnose finding reads well when it states the collection context first: device, iOS build, device state, trigger time and method, retrieval method, archive name and hash. Then list the files examined, the tools and versions used, and the time range each source covered (for example, "unified logs from 2026-09-08 04:12 to 2026-09-12 21:30 UTC; shutdown.log from 2026-03-02 to 2026-09-10"). Close with what the sysdiagnose cannot show: no user content, and only the log history the device still had. If you took two sysdiagnoses around a controlled reboot, describe both and why.
Common mistakes
- Collecting the sysdiagnose after updating or rebooting the device.
- Reading
log showoutput in local time and mixing it with UTC sources. - Treating a process in
ps.txtas suspicious without a baseline. - Counting PowerLog or crash events twice because they appear in several archives.
- Forgetting to note when the buttons were pressed, then finding the examiner's own actions in the logs without context.