Fix for TLS record tampering bug CVE-2013-4353
authorDr. Stephen Henson <steve@openssl.org>
Mon, 6 Jan 2014 14:35:04 +0000 (14:35 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Mon, 6 Jan 2014 14:35:04 +0000 (14:35 +0000)
CHANGES
NEWS
ssl/s3_both.c

diff --git a/CHANGES b/CHANGES
index 173be2465e855b10ab994d889498ac5244067097..6494184bad8a291f7c65974f2b9e41895de25bd3 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -4,6 +4,11 @@
 
  Changes between 1.0.1e and 1.0.1f [xx XXX xxxx]
 
+  *) Fix for TLS record tampering bug. A carefully crafted invalid 
+     handshake could crash OpenSSL with a NULL pointer exception.
+     Thanks to Anton Johansson for reporting this issues.
+     (CVE-2013-4353)
+
   *) Keep original DTLS digest and encryption contexts in retransmission
      structures so we can use the previous session parameters if they need
      to be resent. (CVE-2013-6450)
diff --git a/NEWS b/NEWS
index cdf84d927d2dacb97a1d172684a22c2737090355..81b6ed2c7b275a8a4a8a43ca5bf081e312b062a7 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -7,6 +7,7 @@
 
   Major changes between OpenSSL 1.0.1e and OpenSSL 1.0.1f [under development]
 
+      o Fix for TLS record tampering bug CVE-2013-4353
       o Fix for TLS version checking bug CVE-2013-6449
       o Fix for DTLS retransmission bug CVE-2013-6450
 
index 1e5dcab7d30520c00cc60d55d6ebd6e2ae3e6e6c..53b9390fdd3af30d0576825d0b0e19bc5d290ac6 100644 (file)
@@ -210,7 +210,11 @@ static void ssl3_take_mac(SSL *s)
        {
        const char *sender;
        int slen;
-
+       /* If no new cipher setup return immediately: other functions will
+        * set the appropriate error.
+        */
+       if (s->s3->tmp.new_cipher == NULL)
+               return;
        if (s->state & SSL_ST_CONNECT)
                {
                sender=s->method->ssl3_enc->server_finished_label;