aboutsummaryrefslogtreecommitdiffstats
path: root/apps/s_server.c
diff options
context:
space:
mode:
authorGeoff Thorpe <geoff@openssl.org>2003-10-29 04:14:08 +0000
committerGeoff Thorpe <geoff@openssl.org>2003-10-29 04:14:08 +0000
commit2aaec9cced89edfdc8375b38a130fa1c35a98025 (patch)
tree8f9339b8dac8d23ae1b424216b769cdeef7f59f0 /apps/s_server.c
parent9d473aa2e4076beb959bc9701786a0860877ee12 (diff)
downloadopenssl-2aaec9cced89edfdc8375b38a130fa1c35a98025.tar.gz
Update any code that was using deprecated functions so that everything builds
and links with OPENSSL_NO_DEPRECATED defined.
Diffstat (limited to 'apps/s_server.c')
-rw-r--r--apps/s_server.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/apps/s_server.c b/apps/s_server.c
index dd58591d3b..9b8fe570cc 100644
--- a/apps/s_server.c
+++ b/apps/s_server.c
@@ -1785,7 +1785,12 @@ static RSA MS_CALLBACK *tmp_rsa_cb(SSL *s, int is_export, int keylength)
BIO_printf(bio_err,"Generating temp (%d bit) RSA key...",keylength);
(void)BIO_flush(bio_err);
}
- rsa_tmp=RSA_generate_key(keylength,RSA_F4,NULL,NULL);
+ if(((rsa_tmp = RSA_new()) == NULL) || !RSA_generate_key_ex(
+ rsa_tmp, keylength,RSA_F4,NULL))
+ {
+ if(rsa_tmp) RSA_free(rsa_tmp);
+ rsa_tmp = NULL;
+ }
if (!s_quiet)
{
BIO_printf(bio_err,"\n");