summaryrefslogtreecommitdiff
path: root/main/openssl/ssl/s3_enc.c
diff options
context:
space:
mode:
authorArne Schwabe <arne@rfc2549.org>2014-11-14 09:52:32 +0100
committerArne Schwabe <arne@rfc2549.org>2014-11-14 09:52:32 +0100
commitb28828796ad6d65ac463b41bba153f74e4531a6b (patch)
tree154b9f7436ae575e324f3374a5145e451bf649a8 /main/openssl/ssl/s3_enc.c
parente7a6c1a987ebee1ddb2f908ca028d613a5c52490 (diff)
Update OpenSSL version
Diffstat (limited to 'main/openssl/ssl/s3_enc.c')
-rw-r--r--main/openssl/ssl/s3_enc.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/main/openssl/ssl/s3_enc.c b/main/openssl/ssl/s3_enc.c
index 3595cff4..bcb65d48 100644
--- a/main/openssl/ssl/s3_enc.c
+++ b/main/openssl/ssl/s3_enc.c
@@ -641,10 +641,18 @@ int ssl3_cert_verify_mac(SSL *s, int md_nid, unsigned char *p)
int ssl3_final_finish_mac(SSL *s,
const char *sender, int len, unsigned char *p)
{
- int ret;
+ int ret, sha1len;
ret=ssl3_handshake_mac(s,NID_md5,sender,len,p);
+ if(ret == 0)
+ return 0;
+
p+=ret;
- ret+=ssl3_handshake_mac(s,NID_sha1,sender,len,p);
+
+ sha1len=ssl3_handshake_mac(s,NID_sha1,sender,len,p);
+ if(sha1len == 0)
+ return 0;
+
+ ret+=sha1len;
return(ret);
}
static int ssl3_handshake_mac(SSL *s, int md_nid,