[S] Change in ...nfs-ganesha[next]: Fix current object during readdir of a directory with junctions.
by Name of user not set (GerritHub)
pradeepthomas(a)gmail.com has uploaded this change for review. ( https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/557590?usp=email )
Change subject: Fix current object during readdir of a directory with junctions.
......................................................................
Fix current object during readdir of a directory with junctions.
When going through junctions under a directory, populate_dirent
tries to traverse it. If the client has requested FS level
attributes like FATTR4_SPACE_AVAIL, this process could get to
child FSAL's get_dynamic_info. If get_dynamic_info of the child
FSAL is called with parent's object handle, it could potentially
crash.
For example, if a readdir is performed under server root ("/"),
then ganesha crashes in VFS:get_dynamic_info when doing the
check obj_hdl->fs->fsal as obj_hdl belongs to PSEUDO FSAL and
there fs pointer is NULL. Note that Linux NFS client does not
ask for FS level attributes during readdir. But there are
proprietary NFSv4 clients that could ask for these to avoid
subsequent GETATTR calls.
Change-Id: I3beb7c7c231af7f9d9e3ee32eeaf945a50388355
Signed-off-by: Pradeep Thomas <pradeepthomas(a)gmail.com>
---
M src/Protocols/NFS/nfs4_op_readdir.c
1 file changed, 18 insertions(+), 0 deletions(-)
git pull ssh://review.gerrithub.io:29418/ffilz/nfs-ganesha refs/changes/90/557590/1
--
To view, visit https://review.gerrithub.io/c/ffilz/nfs-ganesha/+/557590?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.gerrithub.io/settings
Gerrit-Project: ffilz/nfs-ganesha
Gerrit-Branch: next
Gerrit-Change-Id: I3beb7c7c231af7f9d9e3ee32eeaf945a50388355
Gerrit-Change-Number: 557590
Gerrit-PatchSet: 1
Gerrit-Owner: pradeepthomas(a)gmail.com
Gerrit-MessageType: newchange