After the improvements in the openssl error handling in the key-manager
module, error codes are now more precise. Currently, in case of wrong
ciphertext, CKM_API_ERROR_INPUT_PARAM is returned, which is translated
to ArgumentException in the csapi.
Change-Id: I293045176c6c798aa11b9e6aa9b85d42a5a7a463
KeyManager.CreateAesKey(256, aesKeyAlias, new Policy(password, false));
/* TEST CODE */
- Assert.Throws<InvalidOperationException>(delegate {
+ Assert.Throws<ArgumentException>(delegate {
cipher.Decrypt(aesKeyAlias, password, Util.GenerateRandom(1024));
});