projects
/
oweals
/
openssl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9ae9cbc
)
Sanity check in ssl_get_algorithm2().
author
Dr. Stephen Henson
<steve@openssl.org>
Tue, 19 Jul 2016 15:03:10 +0000
(16:03 +0100)
committer
Dr. Stephen Henson
<steve@openssl.org>
Tue, 19 Jul 2016 23:14:36 +0000
(
00:14
+0100)
RT#4600
Reviewed-by: Rich Salz <rsalz@openssl.org>
(cherry picked from commit
52eede5a970fdb30c4ed6d3663e51f36bd1b1c73
)
Conflicts:
ssl/s3_lib.c
ssl/s3_lib.c
patch
|
blob
|
history
diff --git
a/ssl/s3_lib.c
b/ssl/s3_lib.c
index 872e636af9e19002e37a7c96fa7df45f8cd2c302..f2aaf36c4099bf6b59d64cacdbc25c09e3191682 100644
(file)
--- a/
ssl/s3_lib.c
+++ b/
ssl/s3_lib.c
@@
-4528,7
+4528,10
@@
int ssl3_renegotiate_check(SSL *s)
*/
long ssl_get_algorithm2(SSL *s)
{
- long alg2 = s->s3->tmp.new_cipher->algorithm2;
+ long alg2;
+ if (s->s3 == NULL || s->s3->tmp.new_cipher == NULL)
+ return -1;
+ alg2 = s->s3->tmp.new_cipher->algorithm2;
if (s->method->ssl3_enc->enc_flags & SSL_ENC_FLAG_SHA256_PRF
&& alg2 == (SSL_HANDSHAKE_MAC_DEFAULT | TLS1_PRF))
return SSL_HANDSHAKE_MAC_SHA256 | TLS1_PRF_SHA256;