+Thu Mar 21 20:33:43 1996 Richard Basch <basch@lehman.com>
+
+ * kadm_funcs.c: new principals were being created with two keys,
+ one of which the key_data_ver=0 and had no valid data.
+
Tue Mar 19 19:42:37 1996 Richard Basch <basch@lehman.com>
* kadm_funcs.c: changed all references of des-cbc-md5 to des-cbc-crc
kdatap = &entry->key_data[entry->n_key_data-1];
}
if (kdatap) {
+ kdatap->key_data_ver = 2;
kdatap->key_data_type[0] = (krb5_int16) ENCTYPE_DES_CBC_CRC;
kdatap->key_data_type[1] = (krb5_int16) KRB5_KDB_SALTTYPE_V4;
kdatap->key_data_kvno = (krb5_int16) princ.key_version;
if ((newpw.contents = (krb5_octet *)malloc(8)) == NULL)
failadd(KADM_NOMEM);
- if (retval = krb5_dbe_find_enctype(kadm_context,
- &newentry,
- ENCTYPE_DES_CBC_CRC,
- KRB5_KDB_SALTTYPE_V4,
- -1,
- &pkey)) {
- if (!(retval = krb5_dbe_create_key_data(kadm_context, &newentry)))
- pkey = &newentry.key_data[newentry.n_key_data-1];
- }
+ retval = krb5_dbe_find_enctype(kadm_context,
+ &newentry,
+ ENCTYPE_DES_CBC_CRC,
+ KRB5_KDB_SALTTYPE_V4,
+ -1,
+ &pkey);
if (retval)
failadd(retval);