How to debug HTTP traffic on Linux
Short answer: *httpry* is excellent utility for HTTP debugging on Linux.
apt-get install -y httpry
httpry
root@d9fbedf5d17d:/app# httpry -i eth0
httpry version 0.1.7 -- HTTP logging and information retrieval tool
Copyright (c) 2005-2012 Jason Bittel <jason.bittel@gmail.com>
----------------------------
Hash buckets: 64
Nodes inserted: 10
Buckets in use: 10
Hash collisions: 0
Longest hash chain: 1
----------------------------
Starting capture on eth0 interface
2017-01-17 07:44:48 185.49.14.190 172.17.0.4 > GET testp3.pospr.waw.pl http://testp3.pospr.waw.pl/testproxy.php HTTP/1.1 - -
2017-01-17 07:44:48 172.17.0.4 185.49.14.190 < - - - HTTP/1.1 503 Service Temporarily Unavailable
2017-01-17 07:45:05 95.67.19.75 172.17.0.4 > HEAD photo.kiev.ua / HTTP/1.1 - -
2017-01-17 07:45:06 172.17.0.4 95.67.19.75 < - - - HTTP/1.1 200 OK
2017-01-17 07:45:06 95.67.19.75 172.17.0.4 > HEAD blog.it-premium.com.ua / HTTP/1.1 - -
2017-01-17 07:45:06 172.17.0.4 172.17.0.6 > HEAD blog.it-premium.com.ua / HTTP/1.1 - -
2017-01-17 07:45:06 172.17.0.6 172.17.0.4 < - - - HTTP/1.1 200 OK
2017-01-17 07:45:06 172.17.0.4 95.67.19.75 < - - - HTTP/1.1 200 OK
2017-01-17 07:46:35 172.17.0.4 172.17.0.2 > GET neovo.kiev.ua / HTTP/1.1 - -
2017-01-17 07:46:35 172.17.0.2 172.17.0.4 < - - - HTTP/1.1 200 OK
2017-01-17 07:46:51 62.80.171.198 172.17.0.4 > GET condom.org.ua / HTTP/1.1 - -
2017-01-17 07:46:51 172.17.0.4 62.80.171.198 < - - - HTTP/1.1 503 Service Temporarily Unavailable
2017-01-17 07:47:19 163.172.65.114 172.17.0.4 > GET photo.kiev.ua /photo_files/75/original/5050.jpg?1458503622 HT
Source http://xmodulo.com/sniff-http-traffic-command-line-linux.html