From: Jouni Malinen Date: Fri, 3 Nov 2017 17:33:17 +0000 (+0200) Subject: DPP: Protocol testing - invalid Status value in PKEX Exchange Response X-Git-Tag: hostap_2_7~894 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f31ef96dc32248c1c35f892adfcc64439655f498;p=thirdparty%2Fhostap.git DPP: Protocol testing - invalid Status value in PKEX Exchange Response Signed-off-by: Jouni Malinen --- diff --git a/src/common/dpp.c b/src/common/dpp.c index fffd5a624..40738fdae 100644 --- a/src/common/dpp.c +++ b/src/common/dpp.c @@ -5689,6 +5689,11 @@ dpp_pkex_build_exchange_resp(struct dpp_pkex *pkex, wpa_printf(MSG_INFO, "DPP: TESTING - no Status"); goto skip_status; } + + if (dpp_test == DPP_TEST_INVALID_STATUS_PKEX_EXCHANGE_RESP) { + wpa_printf(MSG_INFO, "DPP: TESTING - invalid Status"); + status = 255; + } #endif /* CONFIG_TESTING_OPTIONS */ /* DPP Status */ diff --git a/src/common/dpp.h b/src/common/dpp.h index c60d90f42..1526f999f 100644 --- a/src/common/dpp.h +++ b/src/common/dpp.h @@ -264,6 +264,7 @@ enum dpp_test_behavior { DPP_TEST_NO_WRAPPED_DATA_PKEX_CR_RESP = 43, DPP_TEST_INVALID_ENCRYPTED_KEY_PKEX_EXCHANGE_REQ = 44, DPP_TEST_INVALID_ENCRYPTED_KEY_PKEX_EXCHANGE_RESP = 45, + DPP_TEST_INVALID_STATUS_PKEX_EXCHANGE_RESP = 46, }; extern enum dpp_test_behavior dpp_test;