]> git.ipfire.org Git - thirdparty/hostap.git/commit
nl80211: Request kernel to trim off payload of netlink requests from acks
authorJouni Malinen <jouni@codeaurora.org>
Tue, 5 Feb 2019 18:30:08 +0000 (20:30 +0200)
committerJouni Malinen <j@w1.fi>
Tue, 5 Feb 2019 21:34:30 +0000 (23:34 +0200)
commitb14e8ea1d212c29e66af874047b345fa5d5bc6ac
treead77af39f6805b4de0153bf8e0726306f0b385c8
parent789b48bb48b39fcbad780439211cf31dfb9975b1
nl80211: Request kernel to trim off payload of netlink requests from acks

We do not need such payload in the acknowledgment, so adding it uses
resources unnecessarily. Furthermore, the original request can include
key material (e.g., NL80211_ATTR_PMK). libnl does not explicitly clear
this received message buffer and it would be inconvenient for
wpa_supplicant/hostapd to try to clear it with the current libnl design
where a duplicated buffer is actually passed to the callback. This means
that keys might be left unnecessarily in heap memory. Avoid this by
requesting the kernel not to copy back the request payload.

Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
src/drivers/driver_nl80211.c