summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRoss Burton <ross@openedhand.com>2007-09-27 08:01:41 +0000
committerRoss Burton <ross@openedhand.com>2007-09-27 08:01:41 +0000
commitb284e39a7ea5b46e7c78c540d296968d903d63c5 (patch)
tree41d22df89318343e2ee13cf53930e70a3161a64f /meta
parent49535424d20ff063236743ddbfa95507fc325829 (diff)
downloadpoky-b284e39a7ea5b46e7c78c540d296968d903d63c5.tar.gz
wpa-supplicant: remove 0.5.7 and unused files
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2805 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta')
-rw-r--r--meta/packages/wpa-supplicant/files/driver-hermes.patch889
-rw-r--r--meta/packages/wpa-supplicant/files/madwifi-bsd-fix.diff12
-rw-r--r--meta/packages/wpa-supplicant/files/mtx-1/defconfig157
-rw-r--r--meta/packages/wpa-supplicant/files/openmn/defaults8
-rw-r--r--meta/packages/wpa-supplicant/files/slugos/defaults-sane8
-rw-r--r--meta/packages/wpa-supplicant/files/use-channel.patch32
-rw-r--r--meta/packages/wpa-supplicant/wpa-supplicant/gnutlsfix.patch19
-rw-r--r--meta/packages/wpa-supplicant/wpa-supplicant_0.5.7.bb3
8 files changed, 0 insertions, 1128 deletions
diff --git a/meta/packages/wpa-supplicant/files/driver-hermes.patch b/meta/packages/wpa-supplicant/files/driver-hermes.patch
deleted file mode 100644
index ad96db32c1..0000000000
--- a/meta/packages/wpa-supplicant/files/driver-hermes.patch
+++ /dev/null
@@ -1,889 +0,0 @@
1
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5
6--- /dev/null
7+++ wpa_supplicant/driver_hermes.c
8@@ -0,0 +1,705 @@
9+/*
10+ * WPA Supplicant - testing driver interface
11+ * Copyright (c) 2004-2005, Jouni Malinen <jkmaline@cc.hut.fi>
12+ *
13+ * This program is free software; you can redistribute it and/or modify
14+ * it under the terms of the GNU General Public License version 2 as
15+ * published by the Free Software Foundation.
16+ *
17+ * Alternatively, this software may be distributed under the terms of BSD
18+ * license.
19+ *
20+ * See README and COPYING for more details.
21+ */
22+
23+#include <stdlib.h>
24+#include <stdio.h>
25+#include <unistd.h>
26+#include <string.h>
27+#include <sys/ioctl.h>
28+#include <errno.h>
29+#include <net/if_arp.h>
30+
31+#include "wireless_copy.h"
32+#include "common.h"
33+#include "driver.h"
34+
35+#include "eloop.h"
36+#include "wpa_supplicant.h"
37+#include "priv_netlink.h"
38+
39+#include "hostap_common.h"
40+#include "driver_wext.h"
41+#include "driver_hermes.h"
42+
43+
44+
45+/* Enumeration for supported Hermes Types */
46+enum
47+{
48+ WL_HERMES_UNKNOWN = 0,
49+ WL_HERMES_1 = 1,
50+ WL_HERMES_2 = 2,
51+ WL_HERMES_25 = 3
52+};
53+
54+
55+
56+
57+struct wpa_driver_hermes_data {
58+ void *wext; /* private data for driver_wext */
59+ void *ctx;
60+ char ifname[IFNAMSIZ + 1];
61+ int sock;
62+ int type;
63+};
64+
65+
66+
67+/****************************************************************************/
68+/* */
69+/* Routines for basic device access to Agere Hermes-I/Hermes-II via the UIL */
70+/* */
71+/****************************************************************************/
72+
73+IFBP _connect(void *priv)
74+{
75+ struct wpa_driver_hermes_data *drv = priv;
76+ int result = 0;
77+ IFBP ifbp = NULL;
78+ struct uilreq urq;
79+
80+ //wpa_printf(MSG_DEBUG, "%s: %s %d", __FUNCTION__, drv->ifname, drv->sock);
81+
82+ memset(&urq, 0, sizeof(urq));
83+
84+ strcpy(urq.ifr_name, drv->ifname);
85+ urq.command = UIL_FUN_CONNECT;
86+
87+ result = ioctl(drv->sock, WVLAN2_IOCTL_UIL, &urq);
88+ if (result == 0 && urq.result == UIL_SUCCESS) {
89+ ifbp = urq.hcfCtx;
90+ } else {
91+ wpa_printf(MSG_DEBUG, "%s: could not set IFBP, result %d", __FUNCTION__, result);
92+ }
93+
94+ return ifbp;
95+}
96+
97+
98+void _disconnect(void *priv, IFBP ifbp)
99+{
100+ struct wpa_driver_hermes_data *drv = priv;
101+ int result = 0;
102+ struct uilreq urq;
103+
104+ //wpa_printf(MSG_DEBUG, "%s: %s", __FUNCTION__, drv->ifname);
105+
106+ if (ifbp != NULL) {
107+ memset(&urq, 0, sizeof(struct uilreq));
108+
109+ strcpy(urq.ifr_name, drv->ifname);
110+ urq.command = UIL_FUN_DISCONNECT;
111+ urq.hcfCtx = ifbp;
112+
113+ result = ioctl(drv->sock, WVLAN2_IOCTL_UIL, &urq);
114+
115+ if (result != 0 || urq.result != UIL_SUCCESS) {
116+ wpa_printf( MSG_WARNING, "wl_disconnect(): ioctl() failed, errno: %d", errno );
117+ wpa_printf( MSG_WARNING, "wl_disconnect(): urq.result: %d", urq.result );
118+ }
119+ } else {
120+ wpa_printf(MSG_WARNING, "wl_disconnect(): called with NULL ifbp");
121+ }
122+
123+ return;
124+}
125+
126+int _get_info(void *priv, ltv_t *ltv)
127+{
128+ struct wpa_driver_hermes_data *drv = priv;
129+ int result = 0;
130+ IFBP ifbp = NULL;
131+ struct uilreq urq;
132+
133+ //wpa_printf(MSG_DEBUG, "%s: %s", __FUNCTION__, drv->ifname);
134+
135+ /* First, connect to the device */
136+ ifbp = _connect(priv);
137+ if (ifbp != NULL && ltv != NULL) {
138+ memset(&urq, 0, sizeof(struct uilreq));
139+
140+ strcpy(urq.ifr_name, drv->ifname);
141+ urq.hcfCtx = ifbp;
142+ urq.command = UIL_FUN_GET_INFO;
143+ urq.len = sizeof(ltv_t);
144+ urq.data = ltv;
145+
146+ result = ioctl(drv->sock, WVLAN2_IOCTL_UIL, &urq);
147+
148+ if (result != 0 || urq.result != UIL_SUCCESS) {
149+ wpa_printf(MSG_WARNING, "wl_disconnect(): ioctl() failed, errno: %d", errno);
150+ wpa_printf(MSG_WARNING, "wl_disconnect(): urq.result: %d", urq.result);
151+ }
152+ _disconnect(priv, ifbp);
153+ } else {
154+ wpa_printf( MSG_WARNING, "Could not connect to the device, or LTV NULL");
155+ result = -1;
156+ }
157+
158+ return result;
159+}
160+
161+int _put_info(void *priv, ltv_t *ltv)
162+{
163+ struct wpa_driver_hermes_data *drv = priv;
164+ int result = 0;
165+ IFBP ifbp = NULL;
166+ struct uilreq urq;
167+
168+ //wpa_printf(MSG_DEBUG, "%s: %s", __FUNCTION__, drv->ifname);
169+
170+ /* First, connect to the device */
171+ ifbp = _connect(priv);
172+ if (ifbp != NULL && ltv != NULL) {
173+ memset(&urq, 0, sizeof(struct uilreq));
174+
175+ strcpy(urq.ifr_name, drv->ifname);
176+ urq.hcfCtx = ifbp;
177+ urq.command = UIL_FUN_PUT_INFO;
178+ urq.len = sizeof( ltv_t );
179+ urq.data = ltv;
180+
181+ result = ioctl(drv->sock, WVLAN2_IOCTL_UIL, &urq);
182+
183+ if (result != 0 || urq.result != UIL_SUCCESS) {
184+ wpa_printf(MSG_WARNING, "_put_info(): ioctl() failed, errno: %d", errno);
185+ wpa_printf(MSG_WARNING, "_put_info(): urq.result: %d", urq.result);
186+ }
187+
188+ _disconnect(priv, ifbp);
189+ } else {
190+ wpa_printf(MSG_WARNING, "%s: could not connect to the device, or LTV NULL", __FUNCTION__ );
191+ result = -1;
192+ }
193+
194+ return result;
195+}
196+
197+
198+static void _detect_hermes_type(void *priv)
199+{
200+ struct wpa_driver_hermes_data *drv = priv;
201+ CFG_FW_IDENTITY_STRCT *fw_id;
202+ ltv_t ltv;
203+ int result;
204+
205+ //wpa_printf(MSG_DEBUG, "%s", __FUNCTION__);
206+
207+ drv->type = WL_HERMES_UNKNOWN;
208+
209+ if (drv->sock >= 0) {
210+ fw_id = (CFG_FW_IDENTITY_STRCT *)&ltv;
211+ fw_id->len = ( sizeof(CFG_FW_IDENTITY_STRCT) / sizeof( hcf_16 )) - 1;
212+ fw_id->typ = CFG_FW_IDENTITY;
213+
214+ result = _get_info(priv, (ltv_t *)fw_id);
215+ if (result == HCF_SUCCESS) {
216+ //wpa_printf(MSG_DEBUG, "PRI CompID : %d", fw_id->comp_id);
217+ //wpa_printf(MSG_DEBUG, "PRI Variant : %d", fw_id->variant);
218+ //wpa_printf(MSG_DEBUG, "PRI Version : %d.%02d", fw_id->version_major, fw_id->version_minor);
219+
220+ switch(fw_id->comp_id) {
221+ case COMP_ID_FW_STA:
222+ switch (fw_id->variant) {
223+ case 1:
224+ case 2:
225+ wpa_printf(MSG_DEBUG, "found Hermes 1 STA");
226+ drv->type = WL_HERMES_1;
227+ break;
228+
229+ case 3:
230+ wpa_printf(MSG_DEBUG, "found Hermes 2 STA");
231+ drv->type = WL_HERMES_2;
232+ break;
233+ case 4:
234+ wpa_printf(MSG_DEBUG, "found Hermes 2.5 STA");
235+ drv->type = WL_HERMES_25;
236+ break;
237+ }
238+ break;
239+
240+ case COMP_ID_FW_AP:
241+ switch (fw_id->variant) {
242+ case 1:
243+ wpa_printf(MSG_DEBUG, "found Hermes 1 AP");
244+ drv->type = WL_HERMES_1;
245+ break;
246+
247+ case 2:
248+ wpa_printf(MSG_DEBUG, "found Hermes 2 AP" );
249+ drv->type = WL_HERMES_2;
250+ break;
251+ }
252+ break;
253+
254+ default:
255+ wpa_printf(MSG_WARNING, "could not detect Hermes type!");
256+ break;
257+ }
258+ }
259+ }
260+}
261+
262+
263+
264+/****************************************************************************/
265+
266+
267+static int wpa_driver_hermes_set_wpa_ie(void *priv, const char *wpa_ie,
268+ size_t wpa_ie_len)
269+{
270+ struct wpa_driver_hermes_data *drv = priv;
271+ ltv_t ltv;
272+
273+ wpa_printf(MSG_DEBUG, "%s", __FUNCTION__);
274+
275+ ltv.len = 2;
276+ ltv.typ = CFG_SET_WPA_AUTH_KEY_MGMT_SUITE;
277+
278+ switch(drv->type) {
279+ case WL_HERMES_1:
280+ ltv.u.u16[0] = 2;
281+ break;
282+
283+ case WL_HERMES_2:
284+ case WL_HERMES_25:
285+ ltv.u.u16[0] = 4;
286+ break;
287+
288+ default:
289+ ltv.u.u16[0] = 0;
290+ break;
291+ }
292+
293+ return _put_info(priv, &ltv);
294+}
295+
296+
297+static int wpa_driver_hermes_set_wpa(void *priv, int enabled)
298+{
299+ ltv_t ltv;
300+
301+ wpa_printf(MSG_DEBUG, "%s: enabled=%d", __func__, enabled);
302+
303+ ltv.len = 2;
304+ ltv.typ = CFG_CNF_ENCRYPTION;
305+ ltv.u.u16[0] = enabled ? 2 : 0; /* Setting CFG_CNF_ENCRYPTION to 2 sets WPA: TKIP or better */
306+
307+ return _put_info(priv, &ltv);
308+}
309+
310+
311+static int wpa_driver_hermes_set_key(void *priv, wpa_alg alg,
312+ const u8 *addr, int key_idx,
313+ int set_tx, const u8 *seq, size_t seq_len,
314+ const u8 *key, size_t key_len)
315+{
316+ struct wpa_driver_hermes_data *drv = priv;
317+ int ret = 0;
318+ char *alg_name;
319+ ltv_t ltv;
320+ int count = 0;
321+ int buf_idx = 0;
322+ hcf_8 tsc[] = { 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00 };
323+ hcf_8 rsc[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 };
324+
325+
326+ switch (alg) {
327+ case WPA_ALG_NONE:
328+ alg_name = "none";
329+ break;
330+ case WPA_ALG_WEP:
331+ alg_name = "WEP";
332+ break;
333+ case WPA_ALG_TKIP:
334+ alg_name = "TKIP";
335+ break;
336+ case WPA_ALG_CCMP:
337+ alg_name = "CCMP";
338+ break;
339+ default:
340+ return -1;
341+ }
342+
343+ wpa_printf(MSG_DEBUG, "%s: alg=%s key_idx=%d set_tx=%d seq_len=%d "
344+ "key_len=%d", __FUNCTION__, alg_name, key_idx, set_tx,
345+ seq_len, key_len);
346+
347+ if (seq_len > IW_ENCODE_SEQ_MAX_SIZE) {
348+ wpa_printf(MSG_DEBUG, "%s: Invalid seq_len %lu", __FUNCTION__, (unsigned long) seq_len);
349+ return -2;
350+ }
351+
352+ /* Check the key index here; if 0, load as Pairwise Key, otherwise, load as
353+ a group key. Note that for the Hermes, the RIDs for group/pairwise keys
354+ are different from each other and different than the default WEP keys as
355+ well. */
356+ switch (alg) {
357+ case WPA_ALG_TKIP:
358+ /* Make sure that there is no data queued up in the firmware before
359+ setting the TKIP keys. If this check is not performed, some data
360+ may be sent out with incorrect MIC and cause synchronizarion
361+ errors with the AP */
362+ /* Check every 1ms for 100ms */
363+ for (count = 0; count < 100; count++) {
364+ usleep(1000);
365+
366+ ltv.len = 2;
367+ ltv.typ = 0xFD91; // This RID not defined in HCF yet!!!
368+ ltv.u.u16[0] = 0;
369+
370+ _get_info( priv, &ltv);
371+
372+ if (ltv.u.u16[0] == 0)
373+ break;
374+ }
375+
376+ if (count == 100)
377+ wpa_printf(MSG_DEBUG, "%s: Timed out waiting for TxQ!", __FUNCTION__);
378+
379+
380+ switch (key_idx) {
381+ case 0:
382+ /* Only load key as pairwise key for Hermes-II and II.5. For Hermes-I,
383+ fall through to the next case and load the pairwise key as
384+ a Group Key at index 0. */
385+ if (drv->type == WL_HERMES_2 || drv->type == WL_HERMES_25) {
386+ ltv.len = 28;
387+ ltv.typ = CFG_ADD_TKIP_MAPPED_KEY;
388+
389+ /* Load the BSSID */
390+ memcpy(&ltv.u.u8[buf_idx], addr, ETH_ALEN);
391+ buf_idx += ETH_ALEN;
392+
393+ /* Load the TKIP key */
394+ memcpy(&ltv.u.u8[buf_idx], &key[0], 16);
395+ buf_idx += 16;
396+
397+ /* Load the TSC */
398+ memcpy(&ltv.u.u8[buf_idx], tsc, 8);
399+ buf_idx += 8;
400+
401+ /* Load the RSC */
402+ /* Copy the RSC from the supplicant to a local buffer, because
403+ the RSC doesn't always contain the padding needed */
404+ memcpy(rsc, seq, seq_len);
405+ memcpy(&ltv.u.u8[buf_idx], rsc, 8);
406+ buf_idx += 8;
407+
408+ /* Load the TxMIC key */
409+ memcpy(&ltv.u.u8[buf_idx], &key[16], 8);
410+ buf_idx += 8;
411+
412+ /* Load the RxMIC key */
413+ memcpy(&ltv.u.u8[buf_idx], &key[24], 8);
414+
415+ /* Send the request to the Hermes */
416+ _put_info(priv, &ltv);
417+ break;
418+ }
419+
420+ case 1:
421+ case 2:
422+ case 3:
423+ ltv.len = 26;
424+ ltv.typ = CFG_ADD_TKIP_DEFAULT_KEY;
425+
426+ /* Load the key Index */
427+ ltv.u.u16[buf_idx] = key_idx;
428+
429+ /* If this is a Tx Key, set bit 8000 */
430+ if (set_tx)
431+ ltv.u.u16[buf_idx] |= 0x8000;
432+
433+ buf_idx += 2;
434+
435+ /* Load the RSC */
436+ /* Copy the RSC from the supplicant to a local buffer, because
437+ the RSC doesn't always contain the padding needed */
438+ memcpy(rsc, seq, seq_len);
439+ memcpy(&ltv.u.u8[buf_idx], rsc, 8);
440+ buf_idx += 8;
441+
442+ /* Load the TKIP, TxMIC, and RxMIC keys in one shot, because in
443+ CFG_ADD_TKIP_DEFAULT_KEY they are back-to-back */
444+ memcpy(&ltv.u.u8[buf_idx], key, key_len);
445+ buf_idx += key_len;
446+
447+ /* Load the TSC */
448+ memcpy(&ltv.u.u8[buf_idx], tsc, 8);
449+
450+ /* Send the request to the Hermes */
451+ _put_info(priv, &ltv);
452+ break;
453+
454+ default:
455+ break;
456+ }
457+
458+ break;
459+
460+ case WPA_ALG_WEP:
461+ case WPA_ALG_CCMP:
462+ break;
463+
464+ case WPA_ALG_NONE:
465+ switch (key_idx) {
466+ case 0:
467+ if (drv->type == WL_HERMES_2 || drv->type == WL_HERMES_25) {
468+ /* Only clear a pairwise key for Hermes-II. For Hermes-I,
469+ fall through to the next case and clear the key as a
470+ Group Key at index 0. */
471+ if (addr) {
472+ ltv.len = 7;
473+ ltv.typ = CFG_REMOVE_TKIP_MAPPED_KEY;
474+
475+ memcpy(&ltv.u.u8[0], addr, ETH_ALEN);
476+
477+ _put_info(priv, &ltv);
478+ }
479+ break;
480+ }
481+
482+ case 1:
483+ case 2:
484+ case 3:
485+ /* Clear the Group TKIP keys by index */
486+ ltv.len = 2;
487+ ltv.typ = CFG_REMOVE_TKIP_DEFAULT_KEY;
488+
489+ ltv.u.u16[0] = key_idx;
490+
491+ _put_info(priv, &ltv);
492+ break;
493+
494+ default:
495+ break;
496+ }
497+ break;
498+
499+ default:
500+ break;
501+ }
502+
503+ return ret;
504+}
505+
506+
507+static int wpa_driver_hermes_set_countermeasures(void *priv, int enabled)
508+{
509+ ltv_t ltv;
510+
511+ /* The supplicant handles all the timers related to MIC failure and
512+ countermeasures. When countermeasures are enabled, shut down the card;
513+ when disable, re-enable the card. Make sure that the EAPOL message
514+ is getting out before card disable */
515+
516+ wpa_printf(MSG_DEBUG, "%s: enabled=%d", __FUNCTION__, enabled);
517+
518+ ltv.len = 2;
519+ ltv.typ = CFG_DRIVER_ENABLE;
520+ ltv.u.u16[0] = enabled ? 0 : 1;
521+
522+ return _put_info(priv, &ltv);
523+}
524+
525+
526+static int wpa_driver_hermes_set_drop_unencrypted(void *priv, int enabled)
527+{
528+ ltv_t ltv;
529+
530+ wpa_printf(MSG_DEBUG, "%s: enabled=%d", __FUNCTION__, enabled);
531+
532+ ltv.len = 2;
533+ ltv.typ = CFG_CNF_EXCL_UNENCRYPTED;
534+ ltv.u.u16[0] = enabled;
535+
536+ return _put_info(priv, &ltv);
537+}
538+
539+
540+static int wpa_driver_hermes_deauthenticate(void *priv, const u8 *addr,
541+ int reason_code)
542+{
543+ wpa_printf(MSG_DEBUG, "%s: *DUMMY* %d", __FUNCTION__, reason_code);
544+
545+ return 0;
546+}
547+
548+
549+static int wpa_driver_hermes_disassociate(void *priv, const u8 *addr, int reason_code)
550+{
551+ ltv_t ltv;
552+
553+ wpa_printf(MSG_DEBUG, "%s: reason=%d", __FUNCTION__, reason_code);
554+
555+ ltv.len = 2;
556+ ltv.typ = 0xFCC8; // This RID not defined in HCF yet!!!
557+ memcpy( &ltv.u.u8[0], addr, ETH_ALEN );
558+ ltv.u.u16[ETH_ALEN / 2] = reason_code;
559+
560+ return _put_info( priv, &ltv);
561+}
562+
563+
564+static int wpa_driver_hermes_associate(
565+ void *priv, struct wpa_driver_associate_params *params)
566+{
567+ struct wpa_driver_hermes_data *drv = priv;
568+
569+#if 0
570+ wpa_printf(MSG_DEBUG, "%s", __FUNCTION__);
571+#else
572+ wpa_printf(MSG_DEBUG, "%s: priv=%p freq=%d pairwise_suite=%d "
573+ "group_suite=%d key_mgmt_suite=%d auth_alg=%d mode=%d",
574+ __func__, priv, params->freq, params->pairwise_suite,
575+ params->group_suite, params->key_mgmt_suite,
576+ params->auth_alg, params->mode);
577+ if (params->bssid) {
578+ wpa_printf(MSG_DEBUG, " bssid=" MACSTR,
579+ MAC2STR(params->bssid));
580+ }
581+ if (params->ssid) {
582+ wpa_hexdump_ascii(MSG_DEBUG, " ssid",
583+ params->ssid, params->ssid_len);
584+ }
585+ if (params->wpa_ie) {
586+ wpa_hexdump(MSG_DEBUG, " wpa_ie",
587+ params->wpa_ie, params->wpa_ie_len);
588+ }
589+#endif
590+
591+ if (wpa_driver_hermes_set_wpa_ie(priv, params->wpa_ie, params->wpa_ie_len) < 0)
592+ return -1;
593+ if (wpa_driver_wext_set_freq(drv->wext, params->freq) < 0)
594+ return -1;
595+ if (wpa_driver_wext_set_ssid(drv->wext, params->ssid, params->ssid_len) < 0)
596+ return -1;
597+#ifdef UNSUPPORTED_IN_HERMES_DRIVER
598+ if (wpa_driver_wext_hermes_bssid(drv->wext, params->bssid) < 0)
599+ return -1;
600+#endif
601+
602+ return 0;
603+}
604+
605+
606+static int wpa_driver_hermes_get_bssid(void *priv, u8 *bssid)
607+{
608+ struct wpa_driver_hermes_data *drv = priv;
609+ return wpa_driver_wext_get_bssid(drv->wext, bssid);
610+}
611+
612+
613+static int wpa_driver_hermes_get_ssid(void *priv, u8 *ssid)
614+{
615+ struct wpa_driver_hermes_data *drv = priv;
616+ return wpa_driver_wext_get_ssid(drv->wext, ssid);
617+}
618+
619+
620+static int wpa_driver_hermes_scan(void *priv, const u8 *ssid, size_t ssid_len)
621+{
622+ struct wpa_driver_hermes_data *drv = priv;
623+ return wpa_driver_wext_scan(drv->wext, ssid, ssid_len);
624+}
625+
626+
627+static int wpa_driver_hermes_get_scan_results(void *priv,
628+ struct wpa_scan_result *results,
629+ size_t max_size)
630+{
631+ struct wpa_driver_hermes_data *drv = priv;
632+ return wpa_driver_wext_get_scan_results(drv->wext, results, max_size);
633+}
634+
635+
636+static void * wpa_driver_hermes_init(void *ctx, const char *ifname)
637+{
638+ struct wpa_driver_hermes_data *drv;
639+
640+ wpa_printf(MSG_DEBUG, "%s: %s", __FUNCTION__, ifname);
641+
642+ drv = malloc(sizeof(*drv));
643+ if (drv == NULL)
644+ return NULL;
645+ memset(drv, 0, sizeof(*drv));
646+
647+ /* Initialize wireless context */
648+ drv->wext = wpa_driver_wext_init(ctx, ifname);
649+ if (drv->wext == NULL) {
650+ perror("no wext context");
651+ goto no_wext;
652+ }
653+
654+ drv->ctx = ctx;
655+ strncpy(drv->ifname, ifname, sizeof(drv->ifname));
656+
657+ drv->sock = socket(PF_INET, SOCK_DGRAM, 0);
658+ if (drv->sock < 0) {
659+ perror("socket(PF_INET,SOCK_DGRAM)");
660+ goto no_sock;
661+ }
662+
663+ _detect_hermes_type(drv);
664+
665+ return drv;
666+
667+no_sock:
668+ wpa_driver_wext_deinit(drv->wext);
669+no_wext:
670+ free(drv);
671+ return NULL;
672+}
673+
674+
675+static void wpa_driver_hermes_deinit(void *priv)
676+{
677+ struct wpa_driver_hermes_data *drv = priv;
678+ wpa_driver_wext_deinit(drv->wext);
679+ close(drv->sock);
680+ free(drv);
681+}
682+
683+
684+
685+
686+struct wpa_driver_ops wpa_driver_hermes_ops = {
687+ .name = "hermes",
688+ .desc = "wpa_supplicant hermes driver",
689+
690+ .init = wpa_driver_hermes_init,
691+ .deinit = wpa_driver_hermes_deinit,
692+
693+ // from old driver_hermes.c:
694+ .get_bssid = wpa_driver_hermes_get_bssid,
695+ .get_ssid = wpa_driver_hermes_get_ssid,
696+ .set_wpa = wpa_driver_hermes_set_wpa,
697+ .set_key = wpa_driver_hermes_set_key,
698+ //.events_init = wpa_driver_wext_events_init,
699+ //.events_deinit = wpa_driver_wext_events_deinit,
700+ .set_countermeasures = wpa_driver_hermes_set_countermeasures,
701+ .set_drop_unencrypted = wpa_driver_hermes_set_drop_unencrypted,
702+ .scan = wpa_driver_hermes_scan,
703+ .get_scan_results = wpa_driver_hermes_get_scan_results,
704+ .deauthenticate = wpa_driver_hermes_deauthenticate,
705+ .disassociate = wpa_driver_hermes_disassociate,
706+ .associate = wpa_driver_hermes_associate,
707+
708+
709+#if 0
710+ /* Not possible with current Hermes driver:
711+ .set_auth_alg = wpa_driver_hermes_set_auth_alg, */
712+#endif
713+};
714--- /dev/null
715+++ wpa_supplicant/driver_hermes.h
716@@ -0,0 +1,173 @@
717+#ifndef HERMES_DRIVER_H
718+#define HERMES_DRIVER_H
719+
720+typedef unsigned char hcf_8;
721+typedef unsigned short hcf_16;
722+typedef unsigned long hcf_32;
723+typedef hcf_16 hcf_io;
724+typedef hcf_8 *wci_bufp;
725+
726+typedef struct {
727+ hcf_16 len;
728+ hcf_16 typ;
729+ unsigned short * bufp;
730+} RID_LOG_STRCT;
731+typedef RID_LOG_STRCT *RID_LOGP;
732+
733+typedef struct {
734+ hcf_16 len;
735+ hcf_16 typ;
736+ hcf_16 comp_id;
737+ hcf_16 variant;
738+ hcf_16 version_major;
739+ hcf_16 version_minor;
740+} CFG_FW_IDENTITY_STRCT;
741+
742+typedef struct {
743+ hcf_32 TxUnicastFrames;
744+ hcf_32 TxMulticastFrames;
745+ hcf_32 TxFragments;
746+ hcf_32 TxUnicastOctets;
747+ hcf_32 TxMulticastOctets;
748+ hcf_32 TxDeferredTransmissions;
749+ hcf_32 TxSingleRetryFrames;
750+ hcf_32 TxMultipleRetryFrames;
751+ hcf_32 TxRetryLimitExceeded;
752+ hcf_32 TxDiscards;
753+ hcf_32 RxUnicastFrames;
754+ hcf_32 RxMulticastFrames;
755+ hcf_32 RxFragments;
756+ hcf_32 RxUnicastOctets;
757+ hcf_32 RxMulticastOctets;
758+ hcf_32 RxFCSErrors;
759+ hcf_32 RxDiscardsNoBuffer;
760+ hcf_32 TxDiscardsWrongSA;
761+ hcf_32 RxWEPUndecryptable;
762+ hcf_32 RxMsgInMsgFragments;
763+ hcf_32 RxMsgInBadMsgFragments;
764+ hcf_32 RxDiscardsWEPICVError;
765+ hcf_32 RxDiscardsWEPExcluded;
766+} CFG_HERMES_TALLIES_STRCT;
767+
768+typedef struct {
769+ hcf_32 not_used_NoBufInq;
770+ hcf_32 NoBufInfo;
771+ hcf_32 NoBufMB;
772+ hcf_32 MiscErr;
773+ hcf_32 EngCnt;
774+} CFG_HCF_TALLIES_STRCT;
775+
776+typedef struct {
777+ hcf_io IFB_IOBase;
778+ hcf_16 IFB_IORange;
779+
780+ hcf_32 IFB_TickIni;
781+
782+ hcf_16 IFB_Version;
783+ hcf_16 IFB_CardStat;
784+ hcf_16 IFB_TraceLvl;
785+ hcf_16 *IFB_MBp;
786+ hcf_16 IFB_MBSize;
787+ hcf_16 IFB_MBWp;
788+ hcf_16 IFB_MBRp;
789+ hcf_16 IFB_MBInfoLen;
790+
791+ hcf_16 IFB_DLMode;
792+ hcf_16 IFB_Magic;
793+ hcf_16 IFB_Cmd;
794+ hcf_16 IFB_RxFID;
795+ RID_LOGP IFB_RIDLogp;
796+ hcf_16 IFB_Monitor;
797+ hcf_16 IFB_TxFid;
798+ hcf_16 IFB_RxLen;
799+ hcf_16 IFB_DefunctStat;
800+
801+ hcf_16 IFB_ErrCmd;
802+ hcf_16 IFB_ErrQualifier;
803+ hcf_16 IFB_lal;
804+ wci_bufp IFB_lap;
805+ hcf_16 IFB_LinkStat;
806+
807+ void (*IFB_MICRxRtn)( hcf_32*, hcf_32 );
808+ void (*IFB_MICTxRtn)( hcf_32*, hcf_32 );
809+ hcf_16 IFB_rx_tlen;
810+ hcf_16 IFB_tx_tlen;
811+ hcf_8 IFB_rx_32[4];
812+ hcf_8 IFB_tx_32[4];
813+ hcf_16 IFB_RscInd;
814+ hcf_16 IFB_MB_FID;
815+ hcf_16 IFB_DLTarget[2];
816+
817+ hcf_16 IFB_DLPage;
818+ hcf_16 IFB_DLOffset;
819+ hcf_16 IFB_DLLen;
820+
821+ hcf_16 volatile IFB_IntOffCnt;
822+ hcf_16 IFB_IntEnMask;
823+
824+ CFG_FW_IDENTITY_STRCT IFB_FWIdentity;
825+ hcf_16 IFB_Tally;
826+ hcf_16 IFB_TallyTyp;
827+
828+ CFG_HERMES_TALLIES_STRCT IFB_NIC_Tallies;
829+ CFG_HCF_TALLIES_STRCT IFB_HCF_Tallies;
830+
831+ void *IFB_MSFSup;
832+} IFB_STRCT;
833+
834+typedef IFB_STRCT* IFBP;
835+
836+struct uilreq
837+{
838+ union
839+ {
840+ char ifrn_name[16];
841+ } ifr_ifrn;
842+
843+ IFBP hcfCtx;
844+ __u8 command;
845+ __u8 result;
846+ __u16 len;
847+ void *data;
848+};
849+
850+typedef struct
851+{
852+ hcf_16 len;
853+ hcf_16 typ;
854+ union
855+ {
856+ hcf_8 u8[(512 - (sizeof(hcf_16) * 2)) / sizeof(hcf_8)];
857+ hcf_16 u16[(512 - (sizeof(hcf_16) * 2)) / sizeof(hcf_16)];
858+ hcf_32 u32[(512 - (sizeof(hcf_16) * 2)) / sizeof(hcf_32)];
859+ } u;
860+} ltv_t;
861+
862+
863+#define UIL_FUN_CONNECT 0x00
864+#define UIL_FUN_DISCONNECT 0x01
865+#define UIL_FUN_GET_INFO 0x04
866+#define UIL_FUN_PUT_INFO 0x05
867+
868+#define GENERIC_INFO_ELEM 0xdd
869+#define RSN_INFO_ELEM 0x30
870+
871+#define CFG_DRIVER_ENABLE 0x0902
872+#define CFG_CNF_ENCRYPTION 0xFC20
873+#define CFG_ADD_TKIP_DEFAULT_KEY 0xFCB4
874+#define CFG_SET_WPA_AUTH_KEY_MGMT_SUITE 0xFCB5
875+#define CFG_REMOVE_TKIP_DEFAULT_KEY 0xFCB6
876+#define CFG_ADD_TKIP_MAPPED_KEY 0xFCB7
877+#define CFG_REMOVE_TKIP_MAPPED_KEY 0xFCB8
878+#define CFG_FW_IDENTITY 0xFD20
879+#define CFG_CNF_EXCL_UNENCRYPTED 0xFC22
880+
881+#define HCF_SUCCESS 0x00
882+#define UIL_SUCCESS 0x00
883+
884+#define COMP_ID_FW_STA 31
885+#define COMP_ID_FW_AP 32
886+
887+#define WVLAN2_IOCTL_UIL SIOCDEVPRIVATE
888+
889+#endif
diff --git a/meta/packages/wpa-supplicant/files/madwifi-bsd-fix.diff b/meta/packages/wpa-supplicant/files/madwifi-bsd-fix.diff
deleted file mode 100644
index 974eb39627..0000000000
--- a/meta/packages/wpa-supplicant/files/madwifi-bsd-fix.diff
+++ /dev/null
@@ -1,12 +0,0 @@
1--- driver_madwifi.c.orig 2005-03-18 15:12:53.392793216 +0100
2+++ driver_madwifi.c 2005-03-18 15:13:09.246383104 +0100
3@@ -25,7 +25,8 @@
4 #include "eloop.h"
5 #include "wpa_supplicant.h"
6
7-#include <include/compat.h>
8+#include <net80211/compat.h>
9+#include <net80211/_ieee80211.h>
10 #include <net80211/ieee80211.h>
11 #include <net80211/ieee80211_crypto.h>
12 #include <net80211/ieee80211_ioctl.h>
diff --git a/meta/packages/wpa-supplicant/files/mtx-1/defconfig b/meta/packages/wpa-supplicant/files/mtx-1/defconfig
deleted file mode 100644
index a0d9b73d3f..0000000000
--- a/meta/packages/wpa-supplicant/files/mtx-1/defconfig
+++ /dev/null
@@ -1,157 +0,0 @@
1# This file lists the configuration options that are used when building the
2# hostapd binary. All lines starting with # are ignored. Configuration option
3# lines must be commented out complete, if they are not to be included, i.e.,
4# just setting VARIABLE=n is not disabling that variable.
5#
6# This file is included in Makefile, so variables like CFLAGS and LIBS can also
7# be modified from here. In most cass, these lines should use += in order not
8# to override previous values of the variables.
9
10CFLAGS = $(TARGET_CFLAGS) -I../hostapd -I../utils -I../driver/modules -Wall -MMD
11
12# for wpa_supplicant, wpa_cli
13LIBS = $(TARGET_LDFLAGS)
14
15# for wpa_passphrase:
16LIBS_p = $(TARGET_LDFLAGS)
17
18
19# Uncomment following two lines and fix the paths if you have installed openssl
20# in non-default location
21#CFLAGS += -I/usr/local/openssl/include
22#LIBS += -L/usr/local/openssl/lib
23
24# Example configuration for various cross-compilation platforms
25
26#### sveasoft (e.g., for Linksys WRT54G) ######################################
27#CC=mipsel-uclibc-gcc
28#CC=/opt/brcm/hndtools-mipsel-uclibc/bin/mipsel-uclibc-gcc
29#CFLAGS += -Os
30#CPPFLAGS += -I../src/include -I../../src/router/openssl/include
31#LIBS += -L/opt/brcm/hndtools-mipsel-uclibc-0.9.19/lib -lssl
32###############################################################################
33
34#### openwrt (e.g., for Linksys WRT54G) #######################################
35#CC=mipsel-uclibc-gcc
36#CC=/opt/brcm/hndtools-mipsel-uclibc/bin/mipsel-uclibc-gcc
37#CFLAGS += -Os
38#CPPFLAGS=-I../src/include -I../openssl-0.9.7d/include \
39# -I../WRT54GS/release/src/include
40#LIBS = -lssl
41###############################################################################
42
43
44# Driver interface for Host AP driver
45CONFIG_DRIVER_HOSTAP=y
46
47# Driver interface for Agere driver
48#CONFIG_DRIVER_HERMES=y
49
50# Driver interface for madwifi driver
51CONFIG_DRIVER_MADWIFI=y
52# Change include directories to match with the local setup
53#CFLAGS += -I../madwifi/wpa
54
55# Driver interface for Prism54 driver
56CONFIG_DRIVER_PRISM54=y
57
58# Driver interface for ndiswrapper
59#CONFIG_DRIVER_NDISWRAPPER=y
60
61# Driver interface for Atmel driver
62#CONFIG_DRIVER_ATMEL=y
63
64# Driver interface for Broadcom driver
65#CONFIG_DRIVER_BROADCOM=y
66# Example path for wlioctl.h; change to match your configuration
67#CFLAGS += -I/opt/WRT54GS/release/src/include
68
69# Driver interface for Intel ipw2100 driver
70#CONFIG_DRIVER_IPW2100=y
71
72# Driver interface for generic Linux wireless extensions
73CONFIG_DRIVER_WEXT=y
74
75# Driver interface for FreeBSD net80211 layer (e.g., Atheros driver)
76#CONFIG_DRIVER_BSD=y
77#CFLAGS += -I/usr/local/include
78#LIBS += -L/usr/local/lib
79
80# Driver interface for Windows NDIS
81#CONFIG_DRIVER_NDIS=y
82#CFLAGS += -I/usr/include/w32api/ddk
83#LIBS += -L/usr/local/lib
84# For native build using mingw
85#CONFIG_NATIVE_WINDOWS=y
86# Additional directories for cross-compilation on Linux host for mingw target
87#CFLAGS += -I/opt/mingw/mingw32/include/ddk
88#LIBS += -L/opt/mingw/mingw32/lib
89#CC=mingw32-gcc
90
91# Driver interface for development testing
92#CONFIG_DRIVER_TEST=y
93
94# Enable IEEE 802.1X Supplicant (automatically included if any EAP method is
95# included)
96CONFIG_IEEE8021X_EAPOL=y
97
98# EAP-MD5 (automatically included if EAP-TTLS is enabled)
99CONFIG_EAP_MD5=y
100
101# EAP-MSCHAPv2 (automatically included if EAP-PEAP is enabled)
102CONFIG_EAP_MSCHAPV2=y
103
104# EAP-TLS
105CONFIG_EAP_TLS=y
106
107# EAL-PEAP
108CONFIG_EAP_PEAP=y
109
110# EAP-TTLS
111CONFIG_EAP_TTLS=y
112
113# EAP-GTC
114CONFIG_EAP_GTC=y
115
116# EAP-OTP
117CONFIG_EAP_OTP=y
118
119# EAP-SIM (enable CONFIG_PCSC, if EAP-SIM is used)
120#CONFIG_EAP_SIM=y
121
122# EAP-PSK (experimental; this is _not_ needed for WPA-PSK)
123#CONFIG_EAP_PSK=y
124
125# LEAP
126CONFIG_EAP_LEAP=y
127
128# EAP-AKA (enable CONFIG_PCSC, if EAP-AKA is used)
129#CONFIG_EAP_AKA=y
130
131# PKCS#12 (PFX) support (used to read private key and certificate file from
132# a file that usually has extension .p12 or .pfx)
133CONFIG_PKCS12=y
134
135# PC/SC interface for smartcards (USIM, GSM SIM)
136# Enable this if EAP-SIM or EAP-AKA is included
137#CONFIG_PCSC=y
138
139# Development testing
140#CONFIG_EAPOL_TEST=y
141
142# Replace native Linux implementation of packet sockets with libdnet/libpcap.
143# This will be automatically set for non-Linux OS.
144#CONFIG_DNET_PCAP=y
145
146# Include control interface for external programs, e.g, wpa_cli
147CONFIG_CTRL_IFACE=y
148
149# Include interface for using external supplicant (Xsupplicant) for EAP
150# authentication
151#CONFIG_XSUPPLICANT_IFACE=y
152
153# Include support for GNU Readline and History Libraries in wpa_cli.
154# When building a wpa_cli binary for distribution, please note that these
155# libraries are licensed under GPL and as such, BSD license may not apply for
156# the resulting binary.
157#CONFIG_READLINE=y
diff --git a/meta/packages/wpa-supplicant/files/openmn/defaults b/meta/packages/wpa-supplicant/files/openmn/defaults
deleted file mode 100644
index 1da73d30c0..0000000000
--- a/meta/packages/wpa-supplicant/files/openmn/defaults
+++ /dev/null
@@ -1,8 +0,0 @@
1# Useful flags:
2# -i <ifname> Interface (required, unless specified in config)
3# -D <driver> Wireless Driver
4# -d Debugging (-dd for more)
5# -q Quiet (-qq for more)
6
7CONFIG="/etc/wpa_supplicant.conf"
8OPTIONS="-i eth1 -D hermes"
diff --git a/meta/packages/wpa-supplicant/files/slugos/defaults-sane b/meta/packages/wpa-supplicant/files/slugos/defaults-sane
deleted file mode 100644
index df4268b3a6..0000000000
--- a/meta/packages/wpa-supplicant/files/slugos/defaults-sane
+++ /dev/null
@@ -1,8 +0,0 @@
1# Useful flags:
2# -i <ifname> Interface (required, unless specified in config)
3# -D <driver> Wireless Driver
4# -d Debugging (-dd for more)
5# -q Quiet (-qq for more)
6
7CONFIG="/etc/wpa_supplicant.conf"
8OPTIONS="-i ath0 -D madwifi"
diff --git a/meta/packages/wpa-supplicant/files/use-channel.patch b/meta/packages/wpa-supplicant/files/use-channel.patch
deleted file mode 100644
index 337c0422cd..0000000000
--- a/meta/packages/wpa-supplicant/files/use-channel.patch
+++ /dev/null
@@ -1,32 +0,0 @@
1
2#
3# Patch managed by http://www.holgerschurig.de/patcher.html
4#
5
6--- wpa_supplicant/driver_wext.c~use-channel
7+++ wpa_supplicant/driver_wext.c
8@@ -655,6 +655,12 @@
9 }
10
11
12+static const long frequency_list[] =
13+{
14+ 2412, 2417, 2422, 2427, 2432, 2437, 2442,
15+ 2447, 2452, 2457, 2462, 2467, 2472, 2484
16+};
17+
18 int wpa_driver_wext_get_scan_results(void *priv,
19 struct wpa_scan_result *results,
20 size_t max_size)
21@@ -739,6 +745,11 @@
22 case SIOCGIWFREQ:
23 if (ap_num < max_size) {
24 int div = 1000000, i;
25+ /* driver sent a channel, not a frequency */
26+ if (iwe->u.freq.e == 0 && iwe->u.freq.m >= 1 && iwe->u.freq.m <= sizeof(frequency_list)) {
27+ results[ap_num].freq = frequency_list[iwe->u.freq.m-1];
28+ break;
29+ } else
30 if (iwe->u.freq.e > 6) {
31 wpa_printf(
32 MSG_DEBUG, "Invalid freq "
diff --git a/meta/packages/wpa-supplicant/wpa-supplicant/gnutlsfix.patch b/meta/packages/wpa-supplicant/wpa-supplicant/gnutlsfix.patch
deleted file mode 100644
index 795306bb35..0000000000
--- a/meta/packages/wpa-supplicant/wpa-supplicant/gnutlsfix.patch
+++ /dev/null
@@ -1,19 +0,0 @@
1Index: wpa_supplicant-0.5.5/tls_gnutls.c
2===================================================================
3--- wpa_supplicant-0.5.5.orig/tls_gnutls.c 2006-06-25 03:05:07.000000000 +0200
4+++ wpa_supplicant-0.5.5/tls_gnutls.c 2006-10-29 15:12:21.000000000 +0100
5@@ -1029,8 +1029,13 @@
6 const u8 *in_data, size_t in_len,
7 size_t *out_len)
8 {
9+ u8 *appl_data;
10+ size_t appl_data_len;
11+
12+ appl_data = NULL;
13+
14 return tls_connection_handshake(ssl_ctx, conn, in_data, in_len,
15- out_len);
16+ out_len, appl_data, appl_data_len);
17 }
18
19
diff --git a/meta/packages/wpa-supplicant/wpa-supplicant_0.5.7.bb b/meta/packages/wpa-supplicant/wpa-supplicant_0.5.7.bb
deleted file mode 100644
index e985c6af21..0000000000
--- a/meta/packages/wpa-supplicant/wpa-supplicant_0.5.7.bb
+++ /dev/null
@@ -1,3 +0,0 @@
1require wpa-supplicant-0.5.inc
2
3SRC_URI += " file://gnutlsfix.patch;patch=1 "