From 1dc0945cc9de8ef2ea4b45d7c145a639f32d879f Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Sat, 24 Mar 2018 11:47:37 +0200 Subject: [PATCH] FT: Do not send PMK-R1 pull request to own R0KH address If the requested key is not available locally, there is no point in trying to send a pull request back to self for the key. Signed-off-by: Jouni Malinen --- src/ap/wpa_auth_ft.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ap/wpa_auth_ft.c b/src/ap/wpa_auth_ft.c index 153752d17..5191ae090 100644 --- a/src/ap/wpa_auth_ft.c +++ b/src/ap/wpa_auth_ft.c @@ -1459,6 +1459,11 @@ static int wpa_ft_pull_pmk_r1(struct wpa_state_machine *sm, sm->r0kh_id, sm->r0kh_id_len); return -1; } + if (os_memcmp(r0kh->addr, sm->wpa_auth->addr, ETH_ALEN) == 0) { + wpa_printf(MSG_DEBUG, + "FT: R0KH-ID points to self - no matching key available"); + return -1; + } key = r0kh->key; key_len = sizeof(r0kh->key);