Command line tools to monitor POST/GET requests of a loaded website

curlwget

When I load a website with Firefox and open up the Network Profiler, I can see all the POST and GET requests the site is making.

I would like this functionality from the command line. Does any one know of a command line tool which I could use to request the page with say Firefox HTTP headers, and then monitor all outgoing network requests from this page?

Best Answer

Something like this?:

tcpdump -nli eth0 -w - 'tcp port 80' | tshark -i - -R'http.request.method == "GET"'

tcpdump -nli eth0 -w - 'tcp port 80' | tshark -i - -R'http.request.method == "POST"'