+Tue Sep 05 22:10:34 1995 Chris Provenzano (proven@mit.edu)
+
+ * adm_adm_func.c, adm_fmt_inq.c, adm_funcs.c, adm_process.c,
+ * adm_server.c, adm_v4_pwd.c adm_v4_pwd.c: Remove krb5_enctype
+ references, and replace with krb5_keytype where appropriate.
+
Mon Aug 21 17:05:18 EDT 1995 Paul Park (pjpark@mit.edu)
* adm_server.c - Change dbm_db_set_name to db_set_name. Interpret -k
and -e arguments as strings instead of string representations
key_data = (krb5_key_data *) NULL;
if (krb5_dbe_find_keytype(context,
&entry,
- KEYTYPE_DES,
+ KEYTYPE_DES_CBC_MD5,
((oper_type == CHGOPER) ?
KRB5_KDB_SALTTYPE_NORMAL :
KRB5_KDB_SALTTYPE_V4),
*/
if (!krb5_dbe_find_keytype(context,
&entry,
- KEYTYPE_DES,
+ KEYTYPE_DES_CBC_MD5,
KRB5_KDB_SALTTYPE_NORMAL,
-1,
&kdata))
kdata->key_data_kvno = atoi(tempstr);
if (!krb5_dbe_find_keytype(context,
&entry,
- KEYTYPE_DES,
+ KEYTYPE_DES_CBC_CRC,
KRB5_KDB_SALTTYPE_V4,
-1,
&kdata))
kdata->key_data_kvno = atoi(tempstr);
if (!krb5_dbe_find_keytype(context,
&entry,
- KEYTYPE_DES,
+ KEYTYPE_DES_CBC_MD5,
KRB5_KDB_SALTTYPE_NOREALM,
-1,
&kdata))
kdata->key_data_kvno = atoi(tempstr);
if (!krb5_dbe_find_keytype(context,
&entry,
- KEYTYPE_DES,
+ KEYTYPE_DES_CBC_MD5,
KRB5_KDB_SALTTYPE_ONLYREALM,
-1,
&kdata))
};
static const krb5_key_salt_tuple keysalts[] = {
-{ KEYTYPE_DES, KRB5_KDB_SALTTYPE_NORMAL },
-{ KEYTYPE_DES, KRB5_KDB_SALTTYPE_V4 }
+{ KEYTYPE_DES_CBC_MD5, KRB5_KDB_SALTTYPE_NORMAL },
+{ KEYTYPE_DES_CBC_CRC, KRB5_KDB_SALTTYPE_V4 }
};
static const krb5_int32 n_keysalts =
sizeof(keysalts) / sizeof(keysalts[0]);
int keytypedone = 0;
char *mkey_name = 0;
char *local_realm;
- krb5_enctype etype;
- krb5_enctype kdc_etype = DEFAULT_KDC_ETYPE;
+ krb5_keytype ktype;
#ifdef SANDIA
char input_string[80];
}
break;
- case 'e':
- if (krb5_string_to_enctype(optarg, &kdc_etype))
- fprintf(stderr, "%s: %s is an invalid encryption type\n",
- argv[0], optarg);
- break;
-
case 'k': /* keytype for master key */
if (!krb5_string_to_keytype(optarg, &master_keyblock.keytype))
keytypedone++;
}
if (!keytypedone) {
- master_keyblock.keytype = KEYTYPE_DES;
+ master_keyblock.keytype = KEYTYPE_DES_CBC_MD5;
}
/* assemble & parse the master key name */
exit(1);
}
- if (!valid_etype(kdc_etype)) {
- com_err(argv[0], KRB5_PROG_ETYPE_NOSUPP,
- "while setting up etype %d", kdc_etype);
- exit(1);
- }
- krb5_use_cstype(context, &master_encblock, kdc_etype);
+ krb5_use_keytype(context, &master_encblock, master_keyblock.keytype);
if ((retval = krb5_db_fetch_mkey(context,
master_princ,
}
/* initialize random key generators */
- for (etype = 0; etype <= krb5_max_cryptosystem; etype++) {
- if (krb5_csarray[etype]) {
- if ((retval = (*krb5_csarray[etype]->system->
+ for (ktype = 0; ktype <= krb5_max_keytype; ktype++) {
+ if (krb5_keytype_array[ktype]) {
+ if (retval = (*krb5_keytype_array[ktype]->system->
init_random_key)(&master_keyblock,
- &krb5_csarray[etype]->random_sequence))) {
+ &krb5_keytype_array[ktype]->random_sequence)) {
com_err(argv[0], retval,
- "while setting up random key generator for etype %d--etype disabled",
- etype);
- krb5_csarray[etype] = 0;
+ "while setting up random key generator for ktype %d--ktype disabled",
+ ktype);
+ krb5_keytype_array[ktype] = 0;
}
}
}
convert server.key into a real key
(it may be encrypted in the database)
*/
- if ((retval = krb5_dbe_find_keytype(context,
- &server_entry,
- KEYTYPE_DES,
- -1,
- -1,
- &kdatap))) {
+ if (retval = krb5_dbe_find_keytype(context,
+ &server_entry,
+ KEYTYPE_DES_CBC_MD5,
+ -1,
+ -1,
+ &kdatap)) {
krb5_db_free_principal(context, &server_entry, number_of_entries);
(void) krb5_finish_key(context, &master_encblock);
memset((char *)&master_encblock, 0, sizeof(master_encblock));