3 Copyright (C) 2005-2011 Neil Cafferkey
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful, but
11 WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston,
26 /* IEEE 802.11 definitions */
28 #define WIFI_MAXIDLEN 32
29 #define WIFI_WEP64LEN 5
30 #define WIFI_WEP128LEN 13
31 #define WIFI_KEYCOUNT 4
33 #define WIFI_FRM_CONTROL 0x00
34 #define WIFI_FRM_DURATION 0x02
35 #define WIFI_FRM_ADDRESS1 0x04
36 #define WIFI_FRM_ADDRESS2 0x0a
37 #define WIFI_FRM_ADDRESS3 0x10
38 #define WIFI_FRM_SEQCONTROL 0x16
39 #define WIFI_FRM_ADDRESS4 0x18
40 #define WIFI_FRM_DATA 0x18
42 #define WIFI_FRM_CONTROLB_VERSION 0
43 #define WIFI_FRM_CONTROLB_TYPE 2
44 #define WIFI_FRM_CONTROLB_SUBTYPE 4
45 #define WIFI_FRM_CONTROLB_TODS 8
46 #define WIFI_FRM_CONTROLB_FROMDS 9
47 #define WIFI_FRM_CONTROLB_MOREFRAGS 10
48 #define WIFI_FRM_CONTROLB_WEP 14
49 #define WIFI_FRM_CONTROLB_ORDER 15
51 #define WIFI_FRM_CONTROLF_VERSION (0x3 << WIFI_FRM_CONTROLB_VERSION)
52 #define WIFI_FRM_CONTROLF_TYPE (0x3 << WIFI_FRM_CONTROLB_TYPE)
53 #define WIFI_FRM_CONTROLF_SUBTYPE (0xf << WIFI_FRM_CONTROLB_SUBTYPE)
54 #define WIFI_FRM_CONTROLF_TODS (0x1 << WIFI_FRM_CONTROLB_TODS)
55 #define WIFI_FRM_CONTROLF_FROMDS (0x1 << WIFI_FRM_CONTROLB_FROMDS)
56 #define WIFI_FRM_CONTROLF_MOREFRAGS (0x1 << WIFI_FRM_CONTROLB_MOREFRAGS)
57 #define WIFI_FRM_CONTROLF_WEP (0x1 << WIFI_FRM_CONTROLB_WEP)
58 #define WIFI_FRM_CONTROLF_ORDER (0x1 << WIFI_FRM_CONTROLB_ORDER)
60 #define WIFI_FRMTYPE_MGMT 0
61 #define WIFI_FRMTYPE_DATA 2
63 #define WIFI_BEACON_TIMESTAMP 0x0
64 #define WIFI_BEACON_INTERVAL 0x8
65 #define WIFI_BEACON_CAPABILITIES 0xa
66 #define WIFI_BEACON_IES 0xc
68 #define WIFI_IE_SSID 0
69 #define WIFI_IE_CHANNEL 3
70 #define WIFI_IE_RSN 48
71 #define WIFI_IE_CUSTOM 221