summaryrefslogtreecommitdiffstats
path: root/crypto/openssl/ssl/d1_both.c
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2014-01-07 19:58:45 +0000
committerdelphij <delphij@FreeBSD.org>2014-01-07 19:58:45 +0000
commit106d50295b278845242fffccba73ac39f8cc971f (patch)
tree0804b5ed749774647623171c59cc54c7c96f1e41 /crypto/openssl/ssl/d1_both.c
parent207475f6fd4dbccf6c2c65b978e694628a858ae8 (diff)
downloadFreeBSD-src-106d50295b278845242fffccba73ac39f8cc971f.zip
FreeBSD-src-106d50295b278845242fffccba73ac39f8cc971f.tar.gz
MFV r260399:
Apply vendor commits: 197e0ea Fix for TLS record tampering bug. (CVE-2013-4353). 3462896 For DTLS we might need to retransmit messages from the previous session so keep a copy of write context in DTLS retransmission buffers instead of replacing it after sending CCS. (CVE-2013-6450). ca98926 When deciding whether to use TLS 1.2 PRF and record hash algorithms use the version number in the corresponding SSL_METHOD structure instead of the SSL structure. The SSL structure version is sometimes inaccurate. Note: OpenSSL 1.0.2 and later effectively do this already. (CVE-2013-6449). Security: CVE-2013-4353 Security: CVE-2013-6449 Security: CVE-2013-6450
Diffstat (limited to 'crypto/openssl/ssl/d1_both.c')
-rw-r--r--crypto/openssl/ssl/d1_both.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/crypto/openssl/ssl/d1_both.c b/crypto/openssl/ssl/d1_both.c
index de8bab8..4c8c77f 100644
--- a/crypto/openssl/ssl/d1_both.c
+++ b/crypto/openssl/ssl/d1_both.c
@@ -214,6 +214,12 @@ dtls1_hm_fragment_new(unsigned long frag_len, int reassembly)
static void
dtls1_hm_fragment_free(hm_fragment *frag)
{
+
+ if (frag->msg_header.is_ccs)
+ {
+ EVP_CIPHER_CTX_free(frag->msg_header.saved_retransmit_state.enc_write_ctx);
+ EVP_MD_CTX_destroy(frag->msg_header.saved_retransmit_state.write_hash);
+ }
if (frag->fragment) OPENSSL_free(frag->fragment);
if (frag->reassembly) OPENSSL_free(frag->reassembly);
OPENSSL_free(frag);
OpenPOWER on IntegriCloud