summaryrefslogtreecommitdiffstats
path: root/selftest/selftest.pl
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-04-29 15:54:20 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-04-29 16:38:16 +1000
commit3542bd324ecea130292909fd052f71ab0790b7d3 (patch)
tree00d9034bfe240b7a5268d6f1f66fc0dbd034bad4 /selftest/selftest.pl
parentbc31e9c7d2a030dc0f63322f5c42d2fe22bbf7ff (diff)
downloadsamba-3542bd324ecea130292909fd052f71ab0790b7d3.tar.gz
samba-3542bd324ecea130292909fd052f71ab0790b7d3.tar.xz
samba-3542bd324ecea130292909fd052f71ab0790b7d3.zip
selftest: Restore the s3member environment by avoiding smbcacls
This removes the need for acls on the filesystem for simple domain member tests. ACL tests should be written at some point... Andrew Bartlett Pair-Programmed-With: Andrew Tridgell <tridge@samba.org>
Diffstat (limited to 'selftest/selftest.pl')
-rwxr-xr-xselftest/selftest.pl10
1 files changed, 8 insertions, 2 deletions
diff --git a/selftest/selftest.pl b/selftest/selftest.pl
index 5077a17901..6f8cbe1fe8 100755
--- a/selftest/selftest.pl
+++ b/selftest/selftest.pl
@@ -399,8 +399,14 @@ $prefix =~ s+/$++;
die("using an empty prefix isn't allowed") unless $prefix ne "";
-#Ensure we have the test prefix around
-mkdir($prefix, 0777) unless -d $prefix;
+# Ensure we have the test prefix around.
+#
+# We need restrictive
+# permissions on this as some subdirectories in this tree will have
+# wider permissions (ie 0777) and this would allow other users on the
+# host to subvert the test process.
+mkdir($prefix, 0700) unless -d $prefix;
+chmod 0700, $prefix;
my $prefix_abs = abs_path($prefix);
my $tmpdir_abs = abs_path("$prefix/tmp");