Add more debug prints on suite selector selection
This makes it a bit easier to figure out why wpa_supplicant selects a specific cipher/AKM for association. Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
This commit is contained in:
parent
659f7954f4
commit
853bd19f22
1 changed files with 12 additions and 0 deletions
|
@ -1375,6 +1375,9 @@ int wpa_supplicant_set_suites(struct wpa_supplicant *wpa_s,
|
||||||
wpa_s->pairwise_cipher = WPA_CIPHER_NONE;
|
wpa_s->pairwise_cipher = WPA_CIPHER_NONE;
|
||||||
#else /* CONFIG_NO_WPA */
|
#else /* CONFIG_NO_WPA */
|
||||||
sel = ie.group_cipher & ssid->group_cipher;
|
sel = ie.group_cipher & ssid->group_cipher;
|
||||||
|
wpa_dbg(wpa_s, MSG_DEBUG,
|
||||||
|
"WPA: AP group 0x%x network profile group 0x%x; available group 0x%x",
|
||||||
|
ie.group_cipher, ssid->group_cipher, sel);
|
||||||
wpa_s->group_cipher = wpa_pick_group_cipher(sel);
|
wpa_s->group_cipher = wpa_pick_group_cipher(sel);
|
||||||
if (wpa_s->group_cipher < 0) {
|
if (wpa_s->group_cipher < 0) {
|
||||||
wpa_msg(wpa_s, MSG_WARNING, "WPA: Failed to select group "
|
wpa_msg(wpa_s, MSG_WARNING, "WPA: Failed to select group "
|
||||||
|
@ -1385,6 +1388,9 @@ int wpa_supplicant_set_suites(struct wpa_supplicant *wpa_s,
|
||||||
wpa_cipher_txt(wpa_s->group_cipher));
|
wpa_cipher_txt(wpa_s->group_cipher));
|
||||||
|
|
||||||
sel = ie.pairwise_cipher & ssid->pairwise_cipher;
|
sel = ie.pairwise_cipher & ssid->pairwise_cipher;
|
||||||
|
wpa_dbg(wpa_s, MSG_DEBUG,
|
||||||
|
"WPA: AP pairwise 0x%x network profile pairwise 0x%x; available pairwise 0x%x",
|
||||||
|
ie.pairwise_cipher, ssid->pairwise_cipher, sel);
|
||||||
wpa_s->pairwise_cipher = wpa_pick_pairwise_cipher(sel, 1);
|
wpa_s->pairwise_cipher = wpa_pick_pairwise_cipher(sel, 1);
|
||||||
if (wpa_s->pairwise_cipher < 0) {
|
if (wpa_s->pairwise_cipher < 0) {
|
||||||
wpa_msg(wpa_s, MSG_WARNING, "WPA: Failed to select pairwise "
|
wpa_msg(wpa_s, MSG_WARNING, "WPA: Failed to select pairwise "
|
||||||
|
@ -1396,6 +1402,9 @@ int wpa_supplicant_set_suites(struct wpa_supplicant *wpa_s,
|
||||||
#endif /* CONFIG_NO_WPA */
|
#endif /* CONFIG_NO_WPA */
|
||||||
|
|
||||||
sel = ie.key_mgmt & ssid->key_mgmt;
|
sel = ie.key_mgmt & ssid->key_mgmt;
|
||||||
|
wpa_dbg(wpa_s, MSG_DEBUG,
|
||||||
|
"WPA: AP key_mgmt 0x%x network profile key_mgmt 0x%x; available key_mgmt 0x%x",
|
||||||
|
ie.key_mgmt, ssid->key_mgmt, sel);
|
||||||
#ifdef CONFIG_SAE
|
#ifdef CONFIG_SAE
|
||||||
if (!(wpa_s->drv_flags & WPA_DRIVER_FLAGS_SAE))
|
if (!(wpa_s->drv_flags & WPA_DRIVER_FLAGS_SAE))
|
||||||
sel &= ~(WPA_KEY_MGMT_SAE | WPA_KEY_MGMT_FT_SAE);
|
sel &= ~(WPA_KEY_MGMT_SAE | WPA_KEY_MGMT_FT_SAE);
|
||||||
|
@ -1519,6 +1528,9 @@ int wpa_supplicant_set_suites(struct wpa_supplicant *wpa_s,
|
||||||
if (wpas_get_ssid_pmf(wpa_s, ssid) == NO_MGMT_FRAME_PROTECTION ||
|
if (wpas_get_ssid_pmf(wpa_s, ssid) == NO_MGMT_FRAME_PROTECTION ||
|
||||||
!(ie.capabilities & WPA_CAPABILITY_MFPC))
|
!(ie.capabilities & WPA_CAPABILITY_MFPC))
|
||||||
sel = 0;
|
sel = 0;
|
||||||
|
wpa_dbg(wpa_s, MSG_DEBUG,
|
||||||
|
"WPA: AP mgmt_group_cipher 0x%x network profile mgmt_group_cipher 0x%x; available mgmt_group_cipher 0x%x",
|
||||||
|
ie.mgmt_group_cipher, ssid->group_mgmt_cipher, sel);
|
||||||
if (sel & WPA_CIPHER_AES_128_CMAC) {
|
if (sel & WPA_CIPHER_AES_128_CMAC) {
|
||||||
wpa_s->mgmt_group_cipher = WPA_CIPHER_AES_128_CMAC;
|
wpa_s->mgmt_group_cipher = WPA_CIPHER_AES_128_CMAC;
|
||||||
wpa_dbg(wpa_s, MSG_DEBUG, "WPA: using MGMT group cipher "
|
wpa_dbg(wpa_s, MSG_DEBUG, "WPA: using MGMT group cipher "
|
||||||
|
|
Loading…
Reference in a new issue