aboutsummaryrefslogtreecommitdiffstats
path: root/net/wireless/nl80211.c
diff options
context:
space:
mode:
authorJouni Malinen <jouni.malinen@atheros.com>2009-05-11 14:57:58 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-05-13 15:44:39 -0400
commitfaa8fdc85347cc76d87b43ea718785661c54f656 (patch)
treed6a2bad74310885e8f0836791c93070d243b6b2c /net/wireless/nl80211.c
parent3f77316c6b99f596bfbf72c0542f47f7230b702e (diff)
nl80211: Add RSC configuration for new keys
When setting a key with NL80211_CMD_NEW_KEY, we should allow the key sequence number (RSC) to be set in order to allow replay protection to work correctly for group keys. This patch documents this use for nl80211 and adds the couple of missing pieces in nl80211/cfg80211 and mac80211 to support this. In addition, WEXT SIOCSIWENCODEEXT compat processing in cfg80211 is extended to handle the RSC (this was already specified in WEXT, but just not implemented in cfg80211/mac80211). Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'net/wireless/nl80211.c')
-rw-r--r--net/wireless/nl80211.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index cad281390cfa..f0fec2f49828 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -1115,6 +1115,11 @@ static int nl80211_new_key(struct sk_buff *skb, struct genl_info *info)
1115 params.key_len = nla_len(info->attrs[NL80211_ATTR_KEY_DATA]); 1115 params.key_len = nla_len(info->attrs[NL80211_ATTR_KEY_DATA]);
1116 } 1116 }
1117 1117
1118 if (info->attrs[NL80211_ATTR_KEY_SEQ]) {
1119 params.seq = nla_data(info->attrs[NL80211_ATTR_KEY_SEQ]);
1120 params.seq_len = nla_len(info->attrs[NL80211_ATTR_KEY_SEQ]);
1121 }
1122
1118 if (info->attrs[NL80211_ATTR_KEY_IDX]) 1123 if (info->attrs[NL80211_ATTR_KEY_IDX])
1119 key_idx = nla_get_u8(info->attrs[NL80211_ATTR_KEY_IDX]); 1124 key_idx = nla_get_u8(info->attrs[NL80211_ATTR_KEY_IDX]);
1120 1125