Looking for HTTP debugging proxy for Mac similar to Fiddler on Windows [closed]

In previous jobs when I've worked on a Windows machine, I've used Fiddler for viewing HTTP transactions and debugging.

I'm specifically looking to monitor the HTTP transactions for an ajax site I'm working on to verify that the site is doing what I expect. Rewriting HTTP (as provided by Fiddler) is a nice-to-have, but not essential.

Can anybody recommend something similar for use on a Mac?


Solution 1:

Use Chrome and navigate to chrome://net-internals/

It allows detailed analysis and dumps.

Solution 2:

I found Charles Proxy. It's much closer to the functionality of Fiddler. It's not free, but it may be worth the price.

Solution 3:

I've used mitmproxy for intercepting HTTP traffic. It's a great tool and you can use it for debugging mobile devices as well or any operating system for that matter.

Solution 4:

My favorite mac app for monitoring traffic is HTTPScoop, I detail that as well as using tcpdump from the commandline in this post I blogged last year.

Solution 5:

Not what you asked, but in Firefox the Live HTTP Headers add-on is all I need if I want to edit and re-play requests, including changing the URL and the HTTP method.

Live HTTP Headers

In Firebug, the Network Monitoring shows all requests and responses. Likewise, in Safari the Resources pane of the built-in Web Inspector covers most of my needs as well. (Enable the Web Inspector through the preferences: Show Develop menu in menu bar.) Chrome and Firefox have similar tools.

When things get more complicated, I fire up my Wireshark packet sniffer. However, unlike Fiddler, Wireshark does not let you change the data, and does not support things like auto responders, like Fiddler apparently does.

For Wireshark, see Hyper Text Transfer Protocol (HTTP) for some generic HTTP capturing information, and HTTP Packet Capturing to debug Apache, for some example display filters. (You may want to set the capture filter to "port 80", to show all requests to that port, and responses from that port. Or, to limit to some server, use capture filter "port 80 and host www.google.com".) Like:

# Show only 404: page not found
http.response.code == 404

# Show only certain HTTP methods
http.request.method == "POST" || http.request.method == "PUT"

# Show only javascript
http.content_type contains "javascript"

Note that Wireshark can decompress gzip or deflate encoded (compressed) things on the fly for you. That makes things much easier to read as most web servers will compress the data they send to a browser.

(As for auto responders: the excellent JS Bin has a short video on how to use it to debug Ajax requests. If you don't know JS Bin, then first view the introduction video.)