Hi: This test case in ajtest keeps failing and I am looking for some further info:
*TEST_F(CompatibleCredentialAccessorTest, LoadOldFormat) * *in alljoyn_core/unit_test/CredentialAccessorTest.cc: 616 * This happens while I am tackling "ASACORE-3491 <https://jira.allseenalliance.org/browse/ASACORE-3491>". One of the reason AllJoyn wouldn't build against OpenSSL-1.1.0 is that it no longer has AES_ctr128_encrypt API available in aes.h, so I am changing our Crypto_AES's encrypt and decrypt functions to use EVP APIs. The SetUp() function of the above test fixture would use Crypto_AES::Decrypt_CCM to decrypt the "Rev0X103KeyStore[]" str after it is Base64Decoded. The Decrypt_CCM would fail because in the end the computed Tag does not match the last 16 bytes in the input(cyphertext) string. With the new EVP Api-based implementation, the Tag data is obtained and used as follows: 1. In encryption, allocate a buffer, then specify the length for Tag data via EVP Api; 2. Complete the encryption from plaintext to ciphertext in CCM mode; 3. Obtain the Tag data via EVP Api through EVP Cipher context; 4. Append the Tag data to the end of the ciphertext. In CCM Decryption, the process is reversed: Tag should be expected at the end of the ciphertext input, it is fed together with its length to CTX via EVP APIs before Decryption starts, then in the end, EVP_Decryption would check against this Tag data with the computed one during the Decryption process to verify authentication. This implementation is passing all ajctest and cmtest, including all the 26 items in AES_CCM_Test_Vecter. I am wondering what's changed since KeyStore Rev103, and where can I find more information about it? In KeyStore.cc, there are some comments regarding "key store version 0x103 or older... the Decryption would fail". I am wondering if I ran into this problem. Thanks, Vincent
_______________________________________________ Alljoyn-core mailing list Alljoyn-core@lists.alljoyn.org https://lists.alljoyn.org/mailman/listinfo/alljoyn-core