works with "restrict all": in principle, this slapd should be started without any listener, if possible...

This commit is contained in:
Pierangelo Masarati 2005-12-15 18:07:15 +00:00
parent d71b24d0fd
commit 41ae4ec095
2 changed files with 15 additions and 4 deletions

View File

@ -31,12 +31,14 @@ argsfile @TESTDIR@/slapd.3.args
#ldapmod#modulepath ../servers/slapd/back-ldap/
#ldapmod#moduleload back_ldap.la
# We don't need any access to this DSA
restrict all
#######################################################################
# consumer proxy database definitions
#######################################################################
database ldap
restrict all
suffix "dc=example,dc=com"
rootdn "cn=Whoever"
uri @URI2@

View File

@ -140,18 +140,27 @@ for i in 0 1 2 3 4 5; do
$LDAPSEARCH -s base -b "$MONITOR" -h $LOCALHOST -p $PORT3 \
'(objectClass=*)' > /dev/null 2>&1
RC=$?
if test $RC = 0 ; then
if test $RC = 0 -o $RC = 53 ; then
break
fi
echo "Waiting 5 seconds for slapd to start..."
sleep 5
done
if test $RC != 0 ; then
case $RC in
0 )
echo "ldapsearch should have failed ($RC)!"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
exit -1
;;
53)
;;
*)
echo "ldapsearch failed ($RC)!"
test $KILLSERVERS != no && kill -HUP $KILLPIDS
exit $RC
fi
;;
esac
echo "Using ldapadd to populate the master directory..."
$LDAPADD -D "$MANAGERDN" -h $LOCALHOST -p $PORT1 -w $PASSWD < \