switch to the DES_ api, dont provide any compat glue
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12748 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -58,12 +58,12 @@
|
||||
|
||||
#include "des_locl.h"
|
||||
|
||||
void des_ncbc_encrypt(input, output, length, schedule, ivec, encrypt)
|
||||
des_cblock (*input);
|
||||
des_cblock (*output);
|
||||
void DES_ncbc_encrypt(input, output, length, schedule, ivec, encrypt)
|
||||
DES_cblock (*input);
|
||||
DES_cblock (*output);
|
||||
long length;
|
||||
des_key_schedule schedule;
|
||||
des_cblock (*ivec);
|
||||
DES_key_schedule *schedule;
|
||||
DES_cblock (*ivec);
|
||||
int encrypt;
|
||||
{
|
||||
register DES_LONG tin0,tin1;
|
||||
@@ -87,7 +87,7 @@ int encrypt;
|
||||
c2l(in,tin1);
|
||||
tin0^=tout0; tin[0]=tin0;
|
||||
tin1^=tout1; tin[1]=tin1;
|
||||
des_encrypt((DES_LONG *)tin,schedule,DES_ENCRYPT);
|
||||
DES_encrypt((DES_LONG *)tin,schedule,DES_ENCRYPT);
|
||||
tout0=tin[0]; l2c(tout0,out);
|
||||
tout1=tin[1]; l2c(tout1,out);
|
||||
}
|
||||
@@ -96,7 +96,7 @@ int encrypt;
|
||||
c2ln(in,tin0,tin1,l+8);
|
||||
tin0^=tout0; tin[0]=tin0;
|
||||
tin1^=tout1; tin[1]=tin1;
|
||||
des_encrypt((DES_LONG *)tin,schedule,DES_ENCRYPT);
|
||||
DES_encrypt((DES_LONG *)tin,schedule,DES_ENCRYPT);
|
||||
tout0=tin[0]; l2c(tout0,out);
|
||||
tout1=tin[1]; l2c(tout1,out);
|
||||
}
|
||||
@@ -112,7 +112,7 @@ int encrypt;
|
||||
{
|
||||
c2l(in,tin0); tin[0]=tin0;
|
||||
c2l(in,tin1); tin[1]=tin1;
|
||||
des_encrypt((DES_LONG *)tin,schedule,DES_DECRYPT);
|
||||
DES_encrypt((DES_LONG *)tin,schedule,DES_DECRYPT);
|
||||
tout0=tin[0]^xor0;
|
||||
tout1=tin[1]^xor1;
|
||||
l2c(tout0,out);
|
||||
@@ -124,7 +124,7 @@ int encrypt;
|
||||
{
|
||||
c2l(in,tin0); tin[0]=tin0;
|
||||
c2l(in,tin1); tin[1]=tin1;
|
||||
des_encrypt((DES_LONG *)tin,schedule,DES_DECRYPT);
|
||||
DES_encrypt((DES_LONG *)tin,schedule,DES_DECRYPT);
|
||||
tout0=tin[0]^xor0;
|
||||
tout1=tin[1]^xor1;
|
||||
l2cn(tout0,tout1,out,l+8);
|
||||
|
Reference in New Issue
Block a user