开发者

how to generate initial vector for counter mode of encryption

开发者 https://www.devze.com 2023-01-10 07:25 出处:网络
i am implementing CTR mode of encryption using AES. i want know how to generate开发者_Go百科 initial vectors(counter blocks) for this mode.You should generate random IV, and after that increment it wi

i am implementing CTR mode of encryption using AES. i want know how to generate开发者_Go百科 initial vectors(counter blocks) for this mode.


You should generate random IV, and after that increment it with each new block, like 16-byte integer. Also, as far as I remember, some specifications use zero IV for CTR mode.

0

精彩评论

暂无评论...
验证码 换一张
取 消