diff options
-rwxr-xr-x | source4/script/tests/mktestsetup.sh | 8 | ||||
-rwxr-xr-x | source4/script/tests/selftest.sh | 2 | ||||
-rwxr-xr-x | source4/script/tests/test_functions.sh | 6 |
3 files changed, 11 insertions, 5 deletions
diff --git a/source4/script/tests/mktestsetup.sh b/source4/script/tests/mktestsetup.sh index f107f54ace..9453a2f0cd 100755 --- a/source4/script/tests/mktestsetup.sh +++ b/source4/script/tests/mktestsetup.sh @@ -101,6 +101,8 @@ cat >$CONFFILE<<EOF server max protocol = SMB2 notify:inotify = false +system:anonymous = true + [tmp] path = $TMPDIR read only = no @@ -292,13 +294,15 @@ argsfile $LDAPDIR/slapd.args sasl-realm $DNSNAME access to * by * write +allow update_anon + authz-regexp uid=([^,]*),cn=$DNSNAME,cn=digest-md5,cn=auth - ldap:///$BASEDN??sub?(samAccountName=$1) + ldap:///$BASEDN??sub?(samAccountName=\$1) authz-regexp uid=([^,]*),cn=([^,]*),cn=digest-md5,cn=auth - ldap:///$BASEDN??sub?(samAccountName=$1) + ldap:///$BASEDN??sub?(samAccountName=\$1) include $LDAPDIR/modules.conf diff --git a/source4/script/tests/selftest.sh b/source4/script/tests/selftest.sh index 8c4c41e197..a6b1cb7fc3 100755 --- a/source4/script/tests/selftest.sh +++ b/source4/script/tests/selftest.sh @@ -63,7 +63,7 @@ incdir=`dirname $ARG0` #Start slapd before smbd if [ x"$TEST_LDAP" = x"yes" ]; then - slapd_start + slapd_start || exit 1; echo -n "LDAP PROVISIONING..." $srcdir/bin/smbscript $srcdir/setup/provision $PROVISION_OPTIONS --ldap-backend=$LDAPI || { echo "LDAP PROVISIONING failed: $srcdir/bin/smbscript $srcdir/setup/provision $PROVISION_OPTIONS --ldap-backend=$LDAPI" diff --git a/source4/script/tests/test_functions.sh b/source4/script/tests/test_functions.sh index b66e70935d..6baec4982d 100755 --- a/source4/script/tests/test_functions.sh +++ b/source4/script/tests/test_functions.sh @@ -69,10 +69,12 @@ slapd_start() { OLDPATH=$PATH PATH=/usr/local/sbin:/usr/sbin:/sbin:$PATH export PATH - slapd -f $SLAPD_CONF -h $LDAPI_ESCAPE +# running slapd in the background means it stays in the same process group, so it can be +# killed by timelimit + slapd -d0 -f $SLAPD_CONF -h $LDAPI_ESCAPE & PATH=$OLDPATH export PATH - return 0; + return $?; } testit() { |