Topic: [SOLVED] one problem from wc_CmacFinal() function
Hi,
In this function, there is one judgment which list below:
if (outSz != NULL && *outSz < AES_BLOCK_SIZE)
return BUFFER_E;
Why here muse adjust *outSz should great than AES_BLOCK_SIZE??
Normally, if define one variable for store output CMAC size, and initialzie it as 0. then call this function, it will return FAIL ! (BUFFER_E)
actually, at the end of this function, function will put real CMAC output szie to *outSz, so I can't understand why we need to adjust *outSz must great than AES_BLOCK_SIZE???
maybe, the author want caller to assign a actual output CMAC size, but I don't think it is necessary. Because AES key size will decide the output CMAC size (like 128 or 256).
what's your opion??