Mac system version: Mac 10.10 Yosemite
Xcode version: 6.3.1
It is necessary to catch a packet when tracking a bug or analyzing an app communication idea from another company. Here's how Wireshark intercepts iphone packets.
Installing Wireshark
Wireshark is dependent on X11, so first confirm the installation of X11,MAC, you can open the upgrade.
Go to-utility-x11, open and click X11 on the menu bar to check for updates. Intermediate Extract Package content process is long, patient wait.
Download Wireshark The latest version, try to download the official website:
Https://www.wireshark.org/download.html (need to flip.) )
installation, the installation process is simple, the next step.
I download here Wireshark 1.12.4 Intel 64, after installation can not run, Online said X11 location is wrong. Console execution:
[Plain]View PlainCopy
- sudo ln-s/opt/x11/usr/x11
The problem remains.
There's no way to download a XQuartz-2.7.7:
http://xquartz.macosforge.org/landing/
Install, run Wireshark. After finishing the Wireshark icon for more than 10 minutes, it was finally opened, and then opened without having to wait.
Capture iphone Data
To capture the iphone's data, you first need to make the iphone data go through your Mac. See the online a lot of ways to set up agents, more complex, and some have to escape. It's not really necessary. Just chain the data line and then execute it on the Mac's terminal:
[Plain]View PlainCopy
- rvictl-s iphone Device ID
At this point, all iphone network traffic goes through the Mac that the iphone is linked to, and the iphone data goes to its own network, such as the iphone link on a 3g network, and the data is sent via 3G, rather than through the Mac's network. To disconnect the connection:
[Plain]View PlainCopy
- rvictl-x iphone Device ID
After the device is connected, the Mac will appear a corresponding virtual network interface, the name is Rvi0 (if more than one iphone is accumulated, rvi1,rvi2 ... )
Just start Wireshark, listen to the RVi interface to catch the iphone data, of course, you can also use tools other than Wireshark to crawl or analyze.
For the iphone device ID, you can use Xcode-windows-devices, select the appropriate device, the right device information identifier.
Analyze iphone packet--ios end using Wireshark mac crawl