+Sat May 18 01:49:33 1996 Theodore Y. Ts'o <tytso@mit.edu>
+
+ * md5crypto.c: Define MD5_K5BETA_COMPAT and MD5_K5BETA_COMP_DEF so
+ that we continue doing things the wrong (broken) way. All
+ hail backwards compatibility.... The code now generates
+ the old checksum, but it will verify both the old and the
+ correct checksum formats.
+
+ Also fixed two bugs in the "correct" MD5_CRYPTO
+ implementation; use a zero initialization vector, and
+ calculate the confounder at the beginning of the message,
+ not at the end.
+
Tue May 14 19:32:51 1996 Richard Basch <basch@lehman.com>
* md5crypto.c md5glue.c:
krb5_md5_crypto_verify_func PROTOTYPE((krb5_checksum FAR *cksum, krb5_pointer in,
size_t in_length, krb5_pointer seed, size_t seed_length));
+static mit_des_cblock zero_ivec = { 0 };
+
/*
* In Kerberos V5 Beta 5 and previous releases the RSA-MD5-DES implementation
* did not follow RFC1510. The folowing definitions control the compatibility
* the compatible behaviour becomes the default.
*
*/
+#define MD5_K5BETA_COMPAT
+#define MD5_K5BETA_COMPAT_DEF
static void
-krb5_md5_calculate_cksum(md5ctx, in, in_length, confound, confound_length)
+krb5_md5_calculate_cksum(md5ctx, confound, confound_length, in, in_length)
krb5_MD5_CTX *md5ctx;
krb5_pointer in;
size_t in_length;
RSA_MD5_DES_CKSUM_LENGTH +
RSA_MD5_DES_CONFOUND_LENGTH,
(struct mit_des_ks_struct *)eblock.priv,
- keyblock.contents,
+ zero_ivec,
MIT_DES_ENCRYPT);
if (retval) {
(void) mit_des_finish_key(&eblock);
RSA_MD5_DES_CONFOUND_LENGTH,
(struct mit_des_ks_struct *)
eblock.priv,
- keyblock.contents,
+ zero_ivec,
MIT_DES_DECRYPT);
if (retval) {
(void) mit_des_finish_key(&eblock);