blob: b0fba34c319d5b29bd28953b57c3ff97cbfda7c3 [file] [log] [blame]
developer685162e2021-12-09 09:55:13 +08001diff --git a/package/network/services/hostapd/patches/902-2021-print-sae-groups-by-hostapd-ctrl.patch b/package/network/services/hostapd/patches/902-2021-print-sae-groups-by-hostapd-ctrl.patch
developerac8397b2021-11-25 15:14:03 +08002new file mode 100644
developer645ffdc2021-12-01 18:05:59 +08003index 0000000..859fdbf
developerac8397b2021-11-25 15:14:03 +08004--- /dev/null
developer685162e2021-12-09 09:55:13 +08005+++ b/package/network/services/hostapd/patches/902-2021-print-sae-groups-by-hostapd-ctrl.patch
developer645ffdc2021-12-01 18:05:59 +08006@@ -0,0 +1,22 @@
developerac8397b2021-11-25 15:14:03 +08007+--- a/hostapd/ctrl_iface.c
8++++ b/hostapd/ctrl_iface.c
developer645ffdc2021-12-01 18:05:59 +08009+@@ -1584,6 +1584,19 @@ static int hostapd_ctrl_iface_get(struct
10+ if (os_snprintf_error(buflen, res))
11+ return -1;
12+ return res;
13++ } else if (os_strcmp(cmd, "sae_group_capability") == 0) {
14++#ifdef CONFIG_SAE
15++ /* see sae_set_group() */
16++ res = os_snprintf(buf, buflen, "%s%s%s%s19 20 21",
17++ dh_groups_get(15) ? "15 ": "",
18++ dh_groups_get(16) ? "16 ": "",
19++ dh_groups_get(17) ? "17 ": "",
20++ dh_groups_get(18) ? "18 ": "");
21++
22++ if (os_snprintf_error(buflen, res))
23++ return -1;
24++ return res;
25++#endif /* CONFIG_SAE */
developerac8397b2021-11-25 15:14:03 +080026+ }
27+
developer645ffdc2021-12-01 18:05:59 +080028+ return -1;