Bug 6620 - Renames of directories can incorrectly return NT_STATUS_ACCESS_DENIED
Summary: Renames of directories can incorrectly return NT_STATUS_ACCESS_DENIED
Alias: None
Product: Samba 3.4
Classification: Unclassified
Component: File services (show other bugs)
Version: 3.4.0
Hardware: Other All
: P3 normal
Target Milestone: ---
Assignee: Karolin Seeger
QA Contact: Samba QA Contact
Depends on:
Reported: 2009-08-07 12:23 UTC by Tim Prouty
Modified: 2009-08-11 09:06 UTC (History)
0 users

See Also:
vl: review+

Torture test to verify the fix (2.98 KB, patch)
2009-08-07 12:24 UTC, Tim Prouty
no flags Details
Fix (1.90 KB, patch)
2009-08-07 12:25 UTC, Tim Prouty
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Prouty 2009-08-07 12:23:08 UTC
3121249243f52dcbf8083f5ff137bd580515efa7 allowed us to correctly
handle renaming directories when a client has files open underneath
it, but it also introduced a bug.  If a client holds open a handle to
the directory, and then tries to rename it, the rename should be
allowed, but in 3.4.x the client will get NT_STATUS_ACCESS_DENIED.  We
have already seen a few instances of SMB clients doing this in the
field, and customers seeing this seemingly random

The attached patches fix the problem against v3-4-test and add a
regression test so it's not broken by any future patches.  The fix is
slightly different in 3.4 than it was for master due to the
smb_filename changes.
Comment 1 Tim Prouty 2009-08-07 12:24:34 UTC
Created attachment 4526 [details]
Torture test to verify the fix
Comment 2 Tim Prouty 2009-08-07 12:25:02 UTC
Created attachment 4527 [details]
Comment 3 Jeremy Allison 2009-08-07 15:45:13 UTC
Looks good to me - Volker, can you review and assign to Karolin for inclusion in 3.4.1 ? Thanks,
Comment 4 Karolin Seeger 2009-08-11 09:06:49 UTC
Pushed, will be included in 3.4.1.
Closing out bug report.