X-Git-Url: https://git.openssl.org/gitweb/?p=openssl.git;a=blobdiff_plain;f=crypto%2Fdes%2Fede_cbcm_enc.c;h=caaf6daccec624a47d1d0efec0f670c5a2c36cd8;hp=10ffcbc72963661139caef754c433c1a262f1cee;hb=a8da89186c447932b9f5abced708330a3bff313b;hpb=4e31df2cd73dbb659fd8a6eca6270fac661c072d diff --git a/crypto/des/ede_cbcm_enc.c b/crypto/des/ede_cbcm_enc.c index 10ffcbc729..caaf6dacce 100644 --- a/crypto/des/ede_cbcm_enc.c +++ b/crypto/des/ede_cbcm_enc.c @@ -61,16 +61,25 @@ This is an implementation of Triple DES Cipher Block Chaining with Output Feedback Masking, by Coppersmith, Johnson and Matyas, (IBM and Certicom). +Note that there is a known attack on this by Biham and Knudsen but it takes +a lot of work: + +http://www.cs.technion.ac.il/users/wwwb/cgi-bin/tr-get.cgi/1998/CS/CS0928.ps.gz + */ #include "des_locl.h" -void des_ede3_cbcm_encrypt(const unsigned char *in,unsigned char *out, - long length, - des_key_schedule ks1,des_key_schedule ks2, - des_key_schedule ks3, - des_cblock ivec1,des_cblock ivec2, - int enc) +void des_ede3_cbcm_encrypt(in, out, length, ks1, ks2, ks3, ivec1, ivec2, enc) +const unsigned char *in; +unsigned char *out; +long length; +des_key_schedule ks1; +des_key_schedule ks2; +des_key_schedule ks3; +des_cblock ivec1; +des_cblock ivec2; +int enc; { register DES_LONG tin0,tin1; register DES_LONG tout0,tout1,xor0,xor1,m0,m1;