Move tests raw.samba3hide, raw.samba3checkfsp & raw.samba3closeerr from
simpleserver to fileserver. Also need a knownfail for raw.samba3closeerr
which fails in envs that NT ACLs enabled. We will get extra coverage
from ad_dc_smb1 when the same tests are moved there.
Remove the associated entries from skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 13 Dec 2019 13:32:22 +0000 (13:32 +0000)]
s3/selftest: Move rpc.samba3.netlogon & rpc.samba3.sessionkey to nt4_dc_smb1
Move test samba3.rpc.samba3.netlogon & ^samba3.rpc.samba3.sessionkey
to nt4_dc_smb1 as these tests will fail when run against an environment
that doesn't support SMB1 and remove the entries from skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 13 Dec 2019 13:21:13 +0000 (13:21 +0000)]
s3/selftest: Move samba3.rpc.lsa.lookupsids to nt4_dc_smb1
Test samba3.rpc.lsa.lookupsids when run with protocol options specifying
smb1 will of course fail when run against environments the don't support
SMB1 so move such tests to nt4_dc_smb1
Additionally remove those entries from the skip file as porting is
not needed.
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Mon, 16 Dec 2019 12:54:11 +0000 (12:54 +0000)]
s3/selftest: Move samba3.raw.samba3posixtimedlock to nt4_dc_smb1
Test samba3.raw.samba3posixtimedlock will not succeed in test
environments that don't support SMB1 so we move it to nt4_dc_smb1
and remove associated entries from skip_smb1_selftest
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Mon, 16 Dec 2019 12:51:25 +0000 (12:51 +0000)]
s3/selftest: Move samba3.raw.samba3posixtimedlock to ad_dc_smb1
Test samba3.raw.samba3posixtimedlock will not succeed in test
environments that don't support SMB1 so we move it to ad_dc_smb1
and also remove associated entry from skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Mon, 16 Dec 2019 12:48:39 +0000 (12:48 +0000)]
s3/selftest: Prep commit split handling for raw.samba3posixtimedlock
raw.samba3posixtimedlock & smb2.samba3misc share the same logic block
but in a future commit we will need to split these tests into
'_smb1' & non '_smb1' environments
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Tests samba3.raw.samba3checkfsp, samba3.raw.samba3hide &
samba3.raw.samba3closeerr fail in test environments that don't support
SMB1 so move to nt4_dc_smb1. Additionally samba3.raw.samba3closeer was
a known fail in nt4_dc so this also needs to be adjusted for the new
env.
Remove the remaining entries from skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 13 Dec 2019 12:18:03 +0000 (12:18 +0000)]
s3/selftest: Move samba3.raw.notify & samba3.raw.oplock to nt4_dc_smb1
Move samba3.raw.notify & samba3.raw.oplock which fail when used with
test environments that don't support SMB1 to nt4_dc_smb1 and remove
associated entry from skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 3 Apr 2020 13:14:58 +0000 (14:14 +0100)]
s3/selftest: Move samba3.blackbox.smbclient_ntlm.plain to nt4_dc_smb1
samba3.blackbox.smbclient_ntlm.plain will fail in test environment
that doesn't support SMB1 so move to nt4_dc_smb1
This test only fails with options that require it to communicate over
SMB1, there are sibling tests that test against >= SMB2 so also we
remove the skip_smb1_fail entry as this test doen't need porting
(for this env)
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 13 Dec 2019 11:28:06 +0000 (11:28 +0000)]
s3/selftest: Move samba3.blackbox.smbclient_s3.NT1.plain to nt4_dc_smb1
Test samba3.blackbox.smbclient_s3.NT1.plain as its name suggests
requires a test environment that supports SMB1 so we move it to one.
Additionally the entry from the skip_smb1_fail file is removed (for this
env) as not porting is required.
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 13 Dec 2019 10:49:51 +0000 (10:49 +0000)]
s3/selftest: Move samba3.blackbox.smbclient_s3.NT1.crypt to nt4_dc_smb1
now that a specific SMB1 enabled env is available lets move this
test to nt4_dc_smb1 env. Additionally the entry is removed from
skip_smb1_fails as no porting is required
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 13 Dec 2019 10:28:40 +0000 (10:28 +0000)]
s3/selftest: Move samba3.blackbox.smbclient_auth.plain to _smb1_done
samba3.blackbox.smbclient_auth.plain will fail in test environment
that doesn't support SMB1 so move to directly to test env
nt4_dc_smb1_done as it doesn't require porting.
This test only fails with options that require it to communicate over
SMB1, there are sibling tests that test against >= SMB2 so also we
remove the skip_smb1_fail entry as this test doen't need porting
(for this env)
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Tue, 7 Jan 2020 10:32:33 +0000 (10:32 +0000)]
s3/selftest: Move samba3.raw.lock & samba3.base.lock to nt4_dc_smb1
samba3.raw.lock & samba3.raw.lock currently will only work in
environments that negotiate SMB1 so lets move them to new nt4_dc_smb1
and remove those entries form skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Thu, 12 Dec 2019 14:48:54 +0000 (14:48 +0000)]
s4/selftest: Adjust samba4.blackbox.pkinit to use (s3) smbclient
samba4.blackbox.pkinit falls to pass in environments that don't support
SMB2 because of use (s4) smbclient4. Change test to use (s3) smbclient
Additionally a test within the test script test_kinit_trusts_heimdal.sh
explicitly uses smbclient4 which can't negotiate SMB1 in environments
that don't support it. Add knownfail to cater for this & also remove entry
from the skip file
Further reference the smbclient4 specific test is associated with
https://bugzilla.samba.org/show_bug.cgi?id=12554 so maybe we should
keep it for the moment
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Thu, 12 Dec 2019 11:23:54 +0000 (11:23 +0000)]
s4/selftest: Move samba.tests.auth_log_pass_change to ad_dc_smb1
Test samba.tests.auth_log_pass_change will fail when run against
environments that don't support SMB1 so move this test to ad_dc_smb1
and remove entry from skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Thu, 12 Dec 2019 11:22:35 +0000 (11:22 +0000)]
s4/selftest: Move samba.tests.auth_log to ad_dc_smb1
Test samba.tests.auth_log will fail when run against environments that
don't support SMB1 so move this test to ad_dc_smb1 and removing
entry from skip_smb1_fail
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Tue, 7 Jan 2020 10:28:39 +0000 (10:28 +0000)]
s3/selftest: Move samba3.blackbox.smbclient_ntlm.plain NT1 to _smb1_done
samba3.blackbox.smbclient_ntlm.plain NT1 fails in environments that
don't support SMB2 so we need to move it to the appropriate _smb1
test env and since this test doesn't need to be ported we can actually
move it directly to the _smb1_done env to indicate that.
Also remove the samba3.blackbox.smbclient_ntlm.plain NT1(ad_dc)
entry from the skip file because we have moved this to the ad_dc_smb1
*and* this test is already ported to >=SMB2
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Wed, 11 Dec 2019 18:40:23 +0000 (18:40 +0000)]
s3/selftest: Move samba3.raw.session* to ad_dc_smb1
The following tests which fail when used with environments that don't
support SMB1 fail so we move them to ad_dc_smb1 instead and also remove
th entry in skip_smb1_fails
samba3.raw.session ntlm
samba3.raw.session krb5
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Wed, 11 Dec 2019 18:06:47 +0000 (18:06 +0000)]
s3/selftest: Move samba3.rap.basic & samba3.rap.rpc to _smb1 env
Tests:
samba3.rap.basic
samba3.rap.rpc
have been moved to ad_dc_smb1, nt4_dc_smb1
verified by
python3 source3/selftest/tests.py | grep ad_dc_smb1 | grep "^samba3.rap"
these tests have been removed from skip_smb1_fails
Additionally
samba3.rap.basic.netsessiongetinfo was already marked as knownfail
in ad_dc so in ad_dc_smb1 also true
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Wed, 4 Mar 2020 17:35:40 +0000 (17:35 +0000)]
s3/selftest: Move various samba3.base.* tests to _smb1 environment(s)
From list of tests identified as failing with environments that
cannot negotiate SMB2 the following tests have been moved to ad_dc_smb1
& nt4_dc_smb1 (and additionally removed from skip_smb1_fails)
Noel Power [Fri, 6 Dec 2019 17:27:53 +0000 (17:27 +0000)]
s3/selftest: Move samba3.blackbox.net.misc to ad_dc
we have an ad_dc_smb1 env and there is not reason why we need
to use nt4_dc for this test. In a later commit we will move the
NT1 test to the ad_dc_smb1 env.
Addionally we change the existing entry in the skip_smb1_fails
skip file.
Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Wed, 4 Dec 2019 15:27:04 +0000 (15:27 +0000)]
selftest: Create new test env ad_dc_smb1
ad_dc_smb1 is a copy of the ad_dc test environment but
with the difference that it still supports SMB1, this will allow
use to still run SMB1 tests for that env.
Signed-off-by: Noel Power <npower@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Wed, 4 Dec 2019 11:50:48 +0000 (11:50 +0000)]
selftest: Add new test environment fileserver_smb1
fileserver_smb1 is a copy of the fileserver test environment but
with the difference that it still supports SMB1, this will allow
use to still run SMB1 tests.
Signed-off-by: Noel Power <npower@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Fri, 27 Sep 2019 14:24:25 +0000 (15:24 +0100)]
selftest: disable SMB1 from testenv(s) make >=SMB2 the default
Change the values of 'min protocol' set for the various test
environments to be SMB2_02.
Servers will only offer protocols starting with the min specified in the
conf files. We don't change the client value here yet (until SMB1 is
truely gone) as we still want to be able to run SMB1 tests.
Signed-off-by: Noel Power <npower@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
Noel Power [Wed, 27 Nov 2019 08:30:06 +0000 (08:30 +0000)]
selftest: Allow ad_dc_ntvfs negotiate smb1 still
The default for most test envs will be changed in a future
commit(s) to be >= SMB2 then we need to still allow ad_dc_ntvfs to
support SMB1. This will make the number of tests to port easier to
deal with. In addition to test env ad_dc_ntvfs still supporting SMB1
we need to do the same with test other environments that depend on
ad_dc_ntvfs (this will be handled in followup commits).
In addition to the above this change will ensure we don't trigger
failures for ntvfs tests when we switch to default >= SMB2 which will
make the associated skip file (added in a future commit) smaller.
Signed-off-by: Noel Power <npower@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
Ralph Boehme [Fri, 21 Feb 2020 16:44:55 +0000 (17:44 +0100)]
selftest: allow SMB1 in clusteredmember env
This is a relatively new test environment that only uses very few tests
yet. Skip the env name rename dance for this env, but someone has to convert the
tests later on.
Signed-off-by: Ralph Boehme <slow@samba.org> Reviewed-by: Noel Power <npower@samba.org>
Swen Schillig [Mon, 30 Mar 2020 10:54:00 +0000 (12:54 +0200)]
dbwrap: fix possible memleak and false result check.
A cstatus != 0 or a data.dsize != sizeof(uint32_t)
does not guarantee to have no received data referenced by data.dptr.
Therefore, make sure data.dptr is free'd.
Reusing the same data structure as data input and data output parameter
can lead to wrong results, especially when the output parameters value
is used to detect errors. Create the additional local variable outdata
to prevent this issue.
Signed-off-by: Swen Schillig <swen@linux.ibm.com> Reviewed-by: Volker Lendecke <vl@samba.org> Reviewed-by: Martin Schwenke <martin@meltin.net>
Autobuild-User(master): Martin Schwenke <martins@samba.org>
Autobuild-Date(master): Thu Apr 2 11:26:32 UTC 2020 on sn-devel-184