testprogs: Use the system binaries for KRB5 if we don't build in-tree heimdal.
authorAndreas Schneider <asn@samba.org>
Mon, 12 May 2014 14:56:29 +0000 (16:56 +0200)
committerAndreas Schneider <asn@cryptomilk.org>
Mon, 1 Sep 2014 13:47:33 +0000 (15:47 +0200)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
Reviewed-by: Andrew Bartlet <abartlet@samba.org>
source4/scripting/bin/setup_dns.sh
testprogs/blackbox/test_chgdcpass.sh
testprogs/blackbox/test_export_keytab.sh
testprogs/blackbox/test_kinit.sh
testprogs/blackbox/test_ktpass.sh
testprogs/blackbox/test_passwords.sh
testprogs/blackbox/test_pkinit.sh
testprogs/blackbox/test_samba_upgradedns.sh

index bc2ae96b845ad571d21be8b06947480150a0605c..166a2b84351f9faf4c1246d0b3e491a7865cc5b6 100755 (executable)
@@ -18,10 +18,15 @@ RSUFFIX=$(echo $DOMAIN | sed s/[\.]/,DC=/g)
 
 OBJECTGUID=$(bin/ldbsearch -s base -H "$PRIVATEDIR/sam.ldb" -b "CN=NTDS Settings,CN=$HOSTNAME,CN=Servers,CN=Default-First-Site-Name,CN=Sites,CN=Configuration,DC=$RSUFFIX" objectguid|grep ^objectGUID| cut -d: -f2)
 
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=bin/samba4kinit
+fi
+
 echo "Found objectGUID $OBJECTGUID"
 
 echo "Running kinit for $HOSTNAME\$@$DOMAIN"
-bin/samba4kinit -e arcfour-hmac-md5 -k -t "$PRIVATEDIR/secrets.keytab" $HOSTNAME\$@$DOMAIN || exit 1
+$samba4kinit -e arcfour-hmac-md5 -k -t "$PRIVATEDIR/secrets.keytab" $HOSTNAME\$@$DOMAIN || exit 1
 echo "Adding $HOSTNAME.$DOMAIN"
 scripting/bin/nsupdate-gss --noverify $HOSTNAME $DOMAIN $IP 300 || {
     echo "Failed to add A record"
index d4734ea0286aac9b3ed948ddee9982c6c6d42ab0..35161251716a8900a2e881844ebc5585cfacd670 100755 (executable)
@@ -23,7 +23,12 @@ failed=0
 
 samba4bindir="$BINDIR"
 samba4srcdir="$SRCDIR/source4"
-samba4kinit="$samba4bindir/samba4kinit"
+
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=bin/samba4kinit
+fi
+
 
 machineaccountccache="$samba4srcdir/scripting/bin/machineaccountccache"
 
index a72c54847821cc86dcd6869a34b04f3b7e395d02..736c7af099f63af43b7da0628fb9f9b8634cf42d 100755 (executable)
@@ -20,10 +20,14 @@ shift 6
 failed=0
 
 samba4bindir="$BINDIR"
-samba4kinit="$samba4bindir/samba4kinit"
 samba_tool="$samba4bindir/samba-tool"
 newuser="$samba_tool user create"
 
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=$BINDIR/samba4kinit
+fi
+
 . `dirname $0`/subunit.sh
 
 test_smbclient() {
index adfed78255574e0ab0eda90a78a4110aabda70d2..000303ac71fccab8f9c2b584323dc54e080aaef4 100755 (executable)
@@ -23,10 +23,18 @@ failed=0
 
 samba4bindir="$BINDIR"
 samba4srcdir="$SRCDIR/source4"
-samba4kinit="$samba4bindir/samba4kinit"
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=$BINDIR/samba4kinit
+fi
+
 samba_tool="$samba4bindir/samba-tool"
 rkpty="$samba4bindir/rkpty"
-samba4kpasswd="$samba4bindir/samba4kpasswd"
+samba4kpasswd=kpasswd
+if test -x $BINDIR/samba4kpasswd; then
+       samba4kpasswd=$BINDIR/samba4kpasswd
+fi
+
 enableaccount="$samba_tool user enable"
 machineaccountccache="$samba4srcdir/scripting/bin/machineaccountccache"
 
index f9672facabfe32a9f1b71f3cd5f03e043eb27252..8a43eb31a0a11984e2a2d96b966970ea1dc2cf91 100755 (executable)
@@ -16,7 +16,11 @@ shift 1
 samba_tool="$BINDIR/samba-tool"
 samba4bindir="$BINDIR"
 samba4srcdir="$SRCDIR/source4"
-samba4kinit="$samba4bindir/samba4kinit"
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=$BINDIR/samba4kinit
+fi
+
 CONFIG="--configfile=$PREFIX/dc/etc/smb.conf"
 
 TESTUSER="ktpassUser"
index ab546a63084c426a0ccf0a2f222ef621f823fd98..4810177d127675aabec3726a71ad5dc07be1d572 100755 (executable)
@@ -21,11 +21,19 @@ shift 7
 failed=0
 
 samba4bindir="$BINDIR"
-samba4kinit="$samba4bindir/samba4kinit"
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=$BINDIR/samba4kinit
+fi
+
 samba_tool="$samba4bindir/samba-tool"
 smbpasswd="$samba4bindir/smbpasswd"
 rkpty="$samba4bindir/rkpty"
-samba4kpasswd="$samba4bindir/samba4kpasswd"
+samba4kpasswd=kpasswd
+if test -x $BINDIR/samba4kpasswd; then
+       samba4kpasswd=$BINDIR/samba4kpasswd
+fi
+
 newuser="$samba_tool user create"
 
 . `dirname $0`/subunit.sh
index 8fab26158b436b6fcc3ce80e8e1a31d83df12ecc..78c888bb6c337b8c67e74ae165542a93fc3476ed 100755 (executable)
@@ -23,10 +23,18 @@ failed=0
 
 samba4bindir="$BINDIR"
 samba4srcdir="$SRCDIR/source4"
-samba4kinit="$samba4bindir/samba4kinit"
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=$BINDIR/samba4kinit
+fi
+
 samba_tool="$samba4bindir/samba-tool"
 rkpty="$samba4bindir/rkpty"
-samba4kpasswd="$samba4bindir/samba4kpasswd"
+samba4kpasswd=kpasswd
+if test -x $BINDIR/samba4kpasswd; then
+       samba4passwd=$BINDIR/samba4kpasswd
+fi
+
 enableaccount="$samba_tool user enable"
 machineaccountccache="$samba4srcdir/scripting/bin/machineaccountccache"
 
index a080f735ea4f52a44c05bf4d89bf0ab1db2db281..cd5b833b21b9f56e9be4434ee94d7a786cebcc2a 100755 (executable)
@@ -19,7 +19,11 @@ failed=0
 
 samba4bindir="$BINDIR"
 samba4srcdir="$SRCDIR/source4"
-samba4kinit="$samba4bindir/samba4kinit"
+samba4kinit=kinit
+if test -x $BINDIR/samba4kinit; then
+       samba4kinit=$BINDIR/samba4kinit
+fi
+
 
 . `dirname $0`/subunit.sh