Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
iowpa.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 1996, 2003 VIA Networking Technologies, Inc.
3  * All rights reserved.
4  *
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.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License along
16  * with this program; if not, write to the Free Software Foundation, Inc.,
17  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18  *
19  * File: iowpa.h
20  *
21  * Purpose: Handles wpa supplicant ioctl interface
22  *
23  * Author: Lyndon Chen
24  *
25  * Date: May 8, 2002
26  *
27  */
28 
29 #ifndef __IOWPA_H__
30 #define __IOWPA_H__
31 
32 /*--------------------- Export Definitions -------------------------*/
33 
34 
35 #define WPA_IE_LEN 64
36 
37 
38 //WPA related
39 /*
40 typedef enum { WPA_ALG_NONE, WPA_ALG_WEP, WPA_ALG_TKIP, WPA_ALG_CCMP } wpa_alg;
41 typedef enum { CIPHER_NONE, CIPHER_WEP40, CIPHER_TKIP, CIPHER_CCMP,
42  CIPHER_WEP104 } wpa_cipher;
43 typedef enum { KEY_MGMT_802_1X, KEY_MGMT_PSK, KEY_MGMT_NONE,
44  KEY_MGMT_802_1X_NO_WPA, KEY_MGMT_WPA_NONE } wpa_key_mgmt;
45 */
46 
47 enum {
58 };
59 
60 
61 enum {
68 };
69 
70 
71 
72 #pragma pack(1)
73 typedef struct viawget_wpa_header {
78 
79 
80 
83  u8 addr[6];
84  union {
85  struct {
87  u8 data[0];
88  } generic_elem;
89 
90  struct {
91  u8 bssid[6];
92  u8 ssid[32];
99  int auth_alg;
100  int mode;
101 
102  } wpa_associate;
103 
104  struct {
105  int alg_name;
108  u8 *seq;
110  u8 *key;
112  } wpa_key;
113 
114  struct {
115  u8 ssid_len;
116  u8 ssid[32];
117  } scan_req;
118 
119  struct {
121  u8 *buf;
122  } scan_results;
123 
124  } u;
125 
126 };
127 
128 #pragma pack(1)
130  u8 bssid[6];
131  u8 ssid[32];
137  int freq; // MHz
138  int caps; // e.g. privacy
139  int qual; // signal quality
140  int noise;
141  int level;
142  int maxrate;
143 };
144 
145 //2006-1116-01,<Add> by NomadZhao
146 #pragma pack()
147 /*--------------------- Export Classes ----------------------------*/
148 
149 /*--------------------- Export Variables --------------------------*/
150 
151 
152 /*--------------------- Export Types ------------------------------*/
153 
154 
155 /*--------------------- Export Functions --------------------------*/
156 
157 
158 
159 #endif //__IOWPA_H__