From 140deb8f7e227e2ce86055df375e499462d5642a Mon Sep 17 00:00:00 2001 From: Theodore Tso Date: Fri, 6 Oct 1995 02:47:46 +0000 Subject: [PATCH] Remove the profile relation, since it's really a bad idea. Removed the "port" and "secondary_port" relations, and replaced them with the "kdc_port" relation, which takes a list of ports. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6936 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/kadm/ChangeLog | 7 +++++++ src/lib/kadm/alt_prof.c | 39 ++++++--------------------------------- 2 files changed, 13 insertions(+), 33 deletions(-) diff --git a/src/lib/kadm/ChangeLog b/src/lib/kadm/ChangeLog index d25cf5865..ed8818d45 100644 --- a/src/lib/kadm/ChangeLog +++ b/src/lib/kadm/ChangeLog @@ -1,3 +1,10 @@ +Thu Oct 5 19:46:40 1995 Theodore Y. Ts'o + + * alt_prof.c (krb5_read_realm_params): Remove the profile + relation, since it's really a bad idea. Removed the + "port" and "secondary_port" relations, and replaced them + with the "kdc_port" relation, which takes a list of ports. + Mon Oct 2 15:08:53 1995 Theodore Y. Ts'o * logger.c (krb5_klog_init): If the log file can't be opened, diff --git a/src/lib/kadm/alt_prof.c b/src/lib/kadm/alt_prof.c index 316572e3d..597bbc0d5 100644 --- a/src/lib/kadm/alt_prof.c +++ b/src/lib/kadm/alt_prof.c @@ -292,45 +292,18 @@ krb5_read_realm_params(kcontext, realm, kdcprofile, kdcenv, rparamp) /* Initialize realm parameters */ memset((char *) rparams, 0, sizeof(krb5_realm_params)); - /* Get the value of the per-realm profile */ + /* Get the value for the database */ hierarchy[0] = "realms"; hierarchy[1] = lrealm; - hierarchy[2] = "profile"; - hierarchy[3] = (char *) NULL; - if (!krb5_aprof_get_string(aprofile, hierarchy, TRUE, &svalue)) { - const char *filenames[2]; - - /* - * XXX this knows too much about krb5 contexts. - */ - filenames[0] = svalue; - filenames[1] = (char *) NULL; - if (kcontext->profile) - profile_release(kcontext->profile); - if (!(kret = profile_init(filenames, &kcontext->profile))) - rparams->realm_profile = svalue; - else - krb5_xfree(svalue); - } - - /* Get the value for the database */ hierarchy[2] = "database_name"; + hierarchy[3] = (char *) NULL; if (!krb5_aprof_get_string(aprofile, hierarchy, TRUE, &svalue)) rparams->realm_dbname = svalue; - /* Get the value for the KDC primary port */ - hierarchy[2] = "port"; - if (!krb5_aprof_get_int32(aprofile, hierarchy, TRUE, &ivalue)) { - rparams->realm_kdc_pport = ivalue; - rparams->realm_kdc_pport_valid = 1; - } - - /* Get the value for the KDC secondary port */ - hierarchy[2] = "secondary_port"; - if (!krb5_aprof_get_int32(aprofile, hierarchy, TRUE, &ivalue)) { - rparams->realm_kdc_sport = ivalue; - rparams->realm_kdc_sport_valid = 1; - } + /* Get the value for the KDC port list */ + hierarchy[2] = "kdc_ports"; + if (!krb5_aprof_get_string(aprofile, hierarchy, TRUE, &svalue)) + rparams->realm_kdc_ports = svalue; /* Get the value for the kadmind port */ hierarchy[2] = "kadmind_port"; -- 2.26.2