-
Notifications
You must be signed in to change notification settings - Fork 855
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Expressions for upper layer protocols return nothing when 802.1Q header is present in saved files #1387
Comments
This is exactly the documented behaviour, please see FAQ 13. |
Hmm, interesting ... Thank you for sharing the answer. However, @infrastation, it is not the same when I read exactly the same packets directly from the network:
|
Also, @infrastation, it is quite the opposite from what is explained in the FAQ: in my case, I get problems when I do not specify |
Capturing from live network on Linux has its peculiarities that can complicate VLAN processing more than it already is. I do not immediately remember all the details, unfortunately. Reading from the file is a case discussed in the FAQ, although it may take time to understand. |
Seeing different behaviour for the same filter expression for live and saved packets is quite unexpected. When I first faced it, I started checking the man page section for the I wonder what you think about updating the man page saying that filter expressions might work differently depending on whether they are read from network or a saved file. |
The behaviour of The behaviour of |
Hmm, indeed: on macOS, the
Now everything is crystal clear and makes total sense. Thank you so much for your support, Denis! |
Linux is, at least at present, the only OS in which VLAN tags are extracted from received packets in the network data path and put into metadata attached to the packet and are not re-inserted into the packet data before it's handed to the packet capture mechanism. (In most other OSes, they're not extracted the first place; I'm not sure what happens on Windows.) This means that capture filtering requires special handling on Linux, and getting that correct has turned out to be difficult. |
Hi everyone,
I noticed that tcpdump returns nothing when I apply upper layer protocols filtering expressions while reading (-r) previously saved files that contain 802.1Q headers. However, if I start an expression with
vlan and
orvlan n and
it works. For example:Version info:
Sample file:
tagged.pcap.gz
The text was updated successfully, but these errors were encountered: