Diff between aa7df805bf873f454d13ab475f71abfe3856366a and e8f23890653e35f02d72ea0f76f63df2becc3b26

Changed Files

File Additions Deletions Status
tools/mgmt-tester.c +16 -0 modified

Full Patch

diff --git a/tools/mgmt-tester.c b/tools/mgmt-tester.c
index ba916cd..55263d3 100644
--- a/tools/mgmt-tester.c
+++ b/tools/mgmt-tester.c
@@ -2337,6 +2337,19 @@ static const struct generic_data pair_device_reject_test_1 = {
 	.client_pin_len = sizeof(pair_device_pin),
 };
 
+static const struct generic_data pair_device_reject_test_2 = {
+	.setup_settings = settings_powered_pairable,
+	.send_opcode = MGMT_OP_PAIR_DEVICE,
+	.send_func = pair_device_send_param_func,
+	.expect_status = MGMT_STATUS_AUTH_FAILED,
+	.expect_func = pair_device_expect_param_func,
+	.expect_hci_command = BT_HCI_CMD_AUTH_REQUESTED,
+	.expect_hci_param = auth_req_param,
+	.expect_hci_len = sizeof(auth_req_param),
+	.pin = pair_device_pin,
+	.pin_len = sizeof(pair_device_pin),
+};
+
 static uint16_t settings_powered_pairable_ssp[] = {	MGMT_OP_SET_PAIRABLE,
 							MGMT_OP_SET_SSP,
 							MGMT_OP_SET_POWERED,
@@ -3609,6 +3622,9 @@ int main(int argc, char *argv[])
 	test_bredrle("Pair Device - Legacy Reject 1",
 				&pair_device_reject_test_1,
 				NULL, test_command_generic);
+	test_bredrle("Pair Device - Legacy Reject 2",
+				&pair_device_reject_test_2,
+				NULL, test_command_generic);
 	test_bredrle("Pair Device - SSP Just-Works Success 1",
 				&pair_device_ssp_test_1,
 				NULL, test_command_generic);