Looking for a tool to inspect HTTP data between a mobile phone and AV receiver

1

I am trying to dissect the protocol used by my AV receiver and its mobile app on my phone. Basically, I'd like to see all the GET/POST requests from the app on the phone and the responses from the receiver. This, of course, would need to be viewed on a computer that isn't the phone or the receiver. My laptop and phone are connected to my network via wi-fi and the receiver is plugged in through ethernet.

My first thought was to use Wireshark, but I have very limited experience with it and am not sure if it has some way to inspect the packets that aren't meant for the computer it is running on. I'm not even sure what I should google to look into this.

I've also thought that maybe some sort of proxy server would work where it just relays the messages between the two devices while storing them off in a log. Again, I'm not entirely sure what I would search for.

My initial attempt involved creating a very basic web server in python that just prints out the requests it receives. I pointed the mobile app at my web server to see what it what sending. I then used curl to send that same request from the computer to the receiver to see what it would respond with. This got old very quickly.

Long story short: what would be the most appropriate tool for inspecting the HTTP data between two devices?

Pak

Posted 2014-02-16T08:00:30.157

Reputation: 379

Question was closed 2015-01-20T14:33:16.713

If your phone is rooted, I suggest to run tcpdump on it via ssh/adb. Then use wireshark to open the pcap file with the filter http (this assumes that the communication happens over HTTP, not HTTPS or some other protocol). – Lekensteyn – 2014-02-16T15:09:54.720

Answers

1

One way, obviously not the only way, is to connect a switch with mirror port (like this one). I use this setup in my home network - it's simple and not too expensive.

 +-+    +----+      +------+      +-+
 |A|+-->|WiFi|+---->|Switch|+---->|B|
 +-+    +----+      +------+      +-+
                      +
                      v
                    +------+
                    |Laptop|
                    +------+

Here the switch is connected between your WLAN router and the AV receiver which is connected to the router via cable. You'll the configure the switch so that one of its ports is a mirror port and connect a laptop running Wireshark to that port.

Another option is to buy a hub off eBay. A hub is "dumb" and sends packets to all ports, so it doesn't need configuring. Also, it's cheaper.

bytesinflight

Posted 2014-02-16T08:00:30.157

Reputation: 111