From: Tom Yu Date: Fri, 6 Sep 1996 19:45:16 +0000 (+0000) Subject: remove kdb5_anadd as it is no longer needed X-Git-Tag: krb5-1.0-beta7~46 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=7f598d0495fab1281454ff4f8c9f6d3b45c5771f;p=krb5.git remove kdb5_anadd as it is no longer needed git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@9042 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/admin/aname/.Sanitize b/src/admin/aname/.Sanitize deleted file mode 100644 index bcb7a8536..000000000 --- a/src/admin/aname/.Sanitize +++ /dev/null @@ -1,38 +0,0 @@ -# Sanitize.in for Kerberos V5 - -# Each directory to survive it's way into a release will need a file -# like this one called "./.Sanitize". All keyword lines must exist, -# and must exist in the order specified by this file. Each directory -# in the tree will be processed, top down, in the following order. - -# Hash started lines like this one are comments and will be deleted -# before anything else is done. Blank lines will also be squashed -# out. - -# The lines between the "Do-first:" line and the "Things-to-keep:" -# line are executed as a /bin/sh shell script before anything else is -# done in this - -Do-first: - -# All files listed between the "Things-to-keep:" line and the -# "Files-to-sed:" line will be kept. All other files will be removed. -# Directories listed in this section will have their own Sanitize -# called. Directories not listed will be removed in their entirety -# with rm -rf. - -Things-to-keep: - -.cvsignore -ChangeLog -Makefile.in -configure -configure.in -kdb5_anadd.M -kdb5_anadd.c - -Things-to-lose: - -Do-last: - -# End of file. diff --git a/src/admin/aname/ChangeLog b/src/admin/aname/ChangeLog deleted file mode 100644 index 7c853058a..000000000 --- a/src/admin/aname/ChangeLog +++ /dev/null @@ -1,49 +0,0 @@ -Fri Sep 29 16:37:38 1995 Theodore Y. Ts'o - - * kdb5_anadd.c (main): Don't use krb5_lname_file; instead, use - DEFAULT_LNAME_FILENAME directly. - -Fri Jul 7 15:34:15 EDT 1995 Paul Park (pjpark@mit.edu) - * Makefile.in - Remove all explicit library handling and LDFLAGS. - * configure.in - Add KRB5_LIBRARIES. - - -Fri Jun 30 14:28:20 EDT 1995 Paul Park (pjpark@mit.edu) - * kdb5_anadd.c - Add ability to select between Berkeley and DBM format - at compile time. - * configure.in - Add --with-dbm and --with-aname-dbm and check/set - appropriate definitions and libraries. - * Makefile.in - Use DBFLAGS set by configure.in. - - -Thu Jun 15 15:22:33 EDT 1995 Paul Park (pjpark@mit.edu) - * Makefile.in - Change explicit library names to -l form, and - change target link line to use $(LD) and associated flags. - * configure.in - Add shared library usage check. - -Fri Jun 9 18:13:43 1995 - - * configure.in: Remove standardized set of autoconf macros, which - are now handled by CONFIG_RULES. - -Thu Mar 2 12:20:08 1995 Theodore Y. Ts'o - - * Makefile.in (ISODELIB): Remove reference to $(ISODELIB). - -Wed Mar 1 11:50:48 1995 Theodore Y. Ts'o - - * configure.in: Remove ISODE_INCLUDE, replace check for -lsocket - and -lnsl with WITH_NETLIB check. - -Tue Feb 28 02:04:08 1995 John Gilmore (gnu at toad.com) - - * kdb5_anadd.c: Avoid and includes. - -Mon Oct 3 19:11:27 1994 Theodore Y. Ts'o (tytso@dcl) - - * Makefile.in: Use $(srcdir) to find manual page for make install. - -Thu Sep 29 22:22:33 1994 Theodore Y. Ts'o (tytso@dcl) - - * Makefile.in: Relink executable when libraries change. - diff --git a/src/admin/aname/Makefile.in b/src/admin/aname/Makefile.in deleted file mode 100644 index 7b6e93492..000000000 --- a/src/admin/aname/Makefile.in +++ /dev/null @@ -1,14 +0,0 @@ -CFLAGS = $(CCOPTS) $(DEFS) $(LOCALINCLUDE) - -all:: kdb5_anadd - -kdb5_anadd: kdb5_anadd.o $(DEPLIBS) - $(LD) $(LDFLAGS) $(LDARGS) -o kdb5_anadd kdb5_anadd.o $(LIBS) - -install:: - $(INSTALL_PROGRAM) kdb5_anadd $(DESTDIR)$(ADMIN_BINDIR)/kdb5_anadd - $(INSTALL_DATA) $(srcdir)/kdb5_anadd.M $(DESTDIR)$(ADMIN_MANDIR)/kdb5_anadd.8 - -clean:: - $(RM) kdb5_anadd kdb5_anadd.o - diff --git a/src/admin/aname/configure.in b/src/admin/aname/configure.in deleted file mode 100644 index 204fca1c6..000000000 --- a/src/admin/aname/configure.in +++ /dev/null @@ -1,7 +0,0 @@ -AC_INIT(kdb5_anadd.c) -CONFIG_RULES -AC_PROG_INSTALL -USE_ANAME -KRB5_LIBRARIES -V5_USE_SHARED_LIB -V5_AC_OUTPUT_MAKEFILE diff --git a/src/admin/aname/kdb5_anadd.M b/src/admin/aname/kdb5_anadd.M deleted file mode 100644 index d36b5d071..000000000 --- a/src/admin/aname/kdb5_anadd.M +++ /dev/null @@ -1,90 +0,0 @@ -.\" admin/aname/kdb5_anadd.M -.\" -.\" Copyright 1990 by the Massachusetts Institute of Technology. -.\" -.\" Export of this software from the United States of America may -.\" require a specific license from the United States Government. -.\" It is the responsibility of any person or organization contemplating -.\" export to obtain such a license before exporting. -.\" -.\" WITHIN THAT CONSTRAINT, permission to use, copy, modify, and -.\" distribute this software and its documentation for any purpose and -.\" without fee is hereby granted, provided that the above copyright -.\" notice appear in all copies and that both that copyright notice and -.\" this permission notice appear in supporting documentation, and that -.\" the name of M.I.T. not be used in advertising or publicity pertaining -.\" to distribution of the software without specific, written prior -.\" permission. M.I.T. makes no representations about the suitability of -.\" this software for any purpose. It is provided "as is" without express -.\" or implied warranty. -.\" " -.so man1/header.doc -.TH KDB5_ANADD 8 \*h -.SH NAME -kdb5_anadd \- manipulate aname/lname translation database -.SH SYNOPSIS -.B kdb5_anadd -[ -.B \-a -] [ -.B \-n -.I dbname -] kerberos_principal local_name -.br -.B kdb5_anadd \-d -[ -.B \-n -.I dbname -] kerberos_principal -.br -.SH DESCRIPTION -.I kdb5_anadd -is a primitive tool for manipulating a database which maps -kerberos principals into user accounts on the local machine. By -default, Kerberos assumes that a kerberos principal -"username@LOCALREALM" maps into the account "username" on the local -machine. However, this assumption is not always true. - -.PP -In order accomodate systems which have local usernames which are not the -same as Kerberos principals, the system administrator can use -.I krb5_anadd -to set up mappings between a kerberos name and a local account name. (If -this database is established using -.Ikrb5_anadd, -then Kerberos will not do -the default mapping; you will have to specify each mapping between a -Kerberos principal and username manually). - -.PP -For example, the following mapping can be established by -.Ikrb5_anadd: -"joechen@ATHENA.MIT.EDU" maps to "joe" by using the command: - -.PP -krb5_adadd jochen@ATHENA.MIT.EDU joe - -.PP -After this command, if joechen@ATHENA.MIT.EDU tries to do an -authenticated rlogin to the account "joe" on that machine, the Kerberos -access control mechanism will allow the login, since -joechen@ATHENA.MIT.EDU is considered to be the local user "joe". - -.PP -The \fB\-d\fP option deletes translations from the -database; after execution the principal named by -.I pname -will not translate to any local name. -.PP -For both uses, the -.B \-n -.I dbname -option specifies the name of the database which holds the translation; -the default database is DEFAULT_LNAME_FILENAME (usually /krb5/aname). -.SH SEE ALSO -krb5(3) -krb5_aname_to_localname (3) -.SH BUGS -The mapping is many-to-one, not many-to-many. - - diff --git a/src/admin/aname/kdb5_anadd.c b/src/admin/aname/kdb5_anadd.c deleted file mode 100644 index 6f5ab8b98..000000000 --- a/src/admin/aname/kdb5_anadd.c +++ /dev/null @@ -1,149 +0,0 @@ -/* - * admin/aname/kdb5_anadd.c - * - * Copyright 1990 by the Massachusetts Institute of Technology. - * All Rights Reserved. - * - * Export of this software from the United States of America may - * require a specific license from the United States Government. - * It is the responsibility of any person or organization contemplating - * export to obtain such a license before exporting. - * - * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and - * distribute this software and its documentation for any purpose and - * without fee is hereby granted, provided that the above copyright - * notice appear in all copies and that both that copyright notice and - * this permission notice appear in supporting documentation, and that - * the name of M.I.T. not be used in advertising or publicity pertaining - * to distribution of the software without specific, written prior - * permission. M.I.T. makes no representations about the suitability of - * this software for any purpose. It is provided "as is" without express - * or implied warranty. - * - * - * Program to add/delete entries to/from the aname translation database. - */ - -#include "k5-int.h" -#include -#include "com_err.h" -#include -#include - -#ifdef BERK_DB_DBM -/* - * Use Berkeley database code. - */ -extern DBM *db_dbm_open PROTOTYPE((char *, int, int)); -extern void db_dbm_close PROTOTYPE((DBM *)); -extern int db_dbm_delete PROTOTYPE((DBM *, datum)); -extern int db_dbm_store PROTOTYPE((DBM *, datum, datum, int)); - -#define KDBM_OPEN(db, fl, mo) db_dbm_open(db, fl, mo) -#define KDBM_CLOSE(db) db_dbm_close(db) -#define KDBM_DELETE(db, key) db_dbm_delete(db, key) -#define KDBM_STORE(db,key,c,f) db_dbm_store(db, key, c, f) -#else /* BERK_DB_DBM */ -/* - * Use stock DBM code. - */ -#define KDBM_OPEN(db, fl, mo) dbm_open(db, fl, mo) -#define KDBM_CLOSE(db) dbm_close(db) -#define KDBM_DELETE(db, key) dbm_delete(db, key) -#define KDBM_STORE(db,key,c,f) dbm_store(db, key, c, f) -#endif /* BERK_DB_DBM */ - -extern int errno; - -void -usage(name, code) -char *name; -int code; -{ - fprintf(stderr, "usage: %s {-d|-a} [-n dbname] pname [ lname ]\n\ -\t-d requires pname, -a requires pname and lname\n", name); - exit(code); -} - -void -main(argc, argv) -int argc; -char *argv[]; -{ - DBM *db; - datum key, contents; - int optchar; - extern char *optarg; - extern int optind; - int del = 0, add = 0; - char *lname, *pname; - char *andbname = DEFAULT_LNAME_FILENAME; - - while ((optchar = getopt(argc, argv, "dan:")) != EOF) { - switch(optchar) { - case 'd': /* del */ - del++; - if (add) { - fprintf(stderr, "only one of -a, -d\n"); - usage(argv[0], 1); - } - break; - case 'a': /* add */ - add++; - if (del) { - fprintf(stderr, "only one of -a, -d\n"); - usage(argv[0], 1); - } - break; - case 'n': - andbname = optarg; - break; - case '?': - default: - usage(argv[0], 1); - /*NOTREACHED*/ - } - } - if (!del && !add) { - printf("assuming you want to add\n"); - add = 1; - } - if (argc - optind < 1) { - fprintf(stderr, "must supply pname\n"); - usage(argv[0], 1); - } - if (add && (argc - optind < 2)) { - fprintf(stderr, "must supply pname and lname\n"); - usage(argv[0], 1); - } - pname = argv[optind]; - lname = argv[optind+1]; - - if (!(db = KDBM_OPEN(andbname, O_RDWR|O_CREAT, 0644))) { - com_err(argv[0], errno, "while opening/creating %s", - andbname); - exit(1); - } - key.dptr = pname; - key.dsize = strlen(pname)+1; /* include the null */ - - if (del) { - if (KDBM_DELETE(db, key)) { - com_err(argv[0], 0, "No such entry while deleting %s from %s", - pname, andbname); - KDBM_CLOSE(db); - exit(1); - } - } else if (add) { - contents.dptr = lname; - contents.dsize = strlen(lname)+1; - if (KDBM_STORE(db, key, contents, DBM_REPLACE)) { - com_err(argv[0], errno, "while inserting/replacing %s in %s", - pname, andbname); - KDBM_CLOSE(db); - exit(1); - } - } - KDBM_CLOSE(db); - exit(0); -}