-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added test vectors with AES in CBC mode #372
Conversation
Signed-off-by: Pawel Osypiuk <pawelosyp@gmail.com>
May I know the purpose of using the 'ARCH_TEST_CBC_NO_PADDING' macro guard in Test-3 and 4 test-data? |
@avinaw01-arm Looks like you are right, I have used the wrong macro - changed as you suggested. |
In file 'api-tests/dev_apis/crypto/test_c018/test_data.h', may I know your intention behind using the below changes?
From my understanding, for that particular test-data which you're targeting to change algorithm for, it doesn't matter whether it's in CTR or CBC mode. It is going to fail, as we are intentionally giving incorrect algorithm. So, my suggestion would be to keep 'PSA_ALG_CTR' algorithm as it is for this particular data-set. |
Our current implementation does not support |
Fine, let's come to a middle solution. Instead of using all that defines, can you just change the 'algorithm' value for that data-set? You may keep that value anything other than the compatible ones for that key-type. |
Also, please update the Copyright header year to 2024 like this: "Copyright (c) 20XX-2024" for the following files:
|
I can see in the data-sets of Test-3 and 4 which you have requested, have exactly identical parameters from their previous data-sets for CTR mode. Please don't replicate that; instead give an OR option while checking the macro-guards for CTR or CBC mode. Kindly make sure to incorporate this in your commit. |
Also, Test descriptions for many data-sets are coming identical while running the regressions. For example, in file 'api-tests/dev_apis/crypto/test_c032/test_data.h': " |
@avinaw01-arm all your comments are reworked, good catch to combine test vectors in Test-3 and 4. |
Thank you. |
Current test vectors have some lack of the AES in CBC mode. For us, it is impossible to pass the tests because for the time being our platform supports only AES in CBC and no CTR mode.
This PR introduces test vectors of AES in CBC mode and allows to define the failing algorithm for HKDF (currently it was
PSA_ALG_CTR
). All modifications are related to unsupportedPSA_ALG_CTR
.