1. Download tcpdump
http://pan.baidu.com/s/1c0vkU2k
2, through the ADB command to upload to the phone
ADB push Tcpdump/system/bin
3. adb shell tcpdump-p-vv-s 0-w/sdcard/capture.pcap
| 123456789 |
#tcpdump 用法:tcpdump -i any -p -s 0 -w /sdcard/capture.pcap命令参数:# "-i any": listen on any network interface# "-p": disable promiscuous mode (doesn‘t work anyway)# "-s 0": capture the entire packet# "-w": write packets to a file (rather than printing to stdout)# ... do whatever you want to capture, then ^C to stop it … |
4, run the app to intercept the package, after the corresponding operation, CTRL + C terminated, and then the following command to take out the command:
ADB pull/sdcard/capture.pcap
5, open the Capture.pcap file through Wireshark, view the corresponding data, such as:
Transferred from: http://www.yinqisen.cn/blog-470.html
Using tcpdump to intercept analysis network packets in Android