hostapd: add support for setting sae_pwe
authorMichael Yartys <michael.yartys@protonmail.com>
Wed, 2 Jun 2021 17:48:43 +0000 (19:48 +0200)
committerPaul Spooren <mail@aparcar.org>
Mon, 21 Jun 2021 01:42:52 +0000 (15:42 -1000)
Make it possible to specify the SAE mechanism for PWE derivation. The
following values are possible:

0 = hunting-and-pecking loop only
1 = hash-to-element only
2 = both hunting-and-pecking loop and hash-to-element enabled

hostapd currently defaults to hunting-and-pecking loop only.

Signed-off-by: Michael Yartys <michael.yartys@protonmail.com>
package/network/services/hostapd/files/hostapd.sh

index cf85019d564667a140761d7726c75e4cdd5cde2d..8a6c904c58018726d93304a8c0ca2ee0cef8efe5 100644 (file)
@@ -319,6 +319,7 @@ hostapd_common_add_bss_config() {
        config_add_array supported_rates
 
        config_add_boolean sae_require_mfp
+       config_add_int sae_pwe
 
        config_add_string 'owe_transition_bssid:macaddr' 'owe_transition_ssid:string'
 
@@ -520,7 +521,7 @@ hostapd_set_bss_options() {
                macfilter ssid utf8_ssid wmm uapsd hidden short_preamble rsn_preauth \
                iapp_interface eapol_version dynamic_vlan ieee80211w nasid \
                acct_server acct_secret acct_port acct_interval \
-               bss_load_update_period chan_util_avg_period sae_require_mfp \
+               bss_load_update_period chan_util_avg_period sae_require_mfp sae_pwe \
                multi_ap multi_ap_backhaul_ssid multi_ap_backhaul_key skip_inactivity_poll \
                airtime_bss_weight airtime_bss_limit airtime_sta_weight \
                multicast_to_unicast proxy_arp per_sta_vif \
@@ -604,6 +605,7 @@ hostapd_set_bss_options() {
                ;;
        esac
        [ -n "$sae_require_mfp" ] && append bss_conf "sae_require_mfp=$sae_require_mfp" "$N"
+       [ -n "$sae_pwe" ] && append bss_conf "sae_pwe=$sae_pwe" "$N"
 
        local vlan_possible=""