From 3c7da79838d370244822326b805ea97a2b7fe2ab Mon Sep 17 00:00:00 2001 From: "Roland C. Dowdeswell" Date: Tue, 5 Nov 2019 16:00:58 +0000 Subject: [PATCH] derived keys: ensure that princ is correct We copy the princ in the hdb_entry so that if it is later used, it will reflect what we want. --- kdc/misc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kdc/misc.c b/kdc/misc.c index 83abc96e2..e13faba97 100644 --- a/kdc/misc.c +++ b/kdc/misc.c @@ -218,6 +218,8 @@ _fetch_it(krb5_context context, krb5_kdc_configuration *config, HDB *db, log_princ(context, config, 7, " for %s", princ); log_princ(context, config, 7, " from %s", tmpprinc); _derive_the_keys(context, config, princ, kvno, ent); + /* the next function frees the target */ + copy_Principal(princ, ent->entry.principal); } free(host);