6b34cd4350b273973152e8b2e03d2bc5fd30169e
[openwrt/staging/blogic.git] /
1 From: Felix Fietkau <nbd@nbd.name>
2 Date: Mon, 18 Feb 2019 12:57:11 +0100
3 Subject: [PATCH] mesh: allow processing authentication frames in blocked state
4
5 If authentication fails repeatedly e.g. because of a weak signal, the link
6 can end up in blocked state. If one of the nodes tries to establish a link
7 again before it is unblocked on the other side, it will block the link to
8 that other side. The same happens on the other side when it unblocks the
9 link. In that scenario, the link never recovers on its own.
10
11 To fix this, allow restarting authentication even if the link is in blocked
12 state, but don't initiate the attempt until the blocked period is over.
13
14 Signed-off-by: Felix Fietkau <nbd@nbd.name>
15 ---
16
17 --- a/src/ap/ieee802_11.c
18 +++ b/src/ap/ieee802_11.c
19 @@ -3781,15 +3781,6 @@ static void handle_auth(struct hostapd_d
20 seq_ctrl);
21 return;
22 }
23 -#ifdef CONFIG_MESH
24 - if ((hapd->conf->mesh & MESH_ENABLED) &&
25 - sta->plink_state == PLINK_BLOCKED) {
26 - wpa_printf(MSG_DEBUG, "Mesh peer " MACSTR
27 - " is blocked - drop Authentication frame",
28 - MAC2STR(mgmt->sa));
29 - return;
30 - }
31 -#endif /* CONFIG_MESH */
32 #ifdef CONFIG_PASN
33 if (auth_alg == WLAN_AUTH_PASN &&
34 (sta->flags & WLAN_STA_ASSOC)) {