diff options
| author | Pradeep Reddy POTTETI <c_ppotte@qti.qualcomm.com> | 2015-10-15 12:18:59 +0530 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2015-10-20 23:35:15 -0700 |
| commit | f0fcc75f33b1ea750bfb37226cf6e470fc51a45d (patch) | |
| tree | 4662bf99f564c95175acef2c173d04368ad00e66 /src/rsn_supp | |
| parent | 9feeccc0ee8a34656f69a3a83e80d7fa00b64ae5 (diff) | |
| download | android_external_wpa_supplicant_8-f0fcc75f33b1ea750bfb37226cf6e470fc51a45d.tar.gz android_external_wpa_supplicant_8-f0fcc75f33b1ea750bfb37226cf6e470fc51a45d.tar.bz2 android_external_wpa_supplicant_8-f0fcc75f33b1ea750bfb37226cf6e470fc51a45d.zip | |
TDLS: On a TPK timeout, tear down the link before renewal by the initiator
On TPK lifetime expiration, tear down the direct link before renewing
the link in the case of TDLS initiator processing. The expired key
cannot be used anymore, so it is better to explicitly tear down the old
link first.
CRs-fixed: 926482
Change-Id: I1890103c5b754c94e9525b74703a5c149117fa07
Git-commit: 2bd5bdcd4b1822d0fe4c88f3dd02d0a4ea5913bb
Git-repo : git://w1.fi/srv/git/hostap.git
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'src/rsn_supp')
| -rw-r--r-- | src/rsn_supp/tdls.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/rsn_supp/tdls.c b/src/rsn_supp/tdls.c index 6b1df711..2bbcab16 100644 --- a/src/rsn_supp/tdls.c +++ b/src/rsn_supp/tdls.c @@ -626,9 +626,15 @@ static void wpa_tdls_tpk_timeout(void *eloop_ctx, void *timeout_ctx) */ if (peer->initiator) { + u8 addr[ETH_ALEN]; + wpa_printf(MSG_DEBUG, "TDLS: TPK lifetime expired for " MACSTR " - try to renew", MAC2STR(peer->addr)); - wpa_tdls_start(sm, peer->addr); + /* cache the peer address before do_teardown */ + os_memcpy(addr, peer->addr, ETH_ALEN); + wpa_tdls_do_teardown(sm, peer, + WLAN_REASON_TDLS_TEARDOWN_UNSPECIFIED); + wpa_tdls_start(sm, addr); } else { wpa_printf(MSG_DEBUG, "TDLS: TPK lifetime expired for " MACSTR " - tear down", MAC2STR(peer->addr)); |
