]> granicus.if.org Git - openssl/commitdiff
Fix inconsistent check of UNSAFE_LEGACY_RENEGOTIATION (1.0.2)
authorTodd Short <tshort@akamai.com>
Mon, 22 May 2017 15:24:59 +0000 (11:24 -0400)
committerKurt Roeckx <kurt@roeckx.be>
Fri, 26 May 2017 09:33:54 +0000 (11:33 +0200)
The check for SSL3_FLAGS_ALLOW_UNSAFE_LEGACY_RENEGOTIATION is
inconsistent. Most places check SSL->options, one place is checking
SSL_CTX->options; fix that.

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Kurt Roeckx <kurt@roeckx.be>
GH: #3521

ssl/s3_pkt.c

index 0290c991d8101d56613a099c5005507df279b4b0..04212c51e726d72c938b34dcc6b02eabaa9e34ed 100644 (file)
@@ -1427,7 +1427,7 @@ int ssl3_read_bytes(SSL *s, int type, unsigned char *buf, int len, int peek)
         (s->s3->handshake_fragment_len >= 4) &&
         (s->s3->handshake_fragment[0] == SSL3_MT_CLIENT_HELLO) &&
         (s->session != NULL) && (s->session->cipher != NULL) &&
-        !(s->ctx->options & SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION)) {
+        !(s->options & SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION)) {
         /*
          * s->s3->handshake_fragment_len = 0;
          */