Skip to content

Debugging a macOS App

Same Mac as TonyProxy

Most macOS apps use NSURLSession, which respects the system-wide proxy setting. Once TonyProxy’s helper daemon is approved (see Installation) and capture is started (⌘R), it sets itself as the system proxy automatically — no per-app configuration needed.

Trust the CA once via Settings → Certificate → Install, then in Keychain Access find “TonyProxy CA”, double-click, expand Trust, set Always Trust. Full steps in HTTPS Certificate Setup.

Apps that ignore the system proxy

Some apps (anything using raw URLSession with a custom URLSessionConfiguration, or non-Apple networking stacks like some Electron/Go/Rust binaries) don’t read the system proxy setting. For those:

  • Check if the app has its own proxy setting/environment variable (HTTP_PROXY, HTTPS_PROXY) and point it at 127.0.0.1:9090 (or your configured port).
  • For a sandboxed app you don’t control the source of, there’s no reliable way to force it through a proxy — TonyProxy can only see traffic that’s actually routed to it.

A different Mac on your network

Same idea as iOS: use Connect Device to get the CA install URL, open it in Safari on the other Mac, trust it in Keychain Access there, then set that Mac’s network proxy (System Settings → Network → your interface → Details → Proxies) to this Mac’s LAN IP and port.