]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
nl80211: Fix possible Spectre-v1 for CQM RSSI thresholds
authorMasashi Honma <masashi.honma@gmail.com>
Tue, 25 Sep 2018 02:15:01 +0000 (11:15 +0900)
committerStefan Bader <stefan.bader@canonical.com>
Wed, 24 Apr 2019 08:09:09 +0000 (10:09 +0200)
commit45c6bc6c423e7e50bb44c244236d1de8778e04f5
treef6c534b7cd831323a4653d788145abef99f4e64c
parent434a30a6b6b5bb19746105fcf68c525e969cac87
nl80211: Fix possible Spectre-v1 for CQM RSSI thresholds

Use array_index_nospec() to sanitize i with respect to speculation.

Note that the user doesn't control i directly, but can make it out
of bounds by not finding a threshold in the array.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
[add note about user control, as explained by Masashi]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
CVE-2017-5753

(cherry picked from commit 1222a16014888ed9733c11e221730d4a8196222b)
Signed-off-by: Juerg Haefliger <juergh@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
net/wireless/nl80211.c