summaryrefslogtreecommitdiff
path: root/ssl
diff options
context:
space:
mode:
authorbodo <bodo>2000-01-30 02:22:47 +0000
committerbodo <bodo>2000-01-30 02:22:47 +0000
commitf66bd72dc2aa3b71094e176ffa247466847c505a (patch)
tree924710831bb06723c8dff47a9e653b83c209b27e /ssl
parentb7a789725d9e9ffea92d1b90d7266a279ab94d6a (diff)
downloadopenssl-f66bd72dc2aa3b71094e176ffa247466847c505a.tar.gz
Make DSA_generate_parameters, and fix a couple of bug
(including another problem in the s3_srvr.c state machine).
Diffstat (limited to 'ssl')
-rw-r--r--ssl/s3_srvr.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/ssl/s3_srvr.c b/ssl/s3_srvr.c
index d6158dbc6..ce68732e6 100644
--- a/ssl/s3_srvr.c
+++ b/ssl/s3_srvr.c
@@ -963,6 +963,14 @@ static int ssl3_send_server_key_exchange(SSL *s)
SSLerr(SSL_F_SSL3_SEND_SERVER_KEY_EXCHANGE,SSL_R_MISSING_TMP_DH_KEY);
goto f_err;
}
+
+ if (s->s3->tmp.dh != NULL)
+ {
+ DH_free(dh);
+ SSLerr(SSL_F_SSL3_SEND_SERVER_KEY_EXCHANGE, SSL_R_INTERNAL_ERROR);
+ goto err;
+ }
+
if ((dh=DHparams_dup(dhp)) == NULL)
{
SSLerr(SSL_F_SSL3_SEND_SERVER_KEY_EXCHANGE,ERR_R_DH_LIB);
@@ -1109,7 +1117,7 @@ static int ssl3_send_server_key_exchange(SSL *s)
s->init_off=0;
}
- /* SSL3_ST_SW_KEY_EXCH_B */
+ s->state = SSL3_ST_SW_KEY_EXCH_B;
return(ssl3_do_write(s,SSL3_RT_HANDSHAKE));
f_err:
ssl3_send_alert(s,SSL3_AL_FATAL,al);