eiwd

no dbus iwd with iwctl functionality
git clone https://git.daat.foo/repos/eiwd.git
Log | Files | Refs | Submodules | README | LICENSE

commit 958bd1262442cd7d5595fd24a1eafe8f73933df1
parent 397bf9c0bd92bc573af46e8c606f7d20e13f4196
Author: Tim Kourt <tim.a.kourt@linux.intel.com>
Date:   Thu,  6 Sep 2018 15:04:16 -0700

peap: accept EAP type 33 as termination mechanism for PEAPv1

EAP Extensions type 33 is used in PEAPv0 as a termination
mechanism for the tunneled EAP methods. In PEAPv1
the regular EAP-Success/Failure packets must be used to terminate
the method. Some of the server implementations of PEAPv1
rely on EAP Extensions method to terminate the conversation
instead of the required Success/Failure packets. This patch
makes iwd interoperable with such devices.

Diffstat:
Msrc/eap-peap.c | 33++++++++++++++++-----------------
1 file changed, 16 insertions(+), 17 deletions(-)

diff --git a/src/eap-peap.c b/src/eap-peap.c @@ -361,30 +361,29 @@ static void eap_peap_phase2_handle_request(struct eap_state *eap, size_t len) { struct eap_peap_state *peap = eap_get_data(eap); + uint8_t id; - if (peap->version == PEAP_VERSION_0) { - uint8_t id; - - if (len > 4 && pkt[4] == EAP_TYPE_EXTENSIONS) { - uint16_t pkt_len; - uint8_t code = pkt[0]; + if (len > 4 && pkt[4] == EAP_TYPE_EXTENSIONS) { + uint16_t pkt_len; + uint8_t code = pkt[0]; - if (code != EAP_CODE_REQUEST) - return; + if (code != EAP_CODE_REQUEST) + return; - pkt_len = l_get_be16(pkt + 2); - if (pkt_len != len) - return; + pkt_len = l_get_be16(pkt + 2); + if (pkt_len != len) + return; - id = pkt[1]; + id = pkt[1]; - eap_extensions_handle_request(eap, id, - pkt + EAP_EXTENSIONS_HEADER_LEN, - len - EAP_EXTENSIONS_HEADER_LEN); + eap_extensions_handle_request(eap, id, + pkt + EAP_EXTENSIONS_HEADER_LEN, + len - EAP_EXTENSIONS_HEADER_LEN); - return; - } + return; + } + if (peap->version == PEAP_VERSION_0) { if (len < 1) return;