Devices and runtimes
Devices and runtimes overview
How phones, simulators, emulators, terminals and other runtimes send traffic through Cloak Proxy, and where to set each one up in the app.
Cloak Proxy captures more than the Mac it runs on. An iPhone, an Android phone, a simulator, a Docker container or a script in Terminal can all send their traffic through it, as long as two things are true: the device or program uses Cloak Proxy as its proxy, and it trusts the Cloak Proxy root certificate so HTTPS can be decrypted. The Device & Runtime Setup window walks you through both for each kind of client.
Open Device & Runtime Setup
Section titled “Open Device & Runtime Setup”Use any of these:
- Click Devices in the main window’s toolbar.
- Choose Proxy › Device & Runtime Setup….
- Press ⇧ ⌘ A (Tools › Search Everything…) and type the name of a page, such as Capturing Browser, iPhone & iPad or Docker. Each result opens the window on that page. See Search and command palette.
- Ask an AI assistant connected through the MCP server. Its
open_in_apptool opens the window withtargetset tosetupandpageset tomac,appCapture(from 0.5.0),browser,electron,terminal,ios,simulator,android,docker,flutterorother.
The Device & Runtime Setup window. Each page in the sidebar covers one kind of client.
- One page per kind of client
- Turns the macOS proxy on or off
- For apps that ignore the macOS proxy
The setup pages
Section titled “The setup pages”| Page | What it sets up | Docs |
|---|---|---|
| Apps & Browsers | Apps and browsers on this Mac, through the macOS proxy. | macOS traffic |
| App Capture Since 0.5.0 | Picked Mac apps that ignore the proxy (Go and Rust tools, command-line tools, many Electron apps), sent through Cloak Proxy by a network extension. | Capture apps that ignore the proxy |
| Capturing Browser Since 0.4.0 | Chrome, Chromium, Edge, Brave or Firefox in its own profile that’s already proxied and trusts the certificate. | Capturing browser |
| Electron Apps Since 0.4.0 | Electron apps started with the proxy flags and certificate. | Electron apps |
| Terminal | Command-line tools, through a configured Terminal window or lines to paste into zsh, bash, fish or PowerShell. | Terminal and runtimes |
| iPhone & iPad | A real iOS or iPadOS device on the same Wi-Fi network: the Wi-Fi proxy and the certificate profile. | iPhone and iPad |
| iOS Simulator | iOS, tvOS and watchOS Simulators: one click installs the certificate in every booted simulator. | iOS Simulator |
| Android | An emulator or USB-connected device through adb, and a debug-only network security config written into your app. |
Android |
| Docker Since 0.4.0 | A Compose project’s containers, through a generated override, labelled by service. | Docker |
| Flutter Since 0.4.0 | A debug-only Dart file that sets the proxy and trusts the certificate. | Flutter |
| Java & JVM | The JVM’s trust store and proxy settings. | Java and the JVM |
Other computers on your network, and any device the pages don’t cover, use the certificate page at http://cloak.proxy. See Other devices and access control.
Browser extension
Section titled “Browser extension”The browser extension for Chrome, Edge, Brave and Firefox tags each request with the tab and script that made it, and records a single tab without a proxy. Set it up from Proxy › Browser Extension….
Watch traffic from another device
Section titled “Watch traffic from another device”To look at the Mac’s captured traffic on a phone, tablet or another computer, without installing anything, turn on the web companion in Settings › Companion and pair the device’s browser. It shows the traffic list, search and filters, the inspector, and switches for the debugging tools.
See your own app’s traffic without a proxy
Section titled “See your own app’s traffic without a proxy”If you build the app you’re testing, add the in-app SDK to its debug build instead. CloakProxyKit sends the app’s URLSession requests straight to Cloak Proxy over the local network, under the app’s name and icon, with no Wi-Fi proxy or certificate on the device. Turn it on in Settings › In-app SDK. Debugging tools don’t apply to this traffic, since the app has already made the requests.
How each client reaches Cloak Proxy
Section titled “How each client reaches Cloak Proxy”Cloak Proxy listens on port 9090 by default. By default it only accepts connections from this Mac (127.0.0.1). How a client reaches it decides whether you need to let other devices connect.
| Client | How its traffic reaches Cloak Proxy | Needs Allow other devices to connect |
|---|---|---|
| Apps and browsers on this Mac | The macOS system proxy points at 127.0.0.1:9090. |
No |
| iOS, tvOS and watchOS Simulators | They use the Mac’s network settings, so the macOS proxy covers them. | No |
| Terminal programs (Node.js, Python, Ruby, Go, curl, git, Deno, AWS CLI) | http_proxy and related environment variables point at 127.0.0.1:9090. |
No |
| Capturing browsers and Electron apps on this Mac Since 0.4.0 | Started with their own proxy settings pointing at 127.0.0.1:9090. |
No |
| Java and Flutter on this Mac | A flag or a generated file points them at 127.0.0.1:9090. |
No |
| Android emulator or USB device | adb reverse forwards the device’s port 9090 to the Mac, and the device’s proxy is set to 127.0.0.1:9090. |
No |
| Docker containers | HTTP_PROXY points at host.docker.internal:9090, set by a generated Compose override. See Docker. |
Yes |
| iPhone, iPad, Android over Wi-Fi, other computers | The device’s Wi-Fi proxy points at your Mac’s address, for example 192.168.1.20:9090. |
Yes |
| iPhone or iPad, on the device | No Mac: the Cloak Proxy app for iPhone and iPad runs its own proxy on the device, with VPN capture (iOS shows it as a VPN, but nothing leaves the device through it) or the Wi-Fi proxy. Apps that ignore the system proxy aren’t captured. | No (no Mac involved) |
| Your own iOS or macOS app with the in-app SDK | The app sends its own requests to Cloak Proxy on port 9092, found over Bonjour. No proxy is involved. |
No Since 0.3.0 |
Trust the certificate on each client
Section titled “Trust the certificate on each client”Every client that should have its HTTPS decrypted must trust the Cloak Proxy root certificate. Cloak Proxy creates this certificate on your Mac the first time it runs, and its private key never leaves the Mac. See Certificate.
| Client | How it trusts the certificate |
|---|---|
| This Mac (Safari, Chrome, most apps, Electron and Chromium apps) | Install & Trust… in Settings › Certificate adds it to the macOS keychain. |
| Firefox | Turn on security.enterprise_roots.enabled so Firefox reads the macOS keychain. |
| Terminal programs | Environment variables point each tool at the certificate or at a bundle of the macOS root certificates plus Cloak Proxy’s. |
| Java | Import it into the JDK’s cacerts with keytool. |
| iOS Simulator | Install Certificate on All Booted Simulators, once per simulator. |
| iPhone and iPad | Download the profile from http://cloak.proxy, install it, then turn on full trust. |
| Android | Push Certificate, install it as a CA certificate, and allow user certificates in your app’s network security config. |
| Docker containers | Mount the certificate into the container and run update-ca-certificates. |
Find device traffic in the traffic list
Section titled “Find device traffic in the traffic list”Requests from another device appear in the sidebar’s app list under the device’s IP address, for example 192.168.1.42, with a phone icon. Select it to see only that device’s traffic. See Sidebar.
The status capsule in the middle of the toolbar reads Listening on followed by the address the proxy listens on: 127.0.0.1:9090 when only this Mac can connect, and your Mac’s network address, such as 192.168.1.20:9090, while other devices are allowed. Cloak Proxy records any device or program that’s pointed at it, whether or not the macOS proxy is on; the bottom bar shows macOS traffic on or macOS traffic off.
Clean up when you’re done
Section titled “Clean up when you’re done”Proxy settings and trusted certificates stay on a device until you remove them. A device whose proxy points at a Mac where Cloak Proxy isn’t running can’t reach the internet through that network.
-
Remove the proxy from each device: turn the Wi-Fi proxy Off on an iPhone or iPad, click Disconnect Proxy for Android, and close any configured Terminal window.
-
Remove the certificate from devices you no longer debug: delete the iOS profile, remove the Android user certificate, and reset or erase simulators you set up.
-
In Settings › General, turn off Allow other devices to connect (phones, other computers) and click Apply & Restart Proxy.
Each device page has a section with the exact steps to undo its setup.