How can I direct all android data traffic excluding calls and SMS through a proxy server before it actually reaches its destination, I was able to retrieve and edit some system information like the net.eth0.gw
. Will that help and if so, what exactly should I do with it? I'm very new to android and networking, any help will be appreciated.
Thank you.
You can direct your Android to use a Fiddler proxy. Or any HTTP proxy for that matter.
I do this from time to time on my Android phone for debugging HTTP network traffic. And that covers about 90% of everything you could think of needing to capture.
Setup Fiddler on your PC and enable it as a proxy server for other nodes. From the Fiddler Tool's menu, select Fiddler Options, and then Connections Tab. Then enable the "allow remote computers to connect" checkbox.
Then configure your Android device's Wifi settings such that a manual proxy setting is specified for the current Wifi connection. (You give it your PC's IP address at port 8888).
Then browse some websites on your phone. You should see the request/response flows in the Fiddler window.
This obviously only works for HTTP traffic - for code that uses the typical class libraries built into the connection. It doesn't work for code using sockets. Anything over HTTPS will be hard to view since its encrypted, although Fiddler has a few options that you can try (YMMV).