From: Paul Park Date: Fri, 23 Jun 1995 14:00:33 +0000 (+0000) Subject: Remove usage of KDB_CONVERT_KEY_OUTOF_DB X-Git-Tag: krb5-1.0-beta6~1678 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=9a108a9cafe6a619a4ba3a7f3f717ff93bd687ab;p=krb5.git Remove usage of KDB_CONVERT_KEY_OUTOF_DB git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6136 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/kadmin.old/server/ChangeLog b/src/kadmin.old/server/ChangeLog index 0a9bbbff3..23b68c23e 100644 --- a/src/kadmin.old/server/ChangeLog +++ b/src/kadmin.old/server/ChangeLog @@ -1,4 +1,8 @@ +Thu Jun 22 11:54:31 EDT 1995 Paul Park (pjpark@mit.edu) + * adm_server.c - Change KDB_CONVERT_KEY_OUTOF_DB to decrypt_key call. + + Thu Jun 15 17:51:04 EDT 1995 Paul Park (pjpark@mit.edu) * Makefile.in - Change explicit library names to -l form, and change target link line to use $(LD) and associated flags. diff --git a/src/kadmin.old/server/adm_server.c b/src/kadmin.old/server/adm_server.c index 31a0cd833..0276f18f4 100644 --- a/src/kadmin.old/server/adm_server.c +++ b/src/kadmin.old/server/adm_server.c @@ -356,7 +356,8 @@ init_db(context, dbname, masterkeyname, masterkeyblock) convert server.key into a real key (it may be encrypted in the database) */ - if (retval = KDB_CONVERT_KEY_OUTOF_DB(context,&server_entry.key,&tgs_key)) { + if (retval = krb5_kdb_decrypt_key(context,&master_encblock, + &server_entry.key,&tgs_key)) { 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)); diff --git a/src/kdc/do_as_req.c b/src/kdc/do_as_req.c index f7a4d7271..be7155763 100644 --- a/src/kdc/do_as_req.c +++ b/src/kdc/do_as_req.c @@ -70,7 +70,7 @@ check_padata (client, src_addr, padata, pa_id, flags) enckey = &(client->key); /* Extract client key/alt_key from master key */ - retval = KDB_CONVERT_KEY_OUTOF_DB(kdc_context,enckey,&tmpkey); + retval = krb5_kdb_decrypt_key(kdc_context,&master_encblock,enckey,&tmpkey); if (retval) { krb5_klog_syslog( LOG_ERR, "AS_REQ: Unable to extract client key: %s", error_message(retval)); @@ -86,7 +86,8 @@ check_padata (client, src_addr, padata, pa_id, flags) */ enckey = &(client->alt_key); /* Extract client key/alt_key from master key */ - if ((retval = KDB_CONVERT_KEY_OUTOF_DB(kdc_context,enckey,&tmpkey))) { + if ((retval = krb5_kdb_decrypt_key(kdc_context,&master_encblock, + enckey,&tmpkey))) { krb5_klog_syslog( LOG_ERR, "AS_REQ: Unable to extract client alt_key: %s", error_message(retval)); return retval; @@ -405,7 +406,8 @@ krb5_data **response; /* filled in with a response packet */ /* convert server.key into a real key (it may be encrypted in the database) */ - if ((retval = KDB_CONVERT_KEY_OUTOF_DB(kdc_context, &server.key, &encrypting_key))) + if ((retval = krb5_kdb_decrypt_key(kdc_context, &master_encblock, + &server.key, &encrypting_key))) goto errout; retval = krb5_encrypt_tkt_part(kdc_context, &eblock, &encrypting_key, &ticket_reply); memset((char *)encrypting_key.contents, 0, encrypting_key.length); @@ -479,7 +481,8 @@ krb5_data **response; /* filled in with a response packet */ /* convert client.key into a real key (it may be encrypted in the database) */ - if ((retval = KDB_CONVERT_KEY_OUTOF_DB(kdc_context, &client.key, &encrypting_key))) + if ((retval = krb5_kdb_decrypt_key(kdc_context, &master_encblock, + &client.key, &encrypting_key))) goto errout; reply.enc_part.etype = useetype; reply.enc_part.kvno = client.kvno; diff --git a/src/krb524/ChangeLog b/src/krb524/ChangeLog index e63e7fe73..2f3ba0a48 100644 --- a/src/krb524/ChangeLog +++ b/src/krb524/ChangeLog @@ -1,4 +1,8 @@ +Thu Jun 22 11:55:23 EDT 1995 Paul Park (pjpark@mit.edu) + * krb524d.c - Change KRB_CONVERT_KEY_OUTOF_DB to decrypt_key calls. + + Fri Jun 16 17:09:09 EDT 1995 Paul Park (pjpark@mit.edu) * k524init.c - Inline code from krb_save_credentials, it doesn't exist for some K4 (e.g. /usr/athena). diff --git a/src/krb524/krb524d.c b/src/krb524/krb524d.c index 4d411f5c1..d3a54902c 100644 --- a/src/krb524/krb524d.c +++ b/src/krb524/krb524d.c @@ -376,7 +376,7 @@ krb5_error_code kdc_get_server_key(context, service, key, kvno) * convert server.key into a real key (it is encrypted in the * database) */ - ret = KDB_CONVERT_KEY_OUTOF_DB(context, &server.key, key); + ret = krb5_kdb_decrypt_key(context, &master_encblock, &server.key, key); if (kvno) *kvno = server.kvno; krb5_db_free_principal(context, &server, nprincs);