diff options
| author | cvs2svn <cvs2svn@FreeBSD.org> | 2003-06-04 16:00:27 +0000 |
|---|---|---|
| committer | cvs2svn <cvs2svn@FreeBSD.org> | 2003-06-04 16:00:27 +0000 |
| commit | 1c0442969cd576514acfce932c0a0798593c7af7 (patch) | |
| tree | 430cd197d61e20d51161de05e99c28dc8c06ae42 /crypto/heimdal/kpasswd | |
| parent | 196dcb487d15e63d76c2cdd9ad58a847849c6e9e (diff) | |
Diffstat (limited to 'crypto/heimdal/kpasswd')
| -rw-r--r-- | crypto/heimdal/kpasswd/Makefile.am | 31 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/Makefile.in | 747 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswd-generator.c | 200 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswd.1 | 19 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswd.c | 146 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswd.cat1 | 19 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswd_locl.h | 104 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswdd.8 | 88 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswdd.c | 612 | ||||
| -rw-r--r-- | crypto/heimdal/kpasswd/kpasswdd.cat8 | 53 |
10 files changed, 0 insertions, 2019 deletions
diff --git a/crypto/heimdal/kpasswd/Makefile.am b/crypto/heimdal/kpasswd/Makefile.am deleted file mode 100644 index 5e287a9c3779..000000000000 --- a/crypto/heimdal/kpasswd/Makefile.am +++ /dev/null @@ -1,31 +0,0 @@ -# $Id: Makefile.am,v 1.16 2001/08/28 08:31:29 assar Exp $ - -include $(top_srcdir)/Makefile.am.common - -INCLUDES += $(INCLUDE_des) - -man_MANS = kpasswd.1 kpasswdd.8 - -bin_PROGRAMS = kpasswd - -kpasswd_SOURCES = kpasswd.c kpasswd_locl.h - -libexec_PROGRAMS = kpasswdd - -noinst_PROGRAMS = kpasswd-generator - -kpasswdd_SOURCES = kpasswdd.c kpasswd_locl.h - -kpasswdd_LDADD = \ - $(top_builddir)/lib/kadm5/libkadm5srv.la \ - $(top_builddir)/lib/hdb/libhdb.la \ - $(LIB_openldap) \ - $(LDADD) \ - $(LIB_pidfile) \ - $(LIB_dlopen) \ - $(DBLIB) - -LDADD = $(top_builddir)/lib/krb5/libkrb5.la \ - $(LIB_des) \ - $(top_builddir)/lib/asn1/libasn1.la \ - $(LIB_roken) diff --git a/crypto/heimdal/kpasswd/Makefile.in b/crypto/heimdal/kpasswd/Makefile.in deleted file mode 100644 index 8a3afd62c678..000000000000 --- a/crypto/heimdal/kpasswd/Makefile.in +++ /dev/null @@ -1,747 +0,0 @@ -# Makefile.in generated by automake 1.6.1 from Makefile.am. -# @configure_input@ - -# Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 -# Free Software Foundation, Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -# $Id: Makefile.am,v 1.16 2001/08/28 08:31:29 assar Exp $ - -# $Id: Makefile.am.common,v 1.5 2002/05/19 18:35:37 joda Exp $ - -# $Id: Makefile.am.common,v 1.36 2002/08/19 16:10:25 joda Exp $ -SHELL = @SHELL@ - -srcdir = @srcdir@ -top_srcdir = @top_srcdir@ -VPATH = @srcdir@ -prefix = @prefix@ -exec_prefix = @exec_prefix@ - -bindir = @bindir@ -sbindir = @sbindir@ -libexecdir = @libexecdir@ -datadir = @datadir@ -sysconfdir = @sysconfdir@ -sharedstatedir = @sharedstatedir@ -localstatedir = @localstatedir@ -libdir = @libdir@ -infodir = @infodir@ -mandir = @mandir@ -includedir = @includedir@ -oldincludedir = /usr/include -pkgdatadir = $(datadir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -top_builddir = .. - -ACLOCAL = @ACLOCAL@ -AUTOCONF = @AUTOCONF@ -AUTOMAKE = @AUTOMAKE@ -AUTOHEADER = @AUTOHEADER@ - -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -INSTALL = @INSTALL@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_DATA = @INSTALL_DATA@ -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_HEADER = $(INSTALL_DATA) -transform = @program_transform_name@ -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -host_alias = @host_alias@ -host_triplet = @host@ - -EXEEXT = @EXEEXT@ -OBJEXT = @OBJEXT@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -AIX_EXTRA_KAFS = @AIX_EXTRA_KAFS@ -AMTAR = @AMTAR@ -AS = @AS@ -AWK = @AWK@ -CANONICAL_HOST = @CANONICAL_HOST@ -CATMAN = @CATMAN@ -CATMANEXT = @CATMANEXT@ -CC = @CC@ -COMPILE_ET = @COMPILE_ET@ -CPP = @CPP@ -DBLIB = @DBLIB@ -DEPDIR = @DEPDIR@ -DIR_com_err = @DIR_com_err@ -DIR_des = @DIR_des@ -DIR_roken = @DIR_roken@ -DLLTOOL = @DLLTOOL@ -ECHO = @ECHO@ -EXTRA_LIB45 = @EXTRA_LIB45@ -GROFF = @GROFF@ -INCLUDES_roken = @INCLUDES_roken@ -INCLUDE_ = @INCLUDE_@ -INCLUDE_des = @INCLUDE_des@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LEX = @LEX@ - -LEXLIB = @LEXLIB@ -LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@ -LIBTOOL = @LIBTOOL@ -LIB_ = @LIB_@ -LIB_AUTH_SUBDIRS = @LIB_AUTH_SUBDIRS@ -LIB_NDBM = @LIB_NDBM@ -LIB_com_err = @LIB_com_err@ -LIB_com_err_a = @LIB_com_err_a@ -LIB_com_err_so = @LIB_com_err_so@ -LIB_des = @LIB_des@ -LIB_des_a = @LIB_des_a@ -LIB_des_appl = @LIB_des_appl@ -LIB_des_so = @LIB_des_so@ -LIB_kdb = @LIB_kdb@ -LIB_otp = @LIB_otp@ -LIB_roken = @LIB_roken@ -LIB_security = @LIB_security@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -NEED_WRITEAUTH_FALSE = @NEED_WRITEAUTH_FALSE@ -NEED_WRITEAUTH_TRUE = @NEED_WRITEAUTH_TRUE@ -NROFF = @NROFF@ -OBJDUMP = @OBJDUMP@ -PACKAGE = @PACKAGE@ -RANLIB = @RANLIB@ -STRIP = @STRIP@ -VERSION = @VERSION@ -VOID_RETSIGTYPE = @VOID_RETSIGTYPE@ -WFLAGS = @WFLAGS@ -WFLAGS_NOIMPLICITINT = @WFLAGS_NOIMPLICITINT@ -WFLAGS_NOUNUSED = @WFLAGS_NOUNUSED@ -X_CFLAGS = @X_CFLAGS@ -X_EXTRA_LIBS = @X_EXTRA_LIBS@ -X_LIBS = @X_LIBS@ -X_PRE_LIBS = @X_PRE_LIBS@ -YACC = @YACC@ -am__include = @am__include@ -am__quote = @am__quote@ -dpagaix_cflags = @dpagaix_cflags@ -dpagaix_ldadd = @dpagaix_ldadd@ -dpagaix_ldflags = @dpagaix_ldflags@ -install_sh = @install_sh@ - -AUTOMAKE_OPTIONS = foreign no-dependencies 1.6 - -SUFFIXES = .et .h .x .1 .3 .5 .8 .cat1 .cat3 .cat5 .cat8 - -INCLUDES = -I$(top_builddir)/include $(INCLUDES_roken) $(INCLUDE_des) - -@do_roken_rename_TRUE@ROKEN_RENAME = -DROKEN_RENAME - -AM_CFLAGS = $(WFLAGS) - -CP = cp - -buildinclude = $(top_builddir)/include - -LIB_XauReadAuth = @LIB_XauReadAuth@ -LIB_crypt = @LIB_crypt@ -LIB_dbm_firstkey = @LIB_dbm_firstkey@ -LIB_dbopen = @LIB_dbopen@ -LIB_dlopen = @LIB_dlopen@ -LIB_dn_expand = @LIB_dn_expand@ -LIB_el_init = @LIB_el_init@ -LIB_getattr = @LIB_getattr@ -LIB_gethostbyname = @LIB_gethostbyname@ -LIB_getpwent_r = @LIB_getpwent_r@ -LIB_getpwnam_r = @LIB_getpwnam_r@ -LIB_getsockopt = @LIB_getsockopt@ -LIB_logout = @LIB_logout@ -LIB_logwtmp = @LIB_logwtmp@ -LIB_odm_initialize = @LIB_odm_initialize@ -LIB_openpty = @LIB_openpty@ -LIB_pidfile = @LIB_pidfile@ -LIB_res_search = @LIB_res_search@ -LIB_setpcred = @LIB_setpcred@ -LIB_setsockopt = @LIB_setsockopt@ -LIB_socket = @LIB_socket@ -LIB_syslog = @LIB_syslog@ -LIB_tgetent = @LIB_tgetent@ - -HESIODLIB = @HESIODLIB@ -HESIODINCLUDE = @HESIODINCLUDE@ -INCLUDE_hesiod = @INCLUDE_hesiod@ -LIB_hesiod = @LIB_hesiod@ - -INCLUDE_krb4 = @INCLUDE_krb4@ -LIB_krb4 = @LIB_krb4@ - -INCLUDE_openldap = @INCLUDE_openldap@ -LIB_openldap = @LIB_openldap@ - -INCLUDE_readline = @INCLUDE_readline@ -LIB_readline = @LIB_readline@ - -NROFF_MAN = groff -mandoc -Tascii - -@KRB4_TRUE@LIB_kafs = $(top_builddir)/lib/kafs/libkafs.la $(AIX_EXTRA_KAFS) - -@KRB5_TRUE@LIB_krb5 = $(top_builddir)/lib/krb5/libkrb5.la \ -@KRB5_TRUE@ $(top_builddir)/lib/asn1/libasn1.la - -@KRB5_TRUE@LIB_gssapi = $(top_builddir)/lib/gssapi/libgssapi.la - -@DCE_TRUE@LIB_kdfs = $(top_builddir)/lib/kdfs/libkdfs.la - -man_MANS = kpasswd.1 kpasswdd.8 - -bin_PROGRAMS = kpasswd - -kpasswd_SOURCES = kpasswd.c kpasswd_locl.h - -libexec_PROGRAMS = kpasswdd - -noinst_PROGRAMS = kpasswd-generator - -kpasswdd_SOURCES = kpasswdd.c kpasswd_locl.h - -kpasswdd_LDADD = \ - $(top_builddir)/lib/kadm5/libkadm5srv.la \ - $(top_builddir)/lib/hdb/libhdb.la \ - $(LIB_openldap) \ - $(LDADD) \ - $(LIB_pidfile) \ - $(LIB_dlopen) \ - $(DBLIB) - - -LDADD = $(top_builddir)/lib/krb5/libkrb5.la \ - $(LIB_des) \ - $(top_builddir)/lib/asn1/libasn1.la \ - $(LIB_roken) - -subdir = kpasswd -mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs -CONFIG_HEADER = $(top_builddir)/include/config.h -CONFIG_CLEAN_FILES = -bin_PROGRAMS = kpasswd$(EXEEXT) -libexec_PROGRAMS = kpasswdd$(EXEEXT) -noinst_PROGRAMS = kpasswd-generator$(EXEEXT) -PROGRAMS = $(bin_PROGRAMS) $(libexec_PROGRAMS) $(noinst_PROGRAMS) - -am_kpasswd_OBJECTS = kpasswd.$(OBJEXT) -kpasswd_OBJECTS = $(am_kpasswd_OBJECTS) -kpasswd_LDADD = $(LDADD) -kpasswd_DEPENDENCIES = $(top_builddir)/lib/krb5/libkrb5.la \ - $(top_builddir)/lib/asn1/libasn1.la -kpasswd_LDFLAGS = -kpasswd_generator_SOURCES = kpasswd-generator.c -kpasswd_generator_OBJECTS = kpasswd-generator.$(OBJEXT) -kpasswd_generator_LDADD = $(LDADD) -kpasswd_generator_DEPENDENCIES = $(top_builddir)/lib/krb5/libkrb5.la \ - $(top_builddir)/lib/asn1/libasn1.la -kpasswd_generator_LDFLAGS = -am_kpasswdd_OBJECTS = kpasswdd.$(OBJEXT) -kpasswdd_OBJECTS = $(am_kpasswdd_OBJECTS) -kpasswdd_DEPENDENCIES = $(top_builddir)/lib/kadm5/libkadm5srv.la \ - $(top_builddir)/lib/hdb/libhdb.la \ - $(top_builddir)/lib/krb5/libkrb5.la \ - $(top_builddir)/lib/asn1/libasn1.la -kpasswdd_LDFLAGS = - -DEFS = @DEFS@ -DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir)/include -CPPFLAGS = @CPPFLAGS@ -LDFLAGS = @LDFLAGS@ -LIBS = @LIBS@ -depcomp = -am__depfiles_maybe = -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) \ - $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -CCLD = $(CC) -LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ - $(AM_LDFLAGS) $(LDFLAGS) -o $@ -CFLAGS = @CFLAGS@ -DIST_SOURCES = $(kpasswd_SOURCES) kpasswd-generator.c \ - $(kpasswdd_SOURCES) -MANS = $(man_MANS) -DIST_COMMON = Makefile.am Makefile.in -SOURCES = $(kpasswd_SOURCES) kpasswd-generator.c $(kpasswdd_SOURCES) - -all: all-am - -.SUFFIXES: -.SUFFIXES: .et .h .x .1 .3 .5 .8 .cat1 .cat3 .cat5 .cat8 .c .lo .o .obj -$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/Makefile.am.common $(top_srcdir)/cf/Makefile.am.common $(top_srcdir)/configure.in $(ACLOCAL_M4) - cd $(top_srcdir) && \ - $(AUTOMAKE) --foreign kpasswd/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe) -binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) -install-binPROGRAMS: $(bin_PROGRAMS) - @$(NORMAL_INSTALL) - $(mkinstalldirs) $(DESTDIR)$(bindir) - @list='$(bin_PROGRAMS)'; for p in $$list; do \ - p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ - if test -f $$p \ - || test -f $$p1 \ - ; then \ - p1=`echo "$$p1" | sed -e 's,^.*/,,'`; \ - f=`echo $$p1|sed '$(transform);s/$$/$(EXEEXT)/'`; \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) $$p $(DESTDIR)$(bindir)/$$f"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) $$p $(DESTDIR)$(bindir)/$$f; \ - else :; fi; \ - done - -uninstall-binPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(bin_PROGRAMS)'; for p in $$list; do \ - f=`echo $$p|sed 's/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ - f=`echo "$$f" | sed -e 's,^.*/,,'`; \ - echo " rm -f $(DESTDIR)$(bindir)/$$f"; \ - rm -f $(DESTDIR)$(bindir)/$$f; \ - done - -clean-binPROGRAMS: - -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) -libexecPROGRAMS_INSTALL = $(INSTALL_PROGRAM) -install-libexecPROGRAMS: $(libexec_PROGRAMS) - @$(NORMAL_INSTALL) - $(mkinstalldirs) $(DESTDIR)$(libexecdir) - @list='$(libexec_PROGRAMS)'; for p in $$list; do \ - p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ - if test -f $$p \ - || test -f $$p1 \ - ; then \ - p1=`echo "$$p1" | sed -e 's,^.*/,,'`; \ - f=`echo $$p1|sed '$(transform);s/$$/$(EXEEXT)/'`; \ - echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(libexecPROGRAMS_INSTALL) $$p $(DESTDIR)$(libexecdir)/$$f"; \ - $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(libexecPROGRAMS_INSTALL) $$p $(DESTDIR)$(libexecdir)/$$f; \ - else :; fi; \ - done - -uninstall-libexecPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(libexec_PROGRAMS)'; for p in $$list; do \ - f=`echo $$p|sed 's/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ - f=`echo "$$f" | sed -e 's,^.*/,,'`; \ - echo " rm -f $(DESTDIR)$(libexecdir)/$$f"; \ - rm -f $(DESTDIR)$(libexecdir)/$$f; \ - done - -clean-libexecPROGRAMS: - -test -z "$(libexec_PROGRAMS)" || rm -f $(libexec_PROGRAMS) - -clean-noinstPROGRAMS: - -test -z "$(noinst_PROGRAMS)" || rm -f $(noinst_PROGRAMS) -kpasswd$(EXEEXT): $(kpasswd_OBJECTS) $(kpasswd_DEPENDENCIES) - @rm -f kpasswd$(EXEEXT) - $(LINK) $(kpasswd_LDFLAGS) $(kpasswd_OBJECTS) $(kpasswd_LDADD) $(LIBS) -kpasswd-generator$(EXEEXT): $(kpasswd_generator_OBJECTS) $(kpasswd_generator_DEPENDENCIES) - @rm -f kpasswd-generator$(EXEEXT) - $(LINK) $(kpasswd_generator_LDFLAGS) $(kpasswd_generator_OBJECTS) $(kpasswd_generator_LDADD) $(LIBS) -kpasswdd$(EXEEXT): $(kpasswdd_OBJECTS) $(kpasswdd_DEPENDENCIES) - @rm -f kpasswdd$(EXEEXT) - $(LINK) $(kpasswdd_LDFLAGS) $(kpasswdd_OBJECTS) $(kpasswdd_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) core *.core - -distclean-compile: - -rm -f *.tab.c - -.c.o: - $(COMPILE) -c `test -f '$<' || echo '$(srcdir)/'`$< - -.c.obj: - $(COMPILE) -c `cygpath -w $<` - -.c.lo: - $(LTCOMPILE) -c -o $@ `test -f '$<' || echo '$(srcdir)/'`$< - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs - -distclean-libtool: - -rm -f libtool -uninstall-info-am: - -man1dir = $(mandir)/man1 -install-man1: $(man1_MANS) $(man_MANS) - @$(NORMAL_INSTALL) - $(mkinstalldirs) $(DESTDIR)$(man1dir) - @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.1*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ - else file=$$i; fi; \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " $(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst"; \ - $(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst; \ - done -uninstall-man1: - @$(NORMAL_UNINSTALL) - @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.1*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " rm -f $(DESTDIR)$(man1dir)/$$inst"; \ - rm -f $(DESTDIR)$(man1dir)/$$inst; \ - done - -man8dir = $(mandir)/man8 -install-man8: $(man8_MANS) $(man_MANS) - @$(NORMAL_INSTALL) - $(mkinstalldirs) $(DESTDIR)$(man8dir) - @list='$(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.8*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \ - else file=$$i; fi; \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " $(INSTALL_DATA) $$file $(DESTDIR)$(man8dir)/$$inst"; \ - $(INSTALL_DATA) $$file $(DESTDIR)$(man8dir)/$$inst; \ - done -uninstall-man8: - @$(NORMAL_UNINSTALL) - @list='$(man8_MANS) $(dist_man8_MANS) $(nodist_man8_MANS)'; \ - l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \ - for i in $$l2; do \ - case "$$i" in \ - *.8*) list="$$list $$i" ;; \ - esac; \ - done; \ - for i in $$list; do \ - ext=`echo $$i | sed -e 's/^.*\\.//'`; \ - inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \ - inst=`echo $$inst | sed -e 's/^.*\///'`; \ - inst=`echo $$inst | sed '$(transform)'`.$$ext; \ - echo " rm -f $(DESTDIR)$(man8dir)/$$inst"; \ - rm -f $(DESTDIR)$(man8dir)/$$inst; \ - done - -ETAGS = etags -ETAGSFLAGS = - -tags: TAGS - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - mkid -fID $$unique - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - test -z "$(ETAGS_ARGS)$$tags$$unique" \ - || $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$tags $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && cd $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) $$here - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) - -top_distdir = .. -distdir = $(top_distdir)/$(PACKAGE)-$(VERSION) - -distdir: $(DISTFILES) - @for file in $(DISTFILES); do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test "$$dir" != "$$file" && test "$$dir" != "."; then \ - dir="/$$dir"; \ - $(mkinstalldirs) "$(distdir)$$dir"; \ - else \ - dir=''; \ - fi; \ - if test -d $$d/$$file; then \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ - fi; \ - cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ - else \ - test -f $(distdir)/$$file \ - || cp -p $$d/$$file $(distdir)/$$file \ - || exit 1; \ - fi; \ - done - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="${top_distdir}" distdir="$(distdir)" \ - dist-hook -check-am: all-am - $(MAKE) $(AM_MAKEFLAGS) check-local -check: check-am -all-am: Makefile $(PROGRAMS) $(MANS) all-local - -installdirs: - $(mkinstalldirs) $(DESTDIR)$(bindir) $(DESTDIR)$(libexecdir) $(DESTDIR)$(man1dir) $(DESTDIR)$(man8dir) - -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -rm -f Makefile $(CONFIG_CLEAN_FILES) stamp-h stamp-h[0-9]* - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ - clean-libtool clean-noinstPROGRAMS mostlyclean-am - -distclean: distclean-am - -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-libtool distclean-tags - -dvi: dvi-am - -dvi-am: - -info: info-am - -info-am: - -install-data-am: install-data-local install-man - -install-exec-am: install-binPROGRAMS install-libexecPROGRAMS - @$(NORMAL_INSTALL) - $(MAKE) $(AM_MAKEFLAGS) install-exec-hook - -install-info: install-info-am - -install-man: install-man1 install-man8 - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic \ - mostlyclean-libtool - -uninstall-am: uninstall-binPROGRAMS uninstall-info-am \ - uninstall-libexecPROGRAMS uninstall-man - -uninstall-man: uninstall-man1 uninstall-man8 - -.PHONY: GTAGS all all-am all-local check check-am check-local clean \ - clean-binPROGRAMS clean-generic clean-libexecPROGRAMS \ - clean-libtool clean-noinstPROGRAMS distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am info info-am install install-am install-binPROGRAMS \ - install-data install-data-am install-data-local install-exec \ - install-exec-am install-info install-info-am \ - install-libexecPROGRAMS install-man install-man1 install-man8 \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ - tags uninstall uninstall-am uninstall-binPROGRAMS \ - uninstall-info-am uninstall-libexecPROGRAMS uninstall-man \ - uninstall-man1 uninstall-man8 - - -install-suid-programs: - @foo='$(bin_SUIDS)'; \ - for file in $$foo; do \ - x=$(DESTDIR)$(bindir)/$$file; \ - if chown 0:0 $$x && chmod u+s $$x; then :; else \ - echo "*"; \ - echo "* Failed to install $$x setuid root"; \ - echo "*"; \ - fi; done - -install-exec-hook: install-suid-programs - -install-build-headers:: $(include_HEADERS) $(build_HEADERZ) - @foo='$(include_HEADERS) $(nodist_include_HEADERS) $(build_HEADERZ)'; \ - for f in $$foo; do \ - f=`basename $$f`; \ - if test -f "$(srcdir)/$$f"; then file="$(srcdir)/$$f"; \ - else file="$$f"; fi; \ - if cmp -s $$file $(buildinclude)/$$f 2> /dev/null ; then \ - : ; else \ - echo " $(CP) $$file $(buildinclude)/$$f"; \ - $(CP) $$file $(buildinclude)/$$f; \ - fi ; \ - done - -all-local: install-build-headers - -check-local:: - @if test '$(CHECK_LOCAL)'; then \ - foo='$(CHECK_LOCAL)'; else \ - foo='$(PROGRAMS)'; fi; \ - if test "$$foo"; then \ - failed=0; all=0; \ - for i in $$foo; do \ - all=`expr $$all + 1`; \ - if ./$$i --version > /dev/null 2>&1; then \ - echo "PASS: $$i"; \ - else \ - echo "FAIL: $$i"; \ - failed=`expr $$failed + 1`; \ - fi; \ - done; \ - if test "$$failed" -eq 0; then \ - banner="All $$all tests passed"; \ - else \ - banner="$$failed of $$all tests failed"; \ - fi; \ - dashes=`echo "$$banner" | sed s/./=/g`; \ - echo "$$dashes"; \ - echo "$$banner"; \ - echo "$$dashes"; \ - test "$$failed" -eq 0; \ - fi - -.x.c: - @cmp -s $< $@ 2> /dev/null || cp $< $@ -#NROFF_MAN = nroff -man -.1.cat1: - $(NROFF_MAN) $< > $@ -.3.cat3: - $(NROFF_MAN) $< > $@ -.5.cat5: - $(NROFF_MAN) $< > $@ -.8.cat8: - $(NROFF_MAN) $< > $@ - -dist-cat1-mans: - @foo='$(man1_MANS)'; \ - bar='$(man_MANS)'; \ - for i in $$bar; do \ - case $$i in \ - *.1) foo="$$foo $$i";; \ - esac; done ;\ - for i in $$foo; do \ - x=`echo $$i | sed 's/\.[^.]*$$/.cat1/'`; \ - echo "$(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x"; \ - $(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x; \ - done - -dist-cat3-mans: - @foo='$(man3_MANS)'; \ - bar='$(man_MANS)'; \ - for i in $$bar; do \ - case $$i in \ - *.3) foo="$$foo $$i";; \ - esac; done ;\ - for i in $$foo; do \ - x=`echo $$i | sed 's/\.[^.]*$$/.cat3/'`; \ - echo "$(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x"; \ - $(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x; \ - done - -dist-cat5-mans: - @foo='$(man5_MANS)'; \ - bar='$(man_MANS)'; \ - for i in $$bar; do \ - case $$i in \ - *.5) foo="$$foo $$i";; \ - esac; done ;\ - for i in $$foo; do \ - x=`echo $$i | sed 's/\.[^.]*$$/.cat5/'`; \ - echo "$(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x"; \ - $(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x; \ - done - -dist-cat8-mans: - @foo='$(man8_MANS)'; \ - bar='$(man_MANS)'; \ - for i in $$bar; do \ - case $$i in \ - *.8) foo="$$foo $$i";; \ - esac; done ;\ - for i in $$foo; do \ - x=`echo $$i | sed 's/\.[^.]*$$/.cat8/'`; \ - echo "$(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x"; \ - $(NROFF_MAN) $(srcdir)/$$i > $(distdir)/$$x; \ - done - -dist-hook: dist-cat1-mans dist-cat3-mans dist-cat5-mans dist-cat8-mans - -install-cat-mans: - $(SHELL) $(top_srcdir)/cf/install-catman.sh "$(INSTALL_DATA)" "$(mkinstalldirs)" "$(srcdir)" "$(DESTDIR)$(mandir)" '$(CATMANEXT)' $(man_MANS) $(man1_MANS) $(man3_MANS) $(man5_MANS) $(man8_MANS) - -install-data-local: install-cat-mans - -.et.h: - $(COMPILE_ET) $< -.et.c: - $(COMPILE_ET) $< -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/crypto/heimdal/kpasswd/kpasswd-generator.c b/crypto/heimdal/kpasswd/kpasswd-generator.c deleted file mode 100644 index 202dcfc877ca..000000000000 --- a/crypto/heimdal/kpasswd/kpasswd-generator.c +++ /dev/null @@ -1,200 +0,0 @@ -/* - * Copyright (c) 2000 - 2001 Kungliga Tekniska Högskolan - * (Royal Institute of Technology, Stockholm, Sweden). - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * 3. Neither the name of the Institute nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#include "kpasswd_locl.h" - -RCSID("$Id: kpasswd-generator.c,v 1.5 2001/07/31 02:44:42 assar Exp $"); - -static unsigned -read_words (const char *filename, char ***ret_w) -{ - unsigned n, alloc; - FILE *f; - char buf[256]; - char **w = NULL; - - f = fopen (filename, "r"); - if (f == NULL) - err (1, "cannot open %s", filename); - alloc = n = 0; - while (fgets (buf, sizeof(buf), f) != NULL) { - if (buf[strlen (buf) - 1] == '\n') - buf[strlen (buf) - 1] = '\0'; - if (n >= alloc) { - alloc += 16; - w = erealloc (w, alloc * sizeof(char **)); - } - w[n++] = estrdup (buf); - } - *ret_w = w; - return n; -} - -static int -nop_prompter (krb5_context context, - void *data, - const char *name, - const char *banner, - int num_prompts, - krb5_prompt prompts[]) -{ - return 0; -} - -static void -generate_requests (const char *filename, unsigned nreq) -{ - krb5_context context; - krb5_error_code ret; - int i; - char **words; - unsigned nwords; - - ret = krb5_init_context (&context); - if (ret) - errx (1, "krb5_init_context failed: %d", ret); - - nwords = read_words (filename, &words); - - for (i = 0; i < nreq; ++i) { - char *name = words[rand() % nwords]; - krb5_get_init_creds_opt opt; - krb5_creds cred; - krb5_principal principal; - int result_code; - krb5_data result_code_string, result_string; - char *old_pwd, *new_pwd; - - krb5_get_init_creds_opt_init (&opt); - krb5_get_init_creds_opt_set_tkt_life (&opt, 300); - krb5_get_init_creds_opt_set_forwardable (&opt, FALSE); - krb5_get_init_creds_opt_set_proxiable (&opt, FALSE); - - ret = krb5_parse_name (context, name, &principal); - if (ret) - krb5_err (context, 1, ret, "krb5_parse_name %s", name); - - asprintf (&old_pwd, "%s", name); - asprintf (&new_pwd, "%s2", name); - - ret = krb5_get_init_creds_password (context, - &cred, - principal, - old_pwd, - nop_prompter, - NULL, - 0, - "kadmin/changepw", - &opt); - if( ret == KRB5KRB_AP_ERR_BAD_INTEGRITY - || ret == KRB5KRB_AP_ERR_MODIFIED) { - char *tmp; - - tmp = new_pwd; - new_pwd = old_pwd; - old_pwd = tmp; - - ret = krb5_get_init_creds_password (context, - &cred, - principal, - old_pwd, - nop_prompter, - NULL, - 0, - "kadmin/changepw", - &opt); - } - if (ret) - krb5_err (context, 1, ret, "krb5_get_init_creds_password"); - - krb5_free_principal (context, principal); - - ret = krb5_change_password (context, &cred, new_pwd, - &result_code, - &result_code_string, - &result_string); - if (ret) - krb5_err (context, 1, ret, "krb5_change_password"); - - free (old_pwd); - free (new_pwd); - krb5_free_creds_contents (context, &cred); - } -} - -static int version_flag = 0; -static int help_flag = 0; - -static struct getargs args[] = { - { "version", 0, arg_flag, &version_flag }, - { "help", 0, arg_flag, &help_flag } -}; - -static void -usage (int ret) -{ - arg_printusage (args, - sizeof(args)/sizeof(*args), - NULL, - "file [number]"); - exit (ret); -} - -int -main(int argc, char **argv) -{ - int optind = 0; - int nreq; - char *end; - - setprogname(argv[0]); - if(getarg(args, sizeof(args) / sizeof(args[0]), argc, argv, &optind)) - usage(1); - if (help_flag) - usage (0); - if (version_flag) { - print_version(NULL); - return 0; - } - argc -= optind; - argv += optind; - - if (argc != 2) - usage (1); - srand (0); - nreq = strtol (argv[1], &end, 0); - if (argv[1] == end || *end != '\0') - usage (1); - generate_requests (argv[0], nreq); - return 0; -} diff --git a/crypto/heimdal/kpasswd/kpasswd.1 b/crypto/heimdal/kpasswd/kpasswd.1 deleted file mode 100644 index 5d017a6d211d..000000000000 --- a/crypto/heimdal/kpasswd/kpasswd.1 +++ /dev/null @@ -1,19 +0,0 @@ -.\" $Id: kpasswd.1,v 1.4 2002/08/28 14:23:10 joda Exp $ -.\" -.Dd August 27, 1997 -.Dt KPASSWD 1 -.Os HEIMDAL -.Sh NAME -.Nm kpasswd -.Nd Kerberos 5 password changing program -.Sh SYNOPSIS -.Nm -.Op Ar principal -.Sh DESCRIPTION -.Nm -is the client for changing passwords. -.Sh DIAGNOSTICS -If the password quality check fails or some other error occurs, an -explanation is printed. -.Sh SEE ALSO -.Xr kpasswdd 8 diff --git a/crypto/heimdal/kpasswd/kpasswd.c b/crypto/heimdal/kpasswd/kpasswd.c deleted file mode 100644 index 02f95579250d..000000000000 --- a/crypto/heimdal/kpasswd/kpasswd.c +++ /dev/null @@ -1,146 +0,0 @@ -/* - * Copyright (c) 1997-2001 Kungliga Tekniska Högskolan - * (Royal Institute of Technology, Stockholm, Sweden). - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * 3. Neither the name of the Institute nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#include "kpasswd_locl.h" -RCSID("$Id: kpasswd.c,v 1.24 2001/09/27 01:29:40 assar Exp $"); - -static int version_flag; -static int help_flag; - -static struct getargs args[] = { - { "version", 0, arg_flag, &version_flag }, - { "help", 0, arg_flag, &help_flag } -}; - -static void -usage (int ret, struct getargs *a, int num_args) -{ - arg_printusage (a, num_args, NULL, "[principal]"); - exit (ret); -} - -int -main (int argc, char **argv) -{ - krb5_error_code ret; - krb5_context context; - krb5_principal principal; - int optind = 0; - krb5_get_init_creds_opt opt; - krb5_creds cred; - int result_code; - krb5_data result_code_string, result_string; - char pwbuf[BUFSIZ]; - - optind = krb5_program_setup(&context, argc, argv, - args, sizeof(args) / sizeof(args[0]), usage); - - if (help_flag) - usage (0, args, sizeof(args) / sizeof(args[0])); - - if(version_flag){ - print_version (NULL); - exit(0); - } - - krb5_get_init_creds_opt_init (&opt); - - krb5_get_init_creds_opt_set_tkt_life (&opt, 300); - krb5_get_init_creds_opt_set_forwardable (&opt, FALSE); - krb5_get_init_creds_opt_set_proxiable (&opt, FALSE); - - argc -= optind; - argv += optind; - - if (argc > 1) - usage (1, args, sizeof(args) / sizeof(args[0])); - - ret = krb5_init_context (&context); - if (ret) - errx (1, "krb5_init_context failed: %d", ret); - - if(argv[0]) { - ret = krb5_parse_name (context, argv[0], &principal); - if (ret) - krb5_err (context, 1, ret, "krb5_parse_name"); - } else - principal = NULL; - - ret = krb5_get_init_creds_password (context, - &cred, - principal, - NULL, - krb5_prompter_posix, - NULL, - 0, - "kadmin/changepw", - &opt); - switch (ret) { - case 0: - break; - case KRB5_LIBOS_PWDINTR : - return 1; - case KRB5KRB_AP_ERR_BAD_INTEGRITY : - case KRB5KRB_AP_ERR_MODIFIED : - krb5_errx(context, 1, "Password incorrect"); - break; - default: - krb5_err(context, 1, ret, "krb5_get_init_creds"); - } - - krb5_data_zero (&result_code_string); - krb5_data_zero (&result_string); - - if(des_read_pw_string (pwbuf, sizeof(pwbuf), "New password: ", 1) != 0) - return 1; - - ret = krb5_change_password (context, &cred, pwbuf, - &result_code, - &result_code_string, - &result_string); - if (ret) - krb5_err (context, 1, ret, "krb5_change_password"); - - printf ("%s%s%.*s\n", krb5_passwd_result_to_string(context, - result_code), - result_string.length > 0 ? " : " : "", - (int)result_string.length, - (char *)result_string.data); - - krb5_data_free (&result_code_string); - krb5_data_free (&result_string); - - krb5_free_creds_contents (context, &cred); - krb5_free_context (context); - return result_code; -} diff --git a/crypto/heimdal/kpasswd/kpasswd.cat1 b/crypto/heimdal/kpasswd/kpasswd.cat1 deleted file mode 100644 index e76e9cc85ed9..000000000000 --- a/crypto/heimdal/kpasswd/kpasswd.cat1 +++ /dev/null @@ -1,19 +0,0 @@ -KPASSWD(1) NetBSD Reference Manual KPASSWD(1) - -NNAAMMEE - kkppaasssswwdd - Kerberos 5 password changing program - -SSYYNNOOPPSSIISS - kkppaasssswwdd [_p_r_i_n_c_i_p_a_l] - -DDEESSCCRRIIPPTTIIOONN - kkppaasssswwdd is the client for changing passwords. - -DDIIAAGGNNOOSSTTIICCSS - If the password quality check fails or some other error occurs, an expla- - nation is printed. - -SSEEEE AALLSSOO - kpasswdd(8) - - HEIMDAL August 27, 1997 1 diff --git a/crypto/heimdal/kpasswd/kpasswd_locl.h b/crypto/heimdal/kpasswd/kpasswd_locl.h deleted file mode 100644 index c254f6f20f0e..000000000000 --- a/crypto/heimdal/kpasswd/kpasswd_locl.h +++ /dev/null @@ -1,104 +0,0 @@ -/* - * Copyright (c) 1997 - 2001 Kungliga Tekniska Högskolan - * (Royal Institute of Technology, Stockholm, Sweden). - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * 3. Neither the name of the Institute nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -/* $Id: kpasswd_locl.h,v 1.13 2002/09/10 20:03:48 joda Exp $ */ - -#ifndef __KPASSWD_LOCL_H__ -#define __KPASSWD_LOCL_H__ - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#ifdef HAVE_SYS_TYPES_H -#include <sys/types.h> -#endif -#ifdef HAVE_FCNTL_H -#include <fcntl.h> -#endif -#ifdef HAVE_SYS_UIO_H -#include <sys/uio.h> -#endif -#ifdef HAVE_UNISTD_H -#include <unistd.h> -#endif -#ifdef HAVE_PWD_H -#include <pwd.h> -#endif -#ifdef HAVE_SYS_TIME_H -#include <sys/time.h> -#endif -#ifdef HAVE_SYS_SELECT_H -#include <sys/select.h> -#endif -#ifdef HAVE_SYS_SOCKET_H -#include <sys/socket.h> -#endif -#ifdef HAVE_NETINET_IN_H -#include <netinet/in.h> -#endif -#ifdef HAVE_NETINET_IN6_H -#include <netinet/in6.h> -#endif -#ifdef HAVE_NETINET6_IN6_H -#include <netinet6/in6.h> -#endif - -#ifdef HAVE_ARPA_INET_H -#include <arpa/inet.h> -#endif -#ifdef HAVE_NETDB_H -#include <netdb.h> -#endif -#ifdef HAVE_ERRNO_H -#include <errno.h> -#endif -#ifdef HAVE_DLFCN_H -#include <dlfcn.h> -#endif -#ifdef HAVE_UTIL_H -#include <util.h> -#endif -#ifdef HAVE_LIBUTIL_H -#include <libutil.h> -#endif -#include <err.h> -#include <roken.h> -#include <getarg.h> -#include <krb5.h> -#include "crypto-headers.h" /* for des_read_pw_string */ - -#endif /* __KPASSWD_LOCL_H__ */ diff --git a/crypto/heimdal/kpasswd/kpasswdd.8 b/crypto/heimdal/kpasswd/kpasswdd.8 deleted file mode 100644 index fb4d199170bc..000000000000 --- a/crypto/heimdal/kpasswd/kpasswdd.8 +++ /dev/null @@ -1,88 +0,0 @@ -.\" $Id: kpasswdd.8,v 1.7 2002/08/20 16:37:17 joda Exp $ -.\" -.Dd April 19, 1999 -.Dt KPASSWDD 8 -.Os HEIMDAL -.Sh NAME -.Nm kpasswdd -.Nd Kerberos 5 password changing server -.Sh SYNOPSIS -.Nm -.Op Fl -check-library= Ns Ar library -.Op Fl -check-function= Ns Ar function -.Oo Fl k Ar kspec \*(Ba Xo -.Fl -keytab= Ns Ar kspec -.Xc -.Oc -.Oo Fl r Ar realm \*(Ba Xo -.Fl -realm= Ns Ar realm -.Xc -.Oc -.Oo Fl p Ar string \*(Ba Xo -.Fl -port= Ns Ar string -.Xc -.Oc -.Op Fl -version -.Op Fl -help -.Sh DESCRIPTION -.Nm -serves request for password changes. It listens on UDP port 464 -(service kpasswd) and processes requests when they arrive. It changes -the database directly and should thus only run on the master KDC. -.Pp -Supported options: -.Bl -tag -width Ds -.It Xo -.Fl -check-library= Ns Ar library -.Xc -If your system has support for dynamic loading of shared libraries, -you can use an external function to check password quality. This -option specifies which library to load. -.It Xo -.Fl -check-function= Ns Ar function -.Xc -This is the function to call in the loaded library. The function -should look like this: -.Pp -.Ft const char * -.Fn passwd_check "krb5_context context" "krb5_principal principal" "krb5_data *password" -.Pp -.Fa context -is an initialized context; -.Fa principal -is the one who tries to change passwords, and -.Fa password -is the new password. Note that the password (in -.Fa password->data ) -is not zero terminated. -.It Xo -.Fl k Ar kspec , -.Fl -keytab= Ns Ar kspec -.Xc -keytab to get authentication key from -.It Xo -.Fl r Ar realm , -.Fl -realm= Ns Ar realm -.Xc -default realm -.It Xo -.Fl p Ar string , -.Fl -port= Ns Ar string -.Xc -port to listen on (default service kpasswd - 464). -.El -.Sh DIAGNOSTICS -If an error occurs, the error message is returned to the user and/or -logged to syslog. -.Sh BUGS -The default password quality checks are too basic. -.Sh SEE ALSO -.Xr kpasswd 1 , -.Xr kdc 8 -.\".Sh ENVIRONMENT -.\".Sh FILES -.\".Sh EXAMPLES -.\".Sh SEE ALSO -.\".Sh STANDARDS -.\".Sh HISTORY -.\".Sh AUTHORS diff --git a/crypto/heimdal/kpasswd/kpasswdd.c b/crypto/heimdal/kpasswd/kpasswdd.c deleted file mode 100644 index d3a0a27aaab1..000000000000 --- a/crypto/heimdal/kpasswd/kpasswdd.c +++ /dev/null @@ -1,612 +0,0 @@ -/* - * Copyright (c) 1997-2002 Kungliga Tekniska Högskolan - * (Royal Institute of Technology, Stockholm, Sweden). - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * 3. Neither the name of the Institute nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#include "kpasswd_locl.h" -RCSID("$Id: kpasswdd.c,v 1.53 2002/08/19 15:07:31 joda Exp $"); - -#include <kadm5/admin.h> -#ifdef HAVE_SYS_UN_H -#include <sys/un.h> -#endif -#include <hdb.h> -#include <kadm5/private.h> - -static krb5_context context; -static krb5_log_facility *log_facility; - -static sig_atomic_t exit_flag = 0; - -static void -send_reply (int s, - struct sockaddr *sa, - int sa_size, - krb5_data *ap_rep, - krb5_data *rest) -{ - struct msghdr msghdr; - struct iovec iov[3]; - u_int16_t len, ap_rep_len; - u_char header[6]; - u_char *p; - - if (ap_rep) - ap_rep_len = ap_rep->length; - else - ap_rep_len = 0; - - len = 6 + ap_rep_len + rest->length; - p = header; - *p++ = (len >> 8) & 0xFF; - *p++ = (len >> 0) & 0xFF; - *p++ = 0; - *p++ = 1; - *p++ = (ap_rep_len >> 8) & 0xFF; - *p++ = (ap_rep_len >> 0) & 0xFF; - - memset (&msghdr, 0, sizeof(msghdr)); - msghdr.msg_name = (void *)sa; - msghdr.msg_namelen = sa_size; - msghdr.msg_iov = iov; - msghdr.msg_iovlen = sizeof(iov)/sizeof(*iov); -#if 0 - msghdr.msg_control = NULL; - msghdr.msg_controllen = 0; -#endif - - iov[0].iov_base = (char *)header; - iov[0].iov_len = 6; - if (ap_rep_len) { - iov[1].iov_base = ap_rep->data; - iov[1].iov_len = ap_rep->length; - } else { - iov[1].iov_base = NULL; - iov[1].iov_len = 0; - } - iov[2].iov_base = rest->data; - iov[2].iov_len = rest->length; - - if (sendmsg (s, &msghdr, 0) < 0) - krb5_warn (context, errno, "sendmsg"); -} - -static int -make_result (krb5_data *data, - u_int16_t result_code, - const char *expl) -{ - krb5_data_zero (data); - - data->length = asprintf ((char **)&data->data, - "%c%c%s", - (result_code >> 8) & 0xFF, - result_code & 0xFF, - expl); - - if (data->data == NULL) { - krb5_warnx (context, "Out of memory generating error reply"); - return 1; - } - return 0; -} - -static void -reply_error (krb5_principal server, - int s, - struct sockaddr *sa, - int sa_size, - krb5_error_code error_code, - u_int16_t result_code, - const char *expl) -{ - krb5_error_code ret; - krb5_data error_data; - krb5_data e_data; - - if (make_result(&e_data, result_code, expl)) - return; - - ret = krb5_mk_error (context, - error_code, - NULL, - &e_data, - NULL, - server, - NULL, - NULL, - &error_data); - krb5_data_free (&e_data); - if (ret) { - krb5_warn (context, ret, "Could not even generate error reply"); - return; - } - send_reply (s, sa, sa_size, NULL, &error_data); - krb5_data_free (&error_data); -} - -static void -reply_priv (krb5_auth_context auth_context, - int s, - struct sockaddr *sa, - int sa_size, - u_int16_t result_code, - const char *expl) -{ - krb5_error_code ret; - krb5_data krb_priv_data; - krb5_data ap_rep_data; - krb5_data e_data; - - ret = krb5_mk_rep (context, - auth_context, - &ap_rep_data); - if (ret) { - krb5_warn (context, ret, "Could not even generate error reply"); - return; - } - - if (make_result(&e_data, result_code, expl)) - return; - - ret = krb5_mk_priv (context, - auth_context, - &e_data, - &krb_priv_data, - NULL); - krb5_data_free (&e_data); - if (ret) { - krb5_warn (context, ret, "Could not even generate error reply"); - return; - } - send_reply (s, sa, sa_size, &ap_rep_data, &krb_priv_data); - krb5_data_free (&ap_rep_data); - krb5_data_free (&krb_priv_data); -} - -/* - * Change the password for `principal', sending the reply back on `s' - * (`sa', `sa_size') to `pwd_data'. - */ - -static void -change (krb5_auth_context auth_context, - krb5_principal principal, - int s, - struct sockaddr *sa, - int sa_size, - krb5_data *pwd_data) -{ - krb5_error_code ret; - char *client; - const char *pwd_reason; - kadm5_config_params conf; - void *kadm5_handle; - char *tmp; - - memset (&conf, 0, sizeof(conf)); - - krb5_unparse_name (context, principal, &client); - - ret = kadm5_init_with_password_ctx(context, - client, - NULL, - KADM5_ADMIN_SERVICE, - &conf, 0, 0, - &kadm5_handle); - if (ret) { - free (client); - krb5_warn (context, ret, "kadm5_init_with_password_ctx"); - reply_priv (auth_context, s, sa, sa_size, 2, - "Internal error"); - return; - } - - krb5_warnx (context, "Changing password for %s", client); - free (client); - - pwd_reason = kadm5_check_password_quality (context, principal, pwd_data); - if (pwd_reason != NULL ) { - krb5_warnx (context, "%s", pwd_reason); - reply_priv (auth_context, s, sa, sa_size, 4, pwd_reason); - kadm5_destroy (kadm5_handle); - return; - } - - tmp = malloc (pwd_data->length + 1); - if (tmp == NULL) { - krb5_warnx (context, "malloc: out of memory"); - reply_priv (auth_context, s, sa, sa_size, 2, - "Internal error"); - goto out; - } - memcpy (tmp, pwd_data->data, pwd_data->length); - tmp[pwd_data->length] = '\0'; - - ret = kadm5_s_chpass_principal_cond (kadm5_handle, principal, tmp); - memset (tmp, 0, pwd_data->length); - free (tmp); - if (ret) { - krb5_warn (context, ret, "kadm5_s_chpass_principal_cond"); - reply_priv (auth_context, s, sa, sa_size, 2, - "Internal error"); - goto out; - } - reply_priv (auth_context, s, sa, sa_size, 0, "Password changed"); -out: - kadm5_destroy (kadm5_handle); -} - -static int -verify (krb5_auth_context *auth_context, - krb5_principal server, - krb5_keytab keytab, - krb5_ticket **ticket, - krb5_data *out_data, - int s, - struct sockaddr *sa, - int sa_size, - u_char *msg, - size_t len) -{ - krb5_error_code ret; - u_int16_t pkt_len, pkt_ver, ap_req_len; - krb5_data ap_req_data; - krb5_data krb_priv_data; - - pkt_len = (msg[0] << 8) | (msg[1]); - pkt_ver = (msg[2] << 8) | (msg[3]); - ap_req_len = (msg[4] << 8) | (msg[5]); - if (pkt_len != len) { - krb5_warnx (context, "Strange len: %ld != %ld", - (long)pkt_len, (long)len); - reply_error (server, s, sa, sa_size, 0, 1, "Bad request"); - return 1; - } - if (pkt_ver != 0x0001) { - krb5_warnx (context, "Bad version (%d)", pkt_ver); - reply_error (server, s, sa, sa_size, 0, 1, "Wrong program version"); - return 1; - } - - ap_req_data.data = msg + 6; - ap_req_data.length = ap_req_len; - - ret = krb5_rd_req (context, - auth_context, - &ap_req_data, - server, - keytab, - NULL, - ticket); - if (ret) { - if(ret == KRB5_KT_NOTFOUND) { - char *name; - krb5_unparse_name(context, server, &name); - krb5_warnx (context, "krb5_rd_req: %s (%s)", - krb5_get_err_text(context, ret), name); - free(name); - } else - krb5_warn (context, ret, "krb5_rd_req"); - reply_error (server, s, sa, sa_size, ret, 3, "Authentication failed"); - return 1; - } - - if (!(*ticket)->ticket.flags.initial) { - krb5_warnx (context, "initial flag not set"); - reply_error (server, s, sa, sa_size, ret, 1, - "Bad request"); - goto out; - } - krb_priv_data.data = msg + 6 + ap_req_len; - krb_priv_data.length = len - 6 - ap_req_len; - - ret = krb5_rd_priv (context, - *auth_context, - &krb_priv_data, - out_data, - NULL); - - if (ret) { - krb5_warn (context, ret, "krb5_rd_priv"); - reply_error (server, s, sa, sa_size, ret, 3, "Bad request"); - goto out; - } - return 0; -out: - krb5_free_ticket (context, *ticket); - return 1; -} - -static void -process (krb5_principal server, - krb5_keytab keytab, - int s, - krb5_address *this_addr, - struct sockaddr *sa, - int sa_size, - u_char *msg, - int len) -{ - krb5_error_code ret; - krb5_auth_context auth_context = NULL; - krb5_data out_data; - krb5_ticket *ticket; - krb5_address other_addr; - - krb5_data_zero (&out_data); - - ret = krb5_auth_con_init (context, &auth_context); - if (ret) { - krb5_warn (context, ret, "krb5_auth_con_init"); - return; - } - - krb5_auth_con_setflags (context, auth_context, - KRB5_AUTH_CONTEXT_DO_SEQUENCE); - - ret = krb5_sockaddr2address (context, sa, &other_addr); - if (ret) { - krb5_warn (context, ret, "krb5_sockaddr2address"); - goto out; - } - - ret = krb5_auth_con_setaddrs (context, - auth_context, - this_addr, - &other_addr); - krb5_free_address (context, &other_addr); - if (ret) { - krb5_warn (context, ret, "krb5_auth_con_setaddr"); - goto out; - } - - if (verify (&auth_context, server, keytab, &ticket, &out_data, - s, sa, sa_size, msg, len) == 0) { - change (auth_context, - ticket->client, - s, - sa, sa_size, - &out_data); - memset (out_data.data, 0, out_data.length); - krb5_free_ticket (context, ticket); - free (ticket); - } - -out: - krb5_data_free (&out_data); - krb5_auth_con_free (context, auth_context); -} - -static int -doit (krb5_keytab keytab, int port) -{ - krb5_error_code ret; - krb5_principal server; - int *sockets; - int maxfd; - char *realm; - krb5_addresses addrs; - unsigned n, i; - fd_set real_fdset; - struct sockaddr_storage __ss; - struct sockaddr *sa = (struct sockaddr *)&__ss; - - ret = krb5_get_default_realm (context, &realm); - if (ret) - krb5_err (context, 1, ret, "krb5_get_default_realm"); - - ret = krb5_build_principal (context, - &server, - strlen(realm), - realm, - "kadmin", - "changepw", - NULL); - if (ret) - krb5_err (context, 1, ret, "krb5_build_principal"); - - free (realm); - - ret = krb5_get_all_server_addrs (context, &addrs); - if (ret) - krb5_err (context, 1, ret, "krb5_get_all_server_addrs"); - - n = addrs.len; - - sockets = malloc (n * sizeof(*sockets)); - if (sockets == NULL) - krb5_errx (context, 1, "out of memory"); - maxfd = -1; - FD_ZERO(&real_fdset); - for (i = 0; i < n; ++i) { - int sa_size; - - krb5_addr2sockaddr (context, &addrs.val[i], sa, &sa_size, port); - - sockets[i] = socket (sa->sa_family, SOCK_DGRAM, 0); - if (sockets[i] < 0) - krb5_err (context, 1, errno, "socket"); - if (bind (sockets[i], sa, sa_size) < 0) { - char str[128]; - size_t len; - int save_errno = errno; - - ret = krb5_print_address (&addrs.val[i], str, sizeof(str), &len); - if (ret) - strlcpy(str, "unknown address", sizeof(str)); - krb5_warn (context, save_errno, "bind(%s)", str); - continue; - } - maxfd = max (maxfd, sockets[i]); - if (maxfd >= FD_SETSIZE) - krb5_errx (context, 1, "fd too large"); - FD_SET(sockets[i], &real_fdset); - } - if (maxfd == -1) - krb5_errx (context, 1, "No sockets!"); - - while(exit_flag == 0) { - int ret; - fd_set fdset = real_fdset; - - ret = select (maxfd + 1, &fdset, NULL, NULL, NULL); - if (ret < 0) { - if (errno == EINTR) - continue; - else - krb5_err (context, 1, errno, "select"); - } - for (i = 0; i < n; ++i) - if (FD_ISSET(sockets[i], &fdset)) { - u_char buf[BUFSIZ]; - socklen_t addrlen = sizeof(__ss); - - ret = recvfrom (sockets[i], buf, sizeof(buf), 0, - sa, &addrlen); - if (ret < 0) { - if(errno == EINTR) - break; - else - krb5_err (context, 1, errno, "recvfrom"); - } - - process (server, keytab, sockets[i], - &addrs.val[i], - sa, addrlen, - buf, ret); - } - } - krb5_free_addresses (context, &addrs); - krb5_free_principal (context, server); - krb5_free_context (context); - return 0; -} - -static RETSIGTYPE -sigterm(int sig) -{ - exit_flag = 1; -} - -const char *check_library = NULL; -const char *check_function = NULL; -char *keytab_str = "HDB:"; -char *realm_str; -int version_flag; -int help_flag; -char *port_str; - -struct getargs args[] = { -#ifdef HAVE_DLOPEN - { "check-library", 0, arg_string, &check_library, - "library to load password check function from", "library" }, - { "check-function", 0, arg_string, &check_function, - "password check function to load", "function" }, -#endif - { "keytab", 'k', arg_string, &keytab_str, - "keytab to get authentication key from", "kspec" }, - { "realm", 'r', arg_string, &realm_str, "default realm", "realm" }, - { "port", 'p', arg_string, &port_str, "port" }, - { "version", 0, arg_flag, &version_flag }, - { "help", 0, arg_flag, &help_flag } -}; -int num_args = sizeof(args) / sizeof(args[0]); - -int -main (int argc, char **argv) -{ - int optind; - krb5_keytab keytab; - krb5_error_code ret; - int port; - - optind = krb5_program_setup(&context, argc, argv, args, num_args, NULL); - - if(help_flag) - krb5_std_usage(0, args, num_args); - if(version_flag) { - print_version(NULL); - exit(0); - } - - if(realm_str) - krb5_set_default_realm(context, realm_str); - - krb5_openlog (context, "kpasswdd", &log_facility); - krb5_set_warn_dest(context, log_facility); - - if (port_str != NULL) { - struct servent *s = roken_getservbyname (port_str, "udp"); - - if (s != NULL) - port = s->s_port; - else { - char *ptr; - - port = strtol (port_str, &ptr, 10); - if (port == 0 && ptr == port_str) - krb5_errx (context, 1, "bad port `%s'", port_str); - port = htons(port); - } - } else - port = krb5_getportbyname (context, "kpasswd", "udp", KPASSWD_PORT); - - ret = krb5_kt_register(context, &hdb_kt_ops); - if(ret) - krb5_err(context, 1, ret, "krb5_kt_register"); - - ret = krb5_kt_resolve(context, keytab_str, &keytab); - if(ret) - krb5_err(context, 1, ret, "%s", keytab_str); - - kadm5_setup_passwd_quality_check (context, check_library, check_function); - -#ifdef HAVE_SIGACTION - { - struct sigaction sa; - - sa.sa_flags = 0; - sa.sa_handler = sigterm; - sigemptyset(&sa.sa_mask); - - sigaction(SIGINT, &sa, NULL); - sigaction(SIGTERM, &sa, NULL); - } -#else - signal(SIGINT, sigterm); - signal(SIGTERM, sigterm); -#endif - - pidfile(NULL); - - return doit (keytab, port); -} diff --git a/crypto/heimdal/kpasswd/kpasswdd.cat8 b/crypto/heimdal/kpasswd/kpasswdd.cat8 deleted file mode 100644 index 3330b8e3eba8..000000000000 --- a/crypto/heimdal/kpasswd/kpasswdd.cat8 +++ /dev/null @@ -1,53 +0,0 @@ -KPASSWDD(8) NetBSD System Manager's Manual KPASSWDD(8) - -NNAAMMEE - kkppaasssswwdddd - Kerberos 5 password changing server - -SSYYNNOOPPSSIISS - kkppaasssswwdddd [----cchheecckk--lliibbrraarryy==_l_i_b_r_a_r_y] [----cchheecckk--ffuunnccttiioonn==_f_u_n_c_t_i_o_n] [--kk _k_s_p_e_c - | ----kkeeyyttaabb==_k_s_p_e_c] [--rr _r_e_a_l_m | ----rreeaallmm==_r_e_a_l_m] [--pp _s_t_r_i_n_g | ----ppoorrtt==_s_t_r_i_n_g] - [----vveerrssiioonn] [----hheellpp] - -DDEESSCCRRIIPPTTIIOONN - kkppaasssswwdddd serves request for password changes. It listens on UDP port 464 - (service kpasswd) and processes requests when they arrive. It changes the - database directly and should thus only run on the master KDC. - - Supported options: - - ----cchheecckk--lliibbrraarryy==_l_i_b_r_a_r_y - If your system has support for dynamic loading of shared li- - braries, you can use an external function to check password qual- - ity. This option specifies which library to load. - - ----cchheecckk--ffuunnccttiioonn==_f_u_n_c_t_i_o_n - This is the function to call in the loaded library. The function - should look like this: - - _c_o_n_s_t _c_h_a_r _* ppaasssswwdd__cchheecckk(_k_r_b_5___c_o_n_t_e_x_t _c_o_n_t_e_x_t, _k_r_b_5___p_r_i_n_c_i_p_a_l - _p_r_i_n_c_i_p_a_l, _k_r_b_5___d_a_t_a _*_p_a_s_s_w_o_r_d) - - _c_o_n_t_e_x_t is an initialized context; _p_r_i_n_c_i_p_a_l is the one who tries - to change passwords, and _p_a_s_s_w_o_r_d is the new password. Note that - the password (in _p_a_s_s_w_o_r_d_-_>_d_a_t_a) is not zero terminated. - - --kk _k_s_p_e_c, ----kkeeyyttaabb==_k_s_p_e_c - keytab to get authentication key from - - --rr _r_e_a_l_m, ----rreeaallmm==_r_e_a_l_m - default realm - - --pp _s_t_r_i_n_g, ----ppoorrtt==_s_t_r_i_n_g - port to listen on (default service kpasswd - 464). - -DDIIAAGGNNOOSSTTIICCSS - If an error occurs, the error message is returned to the user and/or - logged to syslog. - -BBUUGGSS - The default password quality checks are too basic. - -SSEEEE AALLSSOO - kpasswd(1), kdc(8) - - HEIMDAL April 19, 1999 1 |
