D-Bus: Fix GONegotiationSuccess signal passphrase format

Passphrase is a variable length string of (8..63 characters), not a byte
array of fixed 64 octets.

Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
Jouni Malinen 2014-12-31 11:41:11 +02:00
parent 3cccf0b870
commit 68bb007743

View file

@ -1363,13 +1363,10 @@ void wpas_dbus_signal_p2p_go_neg_resp(struct wpa_supplicant *wpa_s,
int i = 0; int i = 0;
int freq_list_num = 0; int freq_list_num = 0;
if (res->role_go) { if (res->role_go &&
if (!wpa_dbus_dict_append_byte_array( !wpa_dbus_dict_append_string(&dict_iter, "passphrase",
&dict_iter, "passphrase", res->passphrase))
(const char *) res->passphrase,
sizeof(res->passphrase)))
goto err; goto err;
}
if (!wpa_dbus_dict_append_string(&dict_iter, "role_go", if (!wpa_dbus_dict_append_string(&dict_iter, "role_go",
res->role_go ? "GO" : res->role_go ? "GO" :