From fabce04122b1e6a208577c06927b25595d5b5613 Mon Sep 17 00:00:00 2001 From: "Dr. Stephen Henson" Date: Sun, 23 Jan 2000 02:28:08 +0000 Subject: Make s_server, s_client check cipher list return codes. Update docs. --- apps/s_client.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'apps/s_client.c') diff --git a/apps/s_client.c b/apps/s_client.c index 84a475d7b8..c9b52e6a99 100644 --- a/apps/s_client.c +++ b/apps/s_client.c @@ -338,6 +338,7 @@ bad: } SSLeay_add_ssl_algorithms(); + SSL_load_error_strings(); ctx=SSL_CTX_new(meth); if (ctx == NULL) { @@ -352,7 +353,11 @@ bad: if (state) SSL_CTX_set_info_callback(ctx,apps_ssl_info_callback); if (cipher != NULL) - SSL_CTX_set_cipher_list(ctx,cipher); + if(!SSL_CTX_set_cipher_list(ctx,cipher)) { + BIO_printf(bio_err,"error seting cipher list\n"); + ERR_print_errors(bio_err); + goto end; + } #if 0 else SSL_CTX_set_cipher_list(ctx,getenv("SSL_CIPHER")); @@ -370,7 +375,6 @@ bad: /* goto end; */ } - SSL_load_error_strings(); con=(SSL *)SSL_new(ctx); /* SSL_set_cipher_list(con,"RC4-MD5"); */ -- cgit v1.2.3