1/* 2 * This program is free software; you can redistribute it and/or 3 * modify it under the terms of the GNU General Public License as 4 * published by the Free Software Foundation; either version 2 of 5 * the License, or (at your option) any later version. 6 * 7 * This program is distributed in the hope that it will be useful, 8 * but WITHOUT ANY WARRANTY; without even the implied warranty of 9 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 10 * GNU General Public License for more details. 11 * 12 * You should have received a copy of the GNU General Public License 13 * along with this program; if not, write to the Free Software 14 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, 15 * MA 02111-1307 USA 16 */ 17#ifndef __WPS__H__ 18#define __WPS__H__ 19 20#define WSC_CONF_STATUS_STR "WscConfStatus" 21#define WSC_CONF_STATUS_UNCONFIGURED 1 /* these value are taken from 2860 driver Release Note document. */ 22#define WSC_CONF_STATUS_CONFIGURED 2 23 24/* 25 * ripped from driver wsc.h,....ugly 26 */ 27#define PACKED __attribute__ ((packed)) 28#define USHORT unsigned short 29#define UCHAR unsigned char 30 31typedef struct PACKED _WSC_CONFIGURED_VALUE { 32 USHORT WscConfigured; // 1 un-configured; 2 configured 33 UCHAR WscSsid[32 + 1]; 34 USHORT WscAuthMode; // mandatory, 0x01: open, 0x02: wpa-psk, 0x04: shared, 0x08:wpa, 0x10: wpa2, 0x 35 USHORT WscEncrypType; // 0x01: none, 0x02: wep, 0x04: tkip, 0x08: aes 36 UCHAR DefaultKeyIdx; 37 UCHAR WscWPAKey[64 + 1]; 38} WSC_CONFIGURED_VALUE; 39 40#define WSC_ID_VERSION 0x104A 41#define WSC_ID_VERSION_LEN 1 42#define WSC_ID_VERSION_BEACON 0x00000001 43 44#define WSC_ID_SC_STATE 0x1044 45#define WSC_ID_SC_STATE_LEN 1 46#define WSC_ID_SC_STATE_BEACON 0x00000002 47 48#define WSC_ID_AP_SETUP_LOCKED 0x1057 49#define WSC_ID_AP_SETUP_LOCKED_LEN 1 50#define WSC_ID_AP_SETUP_LOCKED_BEACON 0x00000004 51 52#define WSC_ID_SEL_REGISTRAR 0x1041 53#define WSC_ID_SEL_REGISTRAR_LEN 1 54#define WSC_ID_SEL_REGISTRAR_BEACON 0x00000008 55 56#define WSC_ID_DEVICE_PWD_ID 0x1012 57#define WSC_ID_DEVICE_PWD_ID_LEN 2 58#define WSC_ID_DEVICE_PWD_ID_BEACON 0x00000010 59 60 61#define WSC_ID_SEL_REG_CFG_METHODS 0x1053 62#define WSC_ID_SEL_REG_CFG_METHODS_LEN 2 63#define WSC_ID_SEL_REG_CFG_METHODS_BEACON 0x00000020 64 65#define WSC_ID_UUID_E 0x1047 66#define WSC_ID_UUID_E_LEN 16 67#define WSC_ID_UUID_E_BEACON 0x00000040 68 69#define WSC_ID_RF_BAND 0x103C 70#define WSC_ID_RF_BAND_LEN 1 71#define WSC_ID_RF_BAND_BEACON 0x00000080 72 73#define WSC_ID_PRIMARY_DEVICE_TYPE 0x1054 74#define WSC_ID_PRIMARY_DEVICE_TYPE_LEN 8 75#define WSC_ID_PRIMARY_DEVICE_TYPE_BEACON 0x00000100 76 77#endif /* __WPS__H_ */ 78