ios: how to capture packets on vpn/tun interface ?

Hi,

I use rvictl, but that seems to capture only on PHYSICAL interfaces. I am using a vpn client and I want to capture packets on the virtual tun interface that directs packets to the vpn app. Is there any way to do that ? Something equivalent of tcpdump -i utun2 on macos for example

Rgds,
Gopa.

Is there any way to do that ? Something equivalent of tcpdump -i utun2 on macos for example

The short answer is no. However, there is some extra details you can get while taking a packet capture on iOS about the interface metadata. For the details on this, check out this article here.


Matt Eaton
DTS Engineering, CoreOS
meaton3@apple.com
@matt Thx for the reply. I am aware of the metadata that can be seen in wireshark .. The ONLY INTERFACE in all of the metadata in wireshark is interface en0 (on my ipad), occassionaly there are some broadcasts and multicasts on some "en2" interface which I dont know what it is, but there is no metadata that points to any "tunnel" interface - so THAT was the question - it looks like rvictl captures everything on "physical" interfaces (like en0) only ??
Okay, another option would be to look at what physical interface is active during your capture. If you are able to limit the device to one interface and that interface aligns with a route that you are claiming for packet tunnel, does this give you any more insight in your metadata tcpdump if you run a capture for rvi0? If this does not then I would open an enhancement request for such a mechanism to run a packet trace on the virtual interface for a packet tunnel.

Matt Eaton
DTS Engineering, CoreOS
meaton3@apple.com
ios: how to capture packets on vpn/tun interface ?
 
 
Q