17 #include <sys/ioctl.h>
22 #define IWINFO_BUFSIZE 24 * 1024
23 #define IWINFO_ESSID_MAX_SIZE 32
25 #define IWINFO_80211_A (1 << 0)
26 #define IWINFO_80211_B (1 << 1)
27 #define IWINFO_80211_G (1 << 2)
28 #define IWINFO_80211_N (1 << 3)
30 #define IWINFO_CIPHER_NONE (1 << 0)
31 #define IWINFO_CIPHER_WEP40 (1 << 1)
32 #define IWINFO_CIPHER_TKIP (1 << 2)
33 #define IWINFO_CIPHER_WRAP (1 << 3)
34 #define IWINFO_CIPHER_CCMP (1 << 4)
35 #define IWINFO_CIPHER_WEP104 (1 << 5)
36 #define IWINFO_CIPHER_AESOCB (1 << 6)
37 #define IWINFO_CIPHER_CKIP (1 << 7)
39 #define IWINFO_KMGMT_NONE (1 << 0)
40 #define IWINFO_KMGMT_8021x (1 << 1)
41 #define IWINFO_KMGMT_PSK (1 << 2)
43 #define IWINFO_AUTH_OPEN (1 << 0)
44 #define IWINFO_AUTH_SHARED (1 << 1)
46 extern const char *IWINFO_CIPHER_NAMES
[];
47 extern const char *IWINFO_KMGMT_NAMES
[];
48 extern const char *IWINFO_AUTH_NAMES
[];
51 struct iwinfo_assoclist_entry
{
57 struct iwinfo_txpwrlist_entry
{
62 struct iwinfo_freqlist_entry
{
68 struct iwinfo_crypto_entry
{
71 uint8_t group_ciphers
;
77 struct iwinfo_scanlist_entry
{
79 uint8_t ssid
[IWINFO_ESSID_MAX_SIZE
+1];
85 struct iwinfo_crypto_entry crypto
;
88 struct iwinfo_country_entry
{
93 struct iwinfo_iso3166_label
{
98 struct iwinfo_hardware_id
{
101 uint16_t subsystem_vendor_id
;
102 uint16_t subsystem_device_id
;
105 struct iwinfo_hardware_entry
{
106 const char *vendor_name
;
107 const char *device_name
;
110 uint16_t subsystem_vendor_id
;
111 uint16_t subsystem_device_id
;
112 int16_t txpower_offset
;
113 int16_t frequency_offset
;
116 extern const struct iwinfo_iso3166_label IWINFO_ISO3166_NAMES
[];
117 extern const struct iwinfo_hardware_entry IWINFO_HARDWARE_ENTRIES
[];
121 int (*channel
)(const char *, int *);
122 int (*frequency
)(const char *, int *);
123 int (*frequency_offset
)(const char *, int *);
124 int (*txpower
)(const char *, int *);
125 int (*txpower_offset
)(const char *, int *);
126 int (*bitrate
)(const char *, int *);
127 int (*signal
)(const char *, int *);
128 int (*noise
)(const char *, int *);
129 int (*quality
)(const char *, int *);
130 int (*quality_max
)(const char *, int *);
131 int (*mbssid_support
)(const char *, int *);
132 int (*hwmodelist
)(const char *, int *);
133 int (*mode
)(const char *, char *);
134 int (*ssid
)(const char *, char *);
135 int (*bssid
)(const char *, char *);
136 int (*country
)(const char *, char *);
137 int (*hardware_id
)(const char *, char *);
138 int (*hardware_name
)(const char *, char *);
139 int (*encryption
)(const char *, char *);
140 int (*assoclist
)(const char *, char *, int *);
141 int (*txpwrlist
)(const char *, char *, int *);
142 int (*scanlist
)(const char *, char *, int *);
143 int (*freqlist
)(const char *, char *, int *);
144 int (*countrylist
)(const char *, char *, int *);
148 const char * iwinfo_type(const char *ifname
);
149 const struct iwinfo_ops
* iwinfo_backend(const char *ifname
);
150 void iwinfo_finish(void);
152 #include "iwinfo/wext.h"
155 #include "iwinfo/wl.h"
159 #include "iwinfo/madwifi.h"
163 #include "iwinfo/nl80211.h"