androidip-addresssniffer

Get the IP Adresses of other apps connected to the internet in Android?


I would like to get the IP addresses of different android apps which are connected to the internet. E.g. Google Play services is connected to 173.194.39.8. Or Internet app is connected to xxx.xxx.xx.x. I know that it is possible. But I am not sure how I can receive these IP addresses. How can I get them? Do I need root access? Thanks in advance.


Solution

  • Why not run "netstat" via command line?

    Check this question out: java write netstat in cmd.

    Simply Google searches bring up similar "netstat" implementations in Java:

    https://github.com/hyperic/sigar/blob/master/bindings/java/src/org/hyperic/sigar/cmd/Netstat.java

    and

    https://gitorious.org/networklog/networklog/source/60cb640ac27f8b4fb06f11d9d81c94591a531862:src/com/googlecode/networklog/NetStat.java