From e4dc23a5233138b05d4afa19c6e44891f9ec2653 Mon Sep 17 00:00:00 2001 From: Denis Kenzior Date: Thu, 17 Oct 2019 12:04:08 -0500 Subject: [PATCH] monitor: Use print_ie in auth frame dumper Do not assume that the challenge IE is present or the only IE in the authentication frame --- monitor/nlmon.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/monitor/nlmon.c b/monitor/nlmon.c index 5b8986bb..a35ec714 100644 --- a/monitor/nlmon.c +++ b/monitor/nlmon.c @@ -3718,13 +3718,8 @@ static void print_authentication_mgmt_frame(unsigned int level, L_LE16_TO_CPU(body->transaction_sequence) > 3) return; - ie_tlv_iter_init(&iter, body->ies, (const uint8_t *) mmpdu + size - - body->ies); - ie_tlv_iter_next(&iter); - - print_attr(level + 1, "Challenge text: \"%s\" (%u)", - ie_tlv_iter_get_data(&iter), - ie_tlv_iter_get_length(&iter)); + print_ie(level + 1, "IEs", body->ies, + (const uint8_t *) mmpdu + size - body->ies); } static void print_deauthentication_mgmt_frame(unsigned int level,