Age | Commit message (Collapse) | Author | Files | Lines |
|
Rewrote wafsamba using a new dependency handling system, and started
adding the waf test code
|
|
|
|
These tests server behavior when a client compounds both synchronous
and asynchronous requests.
|
|
|
|
|
|
Signed-off-by: Stefan Metzmacher <metze@samba.org>
|
|
|
|
It appears some newer versions of windows return
NT_STATUS_OBJECT_NAME_NOT_FOUND on a createfile when access is denied
rather than NT_STATUS_ACCESS_DENIED. I'm not sure how this translates
to directory enumeration yet, but for now make this a parameter that
can be checked in the various torture tests.
This also gets RAW-ACLS and SMB2-CREATE passing against win7.
|
|
Remove it for now
|
|
- The smblsa calls had to be commented out for now and should be fixed
later, but they aren't crucial to the test.
- The first two tests from RAW-ACLS were already ported to
torture_smb2_setinfo() and test_create_acl(). Modifications were
made similar to the RAW-ACLS changes.
- test_sd_get_set() was ported, but does not pass against XP or Vista;
it is not added to the SMB2-ACLS test suite.
- printf -> torture_comment / torture_warning / torture_result
|
|
- Add a torture_setup_dir() equivalent in SMB2, called smb2_util_setup_dir().
- Add verify_sd() and verify_attrib() helper functions for SMB2.
|
|
|
|
|
|
* test that 2 locks in a single LockAndX are transactional
* test that 1 unlock and 1 lock in a single LockAndX are not
transactional
* test that SMB2 doesn't like mixed lock/unlock in a single
PDU
|
|
in multiple files
|
|
s4 returns NETWORK_NAME_DELETED if you attempt to use an invalid tree connection
for a lock. This test (correctly I think) happens before we validate the file handle.
That implies that when you pass both a closed handle and a invalid tree you
should get NT_STATUS_NETWORK_NAME_DELETED.
|
|
I think the error/success codes returned by windows for these tests
are quite bogus. The ones s4 gives are much more reasonable. The
locking ones returning NT_STATUS_SUCCESS could lead to data loss, as
an application thinks it has a file locked correctly when it fact it
doesn't, so it could do an unsafe modify.
|
|
|
|
RAW-LOCK ported as:
RAW-LOCK-LOCK, RAW-LOCK-LOCKX -> SMB2-LOCK-LOCK
RAW-PIDHIGH -> removed, no longer relevant
RAW-ASYNC -> SMB2-LOCK-ASYNC, SMB2-LOCK-CANCEL, SMB2-LOCK-CANCEL-TDIS, SMB2-LOCK-CANCEL-LOGOFF
RAW-ERRORCODE -> SMB2-LOCK-ERRORCODE
RAW-CHANGETYPE -> removed, no longer relevant
RAW-ZEROBYTELOCKS -> SMB2-LOCK->ZEROBYTELENGTH
RAW-UNLOCK -> SMB2-LOCK-UNLOCK
RAW-MULTIPLE_UNLOCK -> SMB2-LOCK-MULTIPLE-UNLOCK
RAW-STACKING -> SMB2-LOCK-STACKING
BASE-LOCK ported as:
BASE-LOCK-LOCK1 -> SMB2-LOCK-ERRORCODE, timeout is no longer relevant
BASE-LOCK-LOCK2 -> SMB2-LOCK-CONTEND, SMB2-LOCK-LOCK, SMB2-LOCK-CONTEXT
BASE-LOCK-LOCK3 -> SMB2-LOCK-RANGE
BASE-LOCK-LOCK4 -> SMB2-LOCK-OVERLAP
BASE-LOCK-LOCK5 -> SMB2-LOCK-STACKING
BASE-LOCK-LOCK6 -> SMB2-LOCK-CANCEL, change_locktype no longer relevant
BASE-LOCK-LOCK7 -> SMB2-LOCK-RW-SHARED, SMB2-LOCK-RW-EXCLUSIVE
|
|
The lock.in.reserved field has been renamed lock_sequence in the
SMB 2.1 dialect. See MS-SMB 2.2.26.
|
|
|
|
|
|
This is needed in order to mark tests as known failures.
metze
|
|
* Ported all tests from raw/notify.c to smb2/notify.c
* Parameterized the max_buffer_size so it can be set on a
per-target basis.
* Fixed CHECK macros to use torture_result
* Created a SMB2-NOTIFY test suite
|
|
The BRL tests previously based their results off several bugs in the
W2K8 byte range lock code. I've fixed up the tests to pass against
Win7 which has fixed these bugs, and assume that the Win7 behavior
is the default.
I have inverted the test behavior for >63-bit lock requests. The
tests previously expected NT_STATUS_OK as their default in this
case. I've changed that default to expect STATUS_INVALID_LOCK_RANGE.
This may requires some changing of make test to compensate.
I've also removed a few test scenarios from VALID-REQUEST in preparation
of replacing them with separate tests ported from RAW-LOCK.
|
|
This reduces compile time somewhat.
|
|
In some cases we were not doing streams tests on s4 that we should. In
others, we were calling tests that are known to fail on s4. Some of
those are a bit puzzling.
|
|
|
|
|
|
Four tests were ported from raw/open.c
One new tests added LEADING-SLASH, which tests that a server provides
the proper error when a relative path is given to a CREATE PDU
with a leading "/".
|
|
|
|
|
|
|
|
Forgot to "git add" the new file in commit b2bcfaae
|
|
|
|
I've ported all applicable SMB oplock torture tests to SMB2, giving us
a good base for SMB2 oplock testing.
There are several differences between oplocks in SMB and SMB2, mostly
because of differences in W2K3 and W2K8. The existing SMB oplock
tests all pass against W2K3, but several fail against W2K8. These
same tests were failing in SMB2, util I reworked them.
BATCH19, BATCH20: In W2K3/SMB a setfileinfo - rename command wouldn't
cause a sharing violation or break an existing oplock. It appears that
in W2K8/SMB2 a sharing violation is raised.
BATCH22: In W2K3/SMB when a second opener was waiting the full timeout
of an oplock break, it would receive NT_STATUS_SHARING_VIOLATION after
about 35 seconds. This bug has been fixed in W2K8/SMB2 and instead
the second opener succeeds.
LEVELII500: Added 1 new test checking that the server returns a proper
error code when a client improperly replies to a levelII to none break
notification.
STREAM1: W2K8 now grants oplocks on alternate data streams.
|
|
This test has been wholly replaced by the SMB2-DIR-ONE test found
in dir.c.
|
|
* removed all uses of printf, replaced with torture_comment
* replaced custom CHECK macros with new torture_assert_*_todo() helpers
* switched string dir name generation to generate_unique_strs() helper,
to avoid non-deterministic test behavior where generate_rand_str()
would cause file colissions in the same directory.
|
|
|
|
Without this the subunit formated output would be invalid and make test
reports: "UNEXPECTED(error): samba4.smb2.dir (dc).FILE-INDEX"
metze
|
|
metze
|
|
This is needed to get reproducable results...
metze
|
|
metze
|
|
* Most of the tests were ported from SMB torture tests.
* Added one new tests which checks the behavior of the file_index field
present in SMB2_FIND struct.
* Added one new test to check the enumeration of directories containing
lots of files (~2000 files) with name lengths varying from 1 to 200 char.
|
|
metze
|
|
TODO: check why the INVALID1 tests fails with --signing=required.
metze
|
|
metze
|
|
--option=torture:smb2maxwrite=12345
metze
|
|
metze
|
|
|