[openssl-commits] [openssl] master update

Rich Salz rsalz at openssl.org
Fri Dec 11 19:48:49 UTC 2015


The branch master has been updated
       via  777f482d993322d69025014bf1b99c270c978fc0 (commit)
      from  94d61512360c4d16762a13e27fcad39ca4f5e506 (commit)


- Log -----------------------------------------------------------------
commit 777f482d993322d69025014bf1b99c270c978fc0
Author: Rich Salz <rsalz at akamai.com>
Date:   Fri Dec 11 14:48:09 2015 -0500

    Allow ChaCha20-Poly1305 in DTLS
    
    GCM and CCM are modes of operation for block ciphers only. ChaCha20-Poly1305
    operates in neither of them but it is AEAD. This change also enables future
    AEAD ciphers to be available for use with DTLS.
    
    Signed-off-by: Rich Salz <rsalz at akamai.com>
    Reviewed-by: Matt Caswell <matt at openssl.org>

-----------------------------------------------------------------------

Summary of changes:
 ssl/statem/statem_dtls.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ssl/statem/statem_dtls.c b/ssl/statem/statem_dtls.c
index 5194c73..258c6fc 100644
--- a/ssl/statem/statem_dtls.c
+++ b/ssl/statem/statem_dtls.c
@@ -235,8 +235,8 @@ int dtls1_do_write(SSL *s, int type)
 
     if (s->write_hash) {
         if (s->enc_write_ctx
-            && ((EVP_CIPHER_CTX_mode(s->enc_write_ctx) == EVP_CIPH_GCM_MODE) ||
-                (EVP_CIPHER_CTX_mode(s->enc_write_ctx) == EVP_CIPH_CCM_MODE)))
+            && (EVP_CIPHER_CTX_flags(s->enc_write_ctx) &
+                EVP_CIPH_FLAG_AEAD_CIPHER) != 0)
             mac_size = 0;
         else
             mac_size = EVP_MD_CTX_size(s->write_hash);


More information about the openssl-commits mailing list