From: Sam Hartman Date: Mon, 16 Mar 2009 16:50:04 +0000 (+0000) Subject: Call kdb_set_mkey_list from the KDC X-Git-Tag: krb5-1.8-alpha1~591 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=1dfc62e02bcfee4e9b0194a2c5dd956ce7d86c4b;p=krb5.git Call kdb_set_mkey_list from the KDC In order for the kdb keytab to be used from within the KDC, the KDC needs to set the master key list in the context. ticket: 6424 Target_version: 1.7 tags: pullup git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22093 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/kdc/kdc_util.c b/src/kdc/kdc_util.c index 00ae43645..5e1c91c80 100644 --- a/src/kdc/kdc_util.c +++ b/src/kdc/kdc_util.c @@ -454,6 +454,7 @@ kdc_get_server_key(krb5_ticket *ticket, unsigned int flags, &master_keyblock, 0, &tmp_mkey_list) == 0) { krb5_dbe_free_key_list(kdc_context, master_keylist); master_keylist = tmp_mkey_list; + krb5_db_set_mkey_list(kdc_context, master_keylist); if ((retval = krb5_dbe_find_mkey(kdc_context, master_keylist, server, &mkey_ptr))) { goto errout; diff --git a/src/kdc/main.c b/src/kdc/main.c index 631fe3c07..7656dcd8e 100644 --- a/src/kdc/main.c +++ b/src/kdc/main.c @@ -414,7 +414,6 @@ init_realm(kdc_realm_t *rdp, char *realm, char *def_mpname, rdp->realm_mpname, realm); goto whoops; } - #if 0 /************** Begin IFDEF'ed OUT *******************************/ /* * Commenting krb5_db_verify_master_key out because it requires the most @@ -445,6 +444,7 @@ init_realm(kdc_realm_t *rdp, char *realm, char *def_mpname, "while setting master key for realm %s", realm); goto whoops; } + krb5_db_set_mkey_list(rdp->realm_context, rdp->mkey_list); /* Set up the keytab */ if ((kret = krb5_ktkdb_resolve(rdp->realm_context, NULL,