IV Property
The initialization vector (IV) used when encrypting.
Syntax
QByteArray GetIV();
int SetIV(QByteArray qbaIV);
Default Value
""
Remarks
This property optionally specifies an IV to be used when calling Encrypt or Decrypt. If specified the IV is used by EncryptionAlgorithm during encryption.
If not specified the class will create an IV filled with null bytes (zeros). Since the encryption key is only used once the use of null bytes in the IV is considered acceptable and is a standard practice.
The length of the IV should be as follows:
EncryptionAlgorithm | IV Length (in bytes) |
AES | 16 |
3DES | 8 |
This setting is not applicable when EncryptionAlgorithm is set to XOR.
Data Type
Byte Array