forked from wolfSSL/wolfssl
allow NULL IVs for CBC mode, same as all zero IV
This commit is contained in:
@@ -2865,6 +2865,8 @@ int AesSetIV(Aes* aes, const byte* iv)
|
||||
|
||||
if (iv)
|
||||
XMEMCPY(aes->reg, iv, AES_BLOCK_SIZE);
|
||||
else
|
||||
XMEMSET(aes->reg, 0, AES_BLOCK_SIZE);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user