diff --git a/src/common/dpp.h b/src/common/dpp.h index b2b97614b..6ee3bee47 100644 --- a/src/common/dpp.h +++ b/src/common/dpp.h @@ -323,6 +323,7 @@ enum dpp_test_behavior { DPP_TEST_INVALID_CONNECTOR_PEER_DISC_RESP = 79, DPP_TEST_INVALID_CONNECTOR_PEER_DISC_REQ = 80, DPP_TEST_INVALID_I_NONCE_AUTH_REQ = 81, + DPP_TEST_INVALID_TRANSACTION_ID_PEER_DISC_REQ = 82, }; extern enum dpp_test_behavior dpp_test; diff --git a/wpa_supplicant/dpp_supplicant.c b/wpa_supplicant/dpp_supplicant.c index a6b1a58d7..42c102864 100644 --- a/wpa_supplicant/dpp_supplicant.c +++ b/wpa_supplicant/dpp_supplicant.c @@ -2268,6 +2268,12 @@ int wpas_dpp_check_connect(struct wpa_supplicant *wpa_s, struct wpa_ssid *ssid, wpa_printf(MSG_INFO, "DPP: TESTING - no Transaction ID"); goto skip_trans_id; } + if (dpp_test == DPP_TEST_INVALID_TRANSACTION_ID_PEER_DISC_REQ) { + wpa_printf(MSG_INFO, "DPP: TESTING - invalid Transaction ID"); + wpabuf_put_le16(msg, DPP_ATTR_TRANSACTION_ID); + wpabuf_put_le16(msg, 0); + goto skip_trans_id; + } #endif /* CONFIG_TESTING_OPTIONS */ /* Transaction ID */