Home > other >  DES and AES encryption algorithm, there is a need to set the IV, excuse me what is the use the IV, d
DES and AES encryption algorithm, there is a need to set the IV, excuse me what is the use the IV, d

Time:10-08

That's DES and AES symmetric encryption algorithms, is only one secret key key, made no mention of the iv, I learn it is the initial vector sequence code,
But in c # program, there are IV des encryption algorithm, could you tell me what the IV role? Specific how to participate in the operation?

CodePudding user response:

Using random Numbers produced by the initialization vector to achieve semantic security (hash function and also have the same request message authentication code), and makes it hard for an attacker to cipher text for the same key to them

The initialization vector value depends on the cipher algorithm, the most basic requirement is the "uniqueness", that is to say the same keys do not reuse the same initialization vector, the feature both in block or stream encryption is very important,

Example: the clear stream encryption, P do convert ciphertext C, is used by key K, it comes from a secret key and initialization vector, we can get the equation: C=P xor K, if an attacker ciphertext C1 and C2 came from the same key and initial vector, then the attacker can be obtained by formula under the clear P1 and P2:

C1 xor C2=(P1 xor K) xor (P2 xor K)=P1 xor P2.

https://zh.wikipedia.org/wiki/%E5%88%9D%E5%A7%8B%E5%90%91%E9%87%8F
  • Related