[Midnightbsd-cvs] src [6658] stable/0.4: MidnightBSD 0.4-RELEASE-p12
laffer1 at midnightbsd.org
laffer1 at midnightbsd.org
Thu Jun 5 20:11:23 EDT 2014
Revision: 6658
http://svnweb.midnightbsd.org/src/?rev=6658
Author: laffer1
Date: 2014-06-05 20:11:23 -0400 (Thu, 05 Jun 2014)
Log Message:
-----------
MidnightBSD 0.4-RELEASE-p12
Modified Paths:
--------------
stable/0.4/UPDATING
stable/0.4/crypto/openssl/ssl/d1_both.c
stable/0.4/crypto/openssl/ssl/s3_clnt.c
stable/0.4/crypto/openssl/ssl/s3_pkt.c
stable/0.4/crypto/openssl/ssl/s3_srvr.c
stable/0.4/crypto/openssl/ssl/ssl3.h
stable/0.4/sys/conf/newvers.sh
Modified: stable/0.4/UPDATING
===================================================================
--- stable/0.4/UPDATING 2014-06-04 12:28:41 UTC (rev 6657)
+++ stable/0.4/UPDATING 2014-06-06 00:11:23 UTC (rev 6658)
@@ -1,5 +1,22 @@
Updating Information for MidnightBSD users.
+20140605:
+ 0.4-RELEASE-p12
+
+ OpenSSL vulnerabilities
+
+ Receipt of an invalid DTLS fragment on an OpenSSL DTLS client or server can
+ lead to a buffer overrun. [CVE-2014-0195]
+
+ Receipt of an invalid DTLS handshake on an OpenSSL DTLS client can lead the
+ code to unnecessary recurse. [CVE-2014-0221]
+
+ Carefully crafted handshake can force the use of weak keying material in
+ OpenSSL SSL/TLS clients and servers. [CVE-2014-0224]
+
+ Carefully crafted packets can lead to a NULL pointer deference in OpenSSL
+ TLS client code if anonymous ECDH ciphersuites are enabled. [CVE-2014-3470]
+
20140604:
0.4-RELEASE-p11
Modified: stable/0.4/crypto/openssl/ssl/d1_both.c
===================================================================
--- stable/0.4/crypto/openssl/ssl/d1_both.c 2014-06-04 12:28:41 UTC (rev 6657)
+++ stable/0.4/crypto/openssl/ssl/d1_both.c 2014-06-06 00:11:23 UTC (rev 6658)
@@ -620,8 +620,17 @@
frag->msg_header.frag_off = 0;
}
else
+ {
frag = (hm_fragment*) item->data;
+ if (frag->msg_header.msg_len != msg_hdr->msg_len)
+ {
+ item = NULL;
+ frag = NULL;
+ goto err;
+ }
+ }
+
/* If message is already reassembled, this must be a
* retransmit and can be dropped.
*/
@@ -777,6 +786,7 @@
int i,al;
struct hm_header_st msg_hdr;
+ redo:
/* see if we have the required fragment already */
if ((frag_len = dtls1_retrieve_buffered_fragment(s,max,ok)) || *ok)
{
@@ -835,8 +845,7 @@
s->msg_callback_arg);
s->init_num = 0;
- return dtls1_get_message_fragment(s, st1, stn,
- max, ok);
+ goto redo;
}
else /* Incorrectly formated Hello request */
{
Modified: stable/0.4/crypto/openssl/ssl/s3_clnt.c
===================================================================
--- stable/0.4/crypto/openssl/ssl/s3_clnt.c 2014-06-04 12:28:41 UTC (rev 6657)
+++ stable/0.4/crypto/openssl/ssl/s3_clnt.c 2014-06-06 00:11:23 UTC (rev 6658)
@@ -491,6 +491,7 @@
case SSL3_ST_CR_FINISHED_A:
case SSL3_ST_CR_FINISHED_B:
+ s->s3->flags |= SSL3_FLAGS_CCS_OK;
ret=ssl3_get_finished(s,SSL3_ST_CR_FINISHED_A,
SSL3_ST_CR_FINISHED_B);
if (ret <= 0) goto end;
@@ -777,6 +778,7 @@
SSLerr(SSL_F_SSL3_GET_SERVER_HELLO,SSL_R_ATTEMPT_TO_REUSE_SESSION_IN_DIFFERENT_CONTEXT);
goto f_err;
}
+ s->s3->flags |= SSL3_FLAGS_CCS_OK;
s->hit=1;
}
else /* a miss or crap from the other end */
@@ -2170,6 +2172,13 @@
int ecdh_clnt_cert = 0;
int field_size = 0;
+ if (s->session->sess_cert == NULL)
+ {
+ ssl3_send_alert(s,SSL3_AL_FATAL,SSL_AD_UNEXPECTED_MESSAGE);
+ SSLerr(SSL_F_SSL3_SEND_CLIENT_KEY_EXCHANGE,SSL_R_UNEXPECTED_MESSAGE);
+ goto err;
+ }
+
/* Did we send out the client's
* ECDH share for use in premaster
* computation as part of client certificate?
Modified: stable/0.4/crypto/openssl/ssl/s3_pkt.c
===================================================================
--- stable/0.4/crypto/openssl/ssl/s3_pkt.c 2014-06-04 12:28:41 UTC (rev 6657)
+++ stable/0.4/crypto/openssl/ssl/s3_pkt.c 2014-06-06 00:11:23 UTC (rev 6658)
@@ -1147,6 +1147,15 @@
goto f_err;
}
+ if (!(s->s3->flags & SSL3_FLAGS_CCS_OK))
+ {
+ al=SSL_AD_UNEXPECTED_MESSAGE;
+ SSLerr(SSL_F_SSL3_READ_BYTES,SSL_R_CCS_RECEIVED_EARLY);
+ goto f_err;
+ }
+
+ s->s3->flags &= ~SSL3_FLAGS_CCS_OK;
+
rr->length=0;
if (s->msg_callback)
@@ -1278,7 +1287,7 @@
if (s->s3->tmp.key_block == NULL)
{
- if (s->session == NULL)
+ if (s->session == NULL || s->session->master_key_length == 0)
{
/* might happen if dtls1_read_bytes() calls this */
SSLerr(SSL_F_SSL3_DO_CHANGE_CIPHER_SPEC,SSL_R_CCS_RECEIVED_EARLY);
Modified: stable/0.4/crypto/openssl/ssl/s3_srvr.c
===================================================================
--- stable/0.4/crypto/openssl/ssl/s3_srvr.c 2014-06-04 12:28:41 UTC (rev 6657)
+++ stable/0.4/crypto/openssl/ssl/s3_srvr.c 2014-06-06 00:11:23 UTC (rev 6658)
@@ -523,6 +523,7 @@
case SSL3_ST_SR_CERT_VRFY_A:
case SSL3_ST_SR_CERT_VRFY_B:
+ s->s3->flags |= SSL3_FLAGS_CCS_OK;
/* we should decide if we expected this one */
ret=ssl3_get_cert_verify(s);
if (ret <= 0) goto end;
@@ -533,6 +534,7 @@
case SSL3_ST_SR_FINISHED_A:
case SSL3_ST_SR_FINISHED_B:
+ s->s3->flags |= SSL3_FLAGS_CCS_OK;
ret=ssl3_get_finished(s,SSL3_ST_SR_FINISHED_A,
SSL3_ST_SR_FINISHED_B);
if (ret <= 0) goto end;
Modified: stable/0.4/crypto/openssl/ssl/ssl3.h
===================================================================
--- stable/0.4/crypto/openssl/ssl/ssl3.h 2014-06-04 12:28:41 UTC (rev 6657)
+++ stable/0.4/crypto/openssl/ssl/ssl3.h 2014-06-06 00:11:23 UTC (rev 6658)
@@ -344,6 +344,7 @@
* effected, but we can't prevent that.
*/
#define SSL3_FLAGS_SGC_RESTART_DONE 0x0040
+#define SSL3_FLAGS_CCS_OK 0x0080
typedef struct ssl3_state_st
{
Modified: stable/0.4/sys/conf/newvers.sh
===================================================================
--- stable/0.4/sys/conf/newvers.sh 2014-06-04 12:28:41 UTC (rev 6657)
+++ stable/0.4/sys/conf/newvers.sh 2014-06-06 00:11:23 UTC (rev 6658)
@@ -33,7 +33,7 @@
TYPE="MidnightBSD"
REVISION="0.4"
-BRANCH="RELEASE-p11"
+BRANCH="RELEASE-p12"
if [ "X${BRANCH_OVERRIDE}" != "X" ]; then
BRANCH=${BRANCH_OVERRIDE}
fi
More information about the Midnightbsd-cvs
mailing list