Skip to content

Commit

Permalink
wifi: cfg80211: Partial revert "wifi: cfg80211: Fix use after free fo…
Browse files Browse the repository at this point in the history
…r wext"

commit 79d1ed5 upstream.

This reverts part of commit 015b8cc ("wifi: cfg80211: Fix use after
free for wext")

This commit broke WPA offload by unconditionally clearing the crypto
modes for non-WEP connections. Drop that part of the patch.

Signed-off-by: Hector Martin <marcan@marcan.st>
Reported-by: Ilya <me@0upti.me>
Reported-and-tested-by: Janne Grunau <j@jannau.net>
Reviewed-by: Eric Curtin <ecurtin@redhat.com>
Fixes: 015b8cc ("wifi: cfg80211: Fix use after free for wext")
Cc: stable@kernel.org
Link: https://lore.kernel.org/linux-wireless/ZAx0TWRBlGfv7pNl@kroah.com/T/#m11e6e0915ab8fa19ce8bc9695ab288c0fe018edf
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
marcan authored and gregkh committed Mar 13, 2023
1 parent e143354 commit 4a48cd8
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions net/wireless/sme.c
Expand Up @@ -1504,8 +1504,6 @@ int cfg80211_connect(struct cfg80211_registered_device *rdev,
connect->key = NULL;
connect->key_len = 0;
connect->key_idx = 0;
connect->crypto.cipher_group = 0;
connect->crypto.n_ciphers_pairwise = 0;
}

wdev->connect_keys = connkeys;
Expand Down

0 comments on commit 4a48cd8

Please sign in to comment.