path: root/wpa_supplicant/wpa_cli.c
diff options
authorJouni Malinen <j@w1.fi>2015-02-08 14:56:04 (GMT)
committerJouni Malinen <j@w1.fi>2015-02-08 20:49:58 (GMT)
commitf91a512f1f4964316ab9f00bfc7c70cb1986ff5d (patch)
tree046bafcd8bb9df77394c5a8b8dbe8375eeb84688 /wpa_supplicant/wpa_cli.c
parentc612ae97a419e55bb3e815f68376a0d78c871ccf (diff)
This can be used to provide more control to upper layers on network blocks generated as part of Interworking network selection. INTERWORKING_ADD_NETWORK behaves otherwise identically to INTERWORKING_CONNECT, but it does not request a new connection after having added the network block and it returns the network id of the added network. INTERWORKING_ADD_NETWORK followed by REASSOCIATE would behave more or less identically to INTERWORKING_CONNECT, but this allows the created network profile to be modified, if desired, and/or stored externally. SELECT_NETWORK can also be used with the network id returned from INTERWORKING_ADD_NETWORK to enforce that specific network profile to be used for the next connection (though, it should be noted that this behavior may not meet all Hotspot 2.0 requirements if there were other enabled networks that could have higher priority). Signed-off-by: Jouni Malinen <j@w1.fi>
Diffstat (limited to 'wpa_supplicant/wpa_cli.c')
1 files changed, 10 insertions, 0 deletions
diff --git a/wpa_supplicant/wpa_cli.c b/wpa_supplicant/wpa_cli.c
index 2f06c35..af08e13 100644
--- a/wpa_supplicant/wpa_cli.c
+++ b/wpa_supplicant/wpa_cli.c
@@ -2309,6 +2309,13 @@ static int wpa_cli_cmd_interworking_connect(struct wpa_ctrl *ctrl, int argc,
+static int wpa_cli_cmd_interworking_add_network(struct wpa_ctrl *ctrl, int argc,
+ char *argv[])
+ return wpa_cli_cmd(ctrl, "INTERWORKING_ADD_NETWORK", 1, argc, argv);
static int wpa_cli_cmd_anqp_get(struct wpa_ctrl *ctrl, int argc, char *argv[])
return wpa_cli_cmd(ctrl, "ANQP_GET", 2, argc, argv);
@@ -2997,6 +3004,9 @@ static struct wpa_cli_cmd wpa_cli_commands[] = {
{ "interworking_connect", wpa_cli_cmd_interworking_connect,
wpa_cli_complete_bss, cli_cmd_flag_none,
"<BSSID> = connect using Interworking credentials" },
+ { "interworking_add_network", wpa_cli_cmd_interworking_add_network,
+ wpa_cli_complete_bss, cli_cmd_flag_none,
+ "<BSSID> = connect using Interworking credentials" },
{ "anqp_get", wpa_cli_cmd_anqp_get, wpa_cli_complete_bss,
"<addr> <info id>[,<info id>]... = request ANQP information" },