]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
nl80211: Allow NAN management interface MAC address to be set
authorAndrei Otcheretianski <andrei.otcheretianski@intel.com>
Tue, 23 Dec 2025 11:46:07 +0000 (13:46 +0200)
committerJouni Malinen <j@w1.fi>
Thu, 29 Jan 2026 10:31:55 +0000 (12:31 +0200)
Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
src/drivers/driver_nl80211.c

index ce139e9f3af72271a96a8a58387e6c1c21f7bd27..627438bcb8fdcb937239115a94babb3c90669519 100644 (file)
@@ -6529,7 +6529,8 @@ static int nl80211_create_iface_once(struct wpa_driver_nl80211_data *drv,
        if (nla_put_flag(msg, NL80211_ATTR_IFACE_SOCKET_OWNER))
                goto fail;
 
-       if ((addr && iftype == NL80211_IFTYPE_P2P_DEVICE) &&
+       if ((addr && (iftype == NL80211_IFTYPE_P2P_DEVICE ||
+                     iftype == NL80211_IFTYPE_NAN)) &&
            nla_put(msg, NL80211_ATTR_MAC, ETH_ALEN, addr))
                goto fail;