mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-07-07 05:10:48 +02:00
F-5632: zeroize Camellia key schedule on cipher free
FreeCiphersSide freed cipher->cam with XFREE only, leaving the expanded key schedule and IV in freed heap memory. Call wc_CamelliaFree (which ForceZeros the context) before XFREE, matching the ARIA cleanup above.
This commit is contained in:
@@ -3282,6 +3282,7 @@ static void FreeCiphersSide(Ciphers *cipher, void* heap)
|
||||
cipher->aria = NULL;
|
||||
#endif
|
||||
#ifdef HAVE_CAMELLIA
|
||||
wc_CamelliaFree(cipher->cam);
|
||||
XFREE(cipher->cam, heap, DYNAMIC_TYPE_CIPHER);
|
||||
cipher->cam = NULL;
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user