#51213 Issue 51209 - remove legacy tools subpackage
Closed 2 years ago by spichugi. Opened 2 years ago by mreynolds.
mreynolds/389-ds-base issue51209  into  master

file modified
+6 -370
@@ -55,18 +55,6 @@ 

  RUST_DEFINES =

  endif

  

- if ENABLE_PERL

- PERL_ON = 1

- else

- PERL_ON = 0

- endif

- 

- if ENABLE_LEGACY

- LEGACY_ON = 1

- else

- LEGACY_ON = 0

- endif

- 

  if CLANG_ENABLE

  CLANG_ON = 1

  CLANG_LDFLAGS = -latomic
@@ -237,32 +225,7 @@ 

  endif

  

  CLEANFILES =  dberrstrs.h ns-slapd.properties \

- 	ldap/admin/src/scripts/template-dbverify ldap/admin/src/template-initconfig \

- 	ldap/admin/src/scripts/dscreate.map ldap/admin/src/scripts/remove-ds.pl \

- 	ldap/admin/src/scripts/DSCreate.pm ldap/admin/src/scripts/DSMigration.pm \

- 	ldap/admin/src/scripts/DSUpdate.pm ldap/admin/src/scripts/dsupdate.map \

- 	ldap/admin/src/scripts/dsorgentries.map ldap/admin/src/scripts/migrate-ds.pl \

- 	ldap/admin/src/scripts/Migration.pm ldap/admin/src/scripts/SetupDialogs.pm \

- 	ldap/admin/src/scripts/setup-ds.pl ldap/admin/src/scripts/setup-ds.res \

- 	ldap/admin/src/scripts/start-dirsrv ldap/admin/src/scripts/stop-dirsrv \

- 	ldap/admin/src/scripts/restart-dirsrv ldap/admin/src/scripts/Setup.pm \

- 	ldap/admin/src/scripts/status-dirsrv \

- 	ldap/admin/src/scripts/template-bak2db ldap/admin/src/scripts/template-bak2db.pl \

- 	ldap/admin/src/scripts/template-db2bak ldap/admin/src/scripts/template-db2bak.pl \

- 	ldap/admin/src/scripts/template-db2index ldap/admin/src/scripts/template-db2index.pl \

- 	ldap/admin/src/scripts/template-db2ldif ldap/admin/src/scripts/template-db2ldif.pl \

- 	ldap/admin/src/scripts/template-ldif2db ldap/admin/src/scripts/template-ldif2db.pl \

- 	ldap/admin/src/scripts/template-ldif2ldap ldap/admin/src/scripts/template-monitor \

- 	ldap/admin/src/scripts/template-ns-accountstatus.pl ldap/admin/src/scripts/template-ns-activate.pl \

- 	ldap/admin/src/scripts/template-ns-inactivate.pl ldap/admin/src/scripts/template-ns-newpwpolicy.pl \

- 	ldap/admin/src/scripts/template-restart-slapd ldap/admin/src/scripts/template-restoreconfig \

- 	ldap/admin/src/scripts/template-saveconfig ldap/admin/src/scripts/template-start-slapd \

- 	ldap/admin/src/scripts/template-stop-slapd ldap/admin/src/scripts/template-suffix2instance \

- 	ldap/admin/src/scripts/template-upgradedb \

- 	ldap/admin/src/scripts/template-upgradednformat \

- 	ldap/admin/src/scripts/template-usn-tombstone-cleanup.pl \

- 	ldap/admin/src/scripts/template-verify-db.pl \

- 	ldap/admin/src/scripts/template-vlvindex ldap/admin/src/scripts/DSUtil.pm \

+ 	ldap/admin/src/template-initconfig \

  	ldap/ldif/template-baseacis.ldif ldap/ldif/template-bitwise.ldif ldap/ldif/template-country.ldif \

  	ldap/ldif/template-dnaplugin.ldif ldap/ldif/template-domain.ldif ldap/ldif/template-dse.ldif \

  	ldap/ldif/template-dse-minimal.ldif \
@@ -270,24 +233,7 @@ 

  	ldap/ldif/template-ldapi.ldif ldap/ldif/template-locality.ldif ldap/ldif/template-org.ldif \

  	ldap/ldif/template-orgunit.ldif ldap/ldif/template-pampta.ldif ldap/ldif/template-sasl.ldif \

  	ldap/ldif/template-state.ldif ldap/ldif/template-suffix-db.ldif \

- 	ldap/admin/src/scripts/bak2db ldap/admin/src/scripts/db2bak ldap/admin/src/scripts/upgradedb \

- 	ldap/admin/src/scripts/db2index ldap/admin/src/scripts/db2ldif \

- 	ldap/admin/src/scripts/dn2rdn ldap/admin/src/scripts/ldif2db \

- 	ldap/admin/src/scripts/ldif2ldap ldap/admin/src/scripts/monitor \

- 	ldap/admin/src/scripts/restoreconfig ldap/admin/src/scripts/saveconfig  \

- 	ldap/admin/src/scripts/suffix2instance \

- 	ldap/admin/src/scripts/upgradednformat ldap/admin/src/scripts/vlvindex \

- 	ldap/admin/src/scripts/bak2db.pl ldap/admin/src/scripts/db2bak.pl \

- 	ldap/admin/src/scripts/db2index.pl ldap/admin/src/scripts/db2ldif.pl \

- 	ldap/admin/src/scripts/fixup-linkedattrs.pl ldap/admin/src/scripts/fixup-memberof.pl \

- 	ldap/admin/src/scripts/cleanallruv.pl ldap/admin/src/scripts/ldif2db.pl \

- 	ldap/admin/src/scripts/ns-accountstatus.pl ldap/admin/src/scripts/ns-activate.pl \

- 	ldap/admin/src/scripts/ns-inactivate.pl ldap/admin/src/scripts/ns-newpwpolicy.pl \

- 	ldap/admin/src/scripts/schema-reload.pl ldap/admin/src/scripts/syntax-validate.pl \

- 	ldap/admin/src/scripts/usn-tombstone-cleanup.pl ldap/admin/src/scripts/verify-db.pl \

- 	ldap/admin/src/scripts/ds_selinux_port_query ldap/admin/src/scripts/ds_selinux_enabled \

- 	ldap/admin/src/scripts/dbverify ldap/admin/src/scripts/readnsstate \

- 	doxyfile.stamp ldap/admin/src/scripts/dbmon.sh \

+ 	doxyfile.stamp \

  	$(NULL)

  

  if RUST_ENABLE
@@ -303,7 +249,7 @@ 

  endif

  

  dberrstrs.h: Makefile

- 	perl $(srcdir)/ldap/servers/slapd/mkDBErrStrs.pl -i @db_incdir@ -o .

+ 	$(srcdir)/ldap/servers/slapd/mkDBErrStrs.py -i @db_incdir@ -o .

  

  

  #------------------------
@@ -352,14 +298,6 @@ 

  bin_PROGRAMS = dbscan \

  	ldclt \

  	pwdhash

- if ENABLE_LEGACY

- bin_PROGRAMS += \

- 	infadd \

- 	ldif \

- 	migratecred \

- 	mmldif \

- 	rsearch

- endif

  

  # ----------------------------------------------------------------------------------------

  # This odd looking definition is to keep the libraries in ORDER that they are needed. rsds
@@ -578,12 +516,6 @@ 

  	ldap/servers/slapd/tools/ldclt/remote.h \

  	ldap/servers/slapd/tools/ldclt/scalab01.h \

  	ldap/servers/slapd/tools/ldclt/utils.h \

- 	ldap/servers/slapd/tools/rsearch/addthread.h \

- 	ldap/servers/slapd/tools/rsearch/infadd.h \

- 	ldap/servers/slapd/tools/rsearch/nametable.h \

- 	ldap/servers/slapd/tools/rsearch/rsearch.h \

- 	ldap/servers/slapd/tools/rsearch/sdattable.h \

- 	ldap/servers/slapd/tools/rsearch/searchthread.h \

  	ldap/servers/snmp/ldap-agent.h \

  	ldap/systools/pio.h \

  	lib/base/lexer_pvt.h \
@@ -638,11 +570,8 @@ 

  	$(srcdir)/buildnum.py \

  	$(srcdir)/ldap/admin/src/*.in \

  	$(srcdir)/ldap/admin/src/scripts/*.in \

- 	$(srcdir)/ldap/admin/src/scripts/*.ldif \

  	$(srcdir)/ldap/admin/src/scripts/*.py \

- 	$(srcdir)/ldap/admin/src/scripts/*.sh \

  	$(srcdir)/ldap/admin/src/scripts/ds-replcheck \

- 	$(srcdir)/ldap/admin/src/scripts/migrate-ds.res \

  	$(srcdir)/ldap/ldif/*.in \

  	$(srcdir)/ldap/ldif/*.ldif \

  	$(srcdir)/ldap/schema/*.ldif \
@@ -666,10 +595,7 @@ 

  if ENABLE_PERL

  dist_noinst_DATA += \

  	$(srcdir)/ldap/admin/src/*.pl \

- 	$(srcdir)/ldap/admin/src/scripts/*.pl \

- 	$(srcdir)/ldap/admin/src/scripts/*.pm \

- 	$(srcdir)/ldap/servers/slapd/mkDBErrStrs.pl \

- 	$(srcdir)/ldap/servers/slapd/tools/rsearch/scripts/dbgen*

+ 	$(srcdir)/ldap/servers/slapd/mkDBErrStrs.py

  endif

  

  #------------------------
@@ -688,8 +614,7 @@ 

  # with the default schema e.g. there is

  # considerable overlap of 60changelog.ldif and 01common.ldif

  # and 60inetmail.ldif and 50ns-mail.ldif among others

- sampledata_DATA = ldap/admin/src/scripts/DSSharedLib \

- 	$(srcdir)/ldap/ldif/Ace.ldif \

+ sampledata_DATA = $(srcdir)/ldap/ldif/Ace.ldif \

  	$(srcdir)/ldap/ldif/European.ldif \

  	$(srcdir)/ldap/ldif/Eurosuffix.ldif \

  	$(srcdir)/ldap/ldif/Example.ldif \
@@ -710,9 +635,6 @@ 

  	ldap/ldif/template-orgunit.ldif \

  	ldap/ldif/template-baseacis.ldif \

  	ldap/ldif/template-sasl.ldif \

- 	$(srcdir)/ldap/servers/slapd/tools/rsearch/scripts/dbgen-FamilyNames \

- 	$(srcdir)/ldap/servers/slapd/tools/rsearch/scripts/dbgen-GivenNames \

- 	$(srcdir)/ldap/servers/slapd/tools/rsearch/scripts/dbgen-OrgUnits \

  	$(srcdir)/ldap/schema/10rfc2307compat.ldif \

  	$(srcdir)/ldap/schema/10rfc2307bis.ldif \

  	$(srcdir)/ldap/schema/60changelog.ldif \
@@ -790,61 +712,8 @@ 

  endif

  

  sbin_SCRIPTS =

- if ENABLE_PERL

- sbin_SCRIPTS += ldap/admin/src/scripts/setup-ds.pl \

- 	ldap/admin/src/scripts/migrate-ds.pl \

- 	ldap/admin/src/scripts/remove-ds.pl \

- 	ldap/admin/src/scripts/bak2db.pl \

- 	ldap/admin/src/scripts/db2bak.pl \

- 	ldap/admin/src/scripts/db2index.pl \

- 	ldap/admin/src/scripts/db2ldif.pl \

- 	ldap/admin/src/scripts/fixup-linkedattrs.pl \

- 	ldap/admin/src/scripts/fixup-memberof.pl \

- 	ldap/admin/src/scripts/cleanallruv.pl \

- 	ldap/admin/src/scripts/ldif2db.pl \

- 	ldap/admin/src/scripts/ns-accountstatus.pl \

- 	ldap/admin/src/scripts/ns-activate.pl \

- 	ldap/admin/src/scripts/ns-inactivate.pl \

- 	ldap/admin/src/scripts/ns-newpwpolicy.pl \

- 	ldap/admin/src/scripts/schema-reload.pl \

- 	ldap/admin/src/scripts/syntax-validate.pl \

- 	ldap/admin/src/scripts/usn-tombstone-cleanup.pl \

- 	ldap/admin/src/scripts/verify-db.pl

- endif

- if ENABLE_LEGACY

- sbin_SCRIPTS += \

- 	ldap/admin/src/scripts/start-dirsrv \

- 	ldap/admin/src/scripts/stop-dirsrv \

- 	ldap/admin/src/scripts/restart-dirsrv \

- 	ldap/admin/src/scripts/status-dirsrv \

- 	ldap/admin/src/scripts/bak2db \

- 	ldap/admin/src/scripts/db2bak \

- 	ldap/admin/src/scripts/db2index \

- 	ldap/admin/src/scripts/db2ldif \

- 	ldap/admin/src/scripts/dn2rdn \

- 	ldap/admin/src/scripts/ldif2db \

- 	ldap/admin/src/scripts/ldif2ldap \

- 	ldap/admin/src/scripts/monitor \

- 	ldap/admin/src/scripts/restoreconfig \

- 	ldap/admin/src/scripts/saveconfig \

- 	ldap/admin/src/scripts/suffix2instance \

- 	ldap/admin/src/scripts/upgradednformat \

- 	ldap/admin/src/scripts/vlvindex \

- 	ldap/admin/src/scripts/dbverify \

- 	ldap/admin/src/scripts/upgradedb \

- 	ldap/admin/src/scripts/dbmon.sh

- endif

- 

- bin_SCRIPTS = \

- 	ldap/admin/src/scripts/readnsstate

  

- if ENABLE_PERL

- bin_SCRIPTS += ldap/servers/slapd/tools/rsearch/scripts/dbgen.pl \

- 	wrappers/cl-dump \

- 	ldap/admin/src/scripts/cl-dump.pl \

- 	wrappers/repl-monitor \

- 	ldap/admin/src/scripts/repl-monitor.pl

- endif

+ bin_SCRIPTS =

  

  # For scripts that are "as is".

  dist_bin_SCRIPTS = ldap/admin/src/scripts/ds-replcheck \
@@ -852,26 +721,6 @@ 

  

  dist_bin_SCRIPTS += ldap/admin/src/logconv.pl

  

- # SCRIPTS makes them executables - these are perl modules

- # and should not be marked as executable - so use DATA

- if ENABLE_PERL

- perl_DATA = ldap/admin/src/scripts/SetupLog.pm \

- 	ldap/admin/src/scripts/Resource.pm \

- 	ldap/admin/src/scripts/DSUtil.pm \

- 	ldap/admin/src/scripts/Setup.pm \

- 	ldap/admin/src/scripts/SetupDialogs.pm \

- 	ldap/admin/src/scripts/Inf.pm \

- 	ldap/admin/src/scripts/DialogManager.pm \

- 	ldap/admin/src/scripts/Dialog.pm \

- 	ldap/admin/src/scripts/DSDialogs.pm \

- 	ldap/admin/src/scripts/Migration.pm \

- 	ldap/admin/src/scripts/DSMigration.pm \

- 	ldap/admin/src/scripts/FileConn.pm \

- 	ldap/admin/src/scripts/DSCreate.pm \

- 	ldap/admin/src/scripts/DSUpdate.pm \

- 	ldap/admin/src/scripts/DSUpdateDialogs.pm

- endif

- 

  python_DATA = ldap/admin/src/scripts/failedbinds.py \

  	ldap/admin/src/scripts/logregex.py

  
@@ -879,46 +728,6 @@ 

  

  dist_sysctl_DATA = ldap/admin/src/70-dirsrv.conf

  

- if ENABLE_PERL

- property_DATA = ldap/admin/src/scripts/setup-ds.res \

- 	ldap/admin/src/scripts/migrate-ds.res

- 

- task_SCRIPTS = ldap/admin/src/scripts/template-bak2db \

- 	ldap/admin/src/scripts/template-db2bak \

- 	ldap/admin/src/scripts/template-db2index \

- 	ldap/admin/src/scripts/template-db2ldif \

- 	ldap/admin/src/scripts/template-dn2rdn \

- 	ldap/admin/src/scripts/template-ldif2db \

- 	ldap/admin/src/scripts/template-ldif2ldap \

- 	ldap/admin/src/scripts/template-monitor \

- 	ldap/admin/src/scripts/template-restart-slapd \

- 	ldap/admin/src/scripts/template-restoreconfig \

- 	ldap/admin/src/scripts/template-saveconfig \

- 	ldap/admin/src/scripts/template-start-slapd \

- 	ldap/admin/src/scripts/template-stop-slapd \

- 	ldap/admin/src/scripts/template-suffix2instance \

- 	ldap/admin/src/scripts/template-upgradednformat \

- 	ldap/admin/src/scripts/template-vlvindex \

- 	ldap/admin/src/scripts/template-bak2db.pl \

- 	ldap/admin/src/scripts/template-db2bak.pl \

- 	ldap/admin/src/scripts/template-db2index.pl \

- 	ldap/admin/src/scripts/template-db2ldif.pl \

- 	ldap/admin/src/scripts/template-fixup-linkedattrs.pl \

- 	ldap/admin/src/scripts/template-fixup-memberof.pl \

- 	ldap/admin/src/scripts/template-fixup-memberuid.pl \

- 	ldap/admin/src/scripts/template-cleanallruv.pl \

- 	ldap/admin/src/scripts/template-ldif2db.pl \

- 	ldap/admin/src/scripts/template-ns-accountstatus.pl \

- 	ldap/admin/src/scripts/template-ns-activate.pl \

- 	ldap/admin/src/scripts/template-ns-inactivate.pl \

- 	ldap/admin/src/scripts/template-ns-newpwpolicy.pl \

- 	ldap/admin/src/scripts/template-schema-reload.pl \

- 	ldap/admin/src/scripts/template-syntax-validate.pl \

- 	ldap/admin/src/scripts/template-usn-tombstone-cleanup.pl \

- 	ldap/admin/src/scripts/template-verify-db.pl \

- 	ldap/admin/src/scripts/template-dbverify

- endif

- 

  if SYSTEMD

  # yes, that is an @ in the filename . . .

  systemdsystemunit_DATA = wrappers/$(PACKAGE_NAME)@.service \
@@ -943,9 +752,6 @@ 

  endif

  

  inf_DATA = ldap/admin/src/slapd.inf \

- 	ldap/admin/src/scripts/dscreate.map \

- 	ldap/admin/src/scripts/dsupdate.map \

- 	ldap/admin/src/scripts/dsorgentries.map \

  	ldap/admin/src/defaults.inf

  

  mib_DATA = ldap/servers/snmp/redhat-directory.mib
@@ -975,135 +781,12 @@ 

  	man/man1/ldclt.1 \

  	man/man1/logconv.pl.1 \

  	man/man1/pwdhash.1 \

- 	man/man1/readnsstate.1 \

  	man/man5/99user.ldif.5 \

  	man/man8/ns-slapd.8 \

  	man/man5/certmap.conf.5 \

  	man/man5/dirsrv.5 \

  	man/man5/dirsrv.systemd.5 \

  	man/man5/slapd-collations.conf.5

- if ENABLE_LEGACY

- dist_man_MANS += \

- 	man/man1/infadd.1 \

- 	man/man1/ldif.1 \

- 	man/man1/migratecred.1 \

- 	man/man1/mmldif.1 \

- 	man/man1/rsearch.1

- endif

- if ENABLE_PERL

- dist_man_MANS += man/man1/cl-dump.1 \

- 	man/man1/cl-dump.pl.1 \

- 	man/man1/dbgen.pl.1 \

- 	man/man1/repl-monitor.1 \

- 	man/man1/repl-monitor.pl.1 \

- 	man/man8/migrate-ds.pl.8 \

- 	man/man8/restart-dirsrv.8 \

- 	man/man8/setup-ds.pl.8 \

- 	man/man8/start-dirsrv.8 \

- 	man/man8/stop-dirsrv.8 \

- 	man/man8/status-dirsrv.8 \

- 	man/man8/bak2db.8 \

- 	man/man8/bak2db.pl.8 \

- 	man/man8/cleanallruv.pl.8 \

- 	man/man8/dbverify.8 \

- 	man/man8/db2bak.8 \

- 	man/man8/db2bak.pl.8 \

- 	man/man8/db2ldif.8 \

- 	man/man8/db2ldif.pl.8 \

- 	man/man8/db2index.8 \

- 	man/man8/db2index.pl.8 \

- 	man/man8/fixup-linkedattrs.pl.8 \

- 	man/man8/fixup-memberof.pl.8 \

- 	man/man8/ldif2db.8 \

- 	man/man8/ldif2db.pl.8 \

- 	man/man8/dbmon.sh.8 \

- 	man/man8/dn2rdn.8 \

- 	man/man8/ldif2ldap.8 \

- 	man/man8/monitor.8 \

- 	man/man8/ns-accountstatus.pl.8 \

- 	man/man8/ns-newpwpolicy.pl.8 \

- 	man/man8/ns-activate.pl.8 \

- 	man/man8/ns-inactivate.pl.8 \

- 	man/man8/remove-ds.pl.8 \

- 	man/man8/restoreconfig.8 \

- 	man/man8/saveconfig.8 \

- 	man/man8/schema-reload.pl.8 \

- 	man/man8/suffix2instance.8 \

- 	man/man8/syntax-validate.pl.8 \

- 	man/man8/upgradednformat.8 \

- 	man/man8/upgradedb.8 \

- 	man/man8/usn-tombstone-cleanup.pl.8 \

- 	man/man8/vlvindex.8 \

- 	man/man8/verify-db.pl.8 \

- 	man/man5/template-initconfig.5

- endif

- 

- #------------------------

- # updates

- # the first 3 are just the examples provided - since they

- # do not begin with two digits, they will be ignored

- # the remaining items should begin with two digits that

- # correspond to the order in which they should be applied

- # perl files and LDIF files are DATA - not executable

- # processed by the update script

- # shell scripts and other files are SCRIPTS - executable

- #------------------------

- if ENABLE_PERL

- update_DATA = ldap/admin/src/scripts/exampleupdate.pl \

- 	ldap/admin/src/scripts/exampleupdate.ldif \

- 	ldap/admin/src/scripts/10cleanupldapi.pl \

- 	ldap/admin/src/scripts/10delautodnsuffix.pl \

- 	ldap/admin/src/scripts/10fixrundir.pl \

- 	ldap/admin/src/scripts/20betxn.pl \

- 	ldap/admin/src/scripts/50addchainingsaslpwroles.ldif \

- 	ldap/admin/src/scripts/50acctusabilityplugin.ldif \

- 	ldap/admin/src/scripts/50automemberplugin.ldif \

- 	ldap/admin/src/scripts/50memberofindex.ldif \

- 	ldap/admin/src/scripts/50nstombstonecsn.ldif \

- 	ldap/admin/src/scripts/50bitstringsyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50managedentriesplugin.ldif \

- 	ldap/admin/src/scripts/50memberofplugin.ldif \

- 	ldap/admin/src/scripts/50deliverymethodsyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50nameuidsyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50derefplugin.ldif \

- 	ldap/admin/src/scripts/50numericstringsyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50disableurisyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50printablestringsyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50enhancedguidesyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50schemareloadplugin.ldif \

- 	ldap/admin/src/scripts/50entryusnindex.ldif \

- 	ldap/admin/src/scripts/50syntaxvalidplugin.ldif \

- 	ldap/admin/src/scripts/50faxnumbersyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50teletexterminalidsyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50faxsyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50fixNsState.pl \

- 	ldap/admin/src/scripts/50telexnumbersyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50guidesyntaxplugin.ldif \

- 	ldap/admin/src/scripts/50targetuniqueid.ldif \

- 	ldap/admin/src/scripts/60removeLegacyReplication.ldif \

- 	ldap/admin/src/scripts/50linkedattrsplugin.ldif \

- 	ldap/admin/src/scripts/50usnplugin.ldif \

- 	ldap/admin/src/scripts/50smd5pwdstorageplugin.ldif \

- 	ldap/admin/src/scripts/50refintprecedence.ldif \

- 	ldap/admin/src/scripts/50retroclprecedence.ldif \

- 	ldap/admin/src/scripts/50rootdnaccesscontrolplugin.ldif \

- 	ldap/admin/src/scripts/50contentsync.ldif \

- 	ldap/admin/src/scripts/60upgradeschemafiles.pl \

- 	ldap/admin/src/scripts/60upgradeconfigfiles.pl \

- 	ldap/admin/src/scripts/70upgradefromldif.pl \

- 	ldap/admin/src/scripts/80upgradednformat.pl \

- 	ldap/admin/src/scripts/81changelog.pl \

- 	ldap/admin/src/scripts/82targetuniqueidindex.pl \

- 	ldap/admin/src/scripts/90subtreerename.pl \

- 	ldap/admin/src/scripts/91subtreereindex.pl \

- 	ldap/admin/src/scripts/50AES-pbe-plugin.ldif\

- 	ldap/admin/src/scripts/50updateconfig.ldif \

- 	ldap/admin/src/scripts/52updateAESplugin.pl \

- 	ldap/admin/src/scripts/dnaplugindepends.ldif \

- 	ldap/admin/src/scripts/91reindex.pl

- 

- update_SCRIPTS = ldap/admin/src/scripts/exampleupdate.sh

- endif

  

  #////////////////////////////////////////////////////////////////

  #
@@ -2173,16 +1856,6 @@ 

  dbscan_LDADD = $(NSPR_LINK) $(DB_LINK)

  

  #------------------------

- # infadd

- #------------------------

- infadd_SOURCES = ldap/servers/slapd/tools/rsearch/addthread.c \

- 	ldap/servers/slapd/tools/rsearch/infadd.c \

- 	ldap/servers/slapd/tools/rsearch/nametable.c

- 

- infadd_CPPFLAGS = $(AM_CPPFLAGS) $(DSPLUGIN_CPPFLAGS)

- infadd_LDADD = $(NSPR_LINK) $(NSS_LINK) $(LDAPSDK_LINK) $(SASL_LINK) $(LIBSOCKET)

- 

- #------------------------

  # ldap-agent

  #------------------------

  ldap_agent_SOURCES = ldap/servers/snmp/main.c \
@@ -2213,32 +1886,6 @@ 

  ldclt_LDADD = $(NSPR_LINK) $(NSS_LINK) $(LDAPSDK_LINK) $(SASL_LINK) $(LIBNSL) $(LIBSOCKET) $(LIBDL) $(THREADLIB)

  

  #------------------------

- # ldif

- #------------------------

- ldif_SOURCES = ldap/servers/slapd/tools/ldif.c

- 

- ldif_CPPFLAGS = $(AM_CPPFLAGS) $(DSPLUGIN_CPPFLAGS)

- ldif_LDADD = $(NSPR_LINK) $(NSS_LINK) $(LDAPSDK_LINK_NOTHR) $(SASL_LINK)

- 

- #------------------------

- # migratecred

- #------------------------

- migratecred_SOURCES = ldap/servers/slapd/tools/migratecred.c

- 

- migratecred_CPPFLAGS = $(AM_CPPFLAGS) $(DSPLUGIN_CPPFLAGS)

- migratecred_LDADD = libslapd.la libsvrcore.la $(NSPR_LINK) $(NSS_LINK) $(LDAPSDK_LINK) $(SASL_LINK)

- migratecred_DEPENDENCIES = libslapd.la

- 

- #------------------------

- # mmldif

- #------------------------

- mmldif_SOURCES = ldap/servers/slapd/tools/mmldif.c

- 

- mmldif_CPPFLAGS = $(AM_CPPFLAGS) $(DSPLUGIN_CPPFLAGS)

- mmldif_LDADD = libslapd.la libsvrcore.la $(NSPR_LINK) $(NSS_LINK) $(LDAPSDK_LINK_NOTHR) $(SASL_LINK)

- mmldif_DEPENDENCIES = libslapd.la

- 

- #------------------------

  # ns-slapd

  #------------------------

  if enable_ldapi
@@ -2311,17 +1958,6 @@ 

  pwdhash_LDADD = libslapd.la libsvrcore.la $(NSPR_LINK) $(NSS_LINK) $(LDAPSDK_LINK) $(SASL_LINK)

  pwdhash_DEPENDENCIES = libslapd.la

  

- #------------------------

- # rsearch

- #------------------------

- rsearch_SOURCES = ldap/servers/slapd/tools/rsearch/nametable.c \

- 	ldap/servers/slapd/tools/rsearch/rsearch.c \

- 	ldap/servers/slapd/tools/rsearch/sdattable.c \

- 	ldap/servers/slapd/tools/rsearch/searchthread.c

- 

- rsearch_CPPFLAGS = $(AM_CPPFLAGS) $(DSPLUGIN_CPPFLAGS)

- rsearch_LDADD = $(NSPR_LINK) $(NSS_LINK) $(LDAPSDK_LINK) $(SASL_LINK) $(LIBSOCKET)

- 

  #-------------------------

  # CMOCKA TEST PROGRAMS

  #-------------------------

file removed
-1
@@ -1,1 +0,0 @@ 

- Tops artwork by Logan Megginson

file removed
-143
@@ -1,143 +0,0 @@ 

- Nunc Stans

- ==========

- Nunc Stans is an event framework wrapper that provides a thread pool for event

- callback execution.  It provides thread safety to event frameworks by isolating

- and protecting the thread safe parts from the non-thread safe parts, and allows

- multi-threaded applications to use event frameworks that are not thread safe.

- It has been primarily developed using [libevent](http://libevent.org "libevent

- home page") , but has also been tested with [tevent](https://tevent.samba.org

- "tevent home page").   Nunc Stans uses lock free data structures where possible,

- to avoid mutex contention. The ‚Äč[liblfds](http://liblfds.org "Lock Free Data Structure")

- library is used.

- 

- There are two main components: the *event loop thread and queue*, and the

- *worker threads and queues*.  The basic concept is the

- [Thread Pool Pattern](https://en.wikipedia.org/wiki/Thread_pool_pattern "Thread

- Pool Pattern description"), where the primary source of tasks (*job* in nunc

- stans) for the task queue (the *work queue* in nunc stans) is provided by the

- event framework for I/O, timer, and signal events.

- 

- License

- -------

- Nunc Stans is licensed under the GNU General Public License version 3 or later.

- Nunc Stans also provides an exception for the use of OpenSSL.  See the files

- 'COPYING', 'COPYING.openssl', and 'COPYING.liblfds' for more information.

- 

- Event Loop Thread And Queue

- ---------------------------

- 

- The event queue is essentially the "main loop" of the application.  It runs in

- its own thread.  The event queue thread is the only thread that interfaces with

- the event framework - adding events, removing events, and

- issuing the callbacks when the event is triggered.  This guarantees that all

- interactions with the event framework are performed in a thread safe manner.

- When a threaded application wants to be called back because of some event (I/O,

- timer, signal), it posts the event and callback data to the event queue.  All

- interaction with the event queue is thread safe - multiple threads can post

- requests to the event queue at the same time.  The event loop thread dequeues

- all of the event requests from the event queue, creates/removes

- events, then calls the event waiting function of the event framework.  This

- assumes the underlying event framework has a function that allows waiting for a

- single event - something like `event_base_loop()` in libevent, or

- `tevent_loop_wait()` in tevent.

- 

- When the application wants events to be triggered as soon as possible, but the

- event framework is waiting for very long lived events, the event queue has a

- persistent I/O listener called the *event_q_wakeup_pipe*.  When the application

- adds an event, nunc-stans will write to the pipe, which will cause the event

- framework to immediately wake up and add the pending events, then do a thread

- yield to allow the event framework thread to execute.

- 

- When an event is triggered by I/O, timer, or signal, the event callback is

- called.  The callback can either be run in the event loop thread, or can be

- handed off to the *work queue* for execution in a *worker thread*.  The

- application uses the flag *NS_JOB_THREAD* to specify that a job will be

- executed in a worker thread.

- 

- **NOTE:** Jobs executed in the event loop thread don't need locking if they

- don't use resources shared with other threads.  This corresponds to a single

- threaded app where all jobs are run inside the main loop and no locking is

- required.  However, just as in that case, jobs run in the event loop thread

- must be very careful to execute very quickly and not block on I/O or other

- resources.  This can lead to event starvation.

- 

- Worker Threads and Queues

- -------------------------

- 

- When a job is placed on the *work queue*, it will be executed in a *worker

- thread*.  The number of worker threads is specified when nunc stans is

- initialized.  Each worker thread sleeps on a condition variable

- (e.g. `pthread_cond_wait()`).  When a job is placed on the work queue, nunc

- stans will notify the condition variable, waking up one of the worker threads.

- This worker thread will dequeue the job from the work queue and execute it.

- The work queue is thread safe - the event loop thread can enqueue jobs at the

- same time as the worker threads dequeue jobs.  Note that the worker threads

- only execute jobs which have the *NS_JOB_THREAD* flag.  Jobs without this flag

- will be executed in the event loop thread.

- 

- Diagram

- -------

- ![Nunc Stans Diagram](nunc-stans-intro.png "Nunc Stans Diagram")

- 

- Diagram Explanation

- -------------------

- 

- The solid thick lines represent the flow of data, typically an `ns_job_t`

- object.  The small dotted lines represent the flow of the program, or the flow

- of control.  In the case of the signal and notification events, these represent

- the program sending a signal or notification, but not yielding control.  The

- thick dashed lines represent the flow of data and program i.e. a function that

- takes an `ns_job_t` object and is the primary program path.  The *event queue*

- and the *work queue* are thread safe FIFO/queue objects.  The bottom of the

- stack of ellipses is the tail and the top is the head, labeled "head".  The

- shaded box labeled "event framework" is the event framework (e.g. libevent).

- The boxes that are partially in and partially outside of the event framework

- are functions that take nunc stans objects and convert them into the format

- used by the event framework.  Note that the "add/remove event in

- framework" function will pass ownership of the job into the event framework, so

- that the event framework will opaquely own that data in the case of add events.

- The shaded box labeled "event loop callback" is called by the

- event framework for each triggered event.  The event loop callback will either

- execute the job immediately (for non-threaded jobs) or queue the job on the

- work queue for execution by a worker thread (for threaded jobs - the

- `NS_JOB_THREADED` job flag).

- 

- The event loop thread and the worker threads are represented by large boxes.

- Everything in the box happens inside that thread.  The boxes that are partly

- inside and partly outside represent functions (e.g. the functions to

- add/delete an event job) and data structures (the event queue, the

- wakeup fd) that are thread safe or are otherwise protected and can be accessed

- both from within and outside of the thread.  Although the diagram shows only 1

- worker thread, there will usually be more than one, and they all share the same

- work queue, which is thread safe.

- 

- The usual starting point is the application represented by the **APP** icon on

- the left side.  The application will typically create a new event job (e.g. a

- network socket listener).  The job will be handed off to the event queue for

- processing by the event loop thread.  If this is not happening inside the event

- loop thread, the event framework will be notified.  This is necessary because

- the event framework could be waiting for a very long time if there are no I/O

- or signals happening, or if the timer jobs are very long lived.  This will

- wakeup the event framework immediately so that it will loop back around to

- process the events in the event queue.  The event loop will dequeue all of the

- jobs from the event queue and perform the appropriate add/remove job in

- the event framework.  This ensures that only the single event loop thread, not

- multiple threads, will interact with the event framework.  Then the event

- framework will wait for events.  Once an event is triggered, the event

- framework will iterate through all of the triggered events and call the event

- loop callback for each one.  This callback will either execute the job

- immediately or add the job to the work queue for a worker thread.  This will

- also signal the worker threads (e.g. something like `pthread_cond_wait`) to

- notify them that there is a new job for processing.  Once all of the events are

- processed, the event loop goes back to the top to see if there are more events

- to process.  The worker thread signal will typically wake up 1 of the worker

- threads, which will dequeue the job and execute it.

- 

- Note that the job callback is called both with the data (the `ns_job_t` object)

- and the program flow.  This callback is entry point into the application.  It

- is the responsibility of the callback to manage the `ns_job_t` object, either

- by calling `ns_job_done` to dispose of it safely, or by calling `ns_job_rearm` to

- "re-arm" the event.  If the

- job is not a threaded job, it is executed in the event loop thread, and can

- block all other events from being processed, so great care must be taken not to

- perform any long running task or otherwise block the thread.

file removed
-90
@@ -1,90 +0,0 @@ 

- Nunc Stans Job Safety

- =====================

- 

- Nunc Stans 0.2.0 comes with many improvements for job safety. Most consumers of

- this framework will not notice the difference if they are using it "correctly",

- but in other cases, you may find you have error conditions.

- 

- Jobs now flow through a set of states in their lifetime.

- 

- States

- ------

- 

- * WAITING: This represents a job that is idle, and not owned by a worker or event thread. Any thread can alter this job.

- * NEEDS_DELETE: This represents a job that is marked for deletion. It cannot be accessed again!

- * DELETED: This represents a job that is deleted. In theory, you can never access a job in this state.

- * NEEDS_ARM: This is a job that is about to be placed into the event or work queue for arming, but has not yet been queued.

- * ARMED: This is a job that is currently in the event queue or work queue waiting to be executed.

- * RUNNING: This is a job that is in the process of executing it's callback right now.

- 

- Diagram

- -------

- 

- ![Nunc Stans Job States](nunc-stans-job-states.png "Nunc Stans Job States")

- 

- WAITING

- -------

- 

- All jobs start in the WAITING state. At this point, the job can have two transitions. It is sent to ns_job_done, and marked as NEEDS_DELETE, or it can be sent to ns_job_rearm, and marked as NEEDS_ARM. A job that is WAITING can be safely modify with ns_job_set_* and accessed with ns_job_get_* from any thread.

- 

- NEEDS_ARM

- ---------

- 

- Once a job is in the NEEDS_ARM state, it can not be altered by ns_job_set_*. It can be read from with ns_job_get_*. It can be sent to ns_job_done (which moves to NEEDS_DELETE), but generally this is only from within the job callback, with code like the following.

- 

-     callback(ns_job_t *job) {

-         ns_job_rearm(job);

-         ns_job_done(job);

-     }

- 

- 

- NEEDS_ARM in most cases will quickly move to the next state, ARMED

- 

- ARMED

- -----

- 

- In the ARMED state, this means that the job has been sucessfully queued into the event *or* work queue. In the ARMED state, the job can be read from with ns_job_get_*, but it cannot be altered with ns_job_set_*. If a job could be altered while queued, this could cause issues with the intent of what the job should do (set_data, set_cb, set_done_cb) etc.

- 

- A job that is ARMED and queued can NOT be removed from the queue, or stopped from running. This is a point of no return!

- 

- RUNNING

- -------

- 

- In the RUNNING state, the job is in the process of executing the callback that the job contains. While RUNNING, the thread that is executing the callback may call ns_job_done, ns_job_rearm, ns_job_get_* and ns_job_set_* upon the job. Note, that calling both ns_job_done and ns_job_rearm from the callback, as the 'done' is a 'stronger' action we will delete the job even though rearm was also called.

- 

- While RUNNING other threads (ie, not the worker thread executing the callback) may only call ns_job_get_* upon the job. Due to the design of the synchronisation underneath, this will block until the execution of the callback, so for all intents and purposes by the time the external thread is able to call ns_job_get_*, the job will have moved to NEEDS_DELETE, NEEDS_ARM or WAITING.

- 

- NEEDS_DELETE

- ------------

- 

- When you call ns_job_done, this marks the job as NEEDS_DELETE. The deletion actually occurs at "some later point". When a job is set to NEEDS_DELETE, you may *not* call any of the ns_job_get_* and ns_job_set_* functions on the job.

- 

- DELETED

- -------

- 

- This state only exists on the job briefly. This means we are in the process of deleting the job internally. We execute the ns_job_done_cb at this point, so that the user may clean up and free any data as required. Only the ns_job_done_cb thread may access the job at this point.

- 

- 

- Putting it all together

- -----------------------

- 

- This state machine encourages certain types of work flows with jobs. This is because the current states are opaque to the caller, and are enforced inside of nunc-stans. The most obviously side effect of a state machine violation is a ASSERT failure with -DDEBUG, or PR_FAILURE from get()/set(). This encourages certain practices:

- 

- * Only single threads should be accessing jobs. This prevents races and sync issues.

- * Data and variables should exist in a single job. Avoid shared (heap) memory locations!

- * Changing jobs should only happen from within the callback, as you can guarantee a consistent state without needing to spin/block on ns_job_set_*.

- * You may not need mutexes on your data or thread locals, as the job provides the correct cpu synchronisation guarantees. Consider that each job takes a "root" data node, then all other allocated variables are referenced there only by the single thread. You can now dispose of mutexes, as the job will guarantee the synchronisation of this data.

- * Jobs work well if stack variables are used inside the callback functions, rather than heap.

- 

- Some work flows that don't work well here:

- 

- * Having threads alter in-flight jobs. This causes race conditions and inconsistencies.

- * Sharing heap data via pointers in jobs. This means you need a mutex on the data, which causes a serialisation point: Why bother with thread pools if you are just going to serialise on some data points anyway!

- * Modifying jobs and what they handle. Don't do it! Just ns_job_done on the job, and create a new one that matches what you want to do.

- * Map reduce: Nunc-Stans doesn't provide a good way to aggregate data on the return, IE reduce. You may need to provide a queue or some other method to reduce if you were interested in this.

- 

- Examples

- --------

- 

- Inside of the nunc-stans project, the tests/cmocka/stress_test.c code is a good example of a socket server and socket client using nunc-stans that adheres to these principles.

- 

@@ -1,214 +0,0 @@ 

- #!/usr/bin/env perl

- #

- # BEGIN COPYRIGHT BLOCK

- # Copyright (C) 2001 Sun Microsystems, Inc. Used by permission.

- # Copyright (C) 2005 Red Hat, Inc.

- # All rights reserved.

- #

- # License: GPL (version 3 or any later version).

- # See LICENSE for details. 

- # END COPYRIGHT BLOCK

- #

- 

- # makemccvlvindexes

- 

- sub usage_and_exit

- {

-     print "makemccvlvindexes usage\n";

-     print "\n";

-     print "This script analyses an LDAP directory in order to create VLV indices which\n";

-     print "could be configured to improve the performance of one-level searches.\n";

-     print "This is principally to be used to tune the directory browsing feature\n";

-     print "of the Mission Control Console.\n";

-     print "\n";

-     print "An LDAP client can only take advantage of these indices if it is itself\n";

-     print "VLV enabled. See the following specification for full details.\n";

-     print "\n";

-     print "ftp://ftp.ietf.org/internet-drafts/draft-ietf-ldapext-ldapv3-vlv-00.txt\n";

-     print "\n";

-     print "Command Line Arguments\n";

-     print "-?           - help\n";

-     print "-D rootdn    - Provide a root DN.  Default= '$rootdn'\n";

-     print "-w password  - Provide a password for the root DN.\n";

-     print "-h host      - Provide a host name. Default= '$host'\n";

-     print "-p port      - Provide a port. Default= '$port'\n";

-     print "-t threshold - Provide a container subordinate threshold. Default= $threshold\n";

-     print "-f filter    - Provide a search filter. Default= '$vlvfilter'\n";

-     print "-s sort      - Provide a sort specification. Default='$vlvsort'\n";

-     print "-n           - Do the work, but don't create the indices\n";

-     exit;

- }

- 

- # Initialise some things

- $vlvfilter= "(objectclass=*)";

- $vlvsort= "sn givenname cn ou o";

- $rootdn= "cn= Directory Manager";

- $host= "localhost";

- $port= "389";

- $threshold= 1000;

- $really_do_it= "1";

- 

- # Process the command line arguments

- while( $arg = shift)

- {

-     if($arg eq "-?")

-     {

-         usage_and_exit();

-     }

-     elsif($arg eq "-D")

-     {

-         $rootdn= shift @ARGV;

-     }

-     elsif($arg eq "-w")

-     {

-         $rootpw= shift @ARGV;

-     }

-     elsif($arg eq "-h")

-     {

-         $host= shift @ARGV;

-     }

-     elsif($arg eq "-p")

-     {

-         $port= shift @ARGV;

-     }

-     elsif($arg eq "-t")

-     {

-         $threshold= shift @ARGV;

-     }

-     elsif($arg eq "-f")

-     {

-         $vlvfilter= shift @ARGV;

-     }

-     elsif($arg eq "-s")

-     {

-         $vlvsort= shift @ARGV;

-     }

-     elsif($arg eq "-n")

-     {

-         $really_do_it= "0";

-     }

-     else

-     {

-         print "$arg: Unknown command line argument.\n";

-     }

- }

- 

- $ldapsearch= "ldapsearch -h $host -p $port";

- $ldapmodify= "ldapmodify -h $host -p $port -D \"$rootdn\" -w $rootpw";

- 

- if( $vlvfilter eq "" ||

-     $vlvsort eq "" ||

-     $rootdn eq "" ||

-     $host eq "" ||

-     $port eq "" ||

-     $threshold eq "")

- {

-     print "Error: Need command line information..\n";

-     usage_and_exit();

- }

- 

- if( $rootpw eq "" )

- {

-     print "Warning: No root DN password provided.  Won't be able to add VLV Search and Index entries.\n";

- }

- 

- # Tell the user what we're up to.

- print "Searching all naming contexts on '$host:$port' for containers with more than $threshold subordinate entries\n";

- 

- # Read the naming contexts from the root dse

- @namingcontexts= `$ldapsearch -s base -b \"\" \"objectclass=*\" namingcontexts`;

- 

- # Get rid of the first line 'dn:'

- shift @namingcontexts;

- 

- # Foreach naming context...

- foreach $nc (@namingcontexts)

- {

-     # Extract the base from the naming context

-     @base= split ' ', $nc;

-     shift @base;

- 

-     # Find all the containers

-     print "Searching naming context '@base' for containers.\n";

-     @containers= `$ldapsearch -s subtree -b \"@base\" \"numsubordinates=*\" numsubordinates`;

-     chop @containers;

- 

-     # Foreach container

- 

-     while(@containers)

-     {

-         # <dn, count, blank>

-         $dn_line= shift @containers;

-         $count_line= shift @containers;

-         shift @containers;

- 

-         # Extract the count, and check it against the threshold

-         @count_array= split ' ', $count_line;

-         $count= @count_array[1];

-         $dn= substr($dn_line,4);

-         print "Found container '$dn' with $count subordinates. ";

-         if($count > $threshold)

-         {

-             # We've found a container that should be indexed.

-             # Extract the DN and RDN of the container

-             $comma_position= (index $dn, ',');

-             if($comma_position== -1)

-             {

-                 $rdn= $dn

-             }

-             else

-             {

-                 $rdn= substr($dn, 0, $comma_position);

-             }

- 

-             # Tell the user what we're up to.

-             print "Adding VLV Search and Index entries.\n";

- 

-             # Build the vlv search and index entries to be added.

-             $vlvsearch_name= "MCC $rdn";

-             @vlvsearch= ( 

-                         "dn: cn=$vlvsearch_name, cn=config, cn=ldbm\n",

-                         "objectclass: top\n",

-                         "objectclass: vlvSearch\n",

-                         "cn: $vlvsearch_name\n",

-                         "vlvbase: $dn\n",

-                         "vlvfilter: $vlvfilter\n",

-                         "vlvscope: 1\n\n" );

- 

-             $vlvindex_name= "SN $vlvsearch_name";

-             @vlvindex= (

-                         "dn: cn=$vlvindex_name, cn=$vlvsearch_name, cn=config, cn=ldbm\n",

-                         "objectclass: top\n",

-                         "objectclass: vlvIndex\n",

-                         "cn: $vlvindex_name\n",

-                         "vlvsort: $vlvsort\n\n" );

- 

-             @vlvnames = ( @vlvnames, "\"" . $vlvindex_name . "\"");

- 

-             if($really_do_it eq "1")

-             {

-                 open(FD,"| $ldapmodify -a -c");

-                 print FD @vlvsearch;

-                 print FD @vlvindex;

-                 close(FD);

-             }

-         }

-         else

-         {

-             print "Too small.\n";

-         }

-     }

- }

- 

- # Dump a script to actually create the indexes

- if($really_do_it eq "1" && $#vlvnames > 0)

- {

-     print "\n";

-     print "$#vlvnames VLV indices have been declared.  Execute the following commands to build the index files.\n";

-     print "\n";

-     print "<config-dir>\\stop\n";

-     print "slapd db2index -f <config-dir> -V @vlvnames\n";

-     print "<config-dir>\\start\n";

- }

- 

- 

@@ -1,112 +0,0 @@ 

- #!/usr/bin/env perl

- #

- # BEGIN COPYRIGHT BLOCK

- # Copyright (C) 2001 Sun Microsystems, Inc. Used by permission.

- # Copyright (C) 2005 Red Hat, Inc.

- # All rights reserved.

- #

- # License: GPL (version 3 or any later version).

- # See LICENSE for details. 

- # END COPYRIGHT BLOCK

- #

- 

- # makevlvindex

- 

- sub usage_and_exit

- {

-     print "makevlvindex [options]\n";

-     print "\n";

-     print "Options:\n";

-     print "-?              - help\n";

-     print "-D rootdn       - Provide a root DN.  Default= '$rootdn'\n";

-     print "-w password     - Provide a password for the root DN.\n";

-     print "-h host         - Provide a host name. Default= '$host'\n";

-     print "-p port         - Provide a port. Default= '$port'\n";

-     print "-sn search_name - RDN of the vlvSearch parent entry.\n";

-     print "-in index_name  - RDN for the vlvIndex child entry.\n";

-     print "-s sort         - Provide a sort specification. Default='$vlvsort'\n";

-     exit;

- }

- 

- # Initialise some things

- $vlvsearch_name= "";

- $vlvindex_name= "";

- $vlvsort= "sn givenname cn ou o";

- $rootdn= "cn=Directory Manager";

- $host= "localhost";

- $port= "389";

- 

- # Process the command line arguments

- while( $arg = shift)

- {

-     if($arg eq "-?")

-     {

-         usage_and_exit();

-     }

-     elsif($arg eq "-D")

-     {

-         $rootdn= shift @ARGV;

-     }

-     elsif($arg eq "-w")

-     {

-         $rootpw= shift @ARGV;

-     }

-     elsif($arg eq "-h")

-     {

-         $host= shift @ARGV;

-     }

-     elsif($arg eq "-p")

-     {

-         $port= shift @ARGV;

-     }

-     elsif($arg eq "-sn")

-     {

-         $vlvsearch_name= shift @ARGV;

-     }

-     elsif($arg eq "-in")

-     {

-         $vlvindex_name= shift @ARGV;

-     }

-     elsif($arg eq "-s")

-     {

-         $vlvsort= shift @ARGV;

-     }

-     else

-     {

-         print "$arg: Unknown command line argument.\n";

-     }

- }

- 

- $ldapmodify= "ldapmodify -h $host -p $port -D \"$rootdn\" -w $rootpw";

- 

- if( $vlvsearch_name eq "" ||

-     $vlvindex_name eq "" ||

-     $vlvsort eq "" ||

-     $rootdn eq "" ||

-     $host eq "" ||

-     $port eq "")

- {

-     print "Error: Need command line information..\n";

-     usage_and_exit();

- }

- 

- if( $rootpw eq "" )

- {

-     print "Warning: No root DN password provided.  Won't be able to add VLV Search and Index entries.\n";

- }

- 

- # Tell the user what we're up to.

- print "Adding VLV Search entry.\n";

- 

- @vlvindex= (

-             "dn: cn=$vlvindex_name, cn=$vlvsearch_name, cn=config, cn=ldbm\n",

-             "objectclass: top\n",

-             "objectclass: vlvIndex\n",

-             "cn: $vlvindex_name\n",

-             "vlvsort: $vlvsort\n\n" );

- 

- open(FD,"| $ldapmodify -a -c");

- print FD @vlvindex;

- close(FD);

- 

- 

@@ -1,141 +0,0 @@ 

- #!/usr/bin/env perl

- #

- # BEGIN COPYRIGHT BLOCK

- # Copyright (C) 2001 Sun Microsystems, Inc. Used by permission.

- # Copyright (C) 2005 Red Hat, Inc.

- # All rights reserved.

- #

- # License: GPL (version 3 or any later version).

- # See LICENSE for details. 

- # END COPYRIGHT BLOCK

- #

- 

- # makevlvsearch

- 

- sub usage_and_exit

- {

-     print "makevlvsearch [options]\n";

-     print "\n";

-     print "May be used to create just a vlvSearch entry, or to create\n";

-     print "both a vlvSearch and vlvIndex entry.\n";

-     print "\n";

-     print "Options:\n";

-     print "-?              - help\n";

-     print "-D rootdn       - Provide a root DN.  Default= '$rootdn'\n";

-     print "-w password     - Provide a password for the root DN.\n";

-     print "-h host         - Provide a host name. Default= '$host'\n";

-     print "-p port         - Provide a port. Default= '$port'\n";

-     print "-b scope        - Provide a scope. 1 or 2. Default= '$vlvscope'\n";

-     print "-f filter       - Provide a search filter. Default= '$vlvfilter'\n";

-     print "-sn search_name - RDN of the vlvSearch parent entry.\n";

-     print "-in index_name  - RDN for the vlvIndex child entry.\n";

-     print "-s sort         - Provide a sort specification. Default='$vlvsort'\n";

-     exit;

- }

- 

- # Initialise some things

- $vlvsearch_name= "";

- $vlvindex_name= "";

- $vlvscope= "2";

- $vlvfilter= "(objectclass=*)";

- $vlvsort= "";

- $rootdn= "cn=Directory Manager";

- $host= "localhost";

- $port= "389";

- 

- # Process the command line arguments

- while( $arg = shift)

- {

-     if($arg eq "-?")

-     {

-         usage_and_exit();

-     }

-     elsif($arg eq "-D")

-     {

-         $rootdn= shift @ARGV;

-     }

-     elsif($arg eq "-w")

-     {

-         $rootpw= shift @ARGV;

-     }

-     elsif($arg eq "-h")

-     {

-         $host= shift @ARGV;

-     }

-     elsif($arg eq "-p")

-     {

-         $port= shift @ARGV;

-     }

-     elsif($arg eq "-b")

-     {

-         $vlvscope= shift @ARGV;

-     }

-     elsif($arg eq "-f")

-     {

-         $vlvfilter= shift @ARGV;

-     }

-     elsif($arg eq "-s")

-     {

-         $vlvsort= shift @ARGV;

-     }

-     elsif($arg eq "-sn")

-     {

-         $vlvsearch_name= shift @ARGV;

-     }

-     elsif($arg eq "-in")

-     {

-         $vlvindex_name= shift @ARGV;

-     }

-     else

-     {

-         print "$arg: Unknown command line argument.\n";

-     }

- }

- 

- $ldapmodify= "ldapmodify -h $host -p $port -D \"$rootdn\" -w $rootpw";

- 

- if( $vlvfilter eq "" ||

-     $vlvscope eq "" ||

-     $vlvsearch_name eq "" ||

-     $rootdn eq "" ||

-     $host eq "" ||

-     $port eq "")

- {

-     print "Error: Need command line information..\n";

-     usage_and_exit();

- }

- 

- if( $rootpw eq "" )

- {

-     print "Warning: No root DN password provided.  Won't be able to add VLV Search and Index entries.\n";

- }

- 

- # Tell the user what we're up to.

- print "Adding VLV Search and Index entries.\n";

- 

- # Build the vlv search and index entries to be added.

- @vlvsearch= ( 

-             "dn: cn=$vlvsearch_name, cn=config, cn=ldbm\n",

-             "objectclass: top\n",

-             "objectclass: vlvSearch\n",

-             "cn: $vlvsearch_name\n",

-             "vlvbase: $dn\n",

-             "vlvfilter: $vlvfilter\n",

-             "vlvscope: $vlvscope\n\n" );

- 

- @vlvindex= (

-             "dn: cn=$vlvindex_name, cn=$vlvsearch_name, cn=config, cn=ldbm\n",

-             "objectclass: top\n",

-             "objectclass: vlvIndex\n",

-             "cn: $vlvindex_name\n",

-             "vlvsort: $vlvsort\n\n" );

- 

- open(FD,"| $ldapmodify -a -c");

- print FD @vlvsearch;

- if( not($vlvindex_name eq "" || $vlvsort eq ""))

- {

-     print FD @vlvindex;

- }

- close(FD);

- 

- 

@@ -1,23 +0,0 @@ 

- use Mozilla::LDAP::Conn;

- use Mozilla::LDAP::Utils qw(normalizeDN);

- use Mozilla::LDAP::API qw(:constant ldap_url_parse ldap_explode_dn);

- 

- sub runinst {

-     my ($inf, $inst, $dseldif, $conn) = @_;

- 

-     my @errs;

-     my $ldapifile;

- 

-     # see if nsslapd-rundir is defined

-     my $ent = $conn->search("cn=config", "base", "(objectclass=*)");

-     if (!$ent) {

-         return ('error_finding_config_entry', 'cn=config', $conn->getErrorString());

-     }

- 

-     $ldapifile = $ent->getValues('nsslapd-ldapifilepath');

-     if ($ldapifile) {

-         unlink($ldapifile);

-     }

- 

-     return ();

- }

@@ -1,23 +0,0 @@ 

- use Mozilla::LDAP::Conn;

- use Mozilla::LDAP::Utils qw(normalizeDN);

- use Mozilla::LDAP::API qw(:constant ldap_url_parse ldap_explode_dn);

- 

- sub runinst {

-     my ($inf, $inst, $dseldif, $conn) = @_;

- 

-     my @errs;

- 

-     # see if nsslapd-ldapiautodnsuffix is defined

-     my $ent = $conn->search("cn=config", "base", "(objectclass=*)");

-     if (!$ent) {

-         return ('error_finding_config_entry', 'cn=config', $conn->getErrorString());

-     }

- 

-     if ($ent->getValues('nsslapd-ldapiautodnsuffix')) {

-         $ent->remove('nsslapd-ldapiautodnsuffix');

-         $conn->update($ent);

-         # ignore errors - cn=config attr deletion not allowed over ldap

-     }

- 

-     return ();

- }

@@ -1,39 +0,0 @@ 

- use Mozilla::LDAP::Conn;

- use Mozilla::LDAP::Utils qw(normalizeDN);

- use Mozilla::LDAP::API qw(:constant ldap_url_parse ldap_explode_dn);

- 

- sub runinst {

-     my ($inf, $inst, $dseldif, $conn) = @_;

- 

-     my @errs;

-     my $mode;

- 

-     # see if nsslapd-rundir is defined

-     my $ent = $conn->search("cn=config", "base", "(objectclass=*)");

-     if (!$ent) {

-         return ('error_finding_config_entry', 'cn=config', $conn->getErrorString());

-     }

- 

-     if (!$ent->getValues('nsslapd-rundir')) {

-         $ent->setValues('nsslapd-rundir', $inf->{slapd}->{run_dir});

-         # mark as modified so update will use a replace instead of an add

-         $ent->attrModified('nsslapd-rundir');

-         $conn->update($ent);

-         my $rc = $conn->getErrorCode();

-         if ($rc) {

-             return ('error_updating_entry', 'cn=config', $conn->getErrorString());

-         }

-     }

- 

-     # ensure that other doesn't have permissions on rundir

-     $mode = (stat($inf->{slapd}->{run_dir}))[2] or return ('error_chmoding_file', $inf->{slapd}->{run_dir}, $!);

-     # mask off permissions for other

-     $mode &= 07770;

-     $! = 0; # clear errno

-     chmod $mode, $inf->{slapd}->{run_dir};

-     if ($!) {

-         return ('error_chmoding_file', $inf->{slapd}->{run_dir}, $!);

-     }

- 

-     return ();

- }

@@ -1,74 +0,0 @@ 

- use Mozilla::LDAP::Conn;

- use Mozilla::LDAP::Utils qw(normalizeDN);

- use Mozilla::LDAP::API qw(:constant ldap_url_parse ldap_explode_dn);

- 

- sub runinst {

-     my ($inf, $inst, $dseldif, $conn) = @_;

- 

-     my @errs;

-     my $ldapifile;

- 

-     # Turn on nsslapd-pluginbetxn for 

-     #     cn=Multimaster Replication Plugin

-     #     cn=Roles Plugin,cn=plugins,cn=config

-     #     cn=USN,cn=plugins,cn=config

-     #     cn=Retro Changelog Plugin,cn=plugins,cn=config

-     my @objplugins = (

-         "cn=Multimaster Replication Plugin,cn=plugins,cn=config",

-         "cn=Roles Plugin,cn=plugins,cn=config",

-         "cn=USN,cn=plugins,cn=config",

-         "cn=Retro Changelog Plugin,cn=plugins,cn=config"

-     );

-     foreach my $plugin (@objplugins) {

-         my $ent = $conn->search($plugin, "base", "(cn=*)");

-         if (!$ent) {

-             return ('error_finding_config_entry', $plugin, $conn->getErrorString());

-         }

-         $ent->setValues('nsslapd-pluginbetxn', "on");

-         $conn->update($ent);

-     }

- 

-     # Set betxnpreoperation to nsslapd-plugintype for 

-     #     cn=7-bit check,cn=plugins,cn=config

-     #     cn=attribute uniqueness,cn=plugins,cn=config

-     #     cn=Auto Membership Plugin,cn=plugins,cn=config

-     #     cn=Linked Attributes,cn=plugins,cn=config

-     #     cn=Managed Entries,cn=plugins,cn=config

-     #     cn=PAM Pass Through Auth,cn=plugins,cn=config

-     @preplugins = (

-           "cn=7-bit check,cn=plugins,cn=config",

-           "cn=attribute uniqueness,cn=plugins,cn=config",

-           "cn=Auto Membership Plugin,cn=plugins,cn=config",

-           "cn=Linked Attributes,cn=plugins,cn=config",

-           "cn=Managed Entries,cn=plugins,cn=config",

-           "cn=PAM Pass Through Auth,cn=plugins,cn=config"

-     );

-     foreach my $plugin (@preplugins) {

-         my $ent = $conn->search($plugin, "base", "(cn=*)");

-         if (!$ent) {

-             return ('error_finding_config_entry', $plugin, $conn->getErrorString());

-         }

-         $ent->setValues('nsslapd-pluginType', "betxnpreoperation");

-         $conn->update($ent);

-     }

- 

-     # Set betxnpostoperation to nsslapd-plugintype for 

-     #     cn=MemberOf Plugin,cn=plugins,cn=config

-     #     cn=referential integrity postoperation,cn=plugins,cn=config

-     #     cn=State Change Plugin,cn=plugins,cn=config

-     @postplugins = (

-           "cn=MemberOf Plugin,cn=plugins,cn=config",

-           "cn=referential integrity postoperation,cn=plugins,cn=config",

-           "cn=State Change Plugin,cn=plugins,cn=config"

-     );

-     foreach my $plugin (@postplugins) {

-         my $ent = $conn->search($plugin, "base", "(cn=*)");

-         if (!$ent) {

-             return ('error_finding_config_entry', $plugin, $conn->getErrorString());

-         }

-         $ent->setValues('nsslapd-pluginType', "betxnpostoperation");

-         $conn->update($ent);

-     }

- 

-     return ();

- }

@@ -1,16 +0,0 @@ 

- dn: cn=AES,cn=Password Storage Schemes,cn=plugins,cn=config

- objectclass: top

- objectclass: nsSlapdPlugin

- objectclass: extensibleObject

- cn: AES

- nsslapd-pluginpath: libpbe-plugin

- nsslapd-plugininitfunc: aes_init

- nsslapd-plugintype: reverpwdstoragescheme

- nsslapd-pluginenabled: on

- nsslapd-pluginarg0: nsmultiplexorcredentials

- nsslapd-pluginarg1: nsds5ReplicaCredentials

- nsslapd-pluginprecedence: 1

- nsslapd-pluginid: ID

- nsslapd-pluginDescription: DESC

- nsslapd-pluginVersion: PACKAGE_VERSION

- nsslapd-pluginVendor: VENDOR

@@ -1,21 +0,0 @@ 

- dn: cn=Account Usability Plugin,cn=plugins,cn=config

- objectclass: top

- objectclass: nsSlapdPlugin

- objectclass: extensibleObject

- cn: Account Usability Plugin

- nsslapd-pluginpath: libacctusability-plugin

- nsslapd-plugininitfunc: auc_init

- nsslapd-plugintype: preoperation

- nsslapd-pluginenabled: on

- nsslapd-plugin-depends-on-type: database

- # these will be replaced when the server loads the plugin

- nsslapd-pluginId: ID

- nsslapd-pluginVersion: PACKAGE_VERSION

- nsslapd-pluginVendor: VENDOR

- nsslapd-pluginDescription: DESC

- 

- dn: oid=1.3.6.1.4.1.42.2.27.9.5.8,cn=features,cn=config

- objectClass: top

- objectClass: directoryServerFeature

- oid: 1.3.6.1.4.1.42.2.27.9.5.8

- cn: Account Usable Request Control

@@ -1,6 +0,0 @@ 

- dn: cn=config,cn=chaining database,cn=plugins,cn=config

- changetype: modify

- add: nsPossibleChainingComponents

- nsPossibleChainingComponents: cn=password policy,cn=components,cn=config

- nsPossibleChainingComponents: cn=sasl,cn=components,cn=config

- nsPossibleChainingComponents: cn=roles,cn=components,cn=config

@@ -1,15 +0,0 @@ 

- dn: cn=Auto Membership Plugin,cn=plugins,cn=config

- objectclass: top

- objectclass: nsSlapdPlugin

- objectclass: extensibleObject

- cn: Auto Membership Plugin

- nsslapd-pluginpath: libautomember-plugin

- nsslapd-plugininitfunc: automember_init

- nsslapd-plugintype: preoperation

- nsslapd-pluginenabled: on

- nsslapd-plugin-depends-on-type: database

- # these will be replaced when the server loads the plugin

- nsslapd-pluginId: ID

- nsslapd-pluginVersion: PACKAGE_VERSION

- nsslapd-pluginVendor: VENDOR

- nsslapd-pluginDescription: DESC

@@ -1,14 +0,0 @@ 

- dn: cn=Bit String Syntax,cn=plugins,cn=config

- objectclass: top

- objectclass: nsSlapdPlugin

- objectclass: extensibleObject

- cn: Bit String

- nsslapd-pluginpath: libsyntax-plugin

- nsslapd-plugininitfunc: bitstring_init

- nsslapd-plugintype: syntax

- nsslapd-pluginenabled: on

- # these will be replaced when the server loads the plugin

- nsslapd-pluginId: ID

- nsslapd-pluginVersion: PACKAGE_VERSION

- nsslapd-pluginVendor: VENDOR

- nsslapd-pluginDescription: DESC

@@ -1,23 +0,0 @@ 

- dn: cn=Content Synchronization,cn=plugins,cn=config

- objectclass: top

- objectclass: nsSlapdPlugin

- objectclass: extensibleObject

- cn: Content Synchronization

- nsslapd-pluginpath: libcontentsync-plugin

- nsslapd-plugininitfunc: sync_init

- nsslapd-plugintype: object

- nsslapd-pluginenabled: off

- nsslapd-plugin-depends-on-named: Retro Changelog Plugin

- # these will be replaced when the server loads the plugin

- nsslapd-pluginId: ID

- nsslapd-pluginVersion: PACKAGE_VERSION

- nsslapd-pluginVendor: VENDOR

- nsslapd-pluginDescription: DESC

- 

- dn: oid=1.3.6.1.4.1.4203.1.9.1.1,cn=features,cn=config

- objectClass: top

- objectClass: directoryServerFeature

- oid: 1.3.6.1.4.1.4203.1.9.1.1

- cn: Sync Request Control

- aci: (targetattr != "aci")(version 3.0; acl "Sync Request Control"; allow( read

-  , search ) userdn = "ldap:///all";)

@@ -1,14 +0,0 @@ 

- dn: cn=Delivery Method Syntax,cn=plugins,cn=config

- objectclass: top

- objectclass: nsSlapdPlugin

- objectclass: extensibleObject

- cn: Delivery Method Syntax

- nsslapd-pluginpath: libsyntax-plugin

- nsslapd-plugininitfunc: delivery_init

- nsslapd-plugintype: syntax

- nsslapd-pluginenabled: on

- # these will be replaced when the server loads the plugin

- nsslapd-pluginId: ID

- nsslapd-pluginVersion: PACKAGE_VERSION

- nsslapd-pluginVendor: VENDOR

- nsslapd-pluginDescription: DESC

@@ -1,16 +0,0 @@ 

- dn: cn=deref,cn=plugins,cn=config

- objectclass: top

- objectclass: nsSlapdPlugin

- objectclass: extensibleObject

- objectclass: nsContainer

- cn: deref

- nsslapd-pluginpath: libderef-plugin

- nsslapd-plugininitfunc: deref_init

- nsslapd-plugintype: preoperation

- nsslapd-pluginenabled: on

- nsslapd-plugin-depends-on-type: database

- # these will be replaced when the server loads the plugin

- nsslapd-pluginId: ID

- nsslapd-pluginVersion: PACKAGE_VERSION

- nsslapd-pluginVendor: VENDOR

- nsslapd-pluginDescription: DESC

@@ -1,9 +0,0 @@ 

- dn: cn=URI Syntax,cn=plugins,cn=config

- changetype: modify

- replace: nsslapd-pluginenabled

- nsslapd-pluginenabled: off