| OLD | NEW |
| 1 /* | 1 /* |
| 2 * WPA Supplicant - Driver event processing | 2 * WPA Supplicant - Driver event processing |
| 3 * Copyright (c) 2003-2010, Jouni Malinen <j@w1.fi> | 3 * Copyright (c) 2003-2010, Jouni Malinen <j@w1.fi> |
| 4 * | 4 * |
| 5 * This program is free software; you can redistribute it and/or modify | 5 * This program is free software; you can redistribute it and/or modify |
| 6 * it under the terms of the GNU General Public License version 2 as | 6 * it under the terms of the GNU General Public License version 2 as |
| 7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
| 8 * | 8 * |
| 9 * Alternatively, this software may be distributed under the terms of BSD | 9 * Alternatively, this software may be distributed under the terms of BSD |
| 10 * license. | 10 * license. |
| (...skipping 1260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1271 if (wpa_s->wpa_state == WPA_4WAY_HANDSHAKE && | 1271 if (wpa_s->wpa_state == WPA_4WAY_HANDSHAKE && |
| 1272 wpa_key_mgmt_wpa_psk(wpa_s->key_mgmt)) { | 1272 wpa_key_mgmt_wpa_psk(wpa_s->key_mgmt)) { |
| 1273 wpa_msg(wpa_s, MSG_INFO, "WPA: 4-Way Handshake failed - " | 1273 wpa_msg(wpa_s, MSG_INFO, "WPA: 4-Way Handshake failed - " |
| 1274 "pre-shared key may be incorrect"); | 1274 "pre-shared key may be incorrect"); |
| 1275 } | 1275 } |
| 1276 if (wpa_s->wpa_state >= WPA_ASSOCIATED) | 1276 if (wpa_s->wpa_state >= WPA_ASSOCIATED) |
| 1277 wpa_supplicant_req_scan(wpa_s, 0, 100000); | 1277 wpa_supplicant_req_scan(wpa_s, 0, 100000); |
| 1278 bssid = wpa_s->bssid; | 1278 bssid = wpa_s->bssid; |
| 1279 if (is_zero_ether_addr(bssid)) | 1279 if (is_zero_ether_addr(bssid)) |
| 1280 bssid = wpa_s->pending_bssid; | 1280 bssid = wpa_s->pending_bssid; |
| 1281 » wpa_blacklist_add(wpa_s, bssid); | 1281 » /* |
| 1282 » * Don't blacklist the AP on normal/expected disconnects. |
| 1283 » */ |
| 1284 » if (reason_code != WLAN_REASON_DISASSOC_DUE_TO_INACTIVITY && |
| 1285 » reason_code != WLAN_REASON_CLASS2_FRAME_FROM_NONAUTH_STA && |
| 1286 » reason_code != WLAN_REASON_CLASS3_FRAME_FROM_NONASSOC_STA) |
| 1287 » » wpa_blacklist_add(wpa_s, bssid); |
| 1282 wpa_sm_notify_disassoc(wpa_s->wpa); | 1288 wpa_sm_notify_disassoc(wpa_s->wpa); |
| 1283 wpa_msg(wpa_s, MSG_INFO, WPA_EVENT_DISCONNECTED "bssid=" MACSTR | 1289 wpa_msg(wpa_s, MSG_INFO, WPA_EVENT_DISCONNECTED "bssid=" MACSTR |
| 1284 " reason=%d", | 1290 " reason=%d", |
| 1285 MAC2STR(bssid), reason_code); | 1291 MAC2STR(bssid), reason_code); |
| 1286 if (wpa_supplicant_dynamic_keys(wpa_s)) { | 1292 if (wpa_supplicant_dynamic_keys(wpa_s)) { |
| 1287 wpa_printf(MSG_DEBUG, "Disconnect event - remove keys"); | 1293 wpa_printf(MSG_DEBUG, "Disconnect event - remove keys"); |
| 1288 wpa_s->keys_cleared = 0; | 1294 wpa_s->keys_cleared = 0; |
| 1289 wpa_clear_keys(wpa_s, wpa_s->bssid); | 1295 wpa_clear_keys(wpa_s, wpa_s->bssid); |
| 1290 } | 1296 } |
| 1291 wpa_supplicant_mark_disassoc(wpa_s); | 1297 wpa_supplicant_mark_disassoc(wpa_s); |
| (...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1722 break; | 1728 break; |
| 1723 case EVENT_CONNECTION_CHANGE: | 1729 case EVENT_CONNECTION_CHANGE: |
| 1724 bgscan_notify_connection_change(wpa_s, | 1730 bgscan_notify_connection_change(wpa_s, |
| 1725 &data->connection_change); | 1731 &data->connection_change); |
| 1726 break; | 1732 break; |
| 1727 default: | 1733 default: |
| 1728 wpa_printf(MSG_INFO, "Unknown event %d", event); | 1734 wpa_printf(MSG_INFO, "Unknown event %d", event); |
| 1729 break; | 1735 break; |
| 1730 } | 1736 } |
| 1731 } | 1737 } |
| OLD | NEW |