From 632939df4b6246c1a56cebe1489db22f4894cb19 Mon Sep 17 00:00:00 2001 From: Przemek Stekiel Date: Thu, 7 Jul 2022 09:27:20 +0200 Subject: [PATCH] ssl_client2: print pk key name when provided using key_opaque_algs Signed-off-by: Przemek Stekiel --- programs/ssl/ssl_client2.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/programs/ssl/ssl_client2.c b/programs/ssl/ssl_client2.c index 89150114a..3db2b5201 100644 --- a/programs/ssl/ssl_client2.c +++ b/programs/ssl/ssl_client2.c @@ -1769,7 +1769,8 @@ int main( int argc, char *argv[] ) #endif /* MBEDTLS_USE_PSA_CRYPTO */ mbedtls_printf( " ok (key type: %s)\n", - strlen( opt.key_file ) ? mbedtls_pk_get_name( &pkey ) : "none" ); + strlen( opt.key_file ) || strlen( opt.key_opaque_alg1 ) ? + mbedtls_pk_get_name( &pkey ) : "none" ); #endif /* MBEDTLS_X509_CRT_PARSE_C */ /*