History

cfg80211: support 4-way handshake offloading for 802.1X

Add API for setting the PMK to the driver. For FT support, allow setting also the PMK-R0 Name. This can be used by drivers that support 4-Way handshake offload while IEEE802.1X authentication is managed by upper layers.

Avraham Stern committed 9 years ago

Commit 3a00df51 parent 91b5ab67 files · +268 −1Browse files

Showing the changes to include/uapi/linux (1 of 7 files). Show all

Unified · Split

include/uapi/linux/nl80211.h+38−1
@@ -182,6 +182,17 @@ · 181 unmodified lines
182182 * this offload may reject the %NL80211_CMD_CONNECT when no preshared
183183 * key material is provided, for example when that driver does not
184184 * support setting the temporal keys through %CMD_NEW_KEY.
185+ *
186+ * Similarly @NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X flag can be
187+ * set by drivers indicating offload support of the PTK/GTK EAPOL
188+ * handshakes during 802.1X authentication. In order to use the offload
189+ * the %NL80211_CMD_CONNECT should have %NL80211_ATTR_WANT_1X_4WAY_HS
190+ * attribute flag. Drivers supporting this offload may reject the
191+ * %NL80211_CMD_CONNECT when the attribute flag is not present.
192+ *
193+ * For 802.1X the PMK or PMK-R0 are set by providing %NL80211_ATTR_PMK
194+ * using %NL80211_CMD_SET_PMK. For offloaded FT support also
195+ * %NL80211_ATTR_PMKR0_NAME must be provided.
185196 */
186197
187198 /**
@@ -959,6 +970,14 @@ · 771 unmodified lines
959970 * does not result in a change for the current association. Currently,
960971 * only the %NL80211_ATTR_IE data is used and updated with this command.
961972 *
973+ * @NL80211_CMD_SET_PMK: For offloaded 4-Way handshake, set the PMK or PMK-R0
974+ * for the given authenticator address (specified with &NL80211_ATTR_MAC).
975+ * When &NL80211_ATTR_PMKR0_NAME is set, &NL80211_ATTR_PMK specifies the
976+ * PMK-R0, otherwise it specifies the PMK.
977+ * @NL80211_CMD_DEL_PMK: For offloaded 4-Way handshake, delete the previously
978+ * configured PMK for the authenticator address identified by
979+ * &NL80211_ATTR_MAC.
980+ *
962981 * @NL80211_CMD_MAX: highest used command number
963982 * @__NL80211_CMD_AFTER_LAST: internal use
964983 */
@@ -1158,6 +1177,9 @@ enum nl80211_commands { · 193 unmodified lines
11581177
11591178 NL80211_CMD_UPDATE_CONNECT_PARAMS,
11601179
1180+ NL80211_CMD_SET_PMK,
1181+ NL80211_CMD_DEL_PMK,
1182+
11611183 /* add new commands above here */
11621184
11631185 /* used to define NL80211_CMD_MAX below */
@@ -2095,13 +2117,20 @@ enum nl80211_commands { · 931 unmodified lines
20952117 * @NL80211_ATTR_PMK: attribute for passing PMK key material. Used with
20962118 * %NL80211_CMD_SET_PMKSA for the PMKSA identified by %NL80211_ATTR_PMKID.
20972119 * For %NL80211_CMD_CONNECT it is used to provide PSK for offloading 4-way
2098− * handshake for WPA/WPA2-PSK networks.
2120+ * handshake for WPA/WPA2-PSK networks. For 802.1X authentication it is
2121+ * used with %NL80211_CMD_SET_PMK. For offloaded FT support this attribute
2122+ * specifies the PMK-R0 if NL80211_ATTR_PMKR0_NAME is included as well.
20992123 *
21002124 * @NL80211_ATTR_SCHED_SCAN_MULTI: flag attribute which user-space shall use to
21012125 * indicate that it supports multiple active scheduled scan requests.
21022126 * @NL80211_ATTR_SCHED_SCAN_MAX_REQS: indicates maximum number of scheduled
21032127 * scan request that may be active for the device (u32).
21042128 *
2129+ * @NL80211_ATTR_WANT_1X_4WAY_HS: flag attribute which user-space can include
2130+ * in %NL80211_CMD_CONNECT to indicate that for 802.1X authentication it
2131+ * wants to use the supported offload of the 4-way handshake.
2132+ * @NL80211_ATTR_PMKR0_NAME: PMK-R0 Name for offloaded FT.
2133+ *
21052134 * @NUM_NL80211_ATTR: total number of nl80211_attrs available
21062135 * @NL80211_ATTR_MAX: highest attribute number currently defined
21072136 * @__NL80211_ATTR_AFTER_LAST: internal use
@@ -2524,6 +2553,9 @@ enum nl80211_attrs { · 416 unmodified lines
25242553 NL80211_ATTR_SCHED_SCAN_MULTI,
25252554 NL80211_ATTR_SCHED_SCAN_MAX_REQS,
25262555
2556+ NL80211_ATTR_WANT_1X_4WAY_HS,
2557+ NL80211_ATTR_PMKR0_NAME,
2558+
25272559 /* add attributes here, update the policy in nl80211.c */
25282560
25292561 __NL80211_ATTR_AFTER_LAST,
@@ -4869,6 +4901,10 @@ enum nl80211_feature_flags { · 2339 unmodified lines
48694901 * @NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_PSK: Device wants to do 4-way
48704902 * handshake with PSK in station mode (PSK is passed as part of the connect
48714903 * and associate commands), doing it in the host might not be supported.
4904+ * @NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X: Device wants to do doing 4-way
4905+ * handshake with 802.1X in station mode (will pass EAP frames to the host
4906+ * and accept the set_pmk/del_pmk commands), doing it in the host might not
4907+ * be supported.
48724908 *
48734909 * @NUM_NL80211_EXT_FEATURES: number of extended features.
48744910 * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
@@ -4890,6 +4926,7 @@ enum nl80211_ext_feature_index { · 15 unmodified lines
48904926 NL80211_EXT_FEATURE_CQM_RSSI_LIST,
48914927 NL80211_EXT_FEATURE_FILS_SK_OFFLOAD,
48924928 NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_PSK,
4929+ NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X,
48934930
48944931 /* add new features before the definition below */
48954932 NUM_NL80211_EXT_FEATURES,

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t