diff options
author | markus <> | 2002-09-14 11:18:04 +0000 |
---|---|---|
committer | markus <> | 2002-09-14 11:18:04 +0000 |
commit | 3a3a489a756f2852d798376f20cc0d4ab609c866 (patch) | |
tree | 2a4277fc9b7635e82c33faa3bae9f9380bc639e8 /src/lib/libssl/s3_clnt.c | |
parent | 82d2611e1bb67683df1bb201dcc2afbff4c76980 (diff) | |
download | openbsd-3a3a489a756f2852d798376f20cc0d4ab609c866.tar.gz openbsd-3a3a489a756f2852d798376f20cc0d4ab609c866.tar.bz2 openbsd-3a3a489a756f2852d798376f20cc0d4ab609c866.zip |
merge with openssl-0.9.7-stable-SNAP-20020911,
new minor for libcrypto (_X509_REQ_print_ex)
tested by miod@, pb@
Diffstat (limited to 'src/lib/libssl/s3_clnt.c')
-rw-r--r-- | src/lib/libssl/s3_clnt.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/lib/libssl/s3_clnt.c b/src/lib/libssl/s3_clnt.c index 27df7a5a64..9ce5373b51 100644 --- a/src/lib/libssl/s3_clnt.c +++ b/src/lib/libssl/s3_clnt.c | |||
@@ -545,7 +545,11 @@ static int ssl3_client_hello(SSL *s) | |||
545 | *(p++)=i; | 545 | *(p++)=i; |
546 | if (i != 0) | 546 | if (i != 0) |
547 | { | 547 | { |
548 | die(i <= sizeof s->session->session_id); | 548 | if (i > sizeof s->session->session_id) |
549 | { | ||
550 | SSLerr(SSL_F_SSL3_CLIENT_HELLO, ERR_R_INTERNAL_ERROR); | ||
551 | goto err; | ||
552 | } | ||
549 | memcpy(p,s->session->session_id,i); | 553 | memcpy(p,s->session->session_id,i); |
550 | p+=i; | 554 | p+=i; |
551 | } | 555 | } |
@@ -1597,7 +1601,11 @@ static int ssl3_send_client_key_exchange(SSL *s) | |||
1597 | SSL_MAX_MASTER_KEY_LENGTH); | 1601 | SSL_MAX_MASTER_KEY_LENGTH); |
1598 | EVP_EncryptFinal_ex(&ciph_ctx,&(epms[outl]),&padl); | 1602 | EVP_EncryptFinal_ex(&ciph_ctx,&(epms[outl]),&padl); |
1599 | outl += padl; | 1603 | outl += padl; |
1600 | die(outl <= sizeof epms); | 1604 | if (outl > sizeof epms) |
1605 | { | ||
1606 | SSLerr(SSL_F_SSL3_SEND_CLIENT_KEY_EXCHANGE, ERR_R_INTERNAL_ERROR); | ||
1607 | goto err; | ||
1608 | } | ||
1601 | EVP_CIPHER_CTX_cleanup(&ciph_ctx); | 1609 | EVP_CIPHER_CTX_cleanup(&ciph_ctx); |
1602 | 1610 | ||
1603 | /* KerberosWrapper.EncryptedPreMasterSecret */ | 1611 | /* KerberosWrapper.EncryptedPreMasterSecret */ |