mirror of
https://github.com/openssl/openssl.git
synced 2025-01-06 13:26:43 +08:00
90409da6a5
Fixes #12405 Fixes #12377 Calling Init()/Update() and then Init()/Update() again gave a different result when using the same key and iv. Cipher modes that were using ctx->num were not resetting this value, this includes OFB, CFB & CTR. The fix is to reset this value during the ciphers einit() and dinit() methods. Most ciphers go thru a generic method so one line fixes most cases. Add test for calling EVP_EncryptInit()/EVP_EncryptUpdate() multiple times for all ciphers. Ciphers should return the same value for both updates. DES3-WRAP does not since it uses a random in the update. CCM modes currently also fail on the second update (This also happens in 1_1_1). Fix memory leak in AES_OCB cipher if EVP_EncryptInit is called multiple times. Fix AES_SIV cipher dup_ctx and init. Calling EVP_CIPHER_init multiple times resulted in a memory leak in the siv. Fixing this leak also showed that the dup ctx was not working for siv mode. Note: aes_siv_cleanup() can not be used by aes_siv_dupctx() as it clears data that is required for the decrypt (e.g the tag). Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org> (Merged from https://github.com/openssl/openssl/pull/12413) |
||
---|---|---|
.. | ||
__DECC_INCLUDE_EPILOGUE.H | ||
__DECC_INCLUDE_PROLOGUE.H | ||
aes_platform.h | ||
aria.h | ||
asn1_dsa.h | ||
asn1.h | ||
async.h | ||
bn_conf.h.in | ||
bn_dh.h | ||
bn_srp.h | ||
bn.h | ||
chacha.h | ||
cmll_platform.h | ||
cms.h | ||
cryptlib.h | ||
ctype.h | ||
des_platform.h | ||
dh.h | ||
dsa.h | ||
dso_conf.h.in | ||
ec.h | ||
ecx.h | ||
engine.h | ||
err.h | ||
ess.h | ||
evp.h | ||
lhash.h | ||
md32_common.h | ||
modes.h | ||
objects.h | ||
poly1305.h | ||
rand.h | ||
rsa.h | ||
security_bits.h | ||
serializer.h | ||
sha.h | ||
siphash.h | ||
siv.h | ||
sm2.h | ||
sm2err.h | ||
sm4.h | ||
sparse_array.h | ||
store.h | ||
x509.h | ||
x509v3.h |