This is a subtle one. In smbd_dirptr_get_entry() we now open a pathref fsp on all entries - including "..". If we're at the root of the share we don't want a handle to the directory above it, so we should silently open an fsp on "." for meta-data, but leave the name returned to the client as "..". Have patch, need bugnumber.
Hmmm. Thinking about it, we leak the same meta-data info for 4.14 and below also, we just used pathname functions to do it. So it isn't really worse than what we already do. Still, I'd like to tighten it up for 4.15.
Created attachment 16681 [details] git-am fix for master. In ci as: https://gitlab.com/samba-team/devel/samba/-/pipelines/337396028
I would love a second opinion on whether this is something that needs fixing or not. 4.14 and below are currently doing pathname operations on ".." and returning the stat info and EA info for the ".." directory when a query directory is done on the root of the share (but the name cannot be opened by handle or pathname to actually read the contents of those EA's). So in 4.15 we'll be doing the same thing, just by handle rather than pathname. Is this something that needs fixing ? Or shall I let sleeping dogs lie and close as NOTABUG ? I checked Windows, and it returns a fileid of zero for ".." when listing the root directory, but that's the only thing I can see it hiding explicitly.
Passes ci. Now we need to decide if we need it for 4.15rc2.
Comment on attachment 16681 [details] git-am fix for master. Patch lgtm, pushed.
This bug was referenced in samba master: b004ebb1c62742346b84ecb9d52c783173528fac 2acad27686074029ac83c66b42bb37eea380f449
Created attachment 16709 [details] git-am cherry-pick for 4.15.rc2.
Pushed to autobuild-v4-15-test.
This bug was referenced in samba v4-15-test: 3acccfc764df88bd1400bc8da72b2733ca06cdff 9b8e795df6f61fdf530d3fe85faea8ae2e3c00e9
Closing out bug report. Thanks!
This bug was referenced in samba v4-15-stable: 3acccfc764df88bd1400bc8da72b2733ca06cdff 9b8e795df6f61fdf530d3fe85faea8ae2e3c00e9