summaryrefslogtreecommitdiff
path: root/pkg/hostap
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2020-10-07 12:35:53 -0700
committerMichael Forney <mforney@mforney.org>2020-10-07 13:53:01 -0700
commitd05d6928e329f5da64bf21989e783f310dc7a624 (patch)
tree742b8607638db81dec1f9e66002135ec93c700d6 /pkg/hostap
parent69b04f3be77e25e10f1e11b15d862d0cbe707c4d (diff)
wpa_supplicant: Rename from hostap and build from release tar
The release tar contains pregenerated manuals, so we don't need docbook2man.
Diffstat (limited to 'pkg/hostap')
-rw-r--r--pkg/hostap/config.h16
-rw-r--r--pkg/hostap/gen.lua98
-rw-r--r--pkg/hostap/patch/0001-eloop-Prevent-stray-semicolons-in-struct-specifier.patch52
-rw-r--r--pkg/hostap/patch/0002-Avoid-statement-expressions-for-get_aligned_le.patch47
-rw-r--r--pkg/hostap/patch/0003-Avoid-unnecessary-VLA.patch25
-rw-r--r--pkg/hostap/patch/0004-Prevent-reference-to-undefined-symbol-with-CONFIG_NO.patch33
-rw-r--r--pkg/hostap/patch/0005-Add-support-for-some-BearSSL-crypo-primitives.patch98
m---------pkg/hostap/src0
-rw-r--r--pkg/hostap/ver1
9 files changed, 0 insertions, 370 deletions
diff --git a/pkg/hostap/config.h b/pkg/hostap/config.h
deleted file mode 100644
index f56a77d5..00000000
--- a/pkg/hostap/config.h
+++ /dev/null
@@ -1,16 +0,0 @@
-#define CONFIG_BACKEND_FILE
-#define CONFIG_CTRL_IFACE
-#define CONFIG_CTRL_IFACE_DIR "/run/wpa_supplicant"
-#define CONFIG_CTRL_IFACE_UNIX
-#define CONFIG_DRIVER_NL80211
-#define CONFIG_ELOOP_POLL
-#define CONFIG_GETRANDOM
-#define CONFIG_IBSS_RSN
-#define CONFIG_LIBNL20
-#define CONFIG_NO_CONFIG_BLOBS
-#define CONFIG_NO_CONFIG_WRITE
-#define CONFIG_NO_RADIUS
-#define CONFIG_NO_VLAN
-#define CONFIG_SHA256
-#define CONFIG_SME
-#define TLS_DEFAULT_CIPHERS "DEFAULT:!EXP:!LOW"
diff --git a/pkg/hostap/gen.lua b/pkg/hostap/gen.lua
deleted file mode 100644
index eb2568cd..00000000
--- a/pkg/hostap/gen.lua
+++ /dev/null
@@ -1,98 +0,0 @@
-cflags{
- '-include $dir/config.h',
- '-I $srcdir/src/utils',
- '-I $srcdir/src',
- '-isystem $builddir/pkg/bearssl/include',
- '-isystem $builddir/pkg/libnl/include',
- '-isystem $builddir/pkg/linux-headers/include',
-}
-
-pkg.deps = {
- 'pkg/bearssl/headers',
- 'pkg/libnl/headers',
- 'pkg/linux-headers/headers',
-}
-
-lib('libcommon.a', 'src/utils/(common.c eloop.c os_unix.c wpabuf.c wpa_debug.c)')
-
-exe('bin/wpa_supplicant', [[
- src/ap/(
- wpa_auth.c
- wpa_auth_ie.c
- pmksa_cache_auth.c
- )
- src/common/(
- ctrl_iface_common.c
- hw_features_common.c
- ieee802_11_common.c
- wpa_common.c
- )
- src/crypto/(
- aes-internal-dec.c
- aes-internal-enc.c
- aes-internal.c
- aes-unwrap.c
- aes-wrap.c
- crypto_bearssl.c
- random.c
- rc4.c
- sha1-pbkdf2.c
- sha1-prf.c
- sha256-prf.c
- tls_none.c
- )
- src/drivers/(
- driver_common.c
- driver_nl80211.c
- driver_nl80211_capa.c
- driver_nl80211_event.c
- driver_nl80211_monitor.c
- driver_nl80211_scan.c
- drivers.c
- linux_ioctl.c
- netlink.c
- rfkill.c
- )
- src/l2_packet/l2_packet_linux.c
- src/rsn_supp/(
- pmksa_cache.c
- preauth.c
- wpa.c
- wpa_ie.c
- )
- src/utils/(bitfield.c radiotap.c)
- wpa_supplicant/(
- blacklist.c
- bss.c
- config.c
- config_file.c
- ctrl_iface.c
- ctrl_iface_unix.c
- eap_register.c
- events.c
- ibss_rsn.c
- main.c
- notify.c
- op_classes.c
- rrm.c
- scan.c
- sme.c
- wmm_ac.c
- wpa_supplicant.c
- wpas_glue.c
- )
- libcommon.a
- $builddir/pkg/bearssl/libbearssl.a
- $builddir/pkg/libnl/(libnl-3.a libnl-genl-3.a)
-]])
-file('bin/wpa_supplicant', '755', '$outdir/bin/wpa_supplicant')
-
-exe('bin/wpa_cli', [[
- src/common/(cli.c wpa_ctrl.c)
- src/utils/edit_simple.c
- wpa_supplicant/wpa_cli.c
- libcommon.a
-]])
-file('bin/wpa_cli', '755', '$outdir/bin/wpa_cli')
-
-fetch 'git'
diff --git a/pkg/hostap/patch/0001-eloop-Prevent-stray-semicolons-in-struct-specifier.patch b/pkg/hostap/patch/0001-eloop-Prevent-stray-semicolons-in-struct-specifier.patch
deleted file mode 100644
index a48d3194..00000000
--- a/pkg/hostap/patch/0001-eloop-Prevent-stray-semicolons-in-struct-specifier.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From f36da3297eeb6b2363bcede62a72f567cd971617 Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Sun, 11 Aug 2019 03:18:22 +0000
-Subject: [PATCH] eloop: Prevent stray semicolons in struct specifier
-
----
- src/utils/eloop.c | 8 ++++----
- src/utils/trace.h | 2 +-
- 2 files changed, 5 insertions(+), 5 deletions(-)
-
-diff --git a/src/utils/eloop.c b/src/utils/eloop.c
-index bb375be10..b82853308 100644
---- a/src/utils/eloop.c
-+++ b/src/utils/eloop.c
-@@ -44,8 +44,8 @@ struct eloop_sock {
- void *eloop_data;
- void *user_data;
- eloop_sock_handler handler;
-- WPA_TRACE_REF(eloop);
-- WPA_TRACE_REF(user);
-+ WPA_TRACE_REF(eloop)
-+ WPA_TRACE_REF(user)
- WPA_TRACE_INFO
- };
-
-@@ -55,8 +55,8 @@ struct eloop_timeout {
- void *eloop_data;
- void *user_data;
- eloop_timeout_handler handler;
-- WPA_TRACE_REF(eloop);
-- WPA_TRACE_REF(user);
-+ WPA_TRACE_REF(eloop)
-+ WPA_TRACE_REF(user)
- WPA_TRACE_INFO
- };
-
-diff --git a/src/utils/trace.h b/src/utils/trace.h
-index d1636de07..43bc03f1e 100644
---- a/src/utils/trace.h
-+++ b/src/utils/trace.h
-@@ -23,7 +23,7 @@ struct wpa_trace_ref {
- const void *addr;
- WPA_TRACE_INFO
- };
--#define WPA_TRACE_REF(name) struct wpa_trace_ref wpa_trace_ref_##name
-+#define WPA_TRACE_REF(name) struct wpa_trace_ref wpa_trace_ref_##name;
-
- #define wpa_trace_dump(title, ptr) \
- wpa_trace_dump_func((title), (ptr)->btrace, (ptr)->btrace_num)
---
-2.22.0
-
diff --git a/pkg/hostap/patch/0002-Avoid-statement-expressions-for-get_aligned_le.patch b/pkg/hostap/patch/0002-Avoid-statement-expressions-for-get_aligned_le.patch
deleted file mode 100644
index 73484e65..00000000
--- a/pkg/hostap/patch/0002-Avoid-statement-expressions-for-get_aligned_le.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 9698f90ccec779f7812a9aa550a6b77feefb52e3 Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Sun, 11 Aug 2019 03:41:23 +0000
-Subject: [PATCH] Avoid statement expressions for get_aligned_le*
-
----
- src/utils/platform.h | 24 ++++++++++++------------
- 1 file changed, 12 insertions(+), 12 deletions(-)
-
-diff --git a/src/utils/platform.h b/src/utils/platform.h
-index 813987eb6..1aa9dc069 100644
---- a/src/utils/platform.h
-+++ b/src/utils/platform.h
-@@ -4,18 +4,18 @@
- #include "includes.h"
- #include "common.h"
-
--#define le16_to_cpu le_to_host16
--#define le32_to_cpu le_to_host32
-+static inline u16 get_unaligned_le16(void *p)
-+{
-+ u16 v;
-+ memcpy(&v, p, sizeof(v));
-+ return le_to_host16(v);
-+}
-
--#define get_unaligned(p) \
--({ \
-- struct packed_dummy_struct { \
-- typeof(*(p)) __val; \
-- } __attribute__((packed)) *__ptr = (void *) (p); \
-- \
-- __ptr->__val; \
--})
--#define get_unaligned_le16(p) le16_to_cpu(get_unaligned((le16 *)(p)))
--#define get_unaligned_le32(p) le32_to_cpu(get_unaligned((le32 *)(p)))
-+static inline u32 get_unaligned_le32(void *p)
-+{
-+ u32 v;
-+ memcpy(&v, p, sizeof(v));
-+ return le_to_host32(v);
-+}
-
- #endif /* PLATFORM_H */
---
-2.22.0
-
diff --git a/pkg/hostap/patch/0003-Avoid-unnecessary-VLA.patch b/pkg/hostap/patch/0003-Avoid-unnecessary-VLA.patch
deleted file mode 100644
index 5c7e69c6..00000000
--- a/pkg/hostap/patch/0003-Avoid-unnecessary-VLA.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 936dcefafa77e985a9e8dd2b6f5ef96df16d4c03 Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Sun, 11 Aug 2019 03:44:24 +0000
-Subject: [PATCH] Avoid unnecessary VLA
-
----
- src/utils/os_unix.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/utils/os_unix.c b/src/utils/os_unix.c
-index 800c50772..447dae31b 100644
---- a/src/utils/os_unix.c
-+++ b/src/utils/os_unix.c
-@@ -801,7 +801,7 @@ int os_exec(const char *program, const char *arg, int wait_completion)
-
- if (pid == 0) {
- /* run the external command in the child process */
-- const int MAX_ARG = 30;
-+ enum { MAX_ARG = 30 };
- char *_program, *_arg, *pos;
- char *argv[MAX_ARG + 1];
- int i;
---
-2.22.0
-
diff --git a/pkg/hostap/patch/0004-Prevent-reference-to-undefined-symbol-with-CONFIG_NO.patch b/pkg/hostap/patch/0004-Prevent-reference-to-undefined-symbol-with-CONFIG_NO.patch
deleted file mode 100644
index b8235a57..00000000
--- a/pkg/hostap/patch/0004-Prevent-reference-to-undefined-symbol-with-CONFIG_NO.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 5fba603af060a3fd3f0436213527b4b2b74cbd0d Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Sun, 11 Aug 2019 04:00:13 +0000
-Subject: [PATCH] Prevent reference to undefined symbol with CONFIG_NO_RADIUS
-
----
- src/radius/radius.h | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/src/radius/radius.h b/src/radius/radius.h
-index 630c0f9d0..dd013c415 100644
---- a/src/radius/radius.h
-+++ b/src/radius/radius.h
-@@ -296,6 +296,7 @@ char * radius_msg_get_tunnel_password(struct radius_msg *msg, int *keylen,
- const u8 *secret, size_t secret_len,
- struct radius_msg *sent_msg, size_t n);
-
-+#ifndef CONFIG_NO_RADIUS
- static inline int radius_msg_add_attr_int32(struct radius_msg *msg, u8 type,
- u32 value)
- {
-@@ -315,6 +316,8 @@ static inline int radius_msg_get_attr_int32(struct radius_msg *msg, u8 type,
- *value = ntohl(val);
- return 0;
- }
-+#endif /* CONFIG_NO_RADIUS */
-+
- int radius_msg_get_attr_ptr(struct radius_msg *msg, u8 type, u8 **buf,
- size_t *len, const u8 *start);
- int radius_msg_count_attr(struct radius_msg *msg, u8 type, int min_len);
---
-2.22.0
-
diff --git a/pkg/hostap/patch/0005-Add-support-for-some-BearSSL-crypo-primitives.patch b/pkg/hostap/patch/0005-Add-support-for-some-BearSSL-crypo-primitives.patch
deleted file mode 100644
index 45ce07fc..00000000
--- a/pkg/hostap/patch/0005-Add-support-for-some-BearSSL-crypo-primitives.patch
+++ /dev/null
@@ -1,98 +0,0 @@
-From f7dc64ef991c146a491d0ed0a92d2a5890383143 Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Fri, 15 Nov 2019 20:19:37 -0800
-Subject: [PATCH] Add support for some BearSSL crypo primitives
-
----
- src/crypto/crypto_bearssl.c | 79 +++++++++++++++++++++++++++++++++++++
- 1 file changed, 79 insertions(+)
- create mode 100644 src/crypto/crypto_bearssl.c
-
-diff --git a/src/crypto/crypto_bearssl.c b/src/crypto/crypto_bearssl.c
-new file mode 100644
-index 000000000..bc29f9693
---- /dev/null
-+++ b/src/crypto/crypto_bearssl.c
-@@ -0,0 +1,79 @@
-+/*
-+ * Wrapper functions for BearSSL crypto
-+ * Copyright (c) 2019, Michael Forney <mforney@mforney.org>
-+ *
-+ * This software may be distributed under the terms of the BSD license.
-+ * See README for more details.
-+ */
-+
-+#include "includes.h"
-+#include <bearssl.h>
-+
-+#include "common.h"
-+#include "md5.h"
-+#include "crypto.h"
-+
-+int digest_vector(size_t num_elem, const u8 *addr[], const size_t *len, u8 *out,
-+ const br_hash_class *hash)
-+{
-+ br_hash_compat_context ctx;
-+ size_t i;
-+
-+ hash->init(&ctx.vtable);
-+ for (i = 0; i < num_elem; ++i)
-+ hash->update(&ctx.vtable, addr[i], len[i]);
-+ hash->out(&ctx.vtable, out);
-+
-+ return 0;
-+}
-+
-+int sha1_vector(size_t num_elem, const u8 *addr[], const size_t *len, u8 *out)
-+{
-+ return digest_vector(num_elem, addr, len, out, &br_sha1_vtable);
-+}
-+
-+int sha256_vector(size_t num_elem, const u8 *addr[], const size_t *len, u8 *out)
-+{
-+ return digest_vector(num_elem, addr, len, out, &br_sha256_vtable);
-+}
-+
-+static int hmac_vector(const u8 *key, size_t key_len, size_t num_elem,
-+ const u8 *addr[], const size_t *len, u8 *mac,
-+ const br_hash_class *type)
-+{
-+ br_hmac_key_context kc;
-+ br_hmac_context ctx;
-+ size_t i;
-+
-+ br_hmac_key_init(&kc, type, key, key_len);
-+ br_hmac_init(&ctx, &kc, 0);
-+ for (i = 0; i < num_elem; ++i)
-+ br_hmac_update(&ctx, addr[i], len[i]);
-+ br_hmac_out(&ctx, mac);
-+
-+ return 0;
-+}
-+
-+int hmac_sha256_vector(const u8 *key, size_t key_len, size_t num_elem,
-+ const u8 *addr[], const size_t *len, u8 *mac)
-+{
-+ return hmac_vector(key, key_len, num_elem, addr, len, mac, &br_sha256_vtable);
-+}
-+
-+int hmac_sha1_vector(const u8 *key, size_t key_len, size_t num_elem,
-+ const u8 *addr[], const size_t *len, u8 *mac)
-+{
-+ return hmac_vector(key, key_len, num_elem, addr, len, mac, &br_sha1_vtable);
-+}
-+
-+int hmac_sha1(const u8 *key, size_t key_len, const u8 *data, size_t data_len,
-+ u8 *mac)
-+{
-+ return hmac_sha1_vector(key, key_len, 1, &data, &data_len, mac);
-+}
-+
-+int hmac_md5(const u8 *key, size_t key_len, const u8 *data, size_t data_len,
-+ u8 *mac)
-+{
-+ return hmac_vector(key, key_len, 1, &data, &data_len, mac, &br_md5_vtable);
-+}
---
-2.24.0
-
diff --git a/pkg/hostap/src b/pkg/hostap/src
deleted file mode 160000
-Subproject ca8c2bd28ad53f431d6ee60ef754e98cfdb4c17
diff --git a/pkg/hostap/ver b/pkg/hostap/ver
deleted file mode 100644
index 91f8f83d..00000000
--- a/pkg/hostap/ver
+++ /dev/null
@@ -1 +0,0 @@
-2.9 r1