diff options
author | Andrew Bartlett <abartlet@samba.org> | 2023-05-11 10:38:20 +1200 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2023-05-16 23:29:32 +0000 |
commit | 0252941bb36926c3a235593da4c717bc547104f9 (patch) | |
tree | 8eb187ffe4bdb562468b40c2353720bbdfe6fcab | |
parent | 287405862b734e507dd048ff741e96fb35fadb63 (diff) | |
download | samba-0252941bb36926c3a235593da4c717bc547104f9.tar.gz |
selftest: Allow provision_ad_dc() to take functional_level as an argument
The $$$$$$$ is removed as it does not do what you think it does.
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Joseph Sutton <josephsutton@catalyst.net.nz>
-rwxr-xr-x | selftest/target/Samba4.pm | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index bb060503fdb..8f301cae998 100755 --- a/selftest/target/Samba4.pm +++ b/selftest/target/Samba4.pm @@ -1969,7 +1969,7 @@ sub read_config_h($) return \%ret; } -sub provision_ad_dc($$$$$$$) +sub provision_ad_dc() { my ($self, $prefix, @@ -1978,7 +1978,8 @@ sub provision_ad_dc($$$$$$$) $realm, $force_fips_mode, $smbconf_args, - $extra_provision_options) = @_; + $extra_provision_options, + $functional_level) = @_; my $prefix_abs = abs_path($prefix); @@ -1993,6 +1994,10 @@ sub provision_ad_dc($$$$$$$) my $config_h = {}; + if (!defined($functional_level)) { + $functional_level = "2008"; + } + if (defined($ENV{CONFIG_H})) { $config_h = read_config_h($ENV{CONFIG_H}); } @@ -2142,7 +2147,7 @@ sub provision_ad_dc($$$$$$$) $hostname, $domain, $realm, - "2008", + $functional_level, "locDCpass1", undef, undef, @@ -2714,7 +2719,7 @@ sub setup_rodc sub _setup_ad_dc { - my ($self, $path, $conf_opts, $server, $dom) = @_; + my ($self, $path, $conf_opts, $server, $dom, $functional_level) = @_; # If we didn't build with ADS, pretend this env was never available if (not $self->{target3}->have_ads()) { @@ -2734,7 +2739,8 @@ sub _setup_ad_dc $dom, undef, $conf_opts, - undef); + undef, + $functional_level); unless ($env) { return undef; } |