mirror of https://github.com/wolfSSL/wolfssl.git
add sanity check on des cbc decrypt, CID 512990
parent
f96e493790
commit
6f1fe2e4b9
|
@ -1742,6 +1742,10 @@
|
|||
{
|
||||
word32 blocks = sz / DES_BLOCK_SIZE;
|
||||
|
||||
if (des == NULL || out == NULL || in == NULL) {
|
||||
return BAD_FUNC_ARG;
|
||||
}
|
||||
|
||||
while (blocks--) {
|
||||
XMEMCPY(des->tmp, in, DES_BLOCK_SIZE);
|
||||
DesProcessBlock(des, (byte*)des->tmp, out);
|
||||
|
|
Loading…
Reference in New Issue