[PATCH 1/2] NAN: Add gtk_support configuration parameter
Jouni Malinen
j at w1.fi
Wed Dec 2 06:58:33 PST 2026
On Sun, Nov 08, 2026 at 11:19:42AM -0800, Arowa Suliman wrote:
> By default, wpa_supplicant advertises GTK/IGTK support in the NAN Cipher
> Suite Information attribute capabilities whenever the driver supports
> CCMP/GCMP-256 and BIP.
>
> However, some legacy NAN peers fail the 4-way handshake when GTK/IGTK
> support is advertised in the Cipher Suite Information capabilities
> without a configured group cipher suite, as they omit GTK/IGTK KDEs in
> M3/M4 while wpa_supplicant expects them to be present when both peers
> advertise GTK support.
>
> Add a 'NAN_SET gtk_support <0|1>' configuration parameter and
> nan_set_gtk_support() helper so GTK/IGTK capability advertisement can be
> disabled prior to starting NAN for interoperability with such peers.
> diff --git a/src/nan/nan.c b/src/nan/nan.c
> @@ -3728,6 +3728,36 @@ int nan_set_beacon_prot(struct nan_data *nan, bool enable)
> +/**
> + * nan_set_gtk_support - Enable or disable NAN GTK/IGTK/BIGTK support
> + * @nan: Pointer to NAN data structure
> + * @enable: true to advertise GTK/IGTK support, false to disable
That documentation is confusion as far as support for beacon protection
(BIGTK) is concerned..
> +int nan_set_gtk_support(struct nan_data *nan, bool enable)
> + if (enable)
> + gtk_supp = NAN_CS_INFO_CAPA_GTK_SUPP_NO_BIGTK;
> + else
> + gtk_supp = NAN_CS_INFO_CAPA_GTK_SUPP_NONE;
And the implementation seems to explicitly disable beacon protection in
all cases. That feels wrong. This new function should likely be merged
into the existing nan_set_beacon_prot() to cover all options (all group
keys disabled, only GTK and IGTK enabled, all GTK/IGTK/BIGTK eneabled).
Furthermore, the driver capability check should be done (like it is
already in nan_set_beacon_prot()) so that this function cannot enable
IGTK support without it actually being supported by the driver.
--
Jouni Malinen PGP id EFC895FA
More information about the Hostap
mailing list