PROG = kdb5_util
-SRCS = kdb5_util.c kdb5_create.c kadm5_create.c string_table.c kdb5_destroy.c \
+SRCS = kdb5_util.c kdb5_create.c kadm5_create.c kdb5_destroy.c \
kdb5_stash.c import_err.c strtok.c dump.c ovload.c kdb5_mkey.c
-OBJS = kdb5_util.o kdb5_create.o kadm5_create.o string_table.o kdb5_destroy.o \
+OBJS = kdb5_util.o kdb5_create.o kadm5_create.o kdb5_destroy.o \
kdb5_stash.o import_err.o strtok.o dump.o ovload.o kdb5_mkey.o
GETDATE = ../cli/getdate.o
$(top_srcdir)/include/krb5.h $(top_srcdir)/include/krb5/authdata_plugin.h \
$(top_srcdir)/include/krb5/locate_plugin.h $(top_srcdir)/include/krb5/preauth_plugin.h \
$(top_srcdir)/include/port-sockets.h $(top_srcdir)/include/socket-utils.h \
- kadm5_create.c kdb5_util.h string_table.h
-$(OUTPRE)string_table.$(OBJEXT): string_table.c
+ kadm5_create.c kdb5_util.h
$(OUTPRE)kdb5_destroy.$(OBJEXT): $(BUILDTOP)/include/autoconf.h \
$(BUILDTOP)/include/gssapi/gssapi.h $(BUILDTOP)/include/gssrpc/types.h \
$(BUILDTOP)/include/kadm5/admin.h $(BUILDTOP)/include/kadm5/chpass_util_strings.h \
* to be opened if we try a dump that uses it.
*/
if (!dbactive) {
- com_err(progname, 0, Err_no_database);
+ com_err(progname, 0, "Database not currently opened!");
exit_status++;
return;
}
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*/
-#include "string_table.h"
-
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
fullname = build_name_with_realm(name, realm);
ret = krb5_parse_name(context, fullname, &ent.principal);
if (ret) {
- com_err(progname, ret, str_PARSE_NAME);
+ com_err(progname, ret, "while parsing admin principal name");
return(ERR);
}
ent.max_life = lifetime;
"to-be-random");
if (ret) {
if (ret != KADM5_DUP) {
- com_err(progname, ret, str_PUT_PRINC, fullname);
+ com_err(progname, ret, "while creating principal %s", fullname);
krb5_free_principal(context, ent.principal);
free(fullname);
return ERR;
/* only randomize key if we created the principal */
ret = kadm5_randkey_principal(handle, ent.principal, NULL, NULL);
if (ret) {
- com_err(progname, ret, str_RANDOM_KEY, fullname);
+ com_err(progname, ret, "while randomizing principal %s", fullname);
krb5_free_principal(context, ent.principal);
free(fullname);
return ERR;
ent.attributes = attrs;
ret = kadm5_modify_principal(handle, &ent, KADM5_ATTRIBUTES);
if (ret) {
- com_err(progname, ret, str_PUT_PRINC, fullname);
+ com_err(progname, ret, "while setting attributes on %s", fullname);
krb5_free_principal(context, ent.principal);
free(fullname);
return ERR;
#include <time.h>
#include "kdb5_util.h"
-char *Err_no_master_msg = "Master key not entered!\n";
-char *Err_no_database = "Database not currently opened!\n";
-
/*
* XXX Ick, ick, ick. These global variables shouldn't be global....
*/
#define REALM_SEP_STR "@"
extern char *progname;
-extern char *Err_no_database;
#ifndef V4_DECLARES_STATIC
extern krb5_keyblock master_keyblock;
extern krb5_principal master_princ;
+++ /dev/null
-/* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
-/*
- * Copyright 1993 OpenVision Technologies, Inc., All Rights Reserved.
- *
- */
-
-/* String table of messages for kadm5_create */
-
-char *str_PARSE_NAME = "while parsing admin principal name.";
-
-char *str_HISTORY_PARSE_NAME = "while parsing admin history principal name.";
-
-char *str_ADMIN_PRINC_EXISTS = "Warning! Admin principal already exists.";
-
-char *str_CHANGEPW_PRINC_EXISTS = "Warning! Changepw principal already exists.";
-
-char *str_HISTORY_PRINC_EXISTS = "Warning! Admin history principal already exists.";
-
-char *str_ADMIN_PRINC_WRONG_ATTRS =
- "Warning! Admin principal has incorrect attributes.\n"
- "\tDISALLOW_TGT should be set, and max_life should be three hours.\n"
- "\tThis program will leave them as-is, but beware!.";
-
-char *str_CHANGEPW_PRINC_WRONG_ATTRS =
- "Warning! Changepw principal has incorrect attributes.\n"
- "\tDISALLOW_TGT and PW_CHANGE_SERVICE should both be set, and "
- "max_life should be five minutes.\n"
- "\tThis program will leave them as-is, but beware!.";
-
-char *str_HISTORY_PRINC_WRONG_ATTRS =
- "Warning! Admin history principal has incorrect attributes.\n"
- "\tDISALLOW_ALL_TIX should be set.\n"
- "\tThis program will leave it as-is, but beware!.";
-
-char *str_CREATED_PRINC_DB =
- "%s: Admin principal database created (or it already existed).\n"; /* whoami */
-
-char *str_CREATED_POLICY_DB =
- "%s: Admin policy database created (or it already existed).\n"; /* whoami */
-
-char *str_RANDOM_KEY =
- "while calling random key for %s."; /* principal name */
-
-char *str_ENCRYPT_KEY =
- "while calling encrypt key for %s."; /* principal name */
-
-char *str_PUT_PRINC =
- "while storing %s in Kerberos database."; /* principal name */
-
-char *str_CREATING_POLICY_DB = "while creating/opening admin policy database.";
-
-char *str_CLOSING_POLICY_DB = "while closing admin policy database.";
-
-char *str_CREATING_PRINC_DB = "while creating/opening admin principal database.";
-
-char *str_CLOSING_PRINC_DB = "while closing admin principal database.";
-
-char *str_CREATING_PRINC_ENTRY =
- "while creating admin principal database entry for %s."; /* princ_name */
-
-char *str_A_PRINC = "a principal";
-
-char *str_UNPARSE_PRINC = "while unparsing principal.";
-
-char *str_CREATED_PRINC = "%s: Created %s principal.\n"; /* whoami, princ_name */
-
-char *str_INIT_KDB = "while initializing kdb.";
-
-char *str_NO_KDB =
- "while initializing kdb.\nThe Kerberos KDC database needs to exist in /krb5.\n\
-If you haven't run kdb5_create you need to do so before running this command.";
-
-
-char *str_INIT_RANDOM_KEY = "while initializing random key generator.";
-
-char *str_TOO_MANY_ADMIN_PRINC =
- "while fetching admin princ. Can only have one admin principal.";
-
-char *str_TOO_MANY_CHANGEPW_PRINC =
- "while fetching changepw princ. Can only have one changepw principal.";
-
-char *str_TOO_MANY_HIST_PRINC =
- "while fetching history princ. Can only have one history principal.";
-
-char *str_WHILE_DESTROYING_ADMIN_SESSION = "while closing session with admin server and destroying tickets.";
+++ /dev/null
-/* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
-/*
- * Copyright 1993 OpenVision Technologies, Inc., All Rights Reserved.
- *
- * $Header$
- *
- */
-
-#ifndef _OVSEC_ADM_STRINGS_
-
-extern char *str_PARSE_NAME;
-extern char *str_HISTORY_PARSE_NAME;
-extern char *str_ADMIN_PRINC_EXISTS;
-extern char *str_CHANGEPW_PRINC_EXISTS;
-extern char *str_HISTORY_PRINC_EXISTS;
-extern char *str_ADMIN_PRINC_WRONG_ATTRS;
-extern char *str_CHANGEPW_PRINC_WRONG_ATTRS;
-extern char *str_HISTORY_PRINC_WRONG_ATTRS;
-extern char *str_CREATED_PRINC_DB;
-extern char *str_CREATED_POLICY_DB;
-extern char *str_RANDOM_KEY;
-extern char *str_ENCRYPT_KEY;
-extern char *str_PUT_PRINC;
-extern char *str_CREATING_POLICY_DB;
-extern char *str_CLOSING_POLICY_DB;
-extern char *str_CREATING_PRINC_DB;
-extern char *str_CLOSING_PRINC_DB;
-extern char *str_CREATING_PRINC_ENTRY;
-extern char *str_A_PRINC;
-extern char *str_UNPARSE_PRINC;
-extern char *str_CREATED_PRINC;
-extern char *str_INIT_KDB;
-extern char *str_NO_KDB;
-extern char *str_INIT_RANDOM_KEY;
-extern char *str_TOO_MANY_ADMIN_PRINC;
-extern char *str_TOO_MANY_CHANGEPW_PRINC;
-extern char *str_TOO_MANY_HIST_PRINC;
-extern char *str_WHILE_DESTROYING_ADMIN_SESSION;
-
-#endif /* _OVSEC_ADM_STRINGS_ */