# iOS Pentesting Checklist {{#include ../banners/hacktricks-training.md}} ### 準備 - [ ] [**iOSの基本**](ios-pentesting/ios-basics.md)を読む - [ ] [**iOSテスト環境**](ios-pentesting/ios-testing-environment.md)を読んで環境を準備する - [ ] [**iOS初期分析**](ios-pentesting/index.html#initial-analysis)のすべてのセクションを読んで、iOSアプリケーションをペンテストするための一般的なアクションを学ぶ ### データストレージ - [ ] [**Plistファイル**](ios-pentesting/index.html#plist)は機密情報を保存するために使用される可能性があります。 - [ ] [**Core Data**](ios-pentesting/index.html#core-data)(SQLiteデータベース)は機密情報を保存できます。 - [ ] [**YapDatabases**](ios-pentesting/index.html#yapdatabase)(SQLiteデータベース)は機密情報を保存できます。 - [ ] [**Firebase**](ios-pentesting/index.html#firebase-real-time-databases)の誤設定。 - [ ] [**Realmデータベース**](ios-pentesting/index.html#realm-databases)は機密情報を保存できます。 - [ ] [**Couchbase Liteデータベース**](ios-pentesting/index.html#couchbase-lite-databases)は機密情報を保存できます。 - [ ] [**バイナリクッキー**](ios-pentesting/index.html#cookies)は機密情報を保存できます。 - [ ] [**キャッシュデータ**](ios-pentesting/index.html#cache)は機密情報を保存できます。 - [ ] [**自動スナップショット**](ios-pentesting/index.html#snapshots)は視覚的な機密情報を保存できます。 - [ ] [**キーチェーン**](ios-pentesting/index.html#keychain)は通常、再販時に残る可能性のある機密情報を保存するために使用されます。 - [ ] 要約すると、アプリケーションがファイルシステムに保存した機密情報を**確認する**だけです。 ### キーボード - [ ] アプリケーションは[**カスタムキーボードの使用を許可していますか**](ios-pentesting/index.html#custom-keyboards-keyboard-cache)? - [ ] 機密情報が[**キーボードキャッシュファイル**](ios-pentesting/index.html#custom-keyboards-keyboard-cache)に保存されているか確認する ### **ログ** - [ ] [**機密情報がログに記録されているか**](ios-pentesting/index.html#logs)確認する ### バックアップ - [ ] [**バックアップ**](ios-pentesting/index.html#backups)はファイルシステムに保存された**機密情報にアクセスするために使用される可能性があります**(このチェックリストの最初のポイントを確認してください) - [ ] また、[**バックアップ**](ios-pentesting/index.html#backups)はアプリケーションの**設定を変更するために使用される可能性があり**、その後**バックアップを電話に復元すると、**変更された設定**が**読み込まれ**、一部の(セキュリティ)**機能**が**バイパスされる**可能性があります。 ### **アプリケーションメモリ** - [ ] [**アプリケーションのメモリ**](ios-pentesting/index.html#testing-memory-for-sensitive-data)内の機密情報を確認する ### **壊れた暗号化** - [ ] [**暗号化に使用されるパスワード**](ios-pentesting/index.html#broken-cryptography)を見つけられるか確認する - [ ] 機密データを送信/保存するために[**非推奨/弱いアルゴリズム**](ios-pentesting/index.html#broken-cryptography)が使用されているか確認する - [ ] [**暗号化関数をフックして監視する**](ios-pentesting/index.html#broken-cryptography) ### **ローカル認証** - [ ] アプリケーションで[**ローカル認証**](ios-pentesting/index.html#local-authentication)が使用されている場合、認証がどのように機能しているか確認する必要があります。 - [ ] [**ローカル認証フレームワーク**](ios-pentesting/index.html#local-authentication-framework)を使用している場合、簡単にバイパスされる可能性があります。 - [ ] [**動的にバイパス可能な関数**](ios-pentesting/index.html#local-authentication-using-keychain)を使用している場合、カスタムFridaスクリプトを作成できます。 ### IPCを通じた機密機能の露出 - [**カスタムURIハンドラー / ディープリンク / カスタムスキーム**](ios-pentesting/index.html#custom-uri-handlers-deeplinks-custom-schemes) - [ ] アプリケーションが**プロトコル/スキームを登録しているか**確認する - [ ] アプリケーションが**プロトコル/スキームを使用するために登録しているか**確認する - [ ] アプリケーションが**カスタムスキームから受信することを期待している機密情報の種類**を確認し、同じスキームを登録している別のアプリケーションによって**傍受される**可能性があるか確認する - [ ] アプリケーションが**カスタムスキームを介してユーザー入力を確認およびサニタイズしていない**場合、**脆弱性が悪用される**可能性があるか確認する - [ ] アプリケーションが**どこからでも呼び出すことができる機密アクションを公開しているか**確認する - [**ユニバーサルリンク**](ios-pentesting/index.html#universal-links) - [ ] アプリケーションが**ユニバーサルプロトコル/スキームを登録しているか**確認する - [ ] `apple-app-site-association`ファイルを確認する - [ ] アプリケーションが**カスタムスキームを介してユーザー入力を確認およびサニタイズしていない**場合、**脆弱性が悪用される**可能性があるか確認する - [ ] アプリケーションが**どこからでも呼び出すことができる機密アクションを公開しているか**確認する - [**UIActivity共有**](ios-pentesting/ios-uiactivity-sharing.md) - [ ] アプリケーションがUIActivitiesを受信できるか、特別に作成されたアクティビティで脆弱性を悪用できるか確認する - [**UIPasteboard**](ios-pentesting/ios-uipasteboard.md) - [ ] アプリケーションが**一般的なペーストボードに何かをコピーしているか**確認する - [ ] アプリケーションが**一般的なペーストボードのデータを何かに使用しているか**確認する - [ ] ペーストボードを監視して、**機密データがコピーされているか**確認する - [**アプリ拡張**](ios-pentesting/ios-app-extensions.md) - [ ] アプリケーションは**拡張を使用していますか**? - [**WebViews**](ios-pentesting/ios-webviews.md) - [ ] 使用されているWebViewの種類を確認する - [ ] **`javaScriptEnabled`**、**`JavaScriptCanOpenWindowsAutomatically`**、**`hasOnlySecureContent`**の状態を確認する - [ ] WebViewが**file://**プロトコルで**ローカルファイルにアクセスできるか**確認する(`allowFileAccessFromFileURLs`、`allowUniversalAccessFromFileURLs`) - [ ] Javascriptが**ネイティブ**メソッドにアクセスできるか確認する(`JSContext`、`postMessage`) ### ネットワーク通信 - [ ] [**通信に対するMitMを実行**](ios-pentesting/index.html#network-communication)し、Webの脆弱性を探す。 - [ ] [**証明書のホスト名**](ios-pentesting/index.html#hostname-check)が確認されているか確認する - [ ] [**証明書ピンニング**](ios-pentesting/index.html#certificate-pinning)を確認/バイパスする ### **その他** - [ ] [**自動パッチ/更新**](ios-pentesting/index.html#hot-patching-enforced-updateing)メカニズムを確認する - [ ] [**悪意のあるサードパーティライブラリ**](ios-pentesting/index.html#third-parties)を確認する {{#include ../banners/hacktricks-training.md}}