diff options
-rw-r--r-- | confskel/Makefile | 714 | ||||
-rw-r--r-- | confskel/Makefile.am | 5 | ||||
-rw-r--r-- | confskel/Makefile.in | 714 | ||||
-rw-r--r-- | confskel/openldap/ldif/ems-core.ldif | 174 | ||||
-rw-r--r-- | confskel/openldap/ldif/hdb.ldif | 39 | ||||
-rw-r--r-- | confskel/openldap/ldif/olcDatabase.ldif | 26 | ||||
-rw-r--r-- | confskel/openldap/ldif/tde-core.ldif | 10 | ||||
-rw-r--r-- | confskel/openldap/skel.ldif | 6 | ||||
-rw-r--r-- | src/Makefile.am | 2 | ||||
-rw-r--r-- | src/ldapcontroller.cpp | 195 | ||||
-rw-r--r-- | src/ldapcontroller.h | 13 | ||||
-rw-r--r-- | src/realmfinishpage.cpp | 5 | ||||
-rw-r--r-- | src/realmfinishpagedlg.ui | 17 | ||||
-rw-r--r-- | src/realmwizard.cpp | 3 | ||||
-rw-r--r-- | src/sha1.cc | 433 | ||||
-rw-r--r-- | src/sha1.h | 74 | ||||
-rw-r--r-- | subdirs | 2 |
17 files changed, 2414 insertions, 18 deletions
diff --git a/confskel/Makefile b/confskel/Makefile new file mode 100644 index 0000000..33cdd3a --- /dev/null +++ b/confskel/Makefile @@ -0,0 +1,714 @@ +# Makefile.in generated by automake 1.11.1 from Makefile.am. +# KDE tags expanded automatically by am_edit - $Revision$ +# confskel/Makefile. Generated from Makefile.in by configure. + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 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. + + + + +pkgdatadir = $(datadir)/autostart +pkgincludedir = $(includedir)/autostart +pkglibdir = $(libdir)/autostart +pkglibexecdir = $(libexecdir)/autostart +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = i686-pc-linux-gnu +host_triplet = i686-pc-linux-gnu +target_triplet = i686-pc-linux-gnu +subdir = confskel +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ + $(top_srcdir)/configure.in +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(SHELL) $(top_srcdir)/admin/mkinstalldirs +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +SOURCES = +DIST_SOURCES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__installdirs = "$(DESTDIR)$(heimdalskeldir)" \ + "$(DESTDIR)$(ldapconfskeldir)" "$(DESTDIR)$(ldapldifskeldir)" \ + "$(DESTDIR)$(ldapskeldir)" +DATA = $(heimdalskel_DATA) $(ldapconfskel_DATA) $(ldapldifskel_DATA) \ + $(ldapskel_DATA) +#>- DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +#>+ 1 +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) $(KDE_DIST) +ACLOCAL = ${SHELL} /DOMAINS/kcmldapcontroller/admin/missing --run aclocal-1.11 +AMTAR = ${SHELL} /DOMAINS/kcmldapcontroller/admin/missing --run tar +AR = ar +ARTSCCONFIG = /opt/trinity/bin/artsc-config +AUTOCONF = $(SHELL) $(top_srcdir)/admin/cvs.sh configure || touch configure +AUTODIRS = +AUTOHEADER = ${SHELL} /DOMAINS/kcmldapcontroller/admin/missing --run autoheader +AUTOMAKE = ${SHELL} /DOMAINS/kcmldapcontroller/admin/missing --run automake-1.11 +AWK = gawk +CC = gcc +CCDEPMODE = depmode=none +CFLAGS = -std=iso9899:1990 -W -Wall -Wchar-subscripts -Wshadow -Wpointer-arith -Wmissing-prototypes -Wwrite-strings -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -O2 -g -O2 -g -O2 -Wformat-security -Wmissing-format-attribute -I/usr/include/tqt +CONF_FILES = $(top_srcdir)/./admin/configure.in.min $(top_srcdir)/configure.in.in +CPP = gcc -E +CPPFLAGS = -DQT_THREAD_SUPPORT -D_REENTRANT +CXX = g++ +CXXCPP = g++ -E +CXXDEPMODE = depmode=none +CXXFLAGS = -Wno-long-long -Wundef -ansi -D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wchar-subscripts -Wall -W -Wpointer-arith -O2 -g -O2 -g -O2 -Wformat-security -Wmissing-format-attribute -Wno-non-virtual-dtor -fno-exceptions -fno-check-new -fno-common -I/usr/include/tqt +CYGPATH_W = echo +DCOPIDL = /opt/trinity/bin/dcopidl +DCOPIDL2CPP = /opt/trinity/bin/dcopidl2cpp +DCOPIDLNG = /opt/trinity/bin/dcopidlng +DCOP_DEPENDENCIES = $(DCOPIDL) $(DCOPIDLNG) +DEFS = -DHAVE_CONFIG_H +DEPDIR = .deps +DSYMUTIL = +DUMPBIN = +ECHO_C = +ECHO_N = -n +ECHO_T = +EGREP = /bin/grep -E +ENABLE_PERMISSIVE_FLAG = -fpermissive +EXEEXT = +FGREP = /bin/grep -F +FRAMEWORK_COREAUDIO = +GMSGFMT = /usr/bin/msgfmt +GREP = /bin/grep +HAVE_GCC_VISIBILITY = 0 +INSTALL = /usr/bin/install -c -p +INSTALL_DATA = ${INSTALL} -m 644 +INSTALL_PROGRAM = ${INSTALL} $(INSTALL_STRIP_FLAG) +INSTALL_SCRIPT = ${INSTALL} +INSTALL_STRIP_PROGRAM = $(install_sh) -c -s +KCFG_DEPENDENCIES = $(KCONFIG_COMPILER) +KCONFIG_COMPILER = /opt/trinity/bin/kconfig_compiler +KDECONFIG = /opt/trinity/bin/tde-config +KDE_CHECK_PLUGIN = $(KDE_PLUGIN) -rpath $(libdir) +KDE_EXTRA_RPATH = +KDE_INCLUDES = -I/opt/trinity/include +KDE_LDFLAGS = -L/opt/trinity/lib +KDE_MT_LDFLAGS = +KDE_MT_LIBS = -lpthread +KDE_NO_UNDEFINED = -Wl,--no-undefined -Wl,--allow-shlib-undefined +KDE_PLUGIN = -avoid-version -module -no-undefined $(KDE_NO_UNDEFINED) $(KDE_RPATH) $(KDE_MT_LDFLAGS) +KDE_RPATH = +KDE_USE_CLOSURE_FALSE = +KDE_USE_CLOSURE_TRUE = # +KDE_USE_FINAL_FALSE = +KDE_USE_FINAL_TRUE = # +KDE_USE_FPIE = -fPIE +KDE_USE_NMCHECK_FALSE = +KDE_USE_NMCHECK_TRUE = # +KDE_USE_PIE = -pie +KDE_XSL_STYLESHEET = /opt/trinity/share/apps/ksgmltools2/customization/kde-chunk.xsl +LD = /usr/bin/ld +LDFLAGS = -Wl,-Bsymbolic-functions +LDFLAGS_AS_NEEDED = +LDFLAGS_NEW_DTAGS = +LIBCOMPAT = +LIBCRYPT = -lcrypt +LIBDL = -ldl +LIBJPEG = -ljpeg +LIBOBJS = +LIBPNG = -lpng -lz -lm +LIBPTHREAD = -lpthread +LIBRESOLV = -lresolv +LIBS = +LIBSM = -lSM -lICE +LIBSOCKET = +LIBTOOL = $(SHELL) $(top_builddir)/libtool +LIBTQT_LDFLAGS = -ltqt +LIBUCB = +LIBUTIL = -lutil +LIBZ = -lz +LIB_KAB = -lkab +LIB_KABC = -lkabc +LIB_KDED = +LIB_KDNSSD = -lkdnssd +LIB_KFILE = -lkio +LIB_KFM = +LIB_KHTML = -lkhtml +LIB_KIMPROXY = -lkimproxy +LIB_KIO = -lkio +LIB_KJS = -lkjs +LIB_KNEWSTUFF = -lknewstuff +LIB_KPARTS = -lkparts +LIB_KSPELL = -lkspell +LIB_KSYCOCA = -lkio +LIB_KUNITTEST = -lkunittest +LIB_KUTILS = -lkutils +LIB_POLL = +LIB_QPE = +LIB_QT = -ltqt-mt $(LIBZ) $(LIBPNG) -lXext $(LIB_X11) $(LIBSM) $(LIBTQT_LDFLAGS) -lpthread +LIB_QUI = -ltqui +LIB_SMB = -lsmb +LIB_TDECORE = -ltdecore +LIB_TDEPIM = -ltdepim +LIB_TDEPRINT = -ltdeprint +LIB_TDEUI = -ltdeui +LIB_X11 = -lX11 $(LIBSOCKET) +LIB_XEXT = -lXext +LIB_XRENDER = +LIPO = +LN_S = ln -s +LTLIBOBJS = +MAKEINFO = ${SHELL} /DOMAINS/kcmldapcontroller/admin/missing --run makeinfo +MAKEKDEWIDGETS = /opt/trinity/bin/makekdewidgets +MCOPIDL = /opt/trinity/bin/mcopidl +MEINPROC = /opt/trinity/bin/meinproc +MKDIR_P = /bin/mkdir -p +MOC = /usr/share/tqt3/bin/moc +MSGFMT = /usr/bin/msgfmt +NM = /usr/bin/nm -B +NMEDIT = +NOOPT_CFLAGS = -O0 +NOOPT_CXXFLAGS = -O0 +OBJDUMP = objdump +OBJEXT = o +OTOOL = +OTOOL64 = +PACKAGE = autostart +PACKAGE_BUGREPORT = +PACKAGE_NAME = +PACKAGE_STRING = +PACKAGE_TARNAME = +PACKAGE_URL = +PACKAGE_VERSION = +PATH_SEPARATOR = : +PERL = /usr/bin/perl +PKG_CONFIG = /usr/bin/pkg-config +QTE_NORTTI = +QT_INCLUDES = -I/usr/share/tqt3/include -include tqt.h +QT_LDFLAGS = -L/usr/share/qt3/lib -ltqt +RANLIB = ranlib +SED = /bin/sed +SET_MAKE = +SHELL = /bin/bash +STRIP = strip +TOPSUBDIRS = confskel doc po src +TQTDCOPIDL = /opt/trinity/bin/dcopidl +TQTDCOPIDL2CPP = /opt/trinity/bin/dcopidl2cpp +TQTDCOPIDLNG = +TQTMCOPIDL = /opt/trinity/bin/mcopidl +TQTMOC = /usr/bin/tmoc +UIC = /usr/bin/uic-tqt -L $(kde_widgetdir) -nounload +UIC_TR = tr2i18n +USER_INCLUDES = +USER_LDFLAGS = +USE_EXCEPTIONS = -fexceptions +USE_RTTI = +USE_THREADS = +VERSION = 0.1 +WOVERLOADED_VIRTUAL = +XGETTEXT = /usr/bin/xgettext +XMKMF = +XMLLINT = /usr/bin/xmllint +X_EXTRA_LIBS = +X_INCLUDES = -I. +X_LDFLAGS = +X_PRE_LIBS = +X_RPATH = +abs_builddir = /DOMAINS/kcmldapcontroller/confskel +abs_srcdir = /DOMAINS/kcmldapcontroller/confskel +abs_top_builddir = /DOMAINS/kcmldapcontroller +abs_top_srcdir = /DOMAINS/kcmldapcontroller +ac_ct_CC = gcc +ac_ct_CXX = g++ +ac_ct_DUMPBIN = +all_includes = -I/opt/trinity/include -I/usr/share/tqt3/include -I. -include tqt.h +all_libraries = -L/opt/trinity/lib -L/usr/share/qt3/lib +am__include = include +am__leading_dot = . +am__quote = +am__tar = ${AMTAR} chof - "$$tardir" +am__untar = ${AMTAR} xf - +bindir = ${exec_prefix}/bin +build = i686-pc-linux-gnu +build_alias = i686-linux-gnu +build_cpu = i686 +build_os = linux-gnu +build_vendor = pc +builddir = . +datadir = ${datarootdir} +datarootdir = ${prefix}/share +docdir = ${datarootdir}/doc/${PACKAGE} +dvidir = ${docdir} +exec_prefix = ${prefix} +host = i686-pc-linux-gnu +host_alias = +host_cpu = i686 +host_os = linux-gnu +host_vendor = pc +htmldir = ${docdir} +includedir = /opt/trinity/include/tde +infodir = /opt/trinity/share/info +install_sh = ${SHELL} /DOMAINS/kcmldapcontroller/admin/install-sh +kde_appsdir = ${datadir}/applnk +kde_bindir = ${exec_prefix}/bin +kde_confdir = ${datadir}/config +kde_datadir = ${datadir}/apps +kde_htmldir = ${datadir}/doc/tde/HTML +kde_icondir = ${datadir}/icons +kde_includes = /opt/trinity/include +kde_kcfgdir = ${datadir}/config.kcfg +kde_libraries = /opt/trinity/lib +kde_libs_htmldir = /opt/trinity/share/doc/tde/HTML +kde_libs_prefix = /opt/trinity +kde_locale = ${datadir}/locale +kde_mimedir = ${datadir}/mimelnk +kde_moduledir = ${libdir}/trinity +kde_qtver = 3 +kde_servicesdir = ${datadir}/services +kde_servicetypesdir = ${datadir}/servicetypes +kde_sounddir = ${datadir}/sounds +kde_styledir = ${libdir}/trinity/plugins/styles +kde_templatesdir = ${datadir}/templates +kde_wallpaperdir = ${datadir}/wallpapers +kde_widgetdir = /opt/trinity/lib/trinity/plugins/designer +libdir = ${exec_prefix}/lib +libexecdir = ${prefix}/lib/kcontrol-ldap-controller-trinity +localedir = ${datarootdir}/locale +localstatedir = /var +lt_ECHO = echo +mandir = /opt/trinity/share/man +mkdir_p = /bin/mkdir -p +oldincludedir = /usr/include +pdfdir = ${docdir} +prefix = /opt/trinity +program_transform_name = s,x,x, +psdir = ${docdir} +qt_includes = /usr/share/tqt3/include +qt_libraries = /usr/share/qt3/lib +sbindir = ${exec_prefix}/sbin +sharedstatedir = ${prefix}/com +srcdir = . +sysconfdir = /etc +target = i686-pc-linux-gnu +target_alias = +target_cpu = i686 +target_os = linux-gnu +target_vendor = pc +tdeinitdir = $(kde_moduledir) +top_build_prefix = ../ +top_builddir = .. +top_srcdir = .. +x_includes = . +x_libraries = /usr/lib +xdg_appsdir = ${datadir}/applications/kde +xdg_directorydir = ${datadir}/desktop-directories +xdg_menudir = ${sysconfdir}/xdg/menus +confskeldir = $(kde_datadir)/kcmldapcontroller/skel +heimdalskeldir = $(confskeldir)/heimdal +heimdalskel_DATA = heimdal/* +ldapskeldir = $(confskeldir)/openldap +ldapskel_DATA = openldap/skel.ldif +ldapconfskeldir = $(ldapskeldir)/ldap +ldapconfskel_DATA = openldap/ldap/* +ldapldifskeldir = $(ldapskeldir)/ldif +ldapldifskel_DATA = openldap/ldif/* +#>- all: all-am +#>+ 1 +all: docs-am all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +#>- @for dep in $?; do \ +#>- case '$(am__configure_deps)' in \ +#>- *$$dep*) \ +#>- ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ +#>- && { if test -f $@; then exit 0; else break; fi; }; \ +#>- exit 1;; \ +#>- esac; \ +#>- done; \ +#>- echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu confskel/Makefile'; \ +#>- $(am__cd) $(top_srcdir) && \ +#>- $(AUTOMAKE) --gnu confskel/Makefile +#>+ 12 + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu confskel/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --gnu confskel/Makefile + cd $(top_srcdir) && perl admin/am_edit confskel/Makefile.in +.PRECIOUS: Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-heimdalskelDATA: $(heimdalskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(heimdalskeldir)" || $(MKDIR_P) "$(DESTDIR)$(heimdalskeldir)" + @list='$(heimdalskel_DATA)'; test -n "$(heimdalskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(heimdalskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(heimdalskeldir)" || exit $$?; \ + done + +uninstall-heimdalskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(heimdalskel_DATA)'; test -n "$(heimdalskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(heimdalskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(heimdalskeldir)" && rm -f $$files +install-ldapconfskelDATA: $(ldapconfskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(ldapconfskeldir)" || $(MKDIR_P) "$(DESTDIR)$(ldapconfskeldir)" + @list='$(ldapconfskel_DATA)'; test -n "$(ldapconfskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(ldapconfskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(ldapconfskeldir)" || exit $$?; \ + done + +uninstall-ldapconfskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(ldapconfskel_DATA)'; test -n "$(ldapconfskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(ldapconfskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(ldapconfskeldir)" && rm -f $$files +install-ldapldifskelDATA: $(ldapldifskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(ldapldifskeldir)" || $(MKDIR_P) "$(DESTDIR)$(ldapldifskeldir)" + @list='$(ldapldifskel_DATA)'; test -n "$(ldapldifskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(ldapldifskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(ldapldifskeldir)" || exit $$?; \ + done + +uninstall-ldapldifskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(ldapldifskel_DATA)'; test -n "$(ldapldifskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(ldapldifskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(ldapldifskeldir)" && rm -f $$files +install-ldapskelDATA: $(ldapskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(ldapskeldir)" || $(MKDIR_P) "$(DESTDIR)$(ldapskeldir)" + @list='$(ldapskel_DATA)'; test -n "$(ldapskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(ldapskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(ldapskeldir)" || exit $$?; \ + done + +uninstall-ldapskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(ldapskel_DATA)'; test -n "$(ldapskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(ldapskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(ldapskeldir)" && rm -f $$files +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(DATA) +installdirs: + for dir in "$(DESTDIR)$(heimdalskeldir)" "$(DESTDIR)$(ldapconfskeldir)" "$(DESTDIR)$(ldapldifskeldir)" "$(DESTDIR)$(ldapskeldir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +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_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + `test -z '$(STRIP)' || \ + echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +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 +#>+ 1 +clean: kde-rpo-clean clean-am + +#>- clean-am: clean-generic clean-libtool mostlyclean-am +#>+ 1 +clean-am: clean-bcheck clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-heimdalskelDATA install-ldapconfskelDATA \ + install-ldapldifskelDATA install-ldapskelDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-heimdalskelDATA uninstall-ldapconfskelDATA \ + uninstall-ldapldifskelDATA uninstall-ldapskelDATA + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + distclean distclean-generic distclean-libtool distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-heimdalskelDATA \ + install-html install-html-am install-info install-info-am \ + install-ldapconfskelDATA install-ldapldifskelDATA \ + install-ldapskelDATA install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am \ + uninstall-heimdalskelDATA uninstall-ldapconfskelDATA \ + uninstall-ldapldifskelDATA uninstall-ldapskelDATA + + +# 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: + +#>+ 2 +KDE_DIST=Makefile.am Makefile.in + +#>+ 2 +docs-am: + +#>+ 15 +force-reedit: + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu confskel/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --gnu confskel/Makefile + cd $(top_srcdir) && perl admin/am_edit confskel/Makefile.in + + +#>+ 21 +clean-bcheck: + rm -f *.bchecktest.cc *.bchecktest.cc.class a.out + +bcheck: bcheck-am + +bcheck-am: + @for i in ; do \ + if test $(srcdir)/$$i -nt $$i.bchecktest.cc; then \ + echo "int main() {return 0;}" > $$i.bchecktest.cc ; \ + echo "#include \"$$i\"" >> $$i.bchecktest.cc ; \ + echo "$$i"; \ + if ! $(CXX) $(DEFS) -I. -I$(srcdir) -I$(top_builddir) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(KDE_CXXFLAGS) --dump-class-hierarchy -c $$i.bchecktest.cc; then \ + rm -f $$i.bchecktest.cc; exit 1; \ + fi ; \ + echo "" >> $$i.bchecktest.cc.class; \ + perl $(top_srcdir)/admin/bcheck.pl $$i.bchecktest.cc.class || { rm -f $$i.bchecktest.cc; exit 1; }; \ + rm -f a.out; \ + fi ; \ + done + + +#>+ 3 +final: + $(MAKE) all-am + +#>+ 3 +final-install: + $(MAKE) install-am + +#>+ 3 +no-final: + $(MAKE) all-am + +#>+ 3 +no-final-install: + $(MAKE) install-am + +#>+ 3 +kde-rpo-clean: + -rm -f *.rpo + +#>+ 3 +nmcheck: +nmcheck-am: nmcheck diff --git a/confskel/Makefile.am b/confskel/Makefile.am index 911d979..a865f16 100644 --- a/confskel/Makefile.am +++ b/confskel/Makefile.am @@ -7,4 +7,7 @@ ldapskeldir = $(confskeldir)/openldap ldapskel_DATA = openldap/skel.ldif ldapconfskeldir = $(ldapskeldir)/ldap -ldapconfskel_DATA = openldap/ldap/*
\ No newline at end of file +ldapconfskel_DATA = openldap/ldap/* + +ldapldifskeldir = $(ldapskeldir)/ldif +ldapldifskel_DATA = openldap/ldif/*
\ No newline at end of file diff --git a/confskel/Makefile.in b/confskel/Makefile.in new file mode 100644 index 0000000..02c26bd --- /dev/null +++ b/confskel/Makefile.in @@ -0,0 +1,714 @@ +# Makefile.in generated by automake 1.11.1 from Makefile.am. +# KDE tags expanded automatically by am_edit - $Revision$ +# @configure_input@ + +# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, +# 2003, 2004, 2005, 2006, 2007, 2008, 2009 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@ + +VPATH = @srcdir@ +pkgdatadir = $(datadir)/@PACKAGE@ +pkgincludedir = $(includedir)/@PACKAGE@ +pkglibdir = $(libdir)/@PACKAGE@ +pkglibexecdir = $(libexecdir)/@PACKAGE@ +am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd +install_sh_DATA = $(install_sh) -c -m 644 +install_sh_PROGRAM = $(install_sh) -c +install_sh_SCRIPT = $(install_sh) -c +INSTALL_HEADER = $(INSTALL_DATA) +transform = $(program_transform_name) +NORMAL_INSTALL = : +PRE_INSTALL = : +POST_INSTALL = : +NORMAL_UNINSTALL = : +PRE_UNINSTALL = : +POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ +target_triplet = @target@ +subdir = confskel +DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in +ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 +am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ + $(top_srcdir)/configure.in +am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ + $(ACLOCAL_M4) +mkinstalldirs = $(SHELL) $(top_srcdir)/admin/mkinstalldirs +CONFIG_HEADER = $(top_builddir)/config.h +CONFIG_CLEAN_FILES = +CONFIG_CLEAN_VPATH_FILES = +SOURCES = +DIST_SOURCES = +am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; +am__vpath_adj = case $$p in \ + $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ + *) f=$$p;; \ + esac; +am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; +am__install_max = 40 +am__nobase_strip_setup = \ + srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` +am__nobase_strip = \ + for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" +am__nobase_list = $(am__nobase_strip_setup); \ + for p in $$list; do echo "$$p $$p"; done | \ + sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ + $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ + if (++n[$$2] == $(am__install_max)) \ + { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ + END { for (dir in files) print dir, files[dir] }' +am__base_list = \ + sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ + sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' +am__installdirs = "$(DESTDIR)$(heimdalskeldir)" \ + "$(DESTDIR)$(ldapconfskeldir)" "$(DESTDIR)$(ldapldifskeldir)" \ + "$(DESTDIR)$(ldapskeldir)" +DATA = $(heimdalskel_DATA) $(ldapconfskel_DATA) $(ldapldifskel_DATA) \ + $(ldapskel_DATA) +#>- DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) +#>+ 1 +DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) $(KDE_DIST) +ACLOCAL = @ACLOCAL@ +AMTAR = @AMTAR@ +AR = @AR@ +ARTSCCONFIG = @ARTSCCONFIG@ +AUTOCONF = @AUTOCONF@ +AUTODIRS = @AUTODIRS@ +AUTOHEADER = @AUTOHEADER@ +AUTOMAKE = @AUTOMAKE@ +AWK = @AWK@ +CC = @CC@ +CCDEPMODE = @CCDEPMODE@ +CFLAGS = @CFLAGS@ +CONF_FILES = @CONF_FILES@ +CPP = @CPP@ +CPPFLAGS = @CPPFLAGS@ +CXX = @CXX@ +CXXCPP = @CXXCPP@ +CXXDEPMODE = @CXXDEPMODE@ +CXXFLAGS = @CXXFLAGS@ +CYGPATH_W = @CYGPATH_W@ +DCOPIDL = @DCOPIDL@ +DCOPIDL2CPP = @DCOPIDL2CPP@ +DCOPIDLNG = @DCOPIDLNG@ +DCOP_DEPENDENCIES = @DCOP_DEPENDENCIES@ +DEFS = @DEFS@ +DEPDIR = @DEPDIR@ +DSYMUTIL = @DSYMUTIL@ +DUMPBIN = @DUMPBIN@ +ECHO_C = @ECHO_C@ +ECHO_N = @ECHO_N@ +ECHO_T = @ECHO_T@ +EGREP = @EGREP@ +ENABLE_PERMISSIVE_FLAG = @ENABLE_PERMISSIVE_FLAG@ +EXEEXT = @EXEEXT@ +FGREP = @FGREP@ +FRAMEWORK_COREAUDIO = @FRAMEWORK_COREAUDIO@ +GMSGFMT = @GMSGFMT@ +GREP = @GREP@ +HAVE_GCC_VISIBILITY = @HAVE_GCC_VISIBILITY@ +INSTALL = @INSTALL@ +INSTALL_DATA = @INSTALL_DATA@ +INSTALL_PROGRAM = @INSTALL_PROGRAM@ +INSTALL_SCRIPT = @INSTALL_SCRIPT@ +INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ +KCFG_DEPENDENCIES = @KCFG_DEPENDENCIES@ +KCONFIG_COMPILER = @KCONFIG_COMPILER@ +KDECONFIG = @KDECONFIG@ +KDE_CHECK_PLUGIN = @KDE_CHECK_PLUGIN@ +KDE_EXTRA_RPATH = @KDE_EXTRA_RPATH@ +KDE_INCLUDES = @KDE_INCLUDES@ +KDE_LDFLAGS = @KDE_LDFLAGS@ +KDE_MT_LDFLAGS = @KDE_MT_LDFLAGS@ +KDE_MT_LIBS = @KDE_MT_LIBS@ +KDE_NO_UNDEFINED = @KDE_NO_UNDEFINED@ +KDE_PLUGIN = @KDE_PLUGIN@ +KDE_RPATH = @KDE_RPATH@ +KDE_USE_CLOSURE_FALSE = @KDE_USE_CLOSURE_FALSE@ +KDE_USE_CLOSURE_TRUE = @KDE_USE_CLOSURE_TRUE@ +KDE_USE_FINAL_FALSE = @KDE_USE_FINAL_FALSE@ +KDE_USE_FINAL_TRUE = @KDE_USE_FINAL_TRUE@ +KDE_USE_FPIE = @KDE_USE_FPIE@ +KDE_USE_NMCHECK_FALSE = @KDE_USE_NMCHECK_FALSE@ +KDE_USE_NMCHECK_TRUE = @KDE_USE_NMCHECK_TRUE@ +KDE_USE_PIE = @KDE_USE_PIE@ +KDE_XSL_STYLESHEET = @KDE_XSL_STYLESHEET@ +LD = @LD@ +LDFLAGS = @LDFLAGS@ +LDFLAGS_AS_NEEDED = @LDFLAGS_AS_NEEDED@ +LDFLAGS_NEW_DTAGS = @LDFLAGS_NEW_DTAGS@ +LIBCOMPAT = @LIBCOMPAT@ +LIBCRYPT = @LIBCRYPT@ +LIBDL = @LIBDL@ +LIBJPEG = @LIBJPEG@ +LIBOBJS = @LIBOBJS@ +LIBPNG = @LIBPNG@ +LIBPTHREAD = @LIBPTHREAD@ +LIBRESOLV = @LIBRESOLV@ +LIBS = @LIBS@ +LIBSM = @LIBSM@ +LIBSOCKET = @LIBSOCKET@ +LIBTOOL = @LIBTOOL@ +LIBTQT_LDFLAGS = @LIBTQT_LDFLAGS@ +LIBUCB = @LIBUCB@ +LIBUTIL = @LIBUTIL@ +LIBZ = @LIBZ@ +LIB_KAB = @LIB_KAB@ +LIB_KABC = @LIB_KABC@ +LIB_KDED = @LIB_KDED@ +LIB_KDNSSD = @LIB_KDNSSD@ +LIB_KFILE = @LIB_KFILE@ +LIB_KFM = @LIB_KFM@ +LIB_KHTML = @LIB_KHTML@ +LIB_KIMPROXY = @LIB_KIMPROXY@ +LIB_KIO = @LIB_KIO@ +LIB_KJS = @LIB_KJS@ +LIB_KNEWSTUFF = @LIB_KNEWSTUFF@ +LIB_KPARTS = @LIB_KPARTS@ +LIB_KSPELL = @LIB_KSPELL@ +LIB_KSYCOCA = @LIB_KSYCOCA@ +LIB_KUNITTEST = @LIB_KUNITTEST@ +LIB_KUTILS = @LIB_KUTILS@ +LIB_POLL = @LIB_POLL@ +LIB_QPE = @LIB_QPE@ +LIB_QT = @LIB_QT@ +LIB_QUI = @LIB_QUI@ +LIB_SMB = @LIB_SMB@ +LIB_TDECORE = @LIB_TDECORE@ +LIB_TDEPIM = @LIB_TDEPIM@ +LIB_TDEPRINT = @LIB_TDEPRINT@ +LIB_TDEUI = @LIB_TDEUI@ +LIB_X11 = @LIB_X11@ +LIB_XEXT = @LIB_XEXT@ +LIB_XRENDER = @LIB_XRENDER@ +LIPO = @LIPO@ +LN_S = @LN_S@ +LTLIBOBJS = @LTLIBOBJS@ +MAKEINFO = @MAKEINFO@ +MAKEKDEWIDGETS = @MAKEKDEWIDGETS@ +MCOPIDL = @MCOPIDL@ +MEINPROC = @MEINPROC@ +MKDIR_P = @MKDIR_P@ +MOC = @MOC@ +MSGFMT = @MSGFMT@ +NM = @NM@ +NMEDIT = @NMEDIT@ +NOOPT_CFLAGS = @NOOPT_CFLAGS@ +NOOPT_CXXFLAGS = @NOOPT_CXXFLAGS@ +OBJDUMP = @OBJDUMP@ +OBJEXT = @OBJEXT@ +OTOOL = @OTOOL@ +OTOOL64 = @OTOOL64@ +PACKAGE = @PACKAGE@ +PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ +PACKAGE_NAME = @PACKAGE_NAME@ +PACKAGE_STRING = @PACKAGE_STRING@ +PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ +PACKAGE_VERSION = @PACKAGE_VERSION@ +PATH_SEPARATOR = @PATH_SEPARATOR@ +PERL = @PERL@ +PKG_CONFIG = @PKG_CONFIG@ +QTE_NORTTI = @QTE_NORTTI@ +QT_INCLUDES = @QT_INCLUDES@ +QT_LDFLAGS = @QT_LDFLAGS@ +RANLIB = @RANLIB@ +SED = @SED@ +SET_MAKE = @SET_MAKE@ +SHELL = @SHELL@ +STRIP = @STRIP@ +TOPSUBDIRS = @TOPSUBDIRS@ +TQTDCOPIDL = @TQTDCOPIDL@ +TQTDCOPIDL2CPP = @TQTDCOPIDL2CPP@ +TQTDCOPIDLNG = @TQTDCOPIDLNG@ +TQTMCOPIDL = @TQTMCOPIDL@ +TQTMOC = @TQTMOC@ +UIC = @UIC@ +UIC_TR = @UIC_TR@ +USER_INCLUDES = @USER_INCLUDES@ +USER_LDFLAGS = @USER_LDFLAGS@ +USE_EXCEPTIONS = @USE_EXCEPTIONS@ +USE_RTTI = @USE_RTTI@ +USE_THREADS = @USE_THREADS@ +VERSION = @VERSION@ +WOVERLOADED_VIRTUAL = @WOVERLOADED_VIRTUAL@ +XGETTEXT = @XGETTEXT@ +XMKMF = @XMKMF@ +XMLLINT = @XMLLINT@ +X_EXTRA_LIBS = @X_EXTRA_LIBS@ +X_INCLUDES = @X_INCLUDES@ +X_LDFLAGS = @X_LDFLAGS@ +X_PRE_LIBS = @X_PRE_LIBS@ +X_RPATH = @X_RPATH@ +abs_builddir = @abs_builddir@ +abs_srcdir = @abs_srcdir@ +abs_top_builddir = @abs_top_builddir@ +abs_top_srcdir = @abs_top_srcdir@ +ac_ct_CC = @ac_ct_CC@ +ac_ct_CXX = @ac_ct_CXX@ +ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ +all_includes = @all_includes@ +all_libraries = @all_libraries@ +am__include = @am__include@ +am__leading_dot = @am__leading_dot@ +am__quote = @am__quote@ +am__tar = @am__tar@ +am__untar = @am__untar@ +bindir = @bindir@ +build = @build@ +build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ +builddir = @builddir@ +datadir = @datadir@ +datarootdir = @datarootdir@ +docdir = @docdir@ +dvidir = @dvidir@ +exec_prefix = @exec_prefix@ +host = @host@ +host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ +htmldir = @htmldir@ +includedir = @includedir@ +infodir = @infodir@ +install_sh = @install_sh@ +kde_appsdir = @kde_appsdir@ +kde_bindir = @kde_bindir@ +kde_confdir = @kde_confdir@ +kde_datadir = @kde_datadir@ +kde_htmldir = @kde_htmldir@ +kde_icondir = @kde_icondir@ +kde_includes = @kde_includes@ +kde_kcfgdir = @kde_kcfgdir@ +kde_libraries = @kde_libraries@ +kde_libs_htmldir = @kde_libs_htmldir@ +kde_libs_prefix = @kde_libs_prefix@ +kde_locale = @kde_locale@ +kde_mimedir = @kde_mimedir@ +kde_moduledir = @kde_moduledir@ +kde_qtver = @kde_qtver@ +kde_servicesdir = @kde_servicesdir@ +kde_servicetypesdir = @kde_servicetypesdir@ +kde_sounddir = @kde_sounddir@ +kde_styledir = @kde_styledir@ +kde_templatesdir = @kde_templatesdir@ +kde_wallpaperdir = @kde_wallpaperdir@ +kde_widgetdir = @kde_widgetdir@ +libdir = @libdir@ +libexecdir = @libexecdir@ +localedir = @localedir@ +localstatedir = @localstatedir@ +lt_ECHO = @lt_ECHO@ +mandir = @mandir@ +mkdir_p = @mkdir_p@ +oldincludedir = @oldincludedir@ +pdfdir = @pdfdir@ +prefix = @prefix@ +program_transform_name = @program_transform_name@ +psdir = @psdir@ +qt_includes = @qt_includes@ +qt_libraries = @qt_libraries@ +sbindir = @sbindir@ +sharedstatedir = @sharedstatedir@ +srcdir = @srcdir@ +sysconfdir = @sysconfdir@ +target = @target@ +target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ +tdeinitdir = @tdeinitdir@ +top_build_prefix = @top_build_prefix@ +top_builddir = @top_builddir@ +top_srcdir = @top_srcdir@ +x_includes = @x_includes@ +x_libraries = @x_libraries@ +xdg_appsdir = @xdg_appsdir@ +xdg_directorydir = @xdg_directorydir@ +xdg_menudir = @xdg_menudir@ +confskeldir = $(kde_datadir)/kcmldapcontroller/skel +heimdalskeldir = $(confskeldir)/heimdal +heimdalskel_DATA = heimdal/* +ldapskeldir = $(confskeldir)/openldap +ldapskel_DATA = openldap/skel.ldif +ldapconfskeldir = $(ldapskeldir)/ldap +ldapconfskel_DATA = openldap/ldap/* +ldapldifskeldir = $(ldapskeldir)/ldif +ldapldifskel_DATA = openldap/ldif/* +#>- all: all-am +#>+ 1 +all: docs-am all-am + +.SUFFIXES: +$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) +#>- @for dep in $?; do \ +#>- case '$(am__configure_deps)' in \ +#>- *$$dep*) \ +#>- ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ +#>- && { if test -f $@; then exit 0; else break; fi; }; \ +#>- exit 1;; \ +#>- esac; \ +#>- done; \ +#>- echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu confskel/Makefile'; \ +#>- $(am__cd) $(top_srcdir) && \ +#>- $(AUTOMAKE) --gnu confskel/Makefile +#>+ 12 + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu confskel/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --gnu confskel/Makefile + cd $(top_srcdir) && perl admin/am_edit confskel/Makefile.in +.PRECIOUS: Makefile +Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status + @case '$?' in \ + *config.status*) \ + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ + *) \ + echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ + esac; + +$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh + +$(top_srcdir)/configure: $(am__configure_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(ACLOCAL_M4): $(am__aclocal_m4_deps) + cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh +$(am__aclocal_m4_deps): + +mostlyclean-libtool: + -rm -f *.lo + +clean-libtool: + -rm -rf .libs _libs +install-heimdalskelDATA: $(heimdalskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(heimdalskeldir)" || $(MKDIR_P) "$(DESTDIR)$(heimdalskeldir)" + @list='$(heimdalskel_DATA)'; test -n "$(heimdalskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(heimdalskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(heimdalskeldir)" || exit $$?; \ + done + +uninstall-heimdalskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(heimdalskel_DATA)'; test -n "$(heimdalskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(heimdalskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(heimdalskeldir)" && rm -f $$files +install-ldapconfskelDATA: $(ldapconfskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(ldapconfskeldir)" || $(MKDIR_P) "$(DESTDIR)$(ldapconfskeldir)" + @list='$(ldapconfskel_DATA)'; test -n "$(ldapconfskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(ldapconfskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(ldapconfskeldir)" || exit $$?; \ + done + +uninstall-ldapconfskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(ldapconfskel_DATA)'; test -n "$(ldapconfskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(ldapconfskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(ldapconfskeldir)" && rm -f $$files +install-ldapldifskelDATA: $(ldapldifskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(ldapldifskeldir)" || $(MKDIR_P) "$(DESTDIR)$(ldapldifskeldir)" + @list='$(ldapldifskel_DATA)'; test -n "$(ldapldifskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(ldapldifskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(ldapldifskeldir)" || exit $$?; \ + done + +uninstall-ldapldifskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(ldapldifskel_DATA)'; test -n "$(ldapldifskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(ldapldifskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(ldapldifskeldir)" && rm -f $$files +install-ldapskelDATA: $(ldapskel_DATA) + @$(NORMAL_INSTALL) + test -z "$(ldapskeldir)" || $(MKDIR_P) "$(DESTDIR)$(ldapskeldir)" + @list='$(ldapskel_DATA)'; test -n "$(ldapskeldir)" || list=; \ + for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + echo "$$d$$p"; \ + done | $(am__base_list) | \ + while read files; do \ + echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(ldapskeldir)'"; \ + $(INSTALL_DATA) $$files "$(DESTDIR)$(ldapskeldir)" || exit $$?; \ + done + +uninstall-ldapskelDATA: + @$(NORMAL_UNINSTALL) + @list='$(ldapskel_DATA)'; test -n "$(ldapskeldir)" || list=; \ + files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ + test -n "$$files" || exit 0; \ + echo " ( cd '$(DESTDIR)$(ldapskeldir)' && rm -f" $$files ")"; \ + cd "$(DESTDIR)$(ldapskeldir)" && rm -f $$files +tags: TAGS +TAGS: + +ctags: CTAGS +CTAGS: + + +distdir: $(DISTFILES) + @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ + list='$(DISTFILES)'; \ + dist_files=`for file in $$list; do echo $$file; done | \ + sed -e "s|^$$srcdirstrip/||;t" \ + -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ + case $$dist_files in \ + */*) $(MKDIR_P) `echo "$$dist_files" | \ + sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ + sort -u` ;; \ + esac; \ + for file in $$dist_files; do \ + if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ + if test -d $$d/$$file; then \ + dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ + if test -d "$(distdir)/$$file"; then \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ + cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ + find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ + fi; \ + cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ + else \ + test -f "$(distdir)/$$file" \ + || cp -p $$d/$$file "$(distdir)/$$file" \ + || exit 1; \ + fi; \ + done +check-am: all-am +check: check-am +all-am: Makefile $(DATA) +installdirs: + for dir in "$(DESTDIR)$(heimdalskeldir)" "$(DESTDIR)$(ldapconfskeldir)" "$(DESTDIR)$(ldapldifskeldir)" "$(DESTDIR)$(ldapskeldir)"; do \ + test -z "$$dir" || $(MKDIR_P) "$$dir"; \ + done +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_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ + `test -z '$(STRIP)' || \ + echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install +mostlyclean-generic: + +clean-generic: + +distclean-generic: + -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + +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 +#>+ 1 +clean: kde-rpo-clean clean-am + +#>- clean-am: clean-generic clean-libtool mostlyclean-am +#>+ 1 +clean-am: clean-bcheck clean-generic clean-libtool mostlyclean-am + +distclean: distclean-am + -rm -f Makefile +distclean-am: clean-am distclean-generic + +dvi: dvi-am + +dvi-am: + +html: html-am + +html-am: + +info: info-am + +info-am: + +install-data-am: install-heimdalskelDATA install-ldapconfskelDATA \ + install-ldapldifskelDATA install-ldapskelDATA + +install-dvi: install-dvi-am + +install-dvi-am: + +install-exec-am: + +install-html: install-html-am + +install-html-am: + +install-info: install-info-am + +install-info-am: + +install-man: + +install-pdf: install-pdf-am + +install-pdf-am: + +install-ps: install-ps-am + +install-ps-am: + +installcheck-am: + +maintainer-clean: maintainer-clean-am + -rm -f Makefile +maintainer-clean-am: distclean-am maintainer-clean-generic + +mostlyclean: mostlyclean-am + +mostlyclean-am: mostlyclean-generic mostlyclean-libtool + +pdf: pdf-am + +pdf-am: + +ps: ps-am + +ps-am: + +uninstall-am: uninstall-heimdalskelDATA uninstall-ldapconfskelDATA \ + uninstall-ldapldifskelDATA uninstall-ldapskelDATA + +.MAKE: install-am install-strip + +.PHONY: all all-am check check-am clean clean-generic clean-libtool \ + distclean distclean-generic distclean-libtool distdir dvi \ + dvi-am html html-am info info-am install install-am \ + install-data install-data-am install-dvi install-dvi-am \ + install-exec install-exec-am install-heimdalskelDATA \ + install-html install-html-am install-info install-info-am \ + install-ldapconfskelDATA install-ldapldifskelDATA \ + install-ldapskelDATA install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-generic \ + mostlyclean-libtool pdf pdf-am ps ps-am uninstall uninstall-am \ + uninstall-heimdalskelDATA uninstall-ldapconfskelDATA \ + uninstall-ldapldifskelDATA uninstall-ldapskelDATA + + +# 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: + +#>+ 2 +KDE_DIST=Makefile.am Makefile.in + +#>+ 2 +docs-am: + +#>+ 15 +force-reedit: + @for dep in $?; do \ + case '$(am__configure_deps)' in \ + *$$dep*) \ + ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ + && { if test -f $@; then exit 0; else break; fi; }; \ + exit 1;; \ + esac; \ + done; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu confskel/Makefile'; \ + $(am__cd) $(top_srcdir) && \ + $(AUTOMAKE) --gnu confskel/Makefile + cd $(top_srcdir) && perl admin/am_edit confskel/Makefile.in + + +#>+ 21 +clean-bcheck: + rm -f *.bchecktest.cc *.bchecktest.cc.class a.out + +bcheck: bcheck-am + +bcheck-am: + @for i in ; do \ + if test $(srcdir)/$$i -nt $$i.bchecktest.cc; then \ + echo "int main() {return 0;}" > $$i.bchecktest.cc ; \ + echo "#include \"$$i\"" >> $$i.bchecktest.cc ; \ + echo "$$i"; \ + if ! $(CXX) $(DEFS) -I. -I$(srcdir) -I$(top_builddir) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(KDE_CXXFLAGS) --dump-class-hierarchy -c $$i.bchecktest.cc; then \ + rm -f $$i.bchecktest.cc; exit 1; \ + fi ; \ + echo "" >> $$i.bchecktest.cc.class; \ + perl $(top_srcdir)/admin/bcheck.pl $$i.bchecktest.cc.class || { rm -f $$i.bchecktest.cc; exit 1; }; \ + rm -f a.out; \ + fi ; \ + done + + +#>+ 3 +final: + $(MAKE) all-am + +#>+ 3 +final-install: + $(MAKE) install-am + +#>+ 3 +no-final: + $(MAKE) all-am + +#>+ 3 +no-final-install: + $(MAKE) install-am + +#>+ 3 +kde-rpo-clean: + -rm -f *.rpo + +#>+ 3 +nmcheck: +nmcheck-am: nmcheck diff --git a/confskel/openldap/ldif/ems-core.ldif b/confskel/openldap/ldif/ems-core.ldif new file mode 100644 index 0000000..0d48fb0 --- /dev/null +++ b/confskel/openldap/ldif/ems-core.ldif @@ -0,0 +1,174 @@ +dn: cn={@@@LDIFSCHEMANUMBER@@@}ems-core +objectClass: olcSchemaConfig +cn: {@@@LDIFSCHEMANUMBER@@@}ems-core +olcAttributeTypes: {0}( 1.3.6.1.4.1.31267.1.1.1 NAME 'emsdescription' DESC ' + Description of the EMS Object' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSu + bstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{32768} SINGLE-VALUE ) +olcAttributeTypes: {1}( 1.3.6.1.4.1.31267.1.1.2 NAME 'emspermission' DESC 'S + ingle security Entry' SUP name ) +olcAttributeTypes: {2}( 1.3.6.1.4.1.31267.1.1.3 NAME 'emscontainertype' DESC + 'EMS Container Type' SUP emsdescription ) +olcAttributeTypes: {3}( 1.3.6.1.4.1.31267.1.1.4 NAME 'emsplugins' DESC 'Grou + p User Service Plugins' SUP name ) +olcAttributeTypes: {4}( 1.3.6.1.4.1.31267.1.1.5 NAME 'emsprimarygroupdn' DES + C 'EMS Primary Group DN' SUP emsdescription ) +olcAttributeTypes: {5}( 1.3.6.1.4.1.31267.1.1.6 NAME 'emscomputervendormodel + ' DESC 'EMS Computer Vendor Model' SUP emsdescription ) +olcAttributeTypes: {6}( 1.3.6.1.4.1.31267.1.1.7 NAME 'emscomputercpumhz' DES + C 'EMS Computer CPU MHz' SUP emsdescription ) +olcAttributeTypes: {7}( 1.3.6.1.4.1.31267.1.1.8 NAME 'emscomputerram' DES + C 'EMS Computer RAM' SUP emsdescription ) +olcAttributeTypes: {8}( 1.3.6.1.4.1.31267.1.1.9 NAME 'emscomputerswap' DES + C 'EMS Computer SWAP' SUP emsdescription ) +olcAttributeTypes: {9}( 1.3.6.1.4.1.31267.1.1.10 NAME 'emscomputersystem' DE + SC 'EMS Computer System (OS)' SUP emsdescription ) +olcAttributeTypes: {10}( 1.3.6.1.4.1.31267.1.1.11 NAME 'emscomputerdistro' D + ESC 'EMS Computer Distribution' SUP emsdescription ) +olcAttributeTypes: {11}( 1.3.6.1.4.1.31267.1.1.12 NAME 'emscomputerdistrorel + ease' DESC 'EMS Computer Distribution Release' SUP emsdescription ) +olcAttributeTypes: {12}( 1.3.6.1.4.1.31267.1.1.13 NAME 'emsmodelclass' DESC + 'EMS Model Class' SUP emsdescription ) +olcAttributeTypes: {13}( 1.3.6.1.4.1.31267.1.1.14 NAME 'emsservicemap' DESC + 'EMS Computer Map for Plugin' SUP emsplugins ) +olcAttributeTypes: {14}( 1.3.6.1.4.1.31267.1.1.15 NAME 'emsmastercomputerdn' + DESC 'EMS Generic Master Computer Dn' SUP emsdescription ) +olcAttributeTypes: {15}( 1.3.6.1.4.1.31267.1.1.16 NAME 'emscomputersdn' DESC + 'EMS Generic Multivalued Computer Dn' SUP name ) +olcAttributeTypes: {16}( 1.3.6.1.4.1.31267.1.1.17 NAME 'emsmodules' DESC 'EM + S Service Module Name' SUP emsdescription ) +olcAttributeTypes: {17}( 1.3.6.1.4.1.31267.1.1.18 NAME 'emsntpserver' DESC ' + NTP Servers' SUP name ) +olcAttributeTypes: {18}( 1.3.6.1.4.1.31267.1.1.19 NAME 'emssubnetbroadcast' + DESC 'Broadcast To Subnets' SUP name ) +olcAttributeTypes: {19}( 1.3.6.1.4.1.31267.1.1.20 NAME 'emsstatisticsenable' + DESC 'Enable NTP Statistics' SUP emsdescription ) +olcAttributeTypes: {20}( 1.3.6.1.4.1.31267.1.1.21 NAME 'emsstatistics' DESC + 'Statistics To Enable' SUP name ) +olcAttributeTypes: {21}( 1.3.6.1.4.1.31267.1.1.22 NAME 'emsldapserver' DESC + 'Ldap Servers' SUP name ) +olcAttributeTypes: {22}( 1.3.6.1.4.1.31267.1.1.23 NAME 'emskrbserver' DESC ' + Kerberos Servers' SUP name ) +olcAttributeTypes: {23}( 1.3.6.1.4.1.31267.1.1.24 NAME 'emstype' DESC 'Objec + t type' SUP emsdescription ) +olcAttributeTypes: {24}( 1.3.6.1.4.1.31267.1.1.25 NAME 'emsdnsslavecomputerd + ns' DESC 'EMS Dns Slaves' SUP name ) +olcAttributeTypes: {25}( 1.3.6.1.4.1.31267.1.1.26 NAME 'emsdnsreplicationmod + e' DESC 'EMS Dns Replication Mode' SUP emsdescription ) +olcAttributeTypes: {26}( 1.3.6.1.4.1.31267.1.1.27 NAME 'emsdnsmastercomputer + dn' DESC 'EMS Dns Master Computer DN' SUP emsdescription ) +olcAttributeTypes: {27}( 1.3.6.1.4.1.31267.1.1.28 NAME 'emsdnsrootzone' DESC + 'ems dns root Zone ' SUP emsdescription ) +olcAttributeTypes: {28}( 1.3.6.1.4.1.31267.1.1.29 NAME 'emsmodulename' DESC + 'ems module name' SUP emsdescription ) +olcAttributeTypes: {29}( 1.3.6.1.4.1.31267.1.1.30 NAME 'emscaserver' DESC 'C + A Server' SUP name ) +olcAttributeTypes: {30}( 1.3.6.1.4.1.31267.1.1.31 NAME 'emscomputerarch' DES + C 'Computer Arch type' SUP name) +olcAttributeTypes: {31}( 1.3.6.1.4.1.31267.1.1.32 NAME 'emsdnszonetype' DESC + 'Ems DNS Zone Type' SUP emsdescription) +olcAttributeTypes: {32}( 1.3.6.1.4.1.31267.1.1.33 NAME 'emsdistrodesc' DESC + 'Ems Distribution Description' SUP emsdescription) +olcAttributeTypes: {33}( 1.3.6.1.4.1.31267.1.1.34 NAME 'emsdistrocodename' + DESC 'Ems Computer Distribution Codename' SUP emsdescription) +olcAttributeTypes: {34}( 1.3.6.1.4.1.31267.1.1.35 NAME 'emssubchannels' DES + C 'Ems Subscribed Channels' SUP name) +olcAttributeTypes: {35}( 1.3.6.1.4.1.31267.1.1.36 NAME 'emscomputercpucount' DES + C 'EMS Computer CPU count' SUP name) +olcAttributeTypes: {36}( 1.3.6.1.4.1.31267.1.1.37 NAME 'emsdependson' DESC 'EMS + Dependency'SUP name) +olcAttributeTypes: {37}( 1.3.6.1.4.1.31267.1.1.38 NAME 'emsaccountlockout' DESC + 'EMS Global Account Lockout' SUP name) +olcObjectClasses: {0}( 1.3.6.1.4.1.31267.1.2.1 NAME 'ZvLdapObject' DESC 'EMS + Ldap Object' SUP top AUXILIARY MAY (emspermission $ emsdependson )) +olcObjectClasses: {1}( 1.3.6.1.4.1.31267.1.2.2 NAME 'ZvCacheObject' DESC 'EM + S Cacheable Object' SUP ZvLdapObject AUXILIARY ) +olcObjectClasses: {2}( 1.3.6.1.4.1.31267.1.2.3 NAME 'emsSecurityObject' DESC + 'EMS Security Object' SUP zvCacheObject AUXILIARY MAY emspermission ) +olcObjectClasses: {3}( 1.3.6.1.4.1.31267.1.2.4 NAME 'emsObject' DESC 'EMS Ob + ject' SUP zvCacheObject AUXILIARY MUST ( emsdescription $ cn ) MAY ( emsmod + elclass $ emstype $ emsmodulename ) ) +olcObjectClasses: {4}( 1.3.6.1.4.1.31267.1.2.5 NAME 'emsOrganizationalUnit' + DESC 'EMS Organizational Unit' SUP emsObject AUXILIARY MUST ( emsdescriptio + n $ emstype $ ou $ cn $ emscontainertype ) ) +olcObjectClasses: {5}( 1.3.6.1.4.1.31267.1.2.6 NAME 'emsGroup' DESC 'EMS Gro + up' SUP emsObject AUXILIARY MUST ( emsdescription $ emstype $ cn ) MAY ( em + splugins $ emsservicemap $ emsmodules ) ) +olcObjectClasses: {6}( 1.3.6.1.4.1.31267.1.2.7 NAME 'emsUser' DESC 'EMS User + ' SUP emsObject AUXILIARY MUST ( emsdescription $ emstype $ cn $ emsprimary + groupdn ) MAY ( emsplugins $ emsmodules $ emsaccountlockout ) ) +olcObjectClasses: {7}( 1.3.6.1.4.1.31267.1.2.8 NAME 'emsComputer' DESC 'EMS + Computer' SUP emsObject AUXILIARY MUST ( emsdescription $ emstype $ cn ) MA + Y ( emsmodules $ emsservicemap $ emsplugins $ emscomputervendormodel $ emscomp + utercpumhz $ emscomputercpucount $ emscomputersystem $ emscomputerram $ emscom + puterswap $ emscomputerdistro $ emscomputerdistrorelease $ sn $ uid $ emscompu + terarch $ emsdistrodesc $ emsdistrocodename $ emssubchannels) ) +olcObjectClasses: {8}( 1.3.6.1.4.1.31267.1.2.9 NAME 'emsKerberos' DESC 'EMS + Kerberos' SUP emsObject AUXILIARY MUST ( emsdescription $ emstype $ cn ) ) +olcObjectClasses: {9}( 1.3.6.1.4.1.31267.1.2.10 NAME 'emsHost' DESC 'EMS DNS + Host Entry' SUP emsObject AUXILIARY MUST ( emsdescription $ emstype $ cn ) + ) +olcObjectClasses: {10}( 1.3.6.1.4.1.31267.1.2.11 NAME 'emsLocality' DESC 'EM + S Locality Entry' SUP emsObject AUXILIARY ) +olcObjectClasses: {11}( 1.3.6.1.4.1.31267.1.2.12 NAME 'emsUserContainer' DES + C 'EMS User Container' SUP emsOrganizationalUnit AUXILIARY MUST ( emsdescri + ption $ emstype $ cn ) ) +olcObjectClasses: {12}( 1.3.6.1.4.1.31267.1.2.13 NAME 'emsGroupContainer' DE + SC 'EMS Group' SUP emsOrganizationalUnit AUXILIARY MUST ( emsdescription $ + emstype $ cn ) ) +olcObjectClasses: {13}( 1.3.6.1.4.1.31267.1.2.14 NAME 'emsComputerContainer' + DESC 'EMS Group' SUP emsOrganizationalUnit AUXILIARY MUST ( emsdescription + $ emstype $ cn ) ) +olcObjectClasses: {14}( 1.3.6.1.4.1.31267.1.2.15 NAME 'emsKrbContainer' DESC + 'EMS Group' SUP emsObject AUXILIARY MUST ( emsdescription $ emstype $ cn ) + ) +olcObjectClasses: {15}( 1.3.6.1.4.1.31267.1.2.16 NAME 'emsDNSContainer' DESC + 'EMS Group' SUP emsObject AUXILIARY MUST ( emsdescription $ emstype $ cn ) + ) +olcObjectClasses: {16}( 1.3.6.1.4.1.31267.1.2.17 NAME 'emsIgnore' DESC 'EMS + Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {17}( 1.3.6.1.4.1.31267.1.2.18 NAME 'emsDnsZone' DESC 'EMS + Ignore Object' SUP emsObject AUXILIARY MUST (emsdnszonetype) ) +olcObjectClasses: {18}( 1.3.6.1.4.1.31267.1.2.19 NAME 'emsDnsHostName' DESC + 'EMS Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {19}( 1.3.6.1.4.1.31267.1.2.20 NAME 'emsDnsRecord' DESC 'E + MS Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {20}( 1.3.6.1.4.1.31267.1.2.21 NAME 'emsDhcpServer' DESC ' + EMS Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {21}( 1.3.6.1.4.1.31267.1.2.22 NAME 'emsDhcpService' DESC + 'EMS Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {22}( 1.3.6.1.4.1.31267.1.2.23 NAME 'emsDhcpSharedNetwork' + DESC 'EMS Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {23}( 1.3.6.1.4.1.31267.1.2.24 NAME 'emsDhcpSubnet' DESC ' + EMS Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {24}( 1.3.6.1.4.1.31267.1.2.25 NAME 'emsDhcpPool' DESC 'EM + S Ignore Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {25}( 1.3.6.1.4.1.31267.1.2.26 NAME 'emsDhcpContainer' DES + C 'EMS Dhcp Container' SUP emsOrganizationalUnit AUXILIARY ) +olcObjectClasses: {26}( 1.3.6.1.4.1.31267.1.2.27 NAME 'emsOlcDatabase' DESC + 'EMS Exten Entry Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {27}( 1.3.6.1.4.1.31267.1.2.28 NAME 'emsCnConfig' DESC 'EM + S Cn Config Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {28}( 1.3.6.1.4.1.31267.1.2.29 NAME 'emsOlcSchema' DESC 'E + MS Schema Entry Object' SUP emsObject AUXILIARY ) +olcObjectClasses: {29}( 1.3.6.1.4.1.31267.1.2.30 NAME 'emsOlcSchemaConfig' D + ESC 'EMS Schema Collection Entry' SUP emsObject AUXILIARY ) +olcObjectClasses: {30}( 1.3.6.1.4.1.31267.1.2.31 NAME 'emsservice' DESC 'EMS + Service' SUP emsObject AUXILIARY MUST emsmodulename MAY ( emsmastercompute + rdn $ emscomputersdn ) ) +olcObjectClasses: {31}( 1.3.6.1.4.1.31267.1.2.32 NAME 'emsdnsservice' DESC ' + EMS DNS Service' SUP emsservice AUXILIARY MUST ( emsdnsmastercomputerdn $ e + msdnsreplicationmode $ emsdnsrootzone ) MAY emsdnsslavecomputerdns ) +olcObjectClasses: {32}( 1.3.6.1.4.1.31267.1.2.33 NAME 'emsntpservice' DESC ' + EMS NTP Service' SUP emsservice AUXILIARY MUST emsntpserver MAY ( emssubnet + broadcast $ emsstatisticsenable $ emsstatistics ) ) +olcObjectClasses: {33}( 1.3.6.1.4.1.31267.1.2.34 NAME 'emsldapservice' DESC + 'EMS LDAP Service' SUP emsservice AUXILIARY MUST emsldapserver ) +olcObjectClasses: {34}( 1.3.6.1.4.1.31267.1.2.35 NAME 'emskerberosservice' D + ESC 'EMS Kerberos Service' SUP emsservice AUXILIARY MUST emskrbserver ) +olcObjectClasses: {35}( 1.3.6.1.4.1.31267.1.2.36 NAME 'emsplugin' DESC 'EMS + Plugin' SUP ZvCacheObject AUXILIARY ) +olcObjectClasses: {36}( 1.3.6.1.4.1.31267.1.2.37 NAME 'emscaservice' DESC 'E + MS CA Service' SUP emsservice AUXILIARY MUST emscaserver ) +olcObjectClasses: {37}( 1.3.6.1.4.1.31267.1.2.38 NAME 'emscomputergroup' DES + C 'EMS Computer Group' SUP emsobject AUXILIARY MAY (member $ emssubchannels + $ emsmodules $ emsplugins)) diff --git a/confskel/openldap/ldif/hdb.ldif b/confskel/openldap/ldif/hdb.ldif new file mode 100644 index 0000000..10f2651 --- /dev/null +++ b/confskel/openldap/ldif/hdb.ldif @@ -0,0 +1,39 @@ +dn: cn={@@@LDIFSCHEMANUMBER@@@}hdb +objectClass: olcSchemaConfig +cn: {@@@LDIFSCHEMANUMBER@@@}hdb +olcAttributeTypes: {0}( 1.3.6.1.4.1.5322.10.1.1 NAME 'krb5PrincipalName' DESC + 'The unparsed Kerberos principal name' EQUALITY caseExactIA5Match SYNTAX 1.3. + 6.1.4.1.1466.115.121.1.26 SINGLE-VALUE ) +olcAttributeTypes: {1}( 1.3.6.1.4.1.5322.10.1.2 NAME 'krb5KeyVersionNumber' EQ + UALITY integerMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE ) +olcAttributeTypes: {2}( 1.3.6.1.4.1.5322.10.1.3 NAME 'krb5MaxLife' EQUALITY in + tegerMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE ) +olcAttributeTypes: {3}( 1.3.6.1.4.1.5322.10.1.4 NAME 'krb5MaxRenew' EQUALITY i + ntegerMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE ) +olcAttributeTypes: {4}( 1.3.6.1.4.1.5322.10.1.5 NAME 'krb5KDCFlags' EQUALITY i + ntegerMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 SINGLE-VALUE ) +olcAttributeTypes: {5}( 1.3.6.1.4.1.5322.10.1.6 NAME 'krb5EncryptionType' EQUA + LITY integerMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.27 ) +olcAttributeTypes: {6}( 1.3.6.1.4.1.5322.10.1.7 NAME 'krb5ValidStart' EQUALITY + generalizedTimeMatch ORDERING generalizedTimeOrderingMatch SYNTAX 1.3.6.1.4. + 1.1466.115.121.1.24 SINGLE-VALUE ) +olcAttributeTypes: {7}( 1.3.6.1.4.1.5322.10.1.8 NAME 'krb5ValidEnd' EQUALITY g + eneralizedTimeMatch ORDERING generalizedTimeOrderingMatch SYNTAX 1.3.6.1.4.1. + 1466.115.121.1.24 SINGLE-VALUE ) +olcAttributeTypes: {8}( 1.3.6.1.4.1.5322.10.1.9 NAME 'krb5PasswordEnd' EQUALIT + Y generalizedTimeMatch ORDERING generalizedTimeOrderingMatch SYNTAX 1.3.6.1.4 + .1.1466.115.121.1.24 SINGLE-VALUE ) +olcAttributeTypes: {9}( 1.3.6.1.4.1.5322.10.1.10 NAME 'krb5Key' DESC 'Encoded + ASN1 Key as an octet string' SYNTAX 1.3.6.1.4.1.1466.115.121.1.5 ) +olcAttributeTypes: {10}( 1.3.6.1.4.1.5322.10.1.11 NAME 'krb5PrincipalRealm' DE + SC 'Distinguished name of krb5Realm entry' SUP distinguishedName ) +olcAttributeTypes: {11}( 1.3.6.1.4.1.5322.10.1.12 NAME 'krb5RealmName' EQUALIT + Y octetStringMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.40{128} ) +olcObjectClasses: {0}( 1.3.6.1.4.1.5322.10.2.1 NAME 'krb5Principal' SUP top AU + XILIARY MUST krb5PrincipalName MAY ( cn $ krb5PrincipalRealm ) ) +olcObjectClasses: {1}( 1.3.6.1.4.1.5322.10.2.2 NAME 'krb5KDCEntry' SUP krb5Pri + ncipal AUXILIARY MUST krb5KeyVersionNumber MAY ( krb5ValidStart $ krb5ValidEn + d $ krb5PasswordEnd $ krb5MaxLife $ krb5MaxRenew $ krb5KDCFlags $ krb5Encrypt + ionType $ krb5Key ) ) +olcObjectClasses: {2}( 1.3.6.1.4.1.5322.10.2.3 NAME 'krb5Realm' SUP top AUXILI + ARY MUST krb5RealmName ) diff --git a/confskel/openldap/ldif/olcDatabase.ldif b/confskel/openldap/ldif/olcDatabase.ldif new file mode 100644 index 0000000..303a756 --- /dev/null +++ b/confskel/openldap/ldif/olcDatabase.ldif @@ -0,0 +1,26 @@ +dn: olcDatabase={@@@LDIFSCHEMANUMBER@@@}hdb +objectClass: olcDatabaseConfig +objectClass: olcHdbConfig +olcDatabase: {@@@LDIFSCHEMANUMBER@@@}hdb +olcDbDirectory: /var/lib/ldap +olcSuffix: @@@REALM_DCNAME@@@ +olcAccess: {0}to attrs=userPassword,shadowLastChange by self write by anonymou + s auth by dn="cn=@@@ROOTUSER@@@,@@@REALM_DCNAME@@@" write by * none +olcAccess: {1}to dn.base="" by * read +olcAccess: {2}to * by self write by dn="cn=@@@ROOTUSER@@@,@@@REALM_DCNAME@@@" write by + * read +olcLastMod: TRUE +olcRootDN: cn=@@@ROOTUSER@@@,@@@REALM_DCNAME@@@ +olcRootPW: {SHA}@@@ROOTPW_SHA@@@ +olcDbCheckpoint: 512 30 +olcDbConfig: {0}set_cachesize 0 2097152 0 +olcDbConfig: {1}set_lk_max_objects 1500 +olcDbConfig: {2}set_lk_max_locks 1500 +olcDbConfig: {3}set_lk_max_lockers 1500 +olcDbIndex: objectClass eq +structuralObjectClass: olcHdbConfig +creatorsName: cn=config +createTimestamp: @@@TIMESTAMP@@@Z +entryCSN: @@@TIMESTAMP@@@.000000Z#000000#000#000000 +modifiersName: cn=config +modifyTimestamp: @@@TIMESTAMP@@@Z diff --git a/confskel/openldap/ldif/tde-core.ldif b/confskel/openldap/ldif/tde-core.ldif new file mode 100644 index 0000000..8670379 --- /dev/null +++ b/confskel/openldap/ldif/tde-core.ldif @@ -0,0 +1,10 @@ +dn: cn={@@@LDIFSCHEMANUMBER@@@}tde-core +objectClass: olcSchemaConfig +cn: {@@@LDIFSCHEMANUMBER@@@}tde-core +olcAttributeTypes: {0}( 1.3.6.1.4.1.99999.1.1.1 NAME 'websiteURL' DESC 'Website URL' SUP name ) +olcAttributeTypes: {1}( 1.3.6.1.4.1.99999.1.1.2 NAME 'managerName' DESC 'Manager name' SUP name ) +olcAttributeTypes: {2}( 1.3.6.1.4.1.99999.1.1.3 NAME 'secretaryName' DESC 'Secretary name' SUP name ) +olcAttributeTypes: {3}( 1.3.6.1.4.1.99999.1.1.4 NAME 'teletexId' DESC 'Teletex ID' SUP name ) +olcAttributeTypes: {4}( 1.3.6.1.4.1.99999.1.1.5 NAME 'preferredDelivery' DESC 'Preferred delivery location' SUP name ) +olcAttributeTypes: {5}( 1.3.6.1.4.1.99999.1.1.6 NAME 'locallyUniqueID' DESC 'Locally unique identifier' SUP name ) +olcAttributeTypes: {6}( 1.3.6.1.4.1.99999.1.1.7 NAME 'notes' DESC 'Account notes' SUP name )
\ No newline at end of file diff --git a/confskel/openldap/skel.ldif b/confskel/openldap/skel.ldif index 8cb69c5..0320c2d 100644 --- a/confskel/openldap/skel.ldif +++ b/confskel/openldap/skel.ldif @@ -77,15 +77,13 @@ emsplugins: PosixGroup emsplugins: KerberosGroup emstype: GroupEntry gidNumber: 999 -objectClass: groupOfNames objectClass: emsGroup objectClass: posixGroup emsmodules: kerberos emsmodules: posix -member: cn=placeholder,@@@REALM_DCNAME@@@ -member: uid=@@@ADMINUSER@@@,ou=users,ou=core,ou=realm,@@@REALM_DCNAME@@@ +memberUid: @@@ADMINUSER@@@ emsmodelclass: EMSGroup -structuralObjectClass: groupOfNames +structuralObjectClass: posixGroup creatorsName: cn=@@@ROOTUSER@@@,@@@REALM_DCNAME@@@ createTimestamp: @@@TIMESTAMP@@@Z entryCSN: @@@TIMESTAMP@@@.000000Z#000000#000#000000 diff --git a/src/Makefile.am b/src/Makefile.am index 5ad0fd3..5aa0043 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -4,7 +4,7 @@ METASOURCES = AUTO # Install this plugin in the KDE modules directory kde_module_LTLIBRARIES = kcm_ldapcontroller.la -kcm_ldapcontroller_la_SOURCES = ldapcontroller.cpp ldapcontrollerconfigbase.ui realmwizard.cpp realmintropagedlg.ui realmintropage.cpp realmconfigpagedlg.ui realmconfigpage.cpp realmfinishpagedlg.ui realmfinishpage.cpp processingdialog.cpp +kcm_ldapcontroller_la_SOURCES = ldapcontroller.cpp ldapcontrollerconfigbase.ui realmwizard.cpp realmintropagedlg.ui realmintropage.cpp realmconfigpagedlg.ui realmconfigpage.cpp realmfinishpagedlg.ui realmfinishpage.cpp processingdialog.cpp sha1.cc kcm_ldapcontroller_la_LIBADD = -lkio $(LIB_TDEUI) kcm_ldapcontroller_la_LDFLAGS = -avoid-version -module -no-undefined \ $(all_libraries) diff --git a/src/ldapcontroller.cpp b/src/ldapcontroller.cpp index 0b30db9..427148b 100644 --- a/src/ldapcontroller.cpp +++ b/src/ldapcontroller.cpp @@ -41,6 +41,9 @@ #include <kmessagebox.h> #include <tqcheckbox.h> #include <ktempdir.h> +#include <kprocess.h> + +#include "sha1.h" #include "ldapcontroller.h" #include "realmwizard.h" @@ -225,11 +228,109 @@ void LDAPController::save() { load(); } -void replacePlaceholdersInFile(TQString infile, TQString outfile) { +void replacePlaceholdersInFile(TQString infile, TQString outfile, LDAPRealmConfig realmconfig, TQString adminUserName, TQString adminGroupName, const char * adminPassword, TQString rootUserName, const char * rootPassword, int ldifSchemaNumber=-1, uid_t userid=-1, gid_t groupid=-1) { + SHA1 sha; + sha.process(rootPassword, strlen(rootPassword)); + TQString rootpw_hash = sha.base64Hash(); + sha.reset(); + sha.process(adminPassword, strlen(rootPassword)); + TQString adminpw_hash = sha.base64Hash(); + // RAJA FIXME + + // Created needed strings + TQStringList domainChunks = TQStringList::split(".", realmconfig.name.lower()); + TQString basedcname = "dc=" + domainChunks.join(",dc="); + TQString simpledcname = domainChunks[0]; + TQString simpledcnamecap = simpledcname.lower(); + simpledcnamecap[0] = simpledcnamecap[0].upper(); + TQString timestamp = TQDateTime::currentDateTime().toString(TQt::ISODate); + timestamp.replace("-", ""); + timestamp.replace(":", ""); + timestamp.replace("T", ""); + + TQFile ifile(infile); + TQFile ofile(outfile); + if (ifile.open(IO_ReadOnly) && ofile.open(IO_WriteOnly)) { + TQString line; + TQTextStream istream(&ifile); + TQTextStream ostream(&ofile); + while (!istream.atEnd()) { + line = istream.readLine(); + line.replace("@@@REALM_DCNAME@@@", basedcname); + line.replace("@@@REALM_UCNAME@@@", realmconfig.name.upper()); + line.replace("@@@REALM_LCNAME@@@", realmconfig.name.lower()); + line.replace("@@@ADMINSERVER@@@", realmconfig.admin_server); + line.replace("@@@ADMINPORT@@@", TQString("%1").arg(realmconfig.admin_server_port)); + line.replace("@@@KDCSERVER@@@", realmconfig.kdc); + line.replace("@@@KDCPORT@@@", TQString("%1").arg(realmconfig.kdc_port)); + line.replace("@@@ROOTUSER@@@", rootUserName); + line.replace("@@@ROOTPW_SHA@@@", rootpw_hash); + line.replace("@@@ADMINUSER@@@", adminUserName); + line.replace("@@@ADMINGROUP@@@", adminGroupName); + line.replace("@@@ADMINPW_SHA@@@", adminpw_hash); + line.replace("@@@PKINIT_REQUIRE_EKU@@@", (realmconfig.pkinit_require_eku)?"yes":"no"); + line.replace("@@@PKINIT_REQUIRE_KRBTGT_OTHERNAME@@@", (realmconfig.pkinit_require_krbtgt_otherName)?"yes":"no"); + line.replace("@@@WIN2K_PKINIT@@@", (realmconfig.win2k_pkinit)?"yes":"no"); + line.replace("@@@WIN2K_PKINIT_REQUIRE_BINDING@@@", (realmconfig.win2k_pkinit_require_binding)?"yes":"no"); + line.replace("@@@REALM_SIMPLE_CP_NAME@@@", simpledcnamecap); + line.replace("@@@REALM_SIMPLE_LC_NAME@@@", simpledcname.lower()); + line.replace("@@@TIMESTAMP@@@", timestamp); + if (ldifSchemaNumber >= 0) { + line.replace("@@@LDIFSCHEMANUMBER@@@", TQString("%1").arg(ldifSchemaNumber)); + } + ostream << line << "\n"; + } + ifile.close(); + ofile.close(); + } + + // Set permissions + if ((userid > 0) && (groupid > 0)) { + chown(outfile.ascii(), userid, groupid); + } + + // Keep UI responsive + tqApp->processEvents(); } -int LDAPController::createNewLDAPRealm(TQWidget* dialogparent, LDAPRealmConfig realmconfig, TQString adminUserName, const char * adminPassword, TQString adminRealm, TQString *errstr) { +int LDAPController::controlLDAPServer(sc_command command, uid_t userid, gid_t groupid) { + if (command == SC_START) { + // FIXME + // This assumes Debian! + return system("/etc/init.d/slapd start"); + } + if (command == SC_STOP) { + // FIXME + // This assumes Debian! + return system("/etc/init.d/slapd stop"); + } + if (command == SC_RESTART) { + // FIXME + // This assumes Debian! + return system("/etc/init.d/slapd restart"); + } + if (command == SC_PURGE) { + controlLDAPServer(SC_STOP); + // FIXME + // This assumes Debian! + system("rm -rf /var/lib/ldap/*"); + } + if (command == SC_SETDBPERMS) { + if ((userid > 0) && (groupid > 0)) { + TQString command; + command = TQString("chown -R %1 /var/lib/ldap/*").arg(userid); + system(command.ascii()); + command = TQString("chgrp -R %1 /var/lib/ldap/*").arg(groupid); + system(command.ascii()); + } + } + return -2; +} + +int LDAPController::createNewLDAPRealm(TQWidget* dialogparent, LDAPRealmConfig realmconfig, TQString adminUserName, TQString adminGroupName, const char * adminPassword, TQString rootUserName, const char * rootPassword, TQString adminRealm, TQString *errstr) { + int ldifSchemaNumber; + ProcessingDialog pdialog(dialogparent); pdialog.setStatusMessage(i18n("Loading data for realm deployment...")); pdialog.raise(); @@ -237,16 +338,100 @@ int LDAPController::createNewLDAPRealm(TQWidget* dialogparent, LDAPRealmConfig r tqApp->processEvents(); // Find the templates - TQString templateDir = locate("data", "kcmldapcontroller/skel"); -printf("[RAJA DEBUG 100.0] templateDir: %s\n\r", templateDir.ascii()); fflush(stdout); + TQString templateDir = locate("data", "kcmldapcontroller/skel/heimdal/heimdal.defaults"); + templateDir.replace("heimdal/heimdal.defaults", ""); if (templateDir == "") { + if (errstr) *errstr = i18n("Unable to locate required template files"); pdialog.closeDialog(); return -1; } KTempDir configTempDir; configTempDir.setAutoDelete(true); - replacePlaceholdersInFile(templateDir + "heimdal/heimdal.defaults", configTempDir.name() + "heimdal/heimdal.defaults"); +configTempDir.setAutoDelete(false); // RAJA DEBUG ONLY + TQString destDir = "/etc/"; + + mkdir(TQString(destDir + "heimdal").ascii(), S_IRUSR|S_IWUSR|S_IXUSR); + mkdir(TQString(destDir + "openldap").ascii(), S_IRUSR|S_IWUSR|S_IXUSR); + mkdir(TQString(destDir + "openldap/ldap").ascii(), S_IRUSR|S_IWUSR|S_IXUSR); + + replacePlaceholdersInFile(templateDir + "heimdal/heimdal.defaults", destDir + "heimdal.defaults", realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword); + replacePlaceholdersInFile(templateDir + "heimdal/kadmind.acl", destDir + "kadmind.acl", realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword); + replacePlaceholdersInFile(templateDir + "heimdal/kdc.conf", destDir + "kdc.conf", realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword); + replacePlaceholdersInFile(templateDir + "heimdal/krb5.conf", destDir + "krb5.conf", realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword); + + replacePlaceholdersInFile(templateDir + "openldap/skel.ldif", configTempDir.name() + "skel.ldif", realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword); + replacePlaceholdersInFile(templateDir + "openldap/ldap/slapd.conf", destDir + "ldap/slapd.conf", realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword); + replacePlaceholdersInFile(templateDir + "openldap/ldap/slapd.defaults", destDir + "ldap/slapd.defaults", realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword); + + struct stat sb; + uid_t slapd_uid = 0; + gid_t slapd_gid = 0; + if (stat(destDir + "ldap/slapd.d/cn=config/cn=schema", &sb) == 0) { + slapd_uid = sb.st_uid; + slapd_gid = sb.st_gid; + } + + // Base database configuration + ldifSchemaNumber = 1; + replacePlaceholdersInFile(templateDir + "openldap/ldif/olcDatabase.ldif", destDir + "ldap/slapd.d/cn=config/" + TQString("olcDatabase={%1}hdb.ldif").arg(ldifSchemaNumber), realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword, ldifSchemaNumber, slapd_uid, slapd_gid); + + // Schema files + ldifSchemaNumber = 10; + replacePlaceholdersInFile(templateDir + "openldap/ldif/ems-core.ldif", destDir + "ldap/slapd.d/cn=config/cn=schema/" + TQString("cn={%1}ems-core.ldif").arg(ldifSchemaNumber), realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword, ldifSchemaNumber, slapd_uid, slapd_gid); + ldifSchemaNumber = 11; + replacePlaceholdersInFile(templateDir + "openldap/ldif/hdb.ldif", destDir + "ldap/slapd.d/cn=config/cn=schema/" + TQString("cn={%1}hdb.ldif").arg(ldifSchemaNumber), realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword, ldifSchemaNumber, slapd_uid, slapd_gid); + ldifSchemaNumber = 12; + replacePlaceholdersInFile(templateDir + "openldap/ldif/tde-core.ldif", destDir + "ldap/slapd.d/cn=config/cn=schema/" + TQString("cn={%1}tde-core.ldif").arg(ldifSchemaNumber), realmconfig, adminUserName, adminGroupName, adminPassword, rootUserName, rootPassword, ldifSchemaNumber, slapd_uid, slapd_gid); + + // Set permissions + chmod(TQString(destDir + "heimdal.defaults").ascii(), S_IRUSR|S_IWUSR|S_IRGRP); + chmod(TQString(destDir + "kadmind.acl").ascii(), S_IRUSR|S_IWUSR|S_IRGRP); + chmod(TQString(destDir + "kdc.conf").ascii(), S_IRUSR|S_IWUSR|S_IRGRP); + chmod(TQString(destDir + "krb5.conf").ascii(), S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH); + + chmod(TQString(configTempDir.name() + "skel.ldif").ascii(), S_IRUSR|S_IWUSR); + chmod(TQString(destDir + "ldap/slapd.conf").ascii(), S_IRUSR|S_IWUSR); + chmod(TQString(destDir + "ldap/slapd.defaults").ascii(), S_IRUSR|S_IWUSR|S_IRGRP); + + pdialog.setStatusMessage(i18n("Purging existing LDAP database...")); + tqApp->processEvents(); + controlLDAPServer(SC_PURGE); + + pdialog.setStatusMessage(i18n("Loading initial database into LDAP...")); + tqApp->processEvents(); + + // Stop slapd + if (controlLDAPServer(SC_STOP) != 0) { + if (errstr) *errstr = i18n("Unable to stop LDAP server"); + pdialog.closeDialog(); + return -1; + } + + // Load database + KProcess slapadd; + slapadd << "slapadd" << "-l" << configTempDir.name() + "skel.ldif"; + slapadd.start(); + while (slapadd.isRunning()) { + tqApp->processEvents(); + } + if (slapadd.exitStatus() != 0) { + if (errstr) *errstr = i18n("Unable to import initial database into LDAP"); + pdialog.closeDialog(); + return -1; + } + + controlLDAPServer(SC_SETDBPERMS, slapd_uid, slapd_gid); + + pdialog.setStatusMessage(i18n("Starting LDAP server...")); + tqApp->processEvents(); + + // Start slapd + if (controlLDAPServer(SC_START) != 0) { + if (errstr) *errstr = i18n("Unable to start LDAP server"); + pdialog.closeDialog(); + return -1; + } // RAJA FIXME pdialog.closeDialog(); diff --git a/src/ldapcontroller.h b/src/ldapcontroller.h index b09a46c..f5bd2a7 100644 --- a/src/ldapcontroller.h +++ b/src/ldapcontroller.h @@ -32,6 +32,14 @@ #include "ldapcontrollerconfigbase.h" +enum sc_command { + SC_START, + SC_STOP, + SC_RESTART, + SC_PURGE, + SC_SETDBPERMS +}; + // PRIVATE class LDAPRealmConfig { @@ -67,7 +75,7 @@ class LDAPController: public KCModule virtual const KAboutData *aboutData() const { return myAboutData; }; public: - int createNewLDAPRealm(TQWidget* dialogparent, LDAPRealmConfig realmconfig, TQString adminUserName, const char * adminPassword, TQString adminRealm, TQString *errstr); + int createNewLDAPRealm(TQWidget* dialogparent, LDAPRealmConfig realmconfig, TQString adminUserName, TQString adminGroupName, const char * adminPassword, TQString rootUserName, const char * rootPassword, TQString adminRealm, TQString *errstr); // FIXME // This should be moved to a TDE core library @@ -78,6 +86,9 @@ class LDAPController: public KCModule void processLockouts(); private: + int controlLDAPServer(sc_command command, uid_t userid=-1, gid_t groupid=-1); + + private: KAboutData *myAboutData; LDAPControllerConfigBase *m_base; diff --git a/src/realmfinishpage.cpp b/src/realmfinishpage.cpp index c71fc0b..f2fd1b6 100644 --- a/src/realmfinishpage.cpp +++ b/src/realmfinishpage.cpp @@ -43,6 +43,7 @@ RealmFinishPage::RealmFinishPage(TQWidget *parent, const char *name ) : RealmFin px_introSidebar->setPixmap(UserIcon("step3.png")); connect(ldapAdminUsername, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(validateEntries())); + connect(ldapAdminGroupname, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(validateEntries())); m_parentWizard = dynamic_cast<KWizard*>(parent); m_parentDialog = dynamic_cast<KDialogBase*>(parent); @@ -54,7 +55,7 @@ RealmFinishPage::~RealmFinishPage(){ void RealmFinishPage::validateEntries() { if (m_parentWizard) { - if (ldapAdminUsername->text() != "") { + if ((ldapAdminUsername->text() != "") && (ldapAdminGroupname->text() != "")) { m_parentWizard->finishButton()->setEnabled(true); } else { @@ -62,7 +63,7 @@ void RealmFinishPage::validateEntries() { } } if (m_parentDialog) { - if (ldapAdminUsername->text() != "") { + if ((ldapAdminUsername->text() != "") && (ldapAdminGroupname->text() != "")) { m_parentDialog->enableButton(KDialogBase::Ok, true); } else { diff --git a/src/realmfinishpagedlg.ui b/src/realmfinishpagedlg.ui index 121e632..5cd11d6 100644 --- a/src/realmfinishpagedlg.ui +++ b/src/realmfinishpagedlg.ui @@ -99,15 +99,28 @@ <cstring>unnamed</cstring> </property> <property name="text"> - <string>LDAP Realm</string> + <string>Administration Group</string> </property> </widget> <widget class="KLineEdit" row="5" column="2"> <property name="name"> + <cstring>ldapAdminGroupname</cstring> + </property> + </widget> + <widget class="TQLabel" row="6" column="1"> + <property name="name"> + <cstring>unnamed</cstring> + </property> + <property name="text"> + <string>LDAP Realm</string> + </property> + </widget> + <widget class="KLineEdit" row="6" column="2"> + <property name="name"> <cstring>ldapAdminRealm</cstring> </property> </widget> - <spacer row="6" column="1"> + <spacer row="7" column="1"> <property name="name"> <cstring>Spacer6</cstring> </property> diff --git a/src/realmwizard.cpp b/src/realmwizard.cpp index a8c9b81..fa720c2 100644 --- a/src/realmwizard.cpp +++ b/src/realmwizard.cpp @@ -202,7 +202,8 @@ void RealmWizard::accept() { // Try to create realm TQString errorString; // RAJA FIXME - if (m_controller->createNewLDAPRealm(this, m_realmconfig, finishpage->ldapAdminUsername->text(), finishpage->ldapAdminPassword->password(), finishpage->ldapAdminRealm->text(), &errorString) == 0) { + // root account should not be locked to "admin"! + if (m_controller->createNewLDAPRealm(this, m_realmconfig, finishpage->ldapAdminUsername->text(), finishpage->ldapAdminGroupname->text(), finishpage->ldapAdminPassword->password(), "admin", finishpage->ldapAdminPassword->password(), finishpage->ldapAdminRealm->text(), &errorString) == 0) { done(0); } else { diff --git a/src/sha1.cc b/src/sha1.cc new file mode 100644 index 0000000..3f5dbd9 --- /dev/null +++ b/src/sha1.cc @@ -0,0 +1,433 @@ +/* This file is part of the KDE project + Copyright (C) 2001 George Staikos <[email protected]> + Based heavily on SHA1 code from GPG 1.0.3 (C) 1998 FSF + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public License + along with this library; see the file COPYING.LIB. If not, write to + the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + Boston, MA 02110-1301, USA. +*/ + +#include <config.h> + +#ifdef HAVE_SYS_TYPES_H +#include <sys/types.h> +#endif +#ifdef HAVE_STDINT_H +#include <stdint.h> /* For uintXX_t on OSX */ +#endif +#ifdef HAVE_SYS_BITYPES_H +#include <sys/bitypes.h> /* For uintXX_t on Tru64 */ +#endif +#ifdef HAVE_STDINT_H +#include <stdint.h> +#endif + +#include "sha1.h" +#include <string.h> + +// FIXME: this can be optimized to one instruction on most cpus. +#define rol(x,y) ((x << y) | (x >> (32-y))) + + +#define K1 0x5a827999L +#define K2 0x6ed9eba1L +#define K3 0x8f1bbcdcL +#define K4 0xca62c1d6L +#define F1(x,y,z) ( z ^ ( x & ( y ^ z ) ) ) +#define F2(x,y,z) ( x ^ y ^ z ) +#define F3(x,y,z) ( ( x & y ) | ( z & ( x | y ) ) ) +#define F4(x,y,z) ( x ^ y ^ z ) + +#define M(i) ( tm = x[i&0x0f] ^ x[(i-14)&0x0f] \ + ^ x[(i-8)&0x0f] ^ x[(i-3)&0x0f] \ + , (x[i&0x0f] = (tm << 1) | (tm >> 31))) + +#define R(a,b,c,d,e,f,k,m) do { e += rol(a, 5) \ + + f(b, c, d) \ + + k \ + + m; \ + b = rol(b, 30); \ + } while(0) + +const char Base64EncMap[64] = +{ + 0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48, + 0x49, 0x4A, 0x4B, 0x4C, 0x4D, 0x4E, 0x4F, 0x50, + 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, 0x58, + 0x59, 0x5A, 0x61, 0x62, 0x63, 0x64, 0x65, 0x66, + 0x67, 0x68, 0x69, 0x6A, 0x6B, 0x6C, 0x6D, 0x6E, + 0x6F, 0x70, 0x71, 0x72, 0x73, 0x74, 0x75, 0x76, + 0x77, 0x78, 0x79, 0x7A, 0x30, 0x31, 0x32, 0x33, + 0x34, 0x35, 0x36, 0x37, 0x38, 0x39, 0x2B, 0x2F +}; + +void base64Encode( const TQByteArray& in, TQByteArray& out, bool insertLFs ) +{ + // clear out the output buffer + out.resize (0); + if ( in.isEmpty() ) + return; + + unsigned int sidx = 0; + unsigned int didx = 0; + const char* data = in.data(); + const unsigned int len = in.size(); + + unsigned int out_len = ((len+2)/3)*4; + + // Deal with the 76 characters or less per + // line limit specified in RFC 2045 on a + // pre request basis. + insertLFs = (insertLFs && out_len > 76); + if ( insertLFs ) + out_len += ((out_len-1)/76); + + int count = 0; + out.resize( out_len ); + + // 3-byte to 4-byte conversion + 0-63 to ascii printable conversion + if ( len > 1 ) + { + while (sidx < len-2) + { + if ( insertLFs ) + { + if ( count && (count%76) == 0 ) + out[didx++] = '\n'; + count += 4; + } + out[didx++] = Base64EncMap[(data[sidx] >> 2) & 077]; + out[didx++] = Base64EncMap[(data[sidx+1] >> 4) & 017 | + (data[sidx] << 4) & 077]; + out[didx++] = Base64EncMap[(data[sidx+2] >> 6) & 003 | + (data[sidx+1] << 2) & 077]; + out[didx++] = Base64EncMap[data[sidx+2] & 077]; + sidx += 3; + } + } + + if (sidx < len) + { + if ( insertLFs && (count > 0) && (count%76) == 0 ) + out[didx++] = '\n'; + + out[didx++] = Base64EncMap[(data[sidx] >> 2) & 077]; + if (sidx < len-1) + { + out[didx++] = Base64EncMap[(data[sidx+1] >> 4) & 017 | + (data[sidx] << 4) & 077]; + out[didx++] = Base64EncMap[(data[sidx+1] << 2) & 077]; + } + else + { + out[didx++] = Base64EncMap[(data[sidx] << 4) & 077]; + } + } + + // Add padding + while (didx < out.size()) + { + out[didx] = '='; + didx++; + } +} + +SHA1::SHA1() { + _hashlen = 160; + _init = false; + reset(); +} + + +int SHA1::reset() { + _h0 = 0x67452301; + _h1 = 0xefcdab89; + _h2 = 0x98badcfe; + _h3 = 0x10325476; + _h4 = 0xc3d2e1f0; + _nblocks = 0; + _count = 0; + memset(_buf, 0, 56); // clear the buffer + + _init = true; + return 0; +} + + +int SHA1::size() const { + return _hashlen; +} + + +SHA1::~SHA1() { + +} + + +void SHA1::transform(void *data) { + unsigned int a, b, c, d, e, tm; + unsigned int x[16]; + unsigned char *_data = (unsigned char *)data; + + a = _h0; + b = _h1; + c = _h2; + d = _h3; + e = _h4; + +#ifdef WORDS_BIGENDIAN + memcpy(x, _data, 64); +#else + int i; + unsigned char *p2; + for (i = 0, p2 = (unsigned char *)x; + i < 16; i++, p2 += 4) { + p2[3] = *_data++; + p2[2] = *_data++; + p2[1] = *_data++; + p2[0] = *_data++; + } +#endif + + R(a, b, c, d, e, F1, K1, x[ 0]); + R(e, a, b, c, d, F1, K1, x[ 1]); + R(d, e, a, b, c, F1, K1, x[ 2]); + R(c, d, e, a, b, F1, K1, x[ 3]); + R(b, c, d, e, a, F1, K1, x[ 4]); + R(a, b, c, d, e, F1, K1, x[ 5]); + R(e, a, b, c, d, F1, K1, x[ 6]); + R(d, e, a, b, c, F1, K1, x[ 7]); + R(c, d, e, a, b, F1, K1, x[ 8]); + R(b, c, d, e, a, F1, K1, x[ 9]); + R(a, b, c, d, e, F1, K1, x[10]); + R(e, a, b, c, d, F1, K1, x[11]); + R(d, e, a, b, c, F1, K1, x[12]); + R(c, d, e, a, b, F1, K1, x[13]); + R(b, c, d, e, a, F1, K1, x[14]); + R(a, b, c, d, e, F1, K1, x[15]); + R(e, a, b, c, d, F1, K1, M(16)); + R(d, e, a, b, c, F1, K1, M(17)); + R(c, d, e, a, b, F1, K1, M(18)); + R(b, c, d, e, a, F1, K1, M(19)); + R(a, b, c, d, e, F2, K2, M(20)); + R(e, a, b, c, d, F2, K2, M(21)); + R(d, e, a, b, c, F2, K2, M(22)); + R(c, d, e, a, b, F2, K2, M(23)); + R(b, c, d, e, a, F2, K2, M(24)); + R(a, b, c, d, e, F2, K2, M(25)); + R(e, a, b, c, d, F2, K2, M(26)); + R(d, e, a, b, c, F2, K2, M(27)); + R(c, d, e, a, b, F2, K2, M(28)); + R(b, c, d, e, a, F2, K2, M(29)); + R(a, b, c, d, e, F2, K2, M(30)); + R(e, a, b, c, d, F2, K2, M(31)); + R(d, e, a, b, c, F2, K2, M(32)); + R(c, d, e, a, b, F2, K2, M(33)); + R(b, c, d, e, a, F2, K2, M(34)); + R(a, b, c, d, e, F2, K2, M(35)); + R(e, a, b, c, d, F2, K2, M(36)); + R(d, e, a, b, c, F2, K2, M(37)); + R(c, d, e, a, b, F2, K2, M(38)); + R(b, c, d, e, a, F2, K2, M(39)); + R(a, b, c, d, e, F3, K3, M(40)); + R(e, a, b, c, d, F3, K3, M(41)); + R(d, e, a, b, c, F3, K3, M(42)); + R(c, d, e, a, b, F3, K3, M(43)); + R(b, c, d, e, a, F3, K3, M(44)); + R(a, b, c, d, e, F3, K3, M(45)); + R(e, a, b, c, d, F3, K3, M(46)); + R(d, e, a, b, c, F3, K3, M(47)); + R(c, d, e, a, b, F3, K3, M(48)); + R(b, c, d, e, a, F3, K3, M(49)); + R(a, b, c, d, e, F3, K3, M(50)); + R(e, a, b, c, d, F3, K3, M(51)); + R(d, e, a, b, c, F3, K3, M(52)); + R(c, d, e, a, b, F3, K3, M(53)); + R(b, c, d, e, a, F3, K3, M(54)); + R(a, b, c, d, e, F3, K3, M(55)); + R(e, a, b, c, d, F3, K3, M(56)); + R(d, e, a, b, c, F3, K3, M(57)); + R(c, d, e, a, b, F3, K3, M(58)); + R(b, c, d, e, a, F3, K3, M(59)); + R(a, b, c, d, e, F4, K4, M(60)); + R(e, a, b, c, d, F4, K4, M(61)); + R(d, e, a, b, c, F4, K4, M(62)); + R(c, d, e, a, b, F4, K4, M(63)); + R(b, c, d, e, a, F4, K4, M(64)); + R(a, b, c, d, e, F4, K4, M(65)); + R(e, a, b, c, d, F4, K4, M(66)); + R(d, e, a, b, c, F4, K4, M(67)); + R(c, d, e, a, b, F4, K4, M(68)); + R(b, c, d, e, a, F4, K4, M(69)); + R(a, b, c, d, e, F4, K4, M(70)); + R(e, a, b, c, d, F4, K4, M(71)); + R(d, e, a, b, c, F4, K4, M(72)); + R(c, d, e, a, b, F4, K4, M(73)); + R(b, c, d, e, a, F4, K4, M(74)); + R(a, b, c, d, e, F4, K4, M(75)); + R(e, a, b, c, d, F4, K4, M(76)); + R(d, e, a, b, c, F4, K4, M(77)); + R(c, d, e, a, b, F4, K4, M(78)); + R(b, c, d, e, a, F4, K4, M(79)); + + _h0 += a; + _h1 += b; + _h2 += c; + _h3 += d; + _h4 += e; + +} + + +bool SHA1::readyToGo() const { + return _init; +} + + +int SHA1::process(const void *block, int len) { + if (!_init) { + return -1; + } + + unsigned char *_block = (unsigned char *)block; + + int cnt = 0; + // Flush the buffer before proceeding + if (_count == 64) { + transform(_buf); + _count = 0; + _nblocks++; + } + + if (!_block) { + return 0; + } + + if (_count) { + for (; len && _count < 64; len--, cnt++) { + _buf[_count++] = *_block++; + } + process(0, 0); // flush the buffer if necessary + if (!len) { + return cnt; + } + } + + while (len >= 64) { + transform(_block); + _count = 0; + _nblocks++; + len -= 64; + cnt += 64; + _block += 64; + } + + for (; len && _count < 64; len--, cnt++) { + _buf[_count++] = *_block++; + } + + return cnt; +} + + +const unsigned char *SHA1::hash() { + unsigned int t, msb, lsb; + unsigned char *p; + + + if (!_init) { + return (unsigned char *)_buf; + } + + process(0, 0); + + msb = 0; + t = _nblocks; + + if ((lsb = t << 6) < t) { + msb++; + } + + msb += t >> 26; + t = lsb; + + if ((lsb = t + _count) < t) { + msb++; + } + + t = lsb; + + if ((lsb = t << 3) < t) { + msb++; + } + + msb += t >> 29; + + _buf[_count++] = 0x80; + + if (_count < 56) { + while (_count < 56) { + _buf[_count++] = 0; + } + } else { + while (_count < 64) { + _buf[_count++] = 0; + } + process(0, 0); + memset(_buf, 0, 56); + } + + _buf[56] = msb >> 24; + _buf[57] = msb >> 16; + _buf[58] = msb >> 8; + _buf[59] = msb; + _buf[60] = lsb >> 24; + _buf[61] = lsb >> 16; + _buf[62] = lsb >> 8; + _buf[63] = lsb; + + transform(_buf); + + p = _buf; + +#ifdef WORDS_BIGENDIAN +#define X( a ) do { *( uint32_t * )p = _h##a; p += 4; } while ( 0 ) +#else +#define X(a) do { *p++ = _h##a >> 24; *p++ = _h##a >> 16; \ + *p++ = _h##a >> 8; *p++ = _h##a; } while (0) +#endif + + X(0); + X(1); + X(2); + X(3); + X(4); + +#undef X + + _init = false; + + return (unsigned char *)_buf; +} + +TQString SHA1::base64Hash() +{ + const char * output = (const char *)hash(); + TQByteArray binhash(20); + TQByteArray enchash(28); + memcpy(binhash.data(), output, 20); + base64Encode(binhash, enchash, false); + return TQString(enchash); +} + diff --git a/src/sha1.h b/src/sha1.h new file mode 100644 index 0000000..0341827 --- /dev/null +++ b/src/sha1.h @@ -0,0 +1,74 @@ +/* This file is part of the KDE project + Copyright (C) 2001 George Staikos <[email protected]> + Based heavily on SHA1 code from GPG 1.0.3 (C) 1998 FSF + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public License + along with this library; see the file COPYING.LIB. If not, write to + the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + Boston, MA 02110-1301, USA. +*/ + + +#ifndef __sha1__ko__h +#define __sha1__ko__h + +#include <tqstring.h> + +/* @internal + */ +class SHA1 { + public: + SHA1(); + virtual ~SHA1(); + + /* + * The number of bits in the hash generated. + */ + virtual int size() const; + + /* + * True if all settings are good and we are ready to hash. + */ + virtual bool readyToGo() const; + + /* + * Process a block of data for the hash function. + */ + virtual int process(const void *block, int len); + + /* + * Return the digest as a 20 byte array reference. + * Calling this makes readyToGo() == false. + */ + virtual const unsigned char *hash(); + + TQString base64Hash(); + + /* + * Reset the digest so a new one can be calculated. + */ + virtual int reset(); + + protected: + int _hashlen; + bool _init; + + long _h0, _h1, _h2, _h3, _h4; + long _nblocks; + int _count; + unsigned char _buf[64]; + void transform(void *data); +}; + + +#endif @@ -1,4 +1,4 @@ +confskel doc po src -confskel
\ No newline at end of file |