Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!purdue!decwrl!labrea!helens!relgyro!mike From: mike@relgyro.stanford.edu (Mike Macgirvin) Newsgroups: comp.protocols.nfs Subject: Re: PCNFS gid Message-ID: <219@helens.Stanford.EDU> Date: 21 Apr 89 16:50:43 GMT References: <462@sequoia.UUCP> <642@ftp.COM> Sender: news@helens.STANFORD.EDU Reply-To: mike@relgyro.UUCP (Mike Macgirvin) Organization: Stanford Relativity Gyro Experiment (GP-B) Lines: 46 In article <642@ftp.COM> jbvb@ftp.COM (James Van Bokkelen) writes: >In article <462@sequoia.UUCP>, teb@sequoia.UUCP (Thomas E. Bernhard) writes: >> How can I set my group id different from what the passwd file returns? >The real solution is to change both the clients and servers so that >something substantial is passed in the "authentication" field. I think >that Sun plans this in the next version of RPC. > I accomplished this task by hacking up the 'r_pcnfsd.c' that came with PC-NFS. Unfortunately, I can't seem to locate it right now, but the skinny on it is: The authentication procedure was altered to accept a username followed by a backslash followed by a group, and then to look up the name (after password checking) in the group database, and return ok if the person had access for that group. On the PC side, it worked like this: NET NAME name\30 mypassword which would log 'name' in with the GID set to 30. The hack included checking for name and group by either number or text, because it turns out that PC-NFS only sends 8 characters for a username. So the following syntaxes would all be correct for name == "mike" == UID 20 : NET NAME MIKE * #login with default group NET NAME 20\20 * #login with group 20 NET NAME MIKE\BIN * #login with group bin NET NAME MIKE\20 * #login with group 20 NET NAME 20\STAFF * #login with group staff NET NAME MIKE\STAFF * #won't work, more than 8 chars All of this is easily accomplished with a little knowledge of the system uid and gid functions. This solved our immediate problem, and didn't require any changes to the PC software, only the authentication daemon, (for which source is supplied). I have been told by very reliable sources that support for multiple groups will be built in to the next version of PC-NFS, so I would avoid doing this, if it can wait another month or two... ------------------------------------------------------------------------ m m k Mike Macgirvin m m m m o k k eee Stanford Relativity Gyro Experiment m m m k k e e Stanford University m m i kk eeeee (415) 725-4117 m m i k k e ARPA: mike@relgyro.stanford.edu (36.64.0.50) m m i k k eeee UUCP: /dev/null This room has been punched out. Now where are all the gazingas?