IV Property
The initialization vector (IV).
Syntax
ANSI (Cross Platform) int GetIV(char* &lpIV, int &lenIV);
int SetIV(const char* lpIV, int lenIV); Unicode (Windows) INT GetIV(LPSTR &lpIV, INT &lenIV);
INT SetIV(LPCSTR lpIV, INT lenIV);
@property (nonatomic,readwrite,assign,getter=IV,setter=setIV:) NSString* IV; - (NSString*)IV; - (void)setIV:(NSString*)newIV;
@property (nonatomic,readwrite,assign,getter=IVB,setter=setIVB:) NSData* IVB; - (NSData*)IVB; - (void)setIVB:(NSData*)newIV;
#define PID_SALSA20_IV 4 IPWORKSENCRYPT_EXTERNAL void* IPWORKSENCRYPT_CALL IPWorksEncrypt_Salsa20_Get(void *lpObj, int propid, int arridx, int *lpcbVal, int64 *lpllVal); IPWORKSENCRYPT_EXTERNAL int IPWORKSENCRYPT_CALL IPWorksEncrypt_Salsa20_Set(void *lpObj, int propid, int arridx, const void *val, int cbVal);
Default Value
""
Remarks
This property specifies the initialization vector (IV). This is also referred to as the nonce. By default this property is empty and the class will automatically generate a new IV value if KeyPassword or Key is set before Encrypt or EncryptBlock is called.
XSalsa Notes:
When Algorithm is set to XSalsa the length of the IV must be 192 bits in length (24 bytes).
Salsa Notes:
When Algorithm is set to Salsa the length of the IV must be 64 bits in length (8 bytes).
Data Type
Binary String