Reproducer: # mkdir -p /ts/.recycle # chown -R TEMP\\Administrator /ts # chattr +i /ts/.recycle # smbclient //127.0.0.1/ts -UAdministrator%Passw0rd -c "put /etc/hosts test ; rmdir .recycle ; rename test .recycle/test" putting file /etc/hosts as \test (91.6 kb/s) (average 91.6 kb/s) NT_STATUS_ACCESS_DENIED renaming files \test -> \.recycle\test NT_STATUS_ACCESS_DENIED removing remote directory file \.recycle NT_STATUS_SHARING_VIOLATION renaming files \test -> \.recycle\test
Ralph has a patch which is coming soon :-)
This bug was referenced in samba master: 4da50463e1b75c06d5f8c066e8b4eff48186afb0
Created attachment 17977 [details] Patch for Samba 4.17 and 4.18, cherry-picked from master
Iirc 4.17 will also need a backport.
Created attachment 17978 [details] Patch for Samba 4.17, cherry-picked from master
Reassigning to Jule for inclusion in 4.17 and 4.18.
Comment on attachment 17978 [details] Patch for Samba 4.17, cherry-picked from master Patch for 4.17 is the same as for 4.18.
Pushed to autobuild-v4-{18,17}-test.
This bug was referenced in samba v4-18-test: 96793d42907e28446e093285966d4102b37d08dc
This bug was referenced in samba v4-17-test: cdce89e434e258dcf6d58e8510b2f5bf42841932
Closing out bug report. Thanks!
This bug was referenced in samba v4-18-stable (Release samba-4.18.6): 96793d42907e28446e093285966d4102b37d08dc
This bug was referenced in samba v4-17-stable (Release samba-4.17.11): cdce89e434e258dcf6d58e8510b2f5bf42841932