Testing HTTPS with Charles Proxy on iOS Apps
- First, make sure your iOS device and the Mac you’re running Charles on are connected to the same WiFi network. This MUST happen.
- Second, go to your WiFi settings in iOS, select the WiFi network you’re using, then scroll all the way and select Configure Proxy.
- In the Configure Proxy menu, choose Manual, then add the IP address of your Mac to the Server field, and (usually for Charles) add 8888 to Port field. Now the phone will send all HTTP traffic through Charles on the Mac.
- On the Mac, turn off as much as you can that’s using the web. Do the same thing on the phone.
- Run Charles on the Mac, making sure your app is plugged in. Run the app; all the HTTPS calls should now appear in the Charles Log on the left. Note: if you’re not plugged in and using Charles, then you will not have internet connectivity during the time you’re Proxy settings are active.
- Find out either the values you’re looking for in the data stream, or the URL. You might be looking for a string like “aValue: 1” for example, or you might be looking for a URL like https://sb.scorecard.com.
- On the URL, right click and choose Enable SSL Proxy from the popup menu. If you don’t do this, you won’t be able to see the data inside encrypted HTTPS data streams. Once you do this, you can search for, and view, the details of the response and request data streams
- Choose Find and enter the value you’re looking for, and you should see it in the log, in a request or response string in a node attached beneath the URL node in the treeview that is the Charles Log. The data will appear highlighted. If the string is long, you may need to scroll far to the right to see the data.