IEEE 802.11: Frames
Frames
The datagrams are called "frames." The 802.11 standards define "frame" types for use in transmission of data as well as management and control of wireless links. Frames are divided into very specific and standard
Frame Control Field
- Protocol Version: Two bits represent the protocol version. This version is currently zero with other values reserved for future use.
- Type: Two bits identify the type of the WLAN frame. Control, Data, and Management are various frame types defined in IEEE 802.11.
- Sub Type: Four bits provide additional discrimination between frames. Type and Sub type together identify the exact frame.
- ToDS and FromDS: One bit is used to indicate whether a data frame is headed for the distribution system. Control and management frames set these values to zero. All the data frames will have one of these bits set; however, communication within an IBSS network always set these bits to zero.
- More Fragments: This bit is set when a packet is divided into multiple frames for transmission. Every frame except the last frame of the packet will have this bet set.
- Retry: Sometimes frames require retransmission, and for this these is the Retry bit which is set to one when a frame is resent. This aids in the elimination of duplicate frames.
- Power Management: This bit indicates the power management state of the sender after the completion of a frame exchange. Access points are required to manage the connection and will never set the power saver bit.
- More Data: This bit is used to buffer frames received in a distributed system. The access point uses this bit to facilitate stations in power saver mode. It indicates that at least one frame is available and addresses all stations connected.
- WEP: This bit is modified after processing a frame. It is toggled to one after a frame has been decrypted or if no encryption is set it will have already been one.
- Order: This bit is only set when the "strict ordering" delivery method is employed. Frames and fragments are not always sent in order as it causes a transmission performance penalty.
Other Frame General Information
- The next two bytes are reserved for the Duration ID field. This field can take one of three forms: Duration, Contentions Free Period (CFP), and Association ID (AID).
- An 802.11 frame can have up to four address fields. Each field can carry a MAC address. Address 1 is the receiver, Address 2 is the transmitter, Address 3 is used for filtering purposes by the receiver.
- The Sequence Control field is a two-byte section used for identifying message order as well as eliminating duplicate frames. THe first 4 bits are used for the fragmentation number and the last 12 bits are the sequence number.
- An optional two-byte Quality of Service control field which was added with 802.11e.
- The Frame Body field is variable in size, from 0 to 2304 bytes plus an overhead from security encapsulation and contains information from higher layers.
- The Frame Check Sequence (FCS) is the last four bytes in the standard 802.11 frame. Often referred to as the Cyclic Redundancy Check (CRC), it allows for integrity check for retrieved frames. As frames are about to be sent the FCS is calculated and appended. When a station receives a frame it can calculate the FCS of the frame and compare it to the one received. If they match, it is assumed that the frame was not distorted during transmission.
Management Frames
- Authentication Frame: 802.11 authentication begins with the WNIC sending an authentication frame to the access point containing its identity. With an open system authentication the WNIC only sends a single authentication frame and the access point responds with an authentication frame of its own indicating acceptance or rejection. With shared key authentication, after the WNIC sends its initial authentication request it will receive an authentication frame from the access point containing challenge text. The WNIC sends an authentication frame containing the encrypted version of the challenge text to the access point. The access point ensures the text was encrypted with the correct key by decrypting it with its own key. The result of this process determines the WNIC's authentication status.
- Association Request Frame: This frame is sent from a station and when it is, it enables the access point to allocate resources and synchronize. The frame carries information about the WNIC including supported data rates and the SSID of the network the station wished to associate with. If the request is accepted, the access point reserves memory and establishes an association ID for the WNIC.
- Association Response Frame: This frame is sent from an access point to a station containing the acceptance or rejection to an association request. If it is an acceptance, the frame will contain information such as association ID and supported data rates.
- Beacon Frame: This frame is sent periodically from an access point to announce its presence and provide the SSID, and other parameters for WNICs within range.
- Deauthentication Frame: This frame is sent from a station wishing to terminate connection from another station.
- Disassociation Frame: This frame is sent from a station wishing to terminate connection. It is an elegant way to allow the access point to relinquish memory allocation and remove the WNIC from the association table.
- Probe Request Frame: This frame is sent from a station when it requires information from another station.
- Probe Response Frame: This is sent from an access point after receiving a probe request frame, and it contains capability information, supporting data rates, etc.
- Reassociation Request Frame: A WNIC sends one of these frames when it drops from range of the currently associated access point and finds another access point with a stronger signal. The new access point coordinates the forwarding of any information that may still be contained in the buffer of the previous access point.
- Reassociation Response Frame: This is sent from an access point and contains the acceptance or rejection to a WNIC reassociation request frame. The frame includes information required for association such as the association ID and supported data rates.
Information Elements
In terms of ICT, an Information Element (IE) is part of management frames in the IEEE 802.aa wireless LAN protocol. IEs are a device's way to transfer descriptive information about itself inside management frames. There are usually several IEs inside each such frame, and each is built of TLVs mostly defined outside the basic IEEE 802.11 specification. Note that the OUI (organizationally unique identifier) is only used when necessary to the protocol being used, and the data field holds the TLVs relevant to the IE. The common structure of an IE is shown below.
← 1 → ← 1 → ← 3 → ← 1-252 → ------------------------------------------------ | Type |Length| OUI | Data | ------------------------------------------------
Control Frames
Control frames facilitate in the exchange of data frames between stations. Some of the common 802.11 control frames a listed below.
- Acknowledgement (ACK) Frame: After receiving a data frame, the receiving station will send an ACK frame to the sending station if no errors are found. If the sending station doe not receive an ACK frame within a predetermined period of time, the sending station will resend the frame.
- Request to Send (RTS) Frame: The RTS and CTS frames provide an optional collision reduction scheme for access points with hidden stations. A station sends a RTS frame as the first step in a two-way handshake required before sending data frames.
- Clear to Send (CTS) Frame: A station responds to an RTS frame with a CTS frame. It provides clearance for the requesting station to send a data frame. The CTS provides collision control management by including a time value for which all other stations are to hold off transmission while the requesting station transmits.
Data Frames
Data frames carry packets from web pages, files, and other such places within the body. The body begins with an IEEE 802.2 header with the Destination Service Access Point (DSAP) specifying the protocol. If the DSAP is hex AA, the 802.2 header is followed by a Subnetwork Access Protocol (SNAP) header and the Organizationally Unique Identifier (OUI) and protocol ID (PID) fields specify the protocol. If the OUI is all zeroes, the protocol ID field is an EtherType value. Almost all 802.11 data frames use 802.2 and SNAP headers, and most use an OUI of 00:00:00 and an EtherType value.