]> git.ipfire.org Git - thirdparty/hostap.git/commit
D-Bus: Share 'remove all networks' with CLI
authorBrian Norris <briannorris@chromium.org>
Thu, 20 Aug 2020 02:09:35 +0000 (19:09 -0700)
committerJouni Malinen <j@w1.fi>
Sat, 10 Oct 2020 17:39:00 +0000 (20:39 +0300)
commit4b96fafcd8688f4222cf065038ab406f7083d86d
tree3ce144688fc422fafc2f71b83e3799479881f928
parent07aac648a16e8df72463bbaa6f6ee7821d4eb7ed
D-Bus: Share 'remove all networks' with CLI

The D-Bus implementation of RemoveAllNetworks differs wildly from the
CLI implementation. Let's share the implementations.

This resolves use-after-free bugs I noticed, where we continue to use
the 'wpa_s->current_ssid' wpa_ssid object after freeing it, because we
didn't bother to disconnect from (and set to NULL) current_ssid before
freeing it.

Signed-off-by: Brian Norris <briannorris@chromium.org>
wpa_supplicant/ctrl_iface.c
wpa_supplicant/dbus/dbus_new_handlers.c
wpa_supplicant/wpa_supplicant.c
wpa_supplicant/wpa_supplicant_i.h