Re: [opencryptoki-users] testcase failing - AES
Brought to you by:
ebarretto
From: Kent Y. <shp...@gm...> - 2007-01-23 17:43:57
|
Hi Conor, First off, the testcases included with the opencryptoki 2.2.4 tarball are very old. The ones in CVS head should be used. Their build has been tied in with the rest of opencryptoki, and they support pulling the user and SO pins from environment variables (PKCS11_USER_PIN and PKCS11_SO_PIN), which makes running them much easier. Sorry about that. Next, when I comment out the 'return TRUE;' in aes_func.c in the driver directory, which seems to be short circuiting the AES tests, the CBC AES test fails, since a NULL template is being passed in to create the AES key in that case. Looking through these tests, I found 4 general problems: invalid key creation templates, invalid IV sizes, invalid key unwrapping templates and invalid buffer sizes for decrypt operations. I've now fixed these problems and made the AES tests run by default, the fixed code is in CVS. I didn't run into the error you got above, though. Can you tell me if you still get that problem using the CVS testcases? Thanks, Kent On 1/15/07, conor fitzgerald <bou...@ho...> wrote: > Hello > When runnning the aes_func test in testcases/v2.11/ i get the folllowing > error > > do_EncryptAES_ECB... > Looks okay... > Time: 2 msec > do_EncryptAES_CBC... > Looks okay... > Time: 1 msec > do_EncryptAES_Multipart_ECB... > Looks okay... > Time: 2 msec > do_EncryptAES_Multipart_CBC... > Looks okay... > Time: 2 msec > do_EncryptAES_Multipart_CBC_PAD... > Looks okay... > Time: 2 msec > do_WrapUnwrapAES_ECB... > aes_func.c line 1218 Error: C_UnWrapKey #1 returned: 112 > CKR_MECHANISM_INVALID > > All the other tests seem to work fine in this file(when i block out the > WrapUnwrapAes_ECB test) > Has anyone else got this error,any suggestions? > > Also when i run driver testcases in testcases/driver only one function > do_encryptAES_ECB from aes_func is called(when i unblocked the return true > in the main section of aes_func ,a lot oferrors were returned),i assume this > due to above v2.11 aes_func is the deault tests now. > > Conor > > _________________________________________________________________ > The MSN Entertainment Guide to Golden Globes is here. Get all the scoop. > http://tv.msn.com/tv/globes2007/?icid=nctagline2 > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > opencryptoki-users mailing list > ope...@li... > https://lists.sourceforge.net/lists/listinfo/opencryptoki-users > -- Kent Yoder IBM LTC Security Dev. |