Closed yoursunny closed 4 years ago
I tested this piece of code with input array 04 04 04 04 04 04
and got 04 04 04 04 04 04 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A
. It seems fulfill the requirement. Wonder what's wrong with it?
Try an input length that is a multiple of 16 octets. Compare to the results at https://play.golang.org/p/hxyB-O8ARk-
According to PKCS Padding Method:
The currently implementation is incorrect: it does not fulfill the first rule.
https://github.com/named-data-iot/ndn-lite/blob/d60a114a4c4e8422577ab8ae3817f79eed948254/security/default-backend/ndn-lite-default-aes-impl.c#L26-L41