unsigned char *dst, SilcUInt32 len,
unsigned char *iv)
{
- return cipher->cipher->encrypt(cipher->context, src, dst, len, iv);
+ return cipher->cipher->encrypt(cipher->context, src, dst, len,
+ iv ? iv : cipher->iv);
}
/* Decrypts */
unsigned char *dst, SilcUInt32 len,
unsigned char *iv)
{
- return cipher->cipher->decrypt(cipher->context, src, dst, len, iv);
+ return cipher->cipher->decrypt(cipher->context, src, dst, len,
+ iv ? iv : cipher->iv);
}
/* Sets the key for the cipher */