dCache / nfs4j

Pure Java NFSv3 and NFSv4.2 implementation
Other
240 stars 76 forks source link

Add HideFilesBeginningInDot/NoHideFilesBeginningInDot export option #138

Open cedricblancher opened 1 month ago

cedricblancher commented 1 month ago

Windows Server 2022 NFSv4 server has an export option called HideFilesBeginningInDot which is enabled by default, and sets the NFSv4 WORD0_HIDDEN attribute to true if the file name starts with a . (DOT).

IMO nfs4j should do the same, so Windows users do not see files by default which are considered HIDDEN by POSIX.

kofemann commented 1 month ago

Hi @cedricblancher. HIDDEN is a file attribute and has nothing to do with the file name. Thus, any GETATTR should do reverse mapping to the file name, which is not always possible. So, I don't see how, based only on a filename, one mimics hidden files.

BTW, POSIX doesn't have a concept of hidden files. It's ls that doesn't show them by default.