[cifs-protocol] Re: [linux-cifs-client] POSIX pathnames and the
jra at samba.org
Mon Mar 12 21:42:18 GMT 2007
On Mon, Mar 12, 2007 at 05:35:39PM -0400, Wagner, Chris (GE Infra, Non-GE, US) wrote:
> Which brings us back to my suggestion of requiring backslashes only and any client in POSIX mode just has to deal with it, flip the slashes. Embedded backslash literals then have to be escaped. I think the debate is down to which mode is more important to adhere to? Try to get everything POSIX at all costs or make DFS happy at all costs or make whatever, samba etc, happy at all costs. I don't think using front slashes is that important to POSIX-ness. Since we're already going out on the network in a strange protocol we're already sort of leaving the POSIX world and we shouldn't be under any obligation to propagate POSIX-ness off the box.
I've actually implemented the pathname parser
for DFS in POSIX mode so that it works out
what the pathname looks like by looking at
the initial separators.
A DFS path looks like :
So I now look at <sepchar> and if it's '/'
and the client negotiated POSIX pathnames
then I treat the "path" component as
For returning referrals I still return
as we have no knowledge of the target
server's ability to use the POSIX extensions.
This has been checked into 3.0.25 and SAMBA_3_0
svn so please feel free to test things.
All POSIX paths should now be able to cope
with embedded '\\' characters in pathnames.
More information about the cifs-protocol