[openssl-commits] [openssl] OpenSSL_1_1_0-stable update

Andy Polyakov appro at openssl.org
Wed Mar 22 10:10:36 UTC 2017


The branch OpenSSL_1_1_0-stable has been updated
       via  1371be1500a218d26c19c2f61239a5e0262cbf4f (commit)
      from  09de9f0435790eefc082253609c8ef0ed66f8233 (commit)


- Log -----------------------------------------------------------------
commit 1371be1500a218d26c19c2f61239a5e0262cbf4f
Author: Andy Polyakov <appro at openssl.org>
Date:   Mon Mar 20 12:47:08 2017 +0100

    modes/ocb128.c: fix misaligned access in ILP32 builds on 64-bit processors.
    
    One could have fixed the problem by arranging 64-bit alignment of
    EVP_AES_OCB_CTX.aad_buf in evp/e_aes.c, but CRYPTO_ocb128_aad
    prototype doesn't imply alignment and we have to honour it.
    
    Reviewed-by: Rich Salz <rsalz at openssl.org>
    (Merged from https://github.com/openssl/openssl/pull/2994)
    
    (cherry picked from commit a2bb183623dac253792753b82e291fd1d180aa78)

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

Summary of changes:
 crypto/modes/ocb128.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/crypto/modes/ocb128.c b/crypto/modes/ocb128.c
index c3bd13b..f6f8da7 100644
--- a/crypto/modes/ocb128.c
+++ b/crypto/modes/ocb128.c
@@ -294,7 +294,7 @@ int CRYPTO_ocb128_aad(OCB128_CONTEXT *ctx, const unsigned char *aad,
 
         /* Sum_i = Sum_{i-1} xor ENCIPHER(K, A_i xor Offset_i) */
         aad_block = (OCB_BLOCK *)(aad + ((i - ctx->blocks_hashed - 1) * 16));
-        ocb_block16_xor(&ctx->offset_aad, aad_block, &tmp1);
+        ocb_block16_xor_misaligned(&ctx->offset_aad, aad_block, &tmp1);
         ctx->encrypt(tmp1.c, tmp2.c, ctx->keyenc);
         ocb_block16_xor(&ctx->sum, &tmp2, &ctx->sum);
     }


More information about the openssl-commits mailing list