mirror of
https://github.com/samba-team/samba.git
synced 2025-02-26 21:57:41 +03:00
s3:tests: Add a subsitution test for %D %u %g
BUG: https://bugzilla.samba.org/show_bug.cgi?id=12699 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
bc39fb07ce
commit
2be02fdd1e
@ -394,16 +394,33 @@ sub setup_admember($$$$)
|
||||
$substitution_path = "$share_dir/D_SAMBADOMAIN/U_alice/G_domain users";
|
||||
push(@dirs, $substitution_path);
|
||||
|
||||
# Using '/' as the winbind separator is a bad idea ...
|
||||
$substitution_path = "$share_dir/D_SAMBADOMAIN/u_SAMBADOMAIN";
|
||||
push(@dirs, $substitution_path);
|
||||
|
||||
$substitution_path = "$share_dir/D_SAMBADOMAIN/u_SAMBADOMAIN/alice";
|
||||
push(@dirs, $substitution_path);
|
||||
|
||||
$substitution_path = "$share_dir/D_SAMBADOMAIN/u_SAMBADOMAIN/alice/g_SAMBADOMAIN";
|
||||
push(@dirs, $substitution_path);
|
||||
|
||||
$substitution_path = "$share_dir/D_SAMBADOMAIN/u_SAMBADOMAIN/alice/g_SAMBADOMAIN/domain users";
|
||||
push(@dirs, $substitution_path);
|
||||
|
||||
my $member_options = "
|
||||
security = ads
|
||||
workgroup = $dcvars->{DOMAIN}
|
||||
realm = $dcvars->{REALM}
|
||||
netbios aliases = foo bar
|
||||
|
||||
[subDUG]
|
||||
[sub_dug]
|
||||
path = $share_dir/D_%D/U_%U/G_%G
|
||||
writeable = yes
|
||||
|
||||
[sub_dug2]
|
||||
path = $share_dir/D_%D/u_%u/g_%g
|
||||
writeable = yes
|
||||
|
||||
";
|
||||
|
||||
my $ret = $self->provision($prefix,
|
||||
|
@ -24,9 +24,14 @@ smbclient="$samba_bindir/smbclient"
|
||||
. $samba_srcdir/testprogs/blackbox/subunit.sh
|
||||
. $samba_srcdir/testprogs/blackbox/common_test_fns.inc
|
||||
|
||||
SMB_UNC="//$SERVER/subDUG"
|
||||
SMB_UNC="//$SERVER/sub_dug"
|
||||
|
||||
test_smbclient "Test login to share with substitution" \
|
||||
test_smbclient "Test login to share with substitution (DUG)" \
|
||||
"ls" "$SMB_UNC" "-U$USERNAME%$PASSWORD" || failed=$(expr $failed + 1)
|
||||
|
||||
SMB_UNC="//$SERVER/sub_dug2"
|
||||
|
||||
test_smbclient "Test login to share with substitution (Dug)" \
|
||||
"ls" "$SMB_UNC" "-U$USERNAME%$PASSWORD" || failed=$(expr $failed + 1)
|
||||
|
||||
exit $failed
|
||||
|
Loading…
x
Reference in New Issue
Block a user