Fiddler tracks Android data packets

Source: Internet
Author: User

With the rapid growth of HTML5, more and more people are involved in the Web development field of mobile terminals, but there are never so many debugging tools on mobile phones. Even if the PC browser simulates user-agent for development, rendering inconsistency may occur between the mobile terminal and PC browser.

Therefore, it is best to develop and Debug on a real mobile phone, but how to capture packets?

Today, we will introduce how Fiddler captures data packets in the Android browser.

As we all know, Fiddler uses a proxy to capture data. For Android phones, the network connection proxy is directed to the Fiddler port of the PC to intercept data packets.

Next, I will take one of my practices as an example to introduce how to perform this operation.

Environment: Windows7 and moto mb860 (android 2.3.4)

1. First, make sure that the computer and mobile phone that install Fiddler are in the LAN that can be accessed from each other. It is impossible to direct the mobile phone proxy to a PC without mutual access.

2. Enable the remote connection with Fiddler. Fiddler Main Menu Tools> Fiddler Options... -> Connections tab

The remote computer connection is allowed to be checked. The above port number does not need to be changed. Keep the default value.

After checking, restart Fiddler. This step is very important.

3. Before setting the proxy for the mobile phone, we need to first obtain the IP address of the computer with Fiddler installed in the LAN. It will be used when setting proxy server on the mobile phone. Open the Run window (shortcut: Win + R) in the Start Menu, Enter cmd and press enter to go to the Windows command line tool, and enter ipconfig and press Enter, the result is shown as follows:

Your actual lan ip address must be different from mine, but don't worry. You can write down this IP address.

3. Now, we need to set up a mobile phone proxy.

Enable system settings

Enter the wireless and network modules

Go to Wifi settings

Find the Wifi connection currently in use and press it to display the shortcut menu.

Select "modify Network" or "Proxy Server" to go to the editing page.

Check the proxy server and enter the IP address 192.168.1.105 obtained in ipconfig on the PC. Set the port number to the default 8888 value of Fiddler.

Leave the proxy exception address empty.

Click Save to complete the proxy settings.

Now, we can try to check whether the configuration is complete and open the browser

Enter a web http://ming.sinaapp.com, try it

At the same time, let's take a look at the data packet capture results on Fiddler.

Bingo, success

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.