From 0904a742358d8aac71cec1add593305dd7e0e43d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= Date: Fri, 25 Jul 2025 09:33:20 +0200 Subject: [PATCH] Remove tests for 0 limbs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit That rule is common to the whole module and not a likely mistake to make. Also, the test was not really precise as G, I, T were oversized. Better remove it than give a false sense of security. Signed-off-by: Manuel Pégourié-Gonnard --- tests/suites/test_suite_bignum_core.function | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/tests/suites/test_suite_bignum_core.function b/tests/suites/test_suite_bignum_core.function index 8ae1931cbc..55693dec27 100644 --- a/tests/suites/test_suite_bignum_core.function +++ b/tests/suites/test_suite_bignum_core.function @@ -1616,18 +1616,6 @@ void mpi_core_gcd_modinv_odd_preconditions() memcpy(I, two_limbs, 2 * sizeof(mbedtls_mpi_uint)); mbedtls_mpi_core_gcd_modinv_odd(G, I, I, 2, I, 2, T); - /* - * Not specific to this function - */ - - /* A_limbs = 0 */ - mbedtls_mpi_core_gcd_modinv_odd(G, NULL, one_limb, 0, two_limbs, 2, T); - mbedtls_mpi_core_gcd_modinv_odd(G, I, one_limb, 0, two_limbs, 2, T); - - /* A_limbs = N_limbs = 0 */ - mbedtls_mpi_core_gcd_modinv_odd(G, NULL, one_limb, 0, two_limbs, 0, T); - mbedtls_mpi_core_gcd_modinv_odd(G, I, one_limb, 0, two_limbs, 0, T); - exit: mbedtls_free(G); mbedtls_free(I);