wifi: nl80211: strict checking attributes for NL80211_CMD_SET_BSS

Assure user-space only modifies attributes for NL80211_CMD_SET_BSS
that are supported by the driver. This stricter checking is only done
when user-space commits to it by including NL80211_ATTR_BSS_PARAM.

Signed-off-by: Arend van Spriel <arend.vanspriel@broadcom.com>
Link: https://patch.msgid.link/20250817190435.1495094-4-arend.vanspriel@broadcom.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
Arend van Spriel
2025-09-04 11:19:02 +02:00
committed by Johannes Berg
parent 18abf7a05f
commit 4f652a390d
2 changed files with 49 additions and 8 deletions
+4 -1
View File
@@ -2931,7 +2931,10 @@ enum nl80211_commands {
* @enum nl80211_s1g_short_beacon_attrs for the attribute definitions.
*
* @NL80211_ATTR_BSS_PARAM: nested attribute used with %NL80211_CMD_GET_WIPHY
* which indicates which BSS parameters can be modified.
* which indicates which BSS parameters can be modified. The attribute can
* also be used as flag attribute by user-space in %NL80211_CMD_SET_BSS to
* indicate that it wants strict checking on the BSS parameters to be
* modified.
*
* @NUM_NL80211_ATTR: total number of nl80211_attrs available
* @NL80211_ATTR_MAX: highest attribute number currently defined