s3:smbd: handle IO_REPARSE_TAG_DFS in SMB_FIND_FILE_FULL_DIRECTORY_INFO
authorStefan Metzmacher <metze@samba.org>
Mon, 9 Oct 2017 10:06:29 +0000 (12:06 +0200)
committerJeremy Allison <jra@samba.org>
Thu, 28 Mar 2019 23:09:34 +0000 (23:09 +0000)
This completes commit 74829fecd7a4e806ee441cd75141bede2eefef1a,
which missed SMB_FIND_FILE_FULL_DIRECTORY_INFO

BUG: https://bugzilla.samba.org/show_bug.cgi?id=10097

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/trans2.c

index dd5973b089bdad19747fb3c1219904dffe22c0d8..017ad068877e1d146975e548238bdf6a7e81bd42 100644 (file)
@@ -2109,12 +2109,14 @@ static NTSTATUS smbd_marshall_dir_entry(TALLOC_CTX *ctx,
                SOFF_T(p,0,allocation_size); p += 8;
                SIVAL(p,0,mode); p += 4;
                q = p; p += 4; /* q is placeholder for name length. */
-               {
+               if (mode & FILE_ATTRIBUTE_REPARSE_POINT) {
+                       SIVAL(p, 0, IO_REPARSE_TAG_DFS);
+               } else {
                        unsigned int ea_size = estimate_ea_size(conn, NULL,
                                                                smb_fname);
                        SIVAL(p,0,ea_size); /* Extended attributes */
-                       p +=4;
                }
+               p +=4;
                status = srvstr_push(base_data, flags2, p,
                                  fname, PTR_DIFF(end_data, p),
                                  STR_TERMINATE_ASCII, &len);