summaryrefslogtreecommitdiff
path: root/selftest
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2012-12-28 12:36:06 +1100
committerStefan Metzmacher <metze@samba.org>2013-01-10 14:52:52 +0100
commitc9d2ca585e198b1006bbf7f1a3c988c1188b66cb (patch)
tree75094bd1c255ac480771f1afe8655114654b82e3 /selftest
parent5812eb3c1deac51891f01338b4771b1e397dc24d (diff)
downloadsamba-c9d2ca585e198b1006bbf7f1a3c988c1188b66cb.tar.gz
samba-c9d2ca585e198b1006bbf7f1a3c988c1188b66cb.tar.bz2
samba-c9d2ca585e198b1006bbf7f1a3c988c1188b66cb.zip
selftest: Add test for rfc2307 mapping handling
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'selftest')
-rwxr-xr-xselftest/selftest.pl5
-rw-r--r--selftest/target/Samba4.pm8
2 files changed, 11 insertions, 2 deletions
diff --git a/selftest/selftest.pl b/selftest/selftest.pl
index c6eadd74dd..4ac5aeb2a4 100755
--- a/selftest/selftest.pl
+++ b/selftest/selftest.pl
@@ -714,8 +714,11 @@ my @exported_envvars = (
# nss_wrapper
"NSS_WRAPPER_PASSWD",
- "NSS_WRAPPER_GROUP"
+ "NSS_WRAPPER_GROUP",
+ # UID/GID for rfc2307 mapping tests
+ "UID_RFC2307TEST",
+ "GID_RFC2307TEST"
);
$SIG{INT} = $SIG{QUIT} = $SIG{TERM} = sub {
diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm
index ba37504651..a08e550700 100644
--- a/selftest/target/Samba4.pm
+++ b/selftest/target/Samba4.pm
@@ -608,6 +608,8 @@ sub provision_raw_step1($$)
# remove this again, when our smb2 client library
# supports signin on compound related requests
server signing = on
+
+ idmap_ldb:use rfc2307=yes
";
print CONFFILE "
@@ -634,6 +636,7 @@ nobody:x:65534:65533:nobody gecos:$ctx->{prefix_abs}:/bin/false
pdbtest:x:65533:65533:pdbtest gecos:$ctx->{prefix_abs}:/bin/false
";
close(PWD);
+ my $uid_rfc2307test = 65533;
open(GRP, ">$ctx->{nsswrap_group}");
print GRP "
@@ -644,6 +647,7 @@ nobody:x:65533:
nogroup:x:65534:nobody
";
close(GRP);
+ my $gid_rfc2307test = 65532;
my $configuration = "--configfile=$ctx->{smb_conf}";
@@ -686,7 +690,9 @@ nogroup:x:65534:nobody
SAMBA_TEST_LOG => "$ctx->{prefix}/samba_test.log",
SAMBA_TEST_LOG_POS => 0,
NSS_WRAPPER_WINBIND_SO_PATH => Samba::nss_wrapper_winbind_so_path($self),
- LOCAL_PATH => $ctx->{share}
+ LOCAL_PATH => $ctx->{share},
+ UID_RFC2307TEST => $uid_rfc2307test,
+ GID_RFC2307TEST => $gid_rfc2307test
};
return $ret;