diff options
author | Ben Laurie <ben@openssl.org> | 2001-07-30 17:46:22 +0000 |
---|---|---|
committer | Ben Laurie <ben@openssl.org> | 2001-07-30 17:46:22 +0000 |
commit | 3ba5d1cf2eb6ef28ac5f6d9f3d28020d00c5be50 (patch) | |
tree | 73d3b6e7e2ee0ce832943a1e080501b8a96c40d6 /crypto/des/ncbc_enc.c | |
parent | be2e2c32972e421ecc78bb79b502cb9d76d0c391 (diff) | |
download | openssl-3ba5d1cf2eb6ef28ac5f6d9f3d28020d00c5be50.zip openssl-3ba5d1cf2eb6ef28ac5f6d9f3d28020d00c5be50.tar.gz openssl-3ba5d1cf2eb6ef28ac5f6d9f3d28020d00c5be50.tar.bz2 |
Make EVPs allocate context memory, thus making them extensible. Rationalise
DES's keyschedules.
I know these two should be separate, and I'll back out the DES changes if they
are deemed to be an error.
Note that there is a memory leak lurking in SSL somewhere in this version.
Diffstat (limited to 'crypto/des/ncbc_enc.c')
-rw-r--r-- | crypto/des/ncbc_enc.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/crypto/des/ncbc_enc.c b/crypto/des/ncbc_enc.c index b8db07b..6be5184 100644 --- a/crypto/des/ncbc_enc.c +++ b/crypto/des/ncbc_enc.c @@ -65,10 +65,10 @@ #ifdef CBC_ENC_C__DONT_UPDATE_IV void des_cbc_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) #else 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) #endif { register DES_LONG tin0,tin1; @@ -89,7 +89,7 @@ void des_ncbc_encrypt(const unsigned char *in, unsigned char *out, long length, c2l(in,tin1); tin0^=tout0; tin[0]=tin0; tin1^=tout1; tin[1]=tin1; - des_encrypt1((DES_LONG *)tin,schedule,DES_ENCRYPT); + des_encrypt1((DES_LONG *)tin,_schedule,DES_ENCRYPT); tout0=tin[0]; l2c(tout0,out); tout1=tin[1]; l2c(tout1,out); } @@ -98,7 +98,7 @@ void des_ncbc_encrypt(const unsigned char *in, unsigned char *out, long length, c2ln(in,tin0,tin1,l+8); tin0^=tout0; tin[0]=tin0; tin1^=tout1; tin[1]=tin1; - des_encrypt1((DES_LONG *)tin,schedule,DES_ENCRYPT); + des_encrypt1((DES_LONG *)tin,_schedule,DES_ENCRYPT); tout0=tin[0]; l2c(tout0,out); tout1=tin[1]; l2c(tout1,out); } @@ -116,7 +116,7 @@ void des_ncbc_encrypt(const unsigned char *in, unsigned char *out, long length, { c2l(in,tin0); tin[0]=tin0; c2l(in,tin1); tin[1]=tin1; - des_encrypt1((DES_LONG *)tin,schedule,DES_DECRYPT); + des_encrypt1((DES_LONG *)tin,_schedule,DES_DECRYPT); tout0=tin[0]^xor0; tout1=tin[1]^xor1; l2c(tout0,out); @@ -128,7 +128,7 @@ void des_ncbc_encrypt(const unsigned char *in, unsigned char *out, long length, { c2l(in,tin0); tin[0]=tin0; c2l(in,tin1); tin[1]=tin1; - des_encrypt1((DES_LONG *)tin,schedule,DES_DECRYPT); + des_encrypt1((DES_LONG *)tin,_schedule,DES_DECRYPT); tout0=tin[0]^xor0; tout1=tin[1]^xor1; l2cn(tout0,tout1,out,l+8); |