#ifndef DES_DEFAULT_OPTIONS
void des_ncbc_encrypt(const unsigned char *in, unsigned char *out, long length,
- des_key_schedule schedule, des_cblock ivec, int enc)
+ des_key_schedule schedule, des_cblock *ivec, int enc)
{
register DES_LONG tin0,tin1;
register DES_LONG tout0,tout1,xor0,xor1;
DES_LONG tin[2];
unsigned char *iv;
- iv=ivec;
+ iv = &(*ivec)[0];
if (enc)
{
tout0=tin[0]; l2c(tout0,out);
tout1=tin[1]; l2c(tout1,out);
}
- iv=ivec;
+ iv = &(*ivec)[0];
l2c(tout0,iv);
l2c(tout1,iv);
}
xor1=tin1;
}
- iv=ivec;
+ iv = &(*ivec)[0];
l2c(xor0,iv);
l2c(xor1,iv);
}
void des_ede3_cbc_encrypt(const unsigned char *input, unsigned char *output,
long length, des_key_schedule ks1, des_key_schedule ks2,
- des_key_schedule ks3, des_cblock ivec, int enc)
+ des_key_schedule ks3, des_cblock *ivec, int enc)
{
register DES_LONG tin0,tin1;
register DES_LONG tout0,tout1,xor0,xor1;
in=input;
out=output;
- iv=ivec;
+ iv = &(*ivec)[0];
if (enc)
{
l2c(tout0,out);
l2c(tout1,out);
}
- iv=ivec;
+ iv = &(*ivec)[0];
l2c(tout0,iv);
l2c(tout1,iv);
}
xor1=t1;
}
- iv=ivec;
+ iv = &(*ivec)[0];
l2c(xor0,iv);
l2c(xor1,iv);
}