close

開發人員經常有這樣一個需求,將目前應用的 ipa 包下載下來,做一些研究性工作。這裡就給大家推薦一款開源的 ipa 下載工具:ipatool。ipatool 是一個命令行工具,可讓您在 App Store 上搜索 iOS 應用程序並下載應用程序包的 ipa 文件。這個工具是用 Swift 開發的,目前在 Github 上有 1.6k 個 star 和 145 個 fork,最新版本是 1.0.8。

這款開源工具需要運行在 macOS 10.15 或更高版本的系統上。同時需要設置 Apple ID 以使用 App Store。

安裝

該工具可以通過手動和 Homebrew 兩種方式來安裝。如果選擇手動安裝,可以從 GitHub 版本(點擊閱讀原文進入 Github)中獲取最新版本的 ipatool。如果使用 Homebrew 安裝,可以使用以下命令:

$ brew tap majd/repo$ brew install ipatool使用

要在 App Store 上搜索應用程序,請使用搜索命令。

OVERVIEW: Search for iOS apps available on the App Store.USAGE: ipatool search <term> [--limit <limit>] [--country <country>] [--device-family <device-family>] [--log-level <log-level>]ARGUMENTS: <term> The term to search for. OPTIONS: -l, --limit <limit> The maximum amount of search results to retrieve. (default: 5) -c, --country <country> The two-letter (ISO 3166-1 alpha-2) country code for the iTunes Store. (default: US) -d, --device-family <device-family> The device family to limit the search query to. (default: iPhone) --log-level <log-level> The log level. (default: info) --version Show the version. -h, --help Show help information.

要下載 ipa 文件的副本,請使用 download 命令。

OVERVIEW: Download (encrypted) iOS app packages from the App Store.USAGE: ipatool download --bundle-identifier <bundle-identifier> [--email <email>] [--password <password>] [--auth-code <auth-code>] [--country <country>] [--device-family <device-family>] [--log-level <log-level>]OPTIONS: -b, --bundle-identifier <bundle-identifier> The bundle identifier of the target iOS app. -e, --email <email> The email address for the Apple ID. -p, --password <password> The password for the Apple ID. --auth-code <auth-code> The 2FA code for the Apple ID. -c, --country <country> The two-letter (ISO 3166-1 alpha-2) country code for the iTunes Store. (default: US) -d, --device-family <device-family> The device family to limit the search query to. (default: iPhone) --log-level <log-level> The log level. (default: info) --version Show the version. -h, --help Show help information.

注意:您可以在使用該工具時將 Apple ID 電子郵件地址和用戶名指定為參數,或者將它們設置為環境變量(IPATOOL_EMAIL 和 IPATOOL_PASSWORD)。如果您未使用其中任何一種方法指定此信息,則該工具將在交互式會話中提示用戶輸入。同樣,您可以以交互方式或使用環境變量 IPATOOL_2FA_CODE 提供 2FA 代碼。

常見疑問

在使用這款工具時,可能會有一些疑問,這裡可以參考一下:

用戶的 Apple ID 憑據是否安全存儲?

該工具不會將用戶的憑據存儲在任何地方,它只會直接與 Apple 服務器通信。這個可以通過閱讀源碼查看。

用戶的 Apple ID 會因為使用此工具而被標記嗎?

也許,但可能不是。雖然這個工具直接與 iTunes 和 App Store 通信,模仿 iTunes 在 macOS 上運行的行為,但作者不能保證它的安全性。所以建議使用一次性 Apple ID。使用此工具需要用戶自擔風險。(所以,這個工具的參考意義可能大於實際意義)

用戶可以使用此工具下載付費應用程序而無需付費嗎?

不可以,這不是盜版工具;用戶只能下載之前安裝在 iOS 設備上的應用程序。此限制也適用於免費應用程序。本質上,用戶的帳戶必須已經擁有嘗試下載的應用程序的許可證。

用戶可以使用此工具在 Apple Silicon Mac 上加載不受支持的 iOS 應用程序嗎?

雖然以前可以使用此工具下載 ipa 文件並將其安裝在運行 Apple Silicon 的 Mac 上,但最近已不再是這種情況。Apple 停止為應用程序包提供 macOS 兼容的 sinf 數據。但是,用戶可以使用此工具獲取 iOS 應用程序的副本,並使用越獄的 iOS 設備去除任何代碼簽名要求,然後使用臨時簽名再次對應用程序進行代碼簽名以在 Apple Silicon 上運行。

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 鑽石舞台 的頭像
    鑽石舞台

    鑽石舞台

    鑽石舞台 發表在 痞客邦 留言(0) 人氣()