From 52e648c7f1ba70caf419f0095739e1c75c016b95 Mon Sep 17 00:00:00 2001 From: Praneeth Sarode Date: Tue, 27 May 2025 16:42:05 +0530 Subject: [PATCH] tests: remove unsupported SHA1 HMAC tests for compatibility with latest dropbear version Signed-off-by: Praneeth Sarode Reviewed-by: Jakub Jelen (cherry picked from commit ca4c874a9e72be96f407ad7dd7941ce52d80b7ab) --- tests/pkd/pkd_hello.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/tests/pkd/pkd_hello.c b/tests/pkd/pkd_hello.c index 069ed8df..a6d74505 100644 --- a/tests/pkd/pkd_hello.c +++ b/tests/pkd/pkd_hello.c @@ -411,15 +411,20 @@ static int torture_pkd_setup_ecdsa_521(void **state) { #define PKDTESTS_MAC_FIPS(f, client, maccmd) \ - f(client, ecdsa_256_hmac_sha1, maccmd("hmac-sha1"), setup_ecdsa_256, teardown) \ f(client, ecdsa_256_hmac_sha2_256, maccmd("hmac-sha2-256"), setup_ecdsa_256, teardown) \ - f(client, ecdsa_384_hmac_sha1, maccmd("hmac-sha1"), setup_ecdsa_384, teardown) \ f(client, ecdsa_384_hmac_sha2_256, maccmd("hmac-sha2-256"), setup_ecdsa_384, teardown) \ - f(client, ecdsa_521_hmac_sha1, maccmd("hmac-sha1"), setup_ecdsa_521, teardown) \ f(client, ecdsa_521_hmac_sha2_256, maccmd("hmac-sha2-256"), setup_ecdsa_521, teardown) \ - f(client, rsa_hmac_sha1, maccmd("hmac-sha1"), setup_rsa, teardown) \ f(client, rsa_hmac_sha2_256, maccmd("hmac-sha2-256"), setup_rsa, teardown) +/* TODO: Include these tests when an older version of dropbear is used. Currently, they have been removed as the latest dropbear version +does not support these MACs. + +f(client, ecdsa_256_hmac_sha1, maccmd("hmac-sha1"), setup_ecdsa_256, teardown) \ +f(client, ecdsa_384_hmac_sha1, maccmd("hmac-sha1"), setup_ecdsa_384, teardown) \ +f(client, ecdsa_521_hmac_sha1, maccmd("hmac-sha1"), setup_ecdsa_521, teardown) \ +f(client, rsa_hmac_sha1, maccmd("hmac-sha1"), setup_rsa, teardown) \ +*/ + #define PKDTESTS_MAC_OPENSSHONLY_FIPS(f, client, maccmd) \ f(client, ecdsa_256_hmac_sha1_etm, maccmd("hmac-sha1-etm@openssh.com"), setup_ecdsa_256, teardown) \ f(client, ecdsa_256_hmac_sha2_256_etm, maccmd("hmac-sha2-256-etm@openssh.com"), setup_ecdsa_256, teardown) \