From: Jeremy Allison Date: Fri, 4 Jun 2021 17:10:55 +0000 (-0700) Subject: s3: smbd: In smbd_dirptr_get_entry() add a call to is_visible_fsp(). X-Git-Tag: tevent-0.11.0~565 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a66b7de76aa11cd16acc83042cb149b495bb5d75;p=thirdparty%2Fsamba.git s3: smbd: In smbd_dirptr_get_entry() add a call to is_visible_fsp(). Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source3/smbd/dir.c b/source3/smbd/dir.c index 9ce4ba19ee9..287e7cbba10 100644 --- a/source3/smbd/dir.c +++ b/source3/smbd/dir.c @@ -982,6 +982,13 @@ bool smbd_dirptr_get_entry(TALLOC_CTX *ctx, continue; } + if (!is_visible_fsp(smb_fname->fsp, false)) { + TALLOC_FREE(smb_fname); + TALLOC_FREE(dname); + TALLOC_FREE(fname); + continue; + } + ok = mode_fn(ctx, private_data, smb_fname, get_dosmode, &mode); if (!ok) { TALLOC_FREE(smb_fname);