--- title: "WebView Protocol Handlers" section: "Mobile" sectionSlug: "mobile-pentesting" sourcePath: "src/mobile-pentesting/ios-pentesting/ios-protocol-handlers.md" sourceUrl: "https://github.com/HackTricks-wiki/hacktricks/blob/188de82beb54e70956b2952367a0af91d26758b8/src/mobile-pentesting/ios-pentesting/ios-protocol-handlers.md" sha: "188de82beb54e70956b2952367a0af91d26758b8" isIndex: false modified: true license: "CC-BY-NC-4.0" --- # WebView Protocol Handlers ## Basic Information In this page, **protocol handlers** are the URL schemes or URL-like handoffs that make iOS leave the current web context or resolve content through a non-standard path. During a pentest, treat every transition from **web content** to **`UIApplication.open`**, **`canOpenURL`**, or a **`WKURLSchemeHandler`** as a trust boundary.[[1]](#references) This page focuses on **WebView / browser-driven scheme abuse**. For app registration, deeplink hijacking, and callback stealing, see [iOS Custom URI Handlers / Deeplinks / Custom Schemes](/hacktricks/mobile-pentesting/ios-pentesting/ios-custom-uri-handlers-deeplinks-custom-schemes). For the file-origin / `loadFileURL:allowingReadAccessTo:` angle, see [iOS WebViews](/hacktricks/mobile-pentesting/ios-pentesting/ios-webviews). For claimed `https` handlers, see [iOS Universal Links](/hacktricks/mobile-pentesting/ios-pentesting/ios-universal-links). Common protocol-handler surfaces: - System schemes such as `tel:`, `sms:`, `mailto:`, and `facetime:`. - App schemes such as `myapp://`, browser-internal schemes, and `x-callback-url` style callbacks. - Custom resource schemes served from native code via `WKURLSchemeHandler` (for example `app://` or `resources://` inside `WKWebView`). The key question is always: **can attacker-controlled content make the app open, resolve, or bounce to a URL whose scheme/host/path was not supposed to be reachable?** ## High-value bug patterns ### 1. Web content controls the next navigation If a `WKWebView` renders attacker-controlled HTML or attacker-controlled data is injected into the DOM, you may get a **scheme pivot** without touching native code directly. Modern payloads do not need `