Fiddler
lastmod 2024-07-18created 2014-02-2611 edits
The free web debugging proxy for any browser, system or platform.
Inspect HTTP requests from Android devices
When using HttpClient on Android, if traffic is still not captured properly in Fiddler even though you chose to use a Proxy server in Wiki Setting, you can use the method below.
Sometimes it is necessary to have a detailed view on the HTTP requests sent by your Android app and also inspect the responses from the server. With a few steps, it is quite easily possible to do this:
- Connect your Android device and your PC with the same network, e.g. by connecting the PC to the same Wifi.
- On the PC, install Fiddler.
- Make sure, Fiddler is configured to allow remote computers to connect:
- If you want, you can user Fiddler also to capture HTTPS traffic:
- In your Android app you have to set your PC as proxy server for the HTTP traffic. To do this, you have to provide the proxy information to the HttpClient by setting a HttpHost instance pointing to your PC’s IP address and the port Fiddler is listening at as proxy in the Http parameters:
HttpParams httpParameters = new BasicHttpParams();
HttpHost proxy = new HttpHost("<your PC's IP>", 8888); // Proxy server IP & PORT.
httpParameters.setParameter(ConnRoutePNames.DEFAULT_PROXY, proxy);
// ConnRoutePNames.DEFAULT_PROXY = "http.route.default-proxy";
httpClient = new DefaultHttpClient(httpParameters);
Now let Fiddler run on your PC and capture the traffic. Compile your Android app and start it on your mobile device. That’s it. Fiddler should now show you what’s going on between your Android app and the servers it is connecting.
Testing mobile web server integration using an HTTP Proxy
- http://blog.naver.com/ensel7/100155588302
- http://conceptdev.blogspot.kr/2009/01/monitoring-iphone-web-traffic-with.html
If you use a Proxy to detect packets from a mobile device, you can inspect those packets in FIddler.
- Get Fiddler
Download Fiddler and install it on your PC (with Windows 2000 / XP / 2003 / Vista and Microsoft .NET Framework v2.0 or later) - Set-up Fiddler
Start Fiddler then open the Fiddler Options... window
and in the General tab, ensure Allow remote computers to connect is checked.
In the Connections tab, check Act as system proxy on startup and verify what port is set (eg. 8888).
Once you've saved those settings you need to stop and re-start Fiddler. - Ensure Fiddler is 'listening'
Once Fiddler has re-started, verify that the Capture Traffic menuitem is ticked. - Check the 'listening' IP
You need to know your computer's wireless-network IP address to configure the iPhone. This screenshots shows the Command Prompt > ipconfig output: - Set-up iPhone Settings
With the computer IP address and Fiddler port, go to your iPhone's Wifi Settings and scroll down to the HTTP Proxy, choose Manual and input the Fiddler proxy info - 'sniff' away
If everything has been setup right, anything you do in Safari or other internet applications (like, say Microsoft Tag Reader) will be logged in the Fiddler window. - It's extremely useful for testing/debugging - have fun!
See also
- Charles
- Wireshark
- Computer Network
- Postman
- Hetty - Open-source HTTP toolkit for security research
- mitmproxy is a popular open-source HTTPS proxy among security researchers. Use it as a CLI, web, or Python API.
- RESTful
- Hoppscotch - Open source API development ecosystem with PWA support.
- Insomnia
- Hapi
- HTTP Toolkit - Open source for HTTP debugging
- vim-rest-console - Handling
.restfiles in vim.
Favorite site
-
fiddler website - Fiddler website
- Fiddler: Web debugging proxy 1
- Tips on capturing web service calls with Fiddler
References
-
Fiddler_web_debugging_proxy.pdf ↩