From 76b15333844125269f0875fb5cfde804f8768fe8 Mon Sep 17 00:00:00 2001 From: Theodore Tso Date: Thu, 7 Sep 1995 21:55:29 +0000 Subject: [PATCH] srv_key.c: Globally change use of ENCTYPE_DES_CBC_MD5 to DEFAULT_KDC_ENCTYPE, so that we use the same encryption type by default for all KDC server programs. srv_main.c (main): Set the default realm from the -r argument, so that correct defaulting takes place for things like krb5_parse(). srv_net.c (net_init): Use KRB5_ADM_SERVICE_INSTANCE to determine the service instance, instance of KRB5_ADMIN_SERVICE_NAME. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6736 dc483132-0cff-0310-8789-dd5450dbe970 --- src/kadmin/v5server/ChangeLog | 13 +++++++++++++ src/kadmin/v5server/srv_main.c | 8 +++++++- src/kadmin/v5server/srv_net.c | 4 ++-- 3 files changed, 22 insertions(+), 3 deletions(-) diff --git a/src/kadmin/v5server/ChangeLog b/src/kadmin/v5server/ChangeLog index 59bcdb79e..514a5822e 100644 --- a/src/kadmin/v5server/ChangeLog +++ b/src/kadmin/v5server/ChangeLog @@ -1,3 +1,16 @@ +Thu Sep 7 17:52:24 1995 Theodore Y. Ts'o + + * srv_key.c: Globally change use of ENCTYPE_DES_CBC_MD5 to + DEFAULT_KDC_ENCTYPE, so that we use the same encryption + type by default for all KDC server programs. + + * srv_main.c (main): Set the default realm from the -r argument, + so that correct defaulting takes place for things like + krb5_parse(). + + * srv_net.c (net_init): Use KRB5_ADM_SERVICE_INSTANCE to determine + the service instance, instance of KRB5_ADMIN_SERVICE_NAME. + Wed Sep 06 14:20:57 1995 Chris Provenzano (proven@mit.edu) * admin.c, passwd.c, srv_key.c, srv_main.c : diff --git a/src/kadmin/v5server/srv_main.c b/src/kadmin/v5server/srv_main.c index bb63cca41..fce7129ea 100644 --- a/src/kadmin/v5server/srv_main.c +++ b/src/kadmin/v5server/srv_main.c @@ -249,7 +249,13 @@ main(argc, argv) krb5_init_context(&kcontext); krb5_init_ets(kcontext); krb5_klog_init(kcontext, "admin_server", programname, 1); - + if (db_realm) { + if ((error = krb5_set_default_realm(kcontext, db_realm))) { + com_err(programname, error, "while setting default realm name"); + return(1); + } + } + /* * Attempt to read the KDC profile. If we do, then read appropriate values * from it and supercede values supplied on the command line. diff --git a/src/kadmin/v5server/srv_net.c b/src/kadmin/v5server/srv_net.c index 1fa3e507e..dd1b76476 100644 --- a/src/kadmin/v5server/srv_net.c +++ b/src/kadmin/v5server/srv_net.c @@ -459,7 +459,7 @@ net_init(kcontext, debug_level, port) malloc((size_t) (MAX_SLAVES * sizeof(net_slave_info))); /* Make our service name */ net_service_name = (char *) malloc(strlen(realm) + - strlen(KRB5_ADM_SERVICE_NAME) + 2); + strlen(KRB5_ADM_SERVICE_INSTANCE) + 2); if ((net_service_name == (char *) NULL) || (net_slave_table == (net_slave_info *) NULL)) { kret = ENOMEM; @@ -467,7 +467,7 @@ net_init(kcontext, debug_level, port) goto done; } (void) sprintf(net_service_name, "%s%s%s", - KRB5_ADM_SERVICE_NAME, "/", realm); + KRB5_ADM_SERVICE_INSTANCE, "/", realm); memset((char *) net_slave_table, 0, (size_t) (MAX_SLAVES * sizeof(net_slave_info))); net_max_slaves = MAX_SLAVES; -- 2.26.2