You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It looks like the iv is discarded for CKM_AES_CBC wrap implementation; An IV = 0 seems to be always be used, regardless of input. So, as in the example here https://github.com/gshaurya18/aes_cbc_test/blob/main/src/main.rs#L122 performing wrap on the same payload with the same wrapping key but different Initialization vectors yields the same result. Is this expected?
Hello,
It looks like the
iv
is discarded forCKM_AES_CBC
wrap implementation; An IV = 0 seems to be always be used, regardless of input. So, as in the example here https://github.com/gshaurya18/aes_cbc_test/blob/main/src/main.rs#L122 performing wrap on the same payload with the same wrapping key but different Initialization vectors yields the same result. Is this expected?Is the implementation missing to set the
blocksize
to 16 here https://github.com/softhsm/SoftHSMv2/blob/develop/src/lib/SoftHSM.cpp#L6296, causing us to not copy over any bytes from the input iv https://github.com/softhsm/SoftHSMv2/blob/develop/src/lib/SoftHSM.cpp#L6333?There also seems to be a similar issue for
CKM_DES3_CBC
whereblocksize
is not set to 8 https://github.com/softhsm/SoftHSMv2/blob/develop/src/lib/SoftHSM.cpp#L6295Steps to reproduce:
Reference: https://www.cryptsoft.com/pkcs11doc/v211/group__SEC__12__19__3__AES__CBC.html, RFC: https://datatracker.ietf.org/doc/html/rfc3394#section-2.2.1
The text was updated successfully, but these errors were encountered: