From d9f9c87093ebd61e5b63284f7cd88ffa24182900 Mon Sep 17 00:00:00 2001 From: John Kohl Date: Mon, 22 Oct 1990 15:56:23 +0000 Subject: [PATCH] remove kdc_rcache git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@1308 dc483132-0cff-0310-8789-dd5450dbe970 --- src/kdc/extern.c | 2 -- src/kdc/extern.h | 2 -- src/kdc/kdc_util.c | 2 +- src/kdc/main.c | 34 ++-------------------------------- 4 files changed, 3 insertions(+), 37 deletions(-) diff --git a/src/kdc/extern.c b/src/kdc/extern.c index b61fa256d..0bda4474f 100644 --- a/src/kdc/extern.c +++ b/src/kdc/extern.c @@ -22,8 +22,6 @@ static char rcsid_extern_c[] = #include /* real declarations of KDC's externs */ -krb5_rcache kdc_rcache; - krb5_data empty_string = {0, ""}; krb5_timestamp infinity = KRB5_INT32_MAX; /* XXX */ diff --git a/src/kdc/extern.h b/src/kdc/extern.h index 3c85173af..8e13e2102 100644 --- a/src/kdc/extern.h +++ b/src/kdc/extern.h @@ -17,8 +17,6 @@ #define __KRB5_KDC_EXTERN__ /* various externs for KDC */ -extern krb5_rcache kdc_rcache; /* KDC's replay cache */ - extern krb5_data empty_string; /* an empty string */ extern krb5_timestamp infinity; /* greater than all other timestamps */ diff --git a/src/kdc/kdc_util.c b/src/kdc/kdc_util.c index 3fff61db6..a14e396b1 100644 --- a/src/kdc/kdc_util.c +++ b/src/kdc/kdc_util.c @@ -195,7 +195,7 @@ krb5_ticket **ticket; 0, /* no fetchfrom */ kdc_rdreq_keyproc, (krb5_pointer)&who, - kdc_rcache, + 0, /* no replay cache */ &authdat); krb5_db_free_principal(&server, nprincs); bzero((char *)encrypting_key.contents, encrypting_key.length); diff --git a/src/kdc/main.c b/src/kdc/main.c index d36d015b9..8ec9ea910 100644 --- a/src/kdc/main.c +++ b/src/kdc/main.c @@ -140,7 +140,6 @@ char **argv; int keytypedone = 0; char *db_realm = 0; char *mkey_name = 0; - char *rcname = 0; char lrealm[BUFSIZ]; krb5_error_code retval; krb5_enctype etype; @@ -148,7 +147,7 @@ char **argv; extern char *optarg; extern krb5_deltat krb5_clockskew; - while ((c = getopt(argc, argv, "r:d:mM:k:R:")) != EOF) { + while ((c = getopt(argc, argv, "r:d:mM:k:")) != EOF) { switch(c) { case 'r': /* realm name for db */ db_realm = optarg; @@ -166,9 +165,6 @@ char **argv; master_keyblock.keytype = atoi(optarg); keytypedone++; break; - case 'R': - rcname = optarg; - break; case '?': default: usage(argv[0]); @@ -191,31 +187,11 @@ char **argv; if (!keytypedone) master_keyblock.keytype = KEYTYPE_DES; - if (!rcname) - rcname = KDCRCACHE; - if (retval = krb5_rc_resolve_full(&kdc_rcache, rcname)) { - com_err(argv[0], retval, "while resolving replay cache '%s'", rcname); - exit(1); - } - if ((retval = krb5_rc_recover(kdc_rcache)) && - (retval = krb5_rc_initialize(kdc_rcache, krb5_clockskew))) { - com_err(argv[0], retval, "while initializing replay cache '%s:%s'", - kdc_rcache->ops->type, - krb5_rc_get_name(kdc_rcache)); - exit(1); - } - if ((retval = krb5_rc_expunge(kdc_rcache))) { - com_err(argv[0], retval, "while expunging replay cache '%s:%s'", - kdc_rcache->ops->type, - krb5_rc_get_name(kdc_rcache)); - exit(1); - } /* assemble & parse the master key name */ if (retval = krb5_db_setup_mkey_name(mkey_name, db_realm, (char **) 0, &master_princ)) { com_err(argv[0], retval, "while setting up master key name"); - (void) krb5_rc_close(kdc_rcache); exit(1); } @@ -229,7 +205,6 @@ error(You gotta figure out what cryptosystem to use in the KDC); FALSE, /* only read it once, if at all */ &master_keyblock)) { com_err(argv[0], retval, "while fetching master key"); - (void) krb5_rc_close(kdc_rcache); exit(1); } /* initialize random key generators */ @@ -251,12 +226,7 @@ void finish_args(prog) char *prog; { - krb5_error_code retval; - if (retval = krb5_rc_close(kdc_rcache)) { - com_err(prog, retval, "while closing replay cache '%s:%s'", - kdc_rcache->ops->type, - krb5_rc_get_name(kdc_rcache)); - } + /* nothing to do at the moment... */ return; } -- 2.26.2