提交 45cbad6a 编写于 作者: J Juuso Oikarinen 提交者: John W. Linville

cfg80211: Allow non-zero indexes for device specific pair-wise ciphers

Some vendor specific cipher suites require non-zero key indexes for pairwise
keys, but as of currently, the cfg80211 does not allow it.

As validating they cipher parameters for vendor specific cipher suites is the
job of the driver or hardware/firmware, change the cfg80211 to allow also
non-zero pairwise key indexes for vendor specific ciphers.
Signed-off-by: NJuuso Oikarinen <juuso.oikarinen@nokia.com>
Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
上级 53e3b6e2
......@@ -167,12 +167,15 @@ int cfg80211_validate_key_settings(struct cfg80211_registered_device *rdev,
/*
* Disallow pairwise keys with non-zero index unless it's WEP
* (because current deployments use pairwise WEP keys with
* non-zero indizes but 802.11i clearly specifies to use zero)
* or a vendor specific cipher (because current deployments use
* pairwise WEP keys with non-zero indices and for vendor specific
* ciphers this should be validated in the driver or hardware level
* - but 802.11i clearly specifies to use zero)
*/
if (pairwise && key_idx &&
params->cipher != WLAN_CIPHER_SUITE_WEP40 &&
params->cipher != WLAN_CIPHER_SUITE_WEP104)
((params->cipher == WLAN_CIPHER_SUITE_TKIP) ||
(params->cipher == WLAN_CIPHER_SUITE_CCMP) ||
(params->cipher == WLAN_CIPHER_SUITE_AES_CMAC)))
return -EINVAL;
switch (params->cipher) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册