wpa: Add wpa_cli action file event

Yan Zhong at FreeBSD Foundation is working on a wireless network
configuratior for an experimental FreeBSD installer. The new installer
requires an event to detect when connecting to a network fails due to a
bad password. When this happens a WPA-EVENT-TEMP-DISABLED event is
triggered. This patch passes the event to an action file provided by
the new experimental installer.

Submitted by:	Yang Zhong <yzhong () freebsdfoundation.org>
Reviewed by:	assumed to be reviewed by emaste (and cy)
MFC after:	1 week
This commit is contained in:
Cy Schubert 2021-08-12 06:38:21 -07:00
parent 4b4850aefe
commit ce92f5a91b

View File

@ -3977,6 +3977,8 @@ static void wpa_cli_action_process(const char *msg)
wpa_cli_connected = 0;
wpa_cli_exec(action_file, ifname, "DISCONNECTED");
}
} else if (str_starts(pos, WPA_EVENT_TEMP_DISABLED)) {
wpa_cli_exec(action_file, ifname, pos);
} else if (str_starts(pos, WPA_EVENT_CHANNEL_SWITCH_STARTED)) {
wpa_cli_exec(action_file, ctrl_ifname, pos);
} else if (str_starts(pos, AP_EVENT_ENABLED)) {