[linux-cifs-client] Using POSIX filenames.
Jeremy Allison
jra at samba.org
Tue May 10 17:03:33 GMT 2005
Steve,
After getting a good idea from Andrew Bartlett the
best way to do POSIX filenames (including the "evil 6" characters).
We need to return a new capability bit on the server in the
SMB_QUERY_CIFS_UNIX_INFO call.
#define CIFS_UNIX_POSIX_PATHNAMES_CAP 0x10 /* Use POSIX pathnames on the wire. */
Setting this bit will tell the client we offer this capability.
Unfortunately we then need a switch to turn it on. Andrew Bartlett
suggested using a TRANSACT2_SETFSINFO call with the same format
as the SMB_QUERY_CIFS_UNIX_INFO info level - but with the client
setting the UNIX capabilities it wants to turn on in the data
portion of the packet.
So the proceedure for selecting POSIX pathnames would be :
client -> server
QFSINFO - SMB_QUERY_CIFS_UNIX_INFO ->
<- reply with UNIX capabilities.
SETFSINFO - SMB_QUERY_CIFS_UNIX_INFO ->
(selecting UNIX capabilities we will use)
If this call returns success any subsequent pathnames should
be in POSIX format (ie. use "/" instead of "\\" as a separator,
allow any POSIX characters).
Looks good ? I can code this up in the server very
quickly. Let me know about the client.
Cheers,
Jeremy.
More information about the linux-cifs-client
mailing list