Fix RC4-MD5 based ciphersuites
authorMatt Caswell <matt@openssl.org>
Wed, 11 Nov 2020 11:07:12 +0000 (11:07 +0000)
committerMatt Caswell <matt@openssl.org>
Wed, 25 Nov 2020 10:14:43 +0000 (10:14 +0000)
commit6db0d58d815b84b44610471b71de1f259d00c166
treefb689e5678531a14ce1daf4e904ea2f7182b00f9
parent01c6551ce63005d65aa03edaa4c57d04438cc0d0
Fix RC4-MD5 based ciphersuites

The RC4-MD5 ciphersuites were not removing the length of the MAC when
calculating the length of decrypted TLS data. Since RC4 is a streamed
cipher that doesn't use padding we separate out the concepts of fixed
length TLS data to be removed, and TLS padding.

Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/13378)
providers/implementations/ciphers/cipher_aes_cbc_hmac_sha.c
providers/implementations/ciphers/cipher_aes_cbc_hmac_sha1_hw.c
providers/implementations/ciphers/cipher_aes_cbc_hmac_sha256_hw.c
providers/implementations/ciphers/cipher_rc4_hmac_md5_hw.c
providers/implementations/ciphers/ciphercommon.c
providers/implementations/include/prov/ciphercommon.h