### Install and Start PostgreSQL Source: https://blacktop.github.io/ipsw/docs/guides/symbolicate Installs PostgreSQL version 16 using Homebrew and provides commands to start the service either as a background service or manually. ```bash brew install postgresql@16 brew services start postgresql@16 LC_ALL="C" /opt/homebrew/opt/postgresql@16/bin/postgres -D /opt/homebrew/var/postgresql@16 ``` -------------------------------- ### Quick Start: ipsw AI Decompiler Commands Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Demonstrates common ipsw commands for decompiling binary code using AI models. These examples cover decompiling entry points, specific functions with context, and dyld_shared_cache functions with specified languages. ```bash # Decompile a binary's entry point with AI ipsw macho disass /path/to/binary --entry --dec --dec-model "Claude 3.5 Sonnet" # Analyze a specific function with context ipsw macho disass /path/to/binary --symbol "_main" --dec --dec-llm "openai" # Decompile dyld_shared_cache function as Swift ipsw dsc disass dyld_shared_cache --vaddr 0x123456 --dec --dec-lang "Swift" ``` -------------------------------- ### Provider Setup: Ollama (Local LLMs) Installation and Usage Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Details on setting up and using local LLMs via Ollama with the ipsw decompiler. This includes installing Ollama, downloading models like Qwen2.5 or CodeLlama, starting the Ollama server, and specifying the LLM and model in the ipsw command. ```bash # 1. Install Ollama: https://ollama.com # 2. Download models ollama pull qwen2.5:32b-instruct # Good for code analysis ollama pull codellama:34b # Code-specialized model # 3. Start server and use olama serve ipsw macho disass binary --dec --dec-llm ollama --dec-model "qwen2.5:32b-instruct" ``` -------------------------------- ### Provider Setup: GitHub Copilot Authentication (Xcode) Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Instructions for setting up GitHub Copilot authentication for the ipsw decompiler within Xcode. Users are directed to follow GitHub's official setup guide for installing the Copilot extension in Xcode. ```bash # Follow GitHub's Xcode setup guide # https://docs.github.com/en/copilot/managing-copilot/configure-personal-settings/installing-the-github-copilot-extension-in-your-environment?tool=xcode ``` -------------------------------- ### Install ipsw via Snapcraft (Linux) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Installs the ipsw tool using snapcraft. It also shows how to connect the 'removable-media' interface if permission issues arise and how to verify the connection. ```bash sudo snap install ipsw snap connect ipsw:removable-media snap connections ipsw ``` -------------------------------- ### Install ipsw via Scoop (Windows) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Installs the ipsw tool on Windows using Scoop. It first adds the blacktop repository to Scoop and then installs the ipsw package. ```bash scoop bucket add blacktop https://github.com/blacktop/scoop-bucket.git scoop install blacktop/ipsw ``` -------------------------------- ### Install tools for mounting DMG files (Linux) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Provides commands to install necessary tools for mounting DMG files on Linux. Includes installation of 'apfs-fuse' for APFS filesystems and 'hfsprogs' or 'hfsplus-tools' for HFS+ filesystems. ```bash # Install apfs-fuse git clone https://github.com/sgan81/apfs-fuse.git cd apfs-fuse make sudo make install # Ubuntu/Debian sudo apt-get install hfsprogs # RHEL/CentOS/Fedora sudo yum install hfsplus-tools # or sudo dnf install hfsplus-tools # Arch Linux sudo pacman -S hfsprogs ``` -------------------------------- ### Start ipsw Daemon Source: https://blacktop.github.io/ipsw/docs/guides/symbolicate Starts the ipswd daemon, a service that exposes ipsw functionality as a RESTful API for automation and large-scale pipelines. ```bash ipswd start ``` -------------------------------- ### Provider Setup: GitHub Copilot Authentication (Zed Editor) Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Steps to authenticate GitHub Copilot for use with the ipsw decompiler via the Zed editor. This involves installing Zed, accessing the Agent Panel, and signing in to GitHub Copilot Chat. ```bash # Install Zed: https://zed.dev # Open Zed → Agent Panel (Cmd+?) → Settings (Opt+Cmd+C) → Sign in to GitHub Copilot Chat ``` -------------------------------- ### Best Practice: Language Hints for Decompilation Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Provides examples of using the --dec-lang flag to guide the decompiler when analyzing Objective-C runtime functions or Swift compiled code, ensuring accurate interpretation. ```bash # When analyzing ObjC runtime functions ipsw dsc disass cache --symbol "_objc_msgSend" --dec --dec-lang "Objective-C" # When analyzing Swift compiled code ipsw dsc disass cache --symbol "swift_" --dec --dec-lang "Swift" ``` -------------------------------- ### Download and use ipsw Docker image Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Pulls the official ipsw Docker image and provides an alias to run the tool as if it were installed locally, mounting the current directory for data persistence. ```bash $ docker pull blacktop/ipsw $ alias ipsw='docker run -it --rm -v $(pwd):/data blacktop/ipsw' ``` -------------------------------- ### Provider Setup: Gemini (Google AI) API Key Configuration Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Guides users on configuring the Google AI Gemini LLM provider for the ipsw decompiler. This involves getting an API key from Google AI Studio, setting it as an environment variable, and using 'gemini' with the decompiler. ```bash # 1. Get API key from https://aistudio.google.com/apikey # 2. Add to environment export GEMINI_API_KEY="your-key-here" # 3. Use with ipsw ipsw macho disass binary --dec --dec-llm gemini ``` -------------------------------- ### Install IDA Pro Symbolicate Plugin Source: https://blacktop.github.io/ipsw/blog/kernel-symbolication Installs the ipsw symbolication plugin for IDA Pro. This script automates the installation process, enabling direct symbolication within the IDA Pro environment. Requires the plugins/ida/install.sh script to be available. ```bash ❯ bash plugins/ida/install.sh ``` -------------------------------- ### ipsw idev apps install Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/idev/apps/install Installs an application from a provided IPA file path onto a connected device. Supports various configuration and output options. ```APIDOC ## ipsw idev apps install ### Description Installs an application onto a connected device. ### Method N/A (CLI Command) ### Endpoint N/A (CLI Command) ### Parameters #### Path Parameters - **IPA_PATH** (string) - Required - The file path to the IPA file to be installed. #### Query Parameters None #### Request Body None ### Request Example ```bash ipsw idev apps install /path/to/your/app.ipa --udid YOUR_DEVICE_UDID --verbose ``` ### Response #### Success Response (200) Output indicating successful installation or any relevant information. #### Response Example ``` App installed successfully. ``` ### Options #### Command Specific Options - **-h, --help** (bool) - help for install #### Inherited Options - **--color** (bool) - colorize output - **--config** (string) - config file (default is $HOME/.config/ipsw/config.yaml) - **--no-color** (bool) - disable colorize output - **-u, --udid** (string) - Device UniqueDeviceID to connect to - **-V, --verbose** (bool) - verbose output ``` -------------------------------- ### Install ipsw from AUR (Arch Linux) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Installs the ipsw-bin package from the Arch User Repository (AUR) using pacman. ```bash pacman -U ipsw-bin ``` -------------------------------- ### Install ipsw from Debian/RPM/APK packages Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Installs ipsw using system package managers after downloading the respective .deb, .rpm, or .apk files from the releases page. ```bash dpkg -i ipsw*.deb rpm -ivh ipsw*.rpm apk add --allow-untrusted ipsw*.apk ``` -------------------------------- ### Install ipsw via Homebrew (macOS) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Installs the ipsw tool using Homebrew. The `--with-git-delta` flag is optional and enables enhanced diffs. An alternative command installs a version with Frida support. ```bash brew install blacktop/tap/ipsw --with-git-delta brew install blacktop/tap/ipsw-frida ``` -------------------------------- ### Usage Examples: ipsw macho disass for Binary Analysis Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Provides examples of using the `ipsw macho disass` command for analyzing Mach-O binaries. Covers analyzing the main function, decompiling with a specific model and LLM, and forcing language interpretation for Objective-C code. ```bash # Analyze iOS app main function ipsw macho disass /Applications/MyApp.app/MyApp --symbol "_main" --dec # Decompile with specific model ipsw macho disass binary --entry --dec --dec-model "GPT-4" --dec-llm "openai" # Force language interpretation ipsw macho disass ObjCBinary --symbol "initWithFrame:" --dec --dec-lang "Objective-C" ``` -------------------------------- ### Start ipswd Daemon Source: https://blacktop.github.io/ipsw/docs/guides/aea This command starts the ipswd daemon, which will then be available to serve the configured PEM database. Ensure the configuration file is correctly set up before running this command. ```bash ipswd start ``` -------------------------------- ### Install ipsw from release binary (macOS/Linux) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Downloads and extracts the latest ipsw release binary for macOS or Linux. It dynamically fetches the latest version tag from the GitHub API. Separate commands are provided for the standard, extras, and frida versions. ```bash # Download latest release (replace VERSION with current version from releases page) wget https://github.com/blacktop/ipsw/releases/latest/download/ipsw_$(curl -s https://api.github.com/repos/blacktop/ipsw/releases/latest | grep -o '"tag_name": "[^"*']' | cut -d'"' -f4 | tr -d 'v')_macOS_universal.tar.gz tar xzf ipsw_*.tar.gz # Download latest extras version wget https://github.com/blacktop/ipsw/releases/latest/download/ipsw_$(curl -s https://api.github.com/repos/blacktop/ipsw/releases/latest | grep -o '"tag_name": "[^"*']' | cut -d'"' -f4 | tr -d 'v')_macOS_arm64_extras.tar.gz tar xzf ipsw_*_extras.tar.gz # Download latest frida version wget https://github.com/blacktop/ipsw/releases/latest/download/ipsw_$(curl -s https://api.github.com/repos/blacktop/ipsw/releases/latest | grep -o '"tag_name": "[^"*']' | cut -d'"' -f4 | tr -d 'v')_macOS_arm64_frida.tar.gz tar xzf ipsw_*_frida.tar.gz # Download latest Linux release wget https://github.com/blacktop/ipsw/releases/latest/download/ipsw_$(curl -s https://api.github.com/repos/blacktop/ipsw/releases/latest | grep -o '"tag_name": "[^"*']' | cut -d'"' -f4 | tr -d 'v')_linux_x86_64.tar.gz tar xzf ipsw_*.tar.gz ``` -------------------------------- ### Example: Build JSON Database of Firmware Metadata Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/download/wiki Demonstrates using the tool to create a local JSON database containing metadata for firmware files. This enables efficient querying and management of firmware information. ```bash # Build JSON database of firmware metadata ❯ ipsw download wiki --ipsw --device iPhone14,2 --json ``` -------------------------------- ### Example: Download OTA Updates with Prerequisites Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/download/wiki Illustrates downloading Over-The-Air (OTA) update files, including specifying prerequisite versions. This is essential for updating devices when a direct IPSW download is not feasible or when managing phased rollouts. ```bash # Download OTA updates with prerequisites ❯ ipsw download wiki --ota --device iPhone14,2 --version 17.1 --pv 17.0 ``` -------------------------------- ### Start IDA Pro GUI in Docker Container Source: https://blacktop.github.io/ipsw/docs/guides/ida_pro After building the IDA Pro Docker image, this command allows you to enter the container and launch the IDA Pro GUI. This is useful for initial license agreement acceptance and setting persistent configurations. ```bash make ssh-pro # Inside the container: root@add3b0fd6966:/ida# ./ida64 ``` -------------------------------- ### ipsw Symbolicate Command Help Source: https://blacktop.github.io/ipsw/docs/guides/symbolicate Displays the help information for the 'ipsw symbolicate' command, outlining its usage, aliases, flags, and providing examples for symbolication of different crash log types. ```bash ipsw symbolicate --help ``` -------------------------------- ### Usage Examples: ipsw for Kernelcache and KEXT Analysis Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Demonstrates how to download, extract, and analyze kernelcache files using ipsw. Includes commands for extracting the kernel, decompiling a specific symbol like '_panic', and analyzing a KEXT within the kernelcache. ```bash # Extract and analyze kernel function ipsw download ipsw --device iPhone15,2 --latest --kernel ipsw extract --kernel *.ipsw ipsw macho disass kernelcache.* --symbol "_panic" --dec --dec-llm copilot # Analyze KEXT with context ipsw macho disass kernelcache --fileset-entry com.apple.driver.AppleMobileFileIntegrity --entry --dec ``` -------------------------------- ### Clone and Build IDA Pro Docker Image Source: https://blacktop.github.io/ipsw/docs/guides/ida_pro This sequence of commands clones the docker-idapro repository, copies the IDA Pro Linux installer, and builds a Docker image for IDA Pro. It requires a licensed version of IDA Pro and allows for custom image tagging. ```bash ❯ git clone https://github.com/blacktop/docker-idapro.git ❯ cd docker-idapro # Place the linux installer in the 'pro' folder as 'idapro.run' IDAPW="put-your-install-pw-here" make build-pro ``` -------------------------------- ### Install ipsw via MacPorts (macOS) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation Installs the ipsw tool using MacPorts. It also includes steps for setting up the development version by cloning a repository and updating MacPorts sources. ```bash sudo port install ipsw git clone https://github.com/blacktop/ports ~/.config/macports/blacktop sudo echo "file://$HOME/.config/macports/blacktop [default]" >> /opt/local/etc/macports/sources.conf sudo port selfupdate sudo port install ipsw ``` -------------------------------- ### Example: Download Older IPSW for Specific Device Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/download/wiki Demonstrates how to download an older IPSW file for a specific iOS device and version. This is useful for accessing legacy firmware not readily available through standard update channels. ```bash # Download older IPSWs for specific device ❯ ipsw download wiki --ipsw --device iPhone10,6 --version 12.0 ``` -------------------------------- ### GET /idev/info Source: https://blacktop.github.io/ipsw/api/swagger Get info about USB connected devices. This endpoint retrieves information about devices connected via USB. ```APIDOC ## GET /idev/info ### Description Get info about USB connected devices. ### Method GET ### Endpoint /idev/info ### Response #### Success Response (200) - **idevInfoResponse** (object) - The response containing device information. #### Error Response (500) - **Internal Server Error** - If an internal server error occurs. ``` -------------------------------- ### Example: Extract Kernelcache from Remote IPSW Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/download/wiki Shows how to download an IPSW and extract the kernelcache file directly. This is a common requirement for security research and low-level system analysis. ```bash # Extract kernelcache from remote IPSW ❯ ipsw download wiki --ipsw --device iPhone14,2 --build 21A329 --kernel ``` -------------------------------- ### GET /info/ota Source: https://blacktop.github.io/ipsw/api/swagger Retrieves information about a local OTA file. This endpoint allows you to get metadata and details about an OTA file specified by its path. ```APIDOC ## GET /info/ota ### Description Get OTA info. ### Method GET ### Endpoint /info/ota ### Parameters #### Query Parameters - **path** (string) - Required - path to OTA ### Response #### Success Response (200) - **infoResponse** (object) - Contains the information about the OTA file. #### Error Response (500) - **genericError** (object) - Indicates a generic error occurred. ``` -------------------------------- ### GET /info/ipsw Source: https://blacktop.github.io/ipsw/api/swagger Retrieves information about a local IPSW file. This endpoint allows you to get metadata and details about an IPSW file specified by its path. ```APIDOC ## GET /info/ipsw ### Description Get IPSW info. ### Method GET ### Endpoint /info/ipsw ### Parameters #### Query Parameters - **path** (string) - Required - path to IPSW ### Response #### Success Response (200) - **infoResponse** (object) - Contains the information about the IPSW file. #### Error Response (500) - **genericError** (object) - Indicates a generic error occurred. ``` -------------------------------- ### Example Output of --split-seg Command Source: https://blacktop.github.io/ipsw/docs/guides/macho This is an example of the output generated by the 'ipsw macho info --split-seg' command. It illustrates the detailed mapping of different segments and sections within the Mach-O binary, including their memory addresses and kinds of relocation. This output is crucial for understanding binary structure and debugging. ```text __TEXT_EXEC.__text 0x0000400c => __TEXT.__cstring 0x000005c8 kind(arm64_adrp) __TEXT_EXEC.__text 0x0000412c => __TEXT.__cstring 0x000005c8 kind(arm64_adrp) __TEXT_EXEC.__text 0x00004464 => __TEXT.__cstring 0x000005c8 kind(arm64_adrp) __TEXT_EXEC.__text 0x00004010 => __TEXT.__cstring 0x000005c8 kind(arm64_off_12) __TEXT_EXEC.__text 0x00004130 => __TEXT.__cstring 0x000005c8 kind(arm64_off_12) __TEXT_EXEC.__text 0x00004468 => __TEXT.__cstring 0x000005c8 kind(arm64_off_12) __TEXT_EXEC.__text 0x00004300 => __TEXT.__cstring 0x0000066d kind(arm64_adrp) __TEXT_EXEC.__text 0x00004304 => __TEXT.__cstring 0x0000066d kind(arm64_off_12) __TEXT_EXEC.__text 0x000040fc => __TEXT_EXEC.__auth_stubs 0x0000451c kind(arm64_br_26) __TEXT_EXEC.__text 0x00004110 => __TEXT_EXEC.__auth_stubs 0x0000451c kind(arm64_br_26) __TEXT_EXEC.__text 0x00004184 => __TEXT_EXEC.__auth_stubs 0x0000452c kind(arm64_br_26) __TEXT_EXEC.__text 0x000041dc => __TEXT_EXEC.__auth_stubs 0x0000452c kind(arm64_br_26) __TEXT_EXEC.__text 0x00004020 => __TEXT_EXEC.__auth_stubs 0x0000453c kind(arm64_br_26) __TEXT_EXEC.__text 0x00004140 => __TEXT_EXEC.__auth_stubs 0x0000453c kind(arm64_br_26) __TEXT_EXEC.__text 0x00004478 => __TEXT_EXEC.__auth_stubs 0x0000453c kind(arm64_br_26) __TEXT_EXEC.__text 0x00004048 => __TEXT_EXEC.__auth_stubs 0x0000454c kind(arm64_br_26) ``` -------------------------------- ### GET /syms/dsc/{uuid}/{addr} Source: https://blacktop.github.io/ipsw/api/swagger Get a specific image from a DSC (dyld_shared_cache) using its UUID and memory address. This allows for detailed inspection of individual libraries within the cache. ```APIDOC ## GET /syms/dsc/{uuid}/{addr} ### Description Get image from a DSC for a given uuid and address. ### Method GET ### Endpoint /syms/dsc/{uuid}/{addr} ### Parameters #### Path Parameters - **uuid** (string) - Required - dsc UUID - **addr** (integer) - Required - pointer address ### Request Example ```json { "example": "request body not provided" } ``` ### Response #### Success Response (200) - **example** (object) - Description for symMachoResponse #### Response Example ```json { "example": "response body not provided" } ``` ``` -------------------------------- ### Download Beta OTA (Studio Display) Source: https://blacktop.github.io/ipsw/docs/guides/download Downloads a beta OTA update for a Studio Display device. The command prompts for confirmation and displays the download progress. This is useful for updating accessory devices with beta firmware. ```bash #!/bin/bash ipsw download ota --platform accessory --beta --device AppleDisplay2,1 ``` -------------------------------- ### ipsw dyld str Usage Examples Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/dyld/str These examples demonstrate various ways to use the 'ipsw dyld str' command. They cover fast byte searches for single and multiple strings, searching using input from stdin, and performing slower regex searches using the --pattern flag. ```bash # Perform FAST byte search for string in dyld_shared_cache ❯ ipsw dsc str DSC "string1" # Perform FAST byte search for multiple strings in dyld_shared_cache ❯ ipsw dsc str DSC "string1" "string2" # Perform FAST byte search for strings from stdin in dyld_shared_cache ❯ cat strings.txt | ipsw dsc str DSC # Perform SLOW regex search for string in dyld_shared_cache ❯ ipsw dsc str DSC --pattern "REGEX_PATTERN" ``` -------------------------------- ### Best Practice: Provide Context for Decompilation Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Highlights the importance of providing context for decompilation, recommending the inclusion of symbol names with demangling and specifying surrounding code via virtual address and size. ```bash # Better: Include symbol names and demangling ipsw macho disass binary --symbol "_objc_msgSend" --demangle --dec # Best: Include surrounding code for context ipsw macho disass binary --vaddr 0x1000 --size 500 --dec ``` -------------------------------- ### GET /version Source: https://blacktop.github.io/ipsw/api/swagger Retrieves the version information of the daemon. ```APIDOC ## GET /version ### Description This will return the daemon version info. ### Method GET ### Endpoint /version ### Responses #### Success Response (200) - Response body structure is defined by `#/responses/versionResponse`. ``` -------------------------------- ### GET /websites/blacktop_github_io_ipsw Source: https://blacktop.github.io/ipsw/api Retrieves firmware information, including device trees and property lists. The response contains detailed nested objects with various firmware-related properties. ```APIDOC ## GET /websites/blacktop_github_io_ipsw ### Description Retrieves detailed information about firmware files. ### Method GET ### Endpoint /websites/blacktop_github_io_ipsw ### Parameters #### Query Parameters None ### Request Example (No request body for GET request) ### Response #### Success Response (200) - **DeviceTrees** (object) - Contains nested device tree properties. - **Plists** (object) - Contains property list data for the firmware. - **DeviceMap** (array) - List of device configurations. - **BDID** (integer) - **BoardConfig** (string) - **CPID** (integer) - **Platform** (string) - **SCEP** (integer) - **SDOM** (integer) - **ProductBuildVersion** (string) - **ProductVersion** (string) - **SupportedProductTypeIDs** (object) - **SupportedProductTypes** (array of strings) - **SystemRestoreImageFileSystems** (object) - **actual_minimum_system_partition** (integer) - **build** (string) - **build_id** (string) - **build_identities** (array) - Information about build identities. - **ap_board_id** (string) - **ap_chip_id** (string) - **ap_os_long_version** (string) - **ap_security_domain** (string) - **bb_activation_manifest_key_hash** (array of integers) - **bb_chip_id** (string) - **bb_fdr_security_key_hash** (array of integers) - **bb_provisioning_manifest_key_hash** (array of integers) - **info** (object) - Detailed build information. - **build_number** (string) - **code_name** (string) - **device_class** (string) - **fdr_support** (boolean) - **minimum_system_partition** (integer) - **mobile_device_min_version** (string) - **os_var_content_size** (integer) - **restore_behavior** (string) - **system_partition_padding** (object) - **variant** (string) - **variant_contents** (object) - **manifest** (object) - Manifest details. - **property1** (object) - **property2** (object) - **pearl_certification_root_pub** (array of integers) - **product_marketing_version** (string) - **unique_build_id** (array of integers) - **cf_bundle_identifier** (string) - **cf_bundle_info_dictionary_version** (string) - **cf_bundle_name** (string) - **cf_bundle_short_version_string** (string) - **cf_bundle_version** (string) - **device_class** (string) - **hardware_model** (string) - **manifest_version** (integer) - **minimum_system_partition** (integer) - **mobile_asset_properties** (object) - Properties of mobile assets. - **ActualMinimumSystemPartition** (integer) - **ArchiveDecryptionKey** (string) - **ArchiveID** (string) - **AssetFormat** (string) - **AssetType** (string) - **AutoUpdate** (boolean) - **BridgeVersionInfo** (object) - **Build** (string) - **CryptexSizeInfo** (array of objects) - **DataTemplateSize** (integer) - **DeviceName** (string) - **Devices** (array of strings) - **DisablePreSoftwareUpdateAssetStaging** (boolean) - **EAPFSEnabled** (boolean) - **FirmwareBundle** (string) - **FirmwareVersionMajor** (integer) - **FirmwareVersionMinor** (integer) - **FirmwareVersionRelease** (integer) - **InstallationSize** (string) - **InstallationSize-Snapshot** (string) - **MinimumSystemPartition** (integer) - **OSVersion** (string) - **PreflightBuildManifest** (array of integers) - **PreflightGlobalSignatures** (array of integers) - **PrerequisiteBuild** (string) - **PrerequisiteOSVersion** (string) - **ProductVersionExtra** (string) - **RSEPDigest** (array of integers) - **Ramp** (boolean) - **ReleaseType** (string) - **RescueMinimumSystemPartition** (integer) - **RestoreVersion** (string) - **RestoreVersionInfo** (object) #### Response Example ```json { "DeviceTrees": { "property1": { "property1": { "property1": null, "property2": null }, "property2": { "property1": null, "property2": null } }, "property2": { "property1": { "property1": null, "property2": null }, "property2": { "property1": null, "property2": null } } }, "Plists": { "DeviceMap": [ { "BDID": 0, "BoardConfig": "string", "CPID": 0, "Platform": "string", "SCEP": 0, "SDOM": 0 } ], "ProductBuildVersion": "string", "ProductVersion": "string", "SupportedProductTypeIDs": { "property1": [ 0 ], "property2": [ 0 ] }, "SupportedProductTypes": [ "string" ], "SystemRestoreImageFileSystems": { "property1": "string", "property2": "string" }, "actual_minimum_system_partition": 0, "build": "string", "build_id": "string", "build_identities": [ { "ap_board_id": "string", "ap_chip_id": "string", "ap_os_long_version": "string", "ap_security_domain": "string", "bb_activation_manifest_key_hash": [ 0 ], "bb_chip_id": "string", "bb_fdr_security_key_hash": [ 0 ], "bb_provisioning_manifest_key_hash": [ 0 ], "info": { "build_number": "string", "code_name": "string", "device_class": "string", "fdr_support": true, "minimum_system_partition": 0, "mobile_device_min_version": "string", "os_var_content_size": 0, "restore_behavior": "string", "system_partition_padding": { "property1": 0, "property2": 0 }, "variant": "string", "variant_contents": { "property1": "string", "property2": "string" } }, "manifest": { "property1": { "build_string": "string", "digest": [ 0 ], "epro": true, "esec": true, "info": { "property1": null, "property2": null }, "name": "string", "trusted": true }, "property2": { "build_string": "string", "digest": [ 0 ], "epro": true, "esec": true, "info": { "property1": null, "property2": null }, "name": "string", "trusted": true } }, "pearl_certification_root_pub": [ 0 ], "product_marketing_version": "string", "unique_build_id": [ 0 ] } ], "cf_bundle_identifier": "string", "cf_bundle_info_dictionary_version": "string", "cf_bundle_name": "string", "cf_bundle_short_version_string": "string", "cf_bundle_version": "string", "device_class": "string", "hardware_model": "string", "manifest_version": 0, "minimum_system_partition": 0, "mobile_asset_properties": { "ActualMinimumSystemPartition": 0, "ArchiveDecryptionKey": "string", "ArchiveID": "string", "AssetFormat": "string", "AssetType": "string", "AutoUpdate": true, "BridgeVersionInfo": { "BridgeBuildGroup": "string", "BridgeProductBuildVersion": "string", "BridgeVersion": "string", "CatalogURL": "string", "IsSeed": "string", "SEPEpoch": { "Major": 0, "Minor": 0 } }, "Build": "string", "CryptexSizeInfo": [ { "CryptexSize": 0, "CryptexTag": "string" } ], "DataTemplateSize": 0, "DeviceName": "string", "Devices": [ "string" ], "DisablePreSoftwareUpdateAssetStaging": true, "EAPFSEnabled": true, "FirmwareBundle": "string", "FirmwareVersionMajor": 0, "FirmwareVersionMinor": 0, "FirmwareVersionRelease": 0, "InstallationSize": "string", "InstallationSize-Snapshot": "string", "MinimumSystemPartition": 0, "OSVersion": "string", "PreflightBuildManifest": [ 0 ], "PreflightGlobalSignatures": [ 0 ], "PrerequisiteBuild": "string", "PrerequisiteOSVersion": "string", "ProductVersionExtra": "string", "RSEPDigest": [ 0 ], "Ramp": true, "ReleaseType": "string", "RescueMinimumSystemPartition": 0, "RestoreVersion": "string", "RestoreVersionInfo": { "IsSeed": true, "RestoreBuildGroup": null } } } } ``` ``` -------------------------------- ### ipsw download wiki Command Usage Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/download/wiki This snippet shows the general command structure for 'ipsw download wiki'. It is used to initiate firmware downloads with various flags to specify the target device, version, and download type (IPSW or OTA). ```bash ipsw download wiki [flags] ``` -------------------------------- ### GET /device_list Source: https://blacktop.github.io/ipsw/api/swagger Returns a JSON list of all Xcode devices. ```APIDOC ## GET /device_list ### Description This will return JSON of all Xcode devices. ### Method GET ### Endpoint `/device_list` ### Parameters None ### Request Example None ### Response #### Success Response (200) - **devices** (array) - An array of device objects. - **name** (string) - The name of the device. - **udid** (string) - The unique device identifier. - **sdkVersion** (string) - The SDK version installed on the device. #### Response Example ```json { "devices": [ { "name": "iPhone 13 Pro", "udid": "00008030-001A419E0C81002E", "sdkVersion": "15.0" } ] } ``` ``` -------------------------------- ### GET /kernel/version Source: https://blacktop.github.io/ipsw/api Retrieves the version information of a kernelcache file. ```APIDOC ## GET /kernel/version ### Description Retrieves kernelcache version. ### Method GET ### Endpoint /kernel/version ### Query Parameters - **path** (string) - Required - Path to the kernelcache. ### Responses #### Success Response (200) Returns the kernelcache version information. #### Error Response (500) Indicates an internal server error. ### Response Example (200) ```json { "arch": "string", "cpu": "string", "darwin": "string", "date": "2019-08-24T14:15:22Z", "type": "string", "xnu": "string", "clang": "string", "flags": [ "string" ], "version": "string" } ``` ``` -------------------------------- ### Download and Extract ipsw CLI (Shell) Source: https://blacktop.github.io/ipsw/docs/getting-started/installation This command downloads the latest release of the ipsw CLI tool for Windows x86_64 architecture from GitHub. It first fetches the latest release tag using the GitHub API, constructs the download URL, and then downloads the tar.gz archive. Finally, it extracts the contents of the archive. ```shell curl -L https://github.com/blacktop/ipsw/releases/latest/download/ipsw_$(curl -s https://api.github.com/repos/blacktop/ipsw/releases/latest | grep -o '"tag_name": "[^"re*' | cut -d'"' -f4 | tr -d 'v')_windows_x86_64.tar.gz -o ipsw_windows.tar.gz tar xzf ipsw_windows.tar.gz ``` -------------------------------- ### GET /v1/info/ipsw Source: https://blacktop.github.io/ipsw/api Retrieves information about a specified IPSW file. ```APIDOC ## GET /v1/info/ipsw ### Description Retrieves information about a specified IPSW file. ### Method GET ### Endpoint /v1/info/ipsw ### Parameters #### Query Parameters - **pathrequired** (string) - Required - path to IPSW ### Response #### Success Response (200) - **(Type varies)** - Details about the IPSW file. #### Error Response (500) - Indicates a server error. ### Response Example (Specific response format depends on the IPSW file information) ``` -------------------------------- ### Provider Setup: OpenAI API Key Configuration Source: https://blacktop.github.io/ipsw/docs/guides/decompiler Instructions for setting up and using the OpenAI LLM provider with the ipsw decompiler. This involves obtaining an API key, setting it as an environment variable, and then using the 'openai' LLM identifier. ```bash # 1. Get API key from https://platform.openai.com/api-keys # 2. Add to environment export OPENAI_API_KEY="sk-your-key-here" # 3. Use with ipsw ipsw macho disass binary --dec --dec-llm openai ``` -------------------------------- ### ipsw download wiki Command Options Source: https://blacktop.github.io/ipsw/docs/cli/ipsw/download/wiki This section lists the available command-line options for the 'ipsw download wiki' command. These options control various aspects of the download process, including the type of file to download, target device and version, and output formatting. ```bash --beta Download beta IPSWs/OTAs -b, --build string iOS BuildID (i.e. 16F203) -y, --confirm do not prompt user for confirmation --db string Path to local JSON database (will use CWD by default) (default "wiki_db.json") -d, --device string iOS Device (i.e. iPhone11,2) -f, --flat Do NOT preserve directory structure when downloading with --pattern -h, --help help for wiki --insecure do not verify ssl certs --ipsw Download IPSWs --json Parse URLs and store metadata in local JSON database --kernel Extract kernelcache from remote IPSW --ota Download OTAs -o, --output string Folder to download files to --pattern string Download remote files that match regex --pb string OTA prerequisite build --proxy string HTTP/HTTPS proxy --pv string OTA prerequisite version -_, --remove-commas replace commas in IPSW filename with underscores --restart-all always restart resumable IPSWs --resume-all always resume resumable IPSWs --skip-all always skip resumable IPSWs -v, --version string iOS Version (i.e. 12.3.1) ``` -------------------------------- ### GET /v1/idev/info Source: https://blacktop.github.io/ipsw/api Retrieves information about connected USB devices. ```APIDOC ## GET /v1/idev/info ### Description Retrieves information about connected USB devices. ### Method GET ### Endpoint /v1/idev/info ### Parameters No parameters are required for this endpoint. ### Response #### Success Response (200) - **(Type varies)** - Details about connected USB devices. #### Error Response (500) - Indicates a server error. ### Response Example (Specific response format depends on the system's USB device information structure) ``` -------------------------------- ### GET /v1/version Source: https://blacktop.github.io/ipsw/api Retrieves the version information of the ipswd daemon. ```APIDOC ## GET /v1/version ### Description This endpoint returns the version information of the ipswd daemon. ### Method GET ### Endpoint /v1/version ### Parameters None ### Request Example None ### Response #### Success Response (200) - **version** (string) - The version string of the ipswd daemon. - **build** (string) - The build information of the ipswd daemon. #### Response Example ```json { "version": "1.0.0", "build": "abcdef12345" } ``` ```