[PATCH] smbd: Fix snapshot query on shares with DFS enabled
uri at samba.org
Tue Aug 16 05:05:55 UTC 2016
On 08/16/2016 02:44 AM, Jeremy Allison wrote:
>> I will try to take a closer look tomorrow, maybe that can be easily
>> handled in the shadowcopy2 module. The backport should probably wait
>> until this is resolved
> We should probably add a smbclient-based torture test
> for both file and directory inside source3/script/tests/test_shadow_copy.sh
> once this gets fixed to make sure we don't regress.
Looking again at the shadow_copy2 test, it's a great step forward vs no
test, but it is lacking in some areas.
The current test list previous versions of a file, which queries
snapshot file information.
a. Not sure it's complete enough - maybe successfully reading the file
will be safer
b. It does not handle directories at all
c. It only runs on SMB1, and with respect to paths, SMB2 may behave
differently. Strangely, the test seems to pass on SMB3 (adding -m SMB3),
although AFAICT smbclient uses SMB1 calls to list snapshots (so it
should have yielded 0 snapshots). I'll have to look into it.
The SMB3 test must, IMHO, access snapshot files using TWrp create
context (I don't mind doing it once I have time and it shouldn't stop
any bugfixes if it's been reasonably verified that they don't break
things, so it's a note to self).
More information about the samba-technical