tcpdump mailing list archives
Doubt in print_802_11.c
From: "Latha G" <lathajee () gmail com>
Date: Fri, 10 Mar 2006 10:40:07 +0530
Hi all, I read in tcpdump manpage that it supports WLAN. My campus LAN is ethernet, so I want to see how the WLAN o/p will be, for that I am seeing print_802_11.c In that some of the Macros are like this #define FC_VERSION(fc) ((fc) & 0x3) #define FC_TYPE(fc) (((fc) >> 2) & 0x3) #define FC_SUBTYPE(fc) (((fc) >> 4) & 0xF) #define FC_TO_DS(fc) ((fc) & 0x0100) #define FC_FROM_DS(fc) ((fc) & 0x0200) #define FC_MORE_FLAG(fc) ((fc) & 0x0400) #define FC_RETRY(fc) ((fc) & 0x0800) #define FC_POWER_MGMT(fc) ((fc) & 0x1000) #define FC_MORE_DATA(fc) ((fc) & 0x2000) #define FC_WEP(fc) ((fc) & 0x4000) #define FC_ORDER(fc) ((fc) & 0x8000) fc is frame control. As i know, FC structure is like [ Version Type Subtype ToDs FromDS MF Retry Pwr More W O] Since FC is a 16-bit field, to obtain Version field fc &cooo, this is enough...but what i am seeing was completely different.... If we reverse the FC fields , then above code will be supported... Please assist me in understanding this... Thanks in advance.. -- Regards, Latha. - This is the tcpdump-workers list. Visit https://lists.sandelman.ca/ to unsubscribe.
Current thread:
- Doubt in print_802_11.c Latha G (Mar 09)