I am capturing packets using tcpdump for real-time processing. I'm using the IEEE_80211_RADIO headers and processing the output in a python 3 script. My invocation currently looks like this:
tcpdump -IUnSA -y IEEE802_11_RADIO -i $iface
Using -A or -x I can detect the beginning of the next packet, since the header details are distinct from the packet dump, but I can't detect the end of the current packet. Is there a way to detect the end of the current packet in this context?
(An acceptable alternative for my application is to print the packet length in the header summary and avoid printing the packet dump. This is possible using the -e or -v flags in other contexts but these don't seem to print the packet length in combination with the rest of my call.)