mechanisms for client to determine which username a server uid represents

Steven French sfrench at us.ibm.com
Tue May 10 15:25:11 GMT 2005






One of the obvious mechanisms to work through in the interim that will help
users which have more than a few Samba servers will be providing a method
(probably via an ioctl or /proc pseudofile) to load a table on the client
in order to all the client to override the uid that the server returns on
readdir and lookup

The default assumption when the server, like Samba, supports the Unix
extensions, is that uids on server and client match (and e.g. that winbind
or pam/nss_ldap maintains this consistency for servers and clients in the
domain) - but this is clearly not the case for mounts to servers outside
your domain for which the servers' uids bear no relation to uids of another
domain.

server uid -> client uid mappings to override a particular set of uids,
and/or to provide a default uid for unmapped ids would be very helpful but
will need to allow a different uid mapping on the client by smb session
(default) and even a different one by tree connection (since a server
acting as a fileserver gateway may have the same problem on the server's
client, that the client does).

My main worry in this is that doing it via an ioctl to cifs vfs (although
it would be relatively easy) would provoke the - "I hate ioctl"
comments/flames (I don't much like ioctls either) and that doing it via
/proc would get unwieldy - and that in any case, it might even be better to
do this in a way that was not specific to one client filesystem (cifs) and
could allow for nfs, afs, etc. but protocol differences (the size of the
uid_t equivalent on the network differ in the protocols)


Steve French
Senior Software Engineer
Linux Technology Center - IBM Austin
phone: 512-838-2294
email: sfrench at-sign us dot ibm dot com


More information about the samba-technical mailing list