Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 214013
b: refs/heads/master
c: afea0b7
h: refs/heads/master
i:
  214011: 807518b
v: v3
  • Loading branch information
Johannes Berg authored and John W. Linville committed Aug 16, 2010
1 parent 9792b54 commit a2e5376
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5daa8a8e691e28c6c725e7e91319b160b555c615
refs/heads/master: afea0b7af7a0c070da8b2029d721abc930e5f96f
15 changes: 15 additions & 0 deletions trunk/net/wireless/nl80211.c
Original file line number Diff line number Diff line change
Expand Up @@ -3572,6 +3572,21 @@ static int nl80211_authenticate(struct sk_buff *skb, struct genl_info *info)
if (err)
goto unlock_rtnl;

if (key.idx >= 0) {
int i;
bool ok = false;
for (i = 0; i < rdev->wiphy.n_cipher_suites; i++) {
if (key.p.cipher == rdev->wiphy.cipher_suites[i]) {
ok = true;
break;
}
}
if (!ok) {
err = -EINVAL;
goto out;
}
}

if (!rdev->ops->auth) {
err = -EOPNOTSUPP;
goto out;
Expand Down

0 comments on commit a2e5376

Please sign in to comment.