login.c, login shell, user-setable login gid

George A. Planansky umb!umb!gplan at husc6.harvard.edu
Fri Jul 14 01:52:43 AEST 1989


Questions on changing user gid's & passwd's

I want to modify login.c, so it will query a user, asking for the user's
desired group number (gid).  We do accounting by charging usage to a
user's gid -- there is a mapping between accounting projects and gid's.  A
modified login would let a user select what project will be billed, at
login time.

Currently we have a newgrp command in users' .login files, which does let
them choose a project.  BUT, it kills much of the functionality of the
.login file.  And it's messy.

QUESTION:  We are running several diskless client 3/60 workstations, off a
3/280 server, using Yellow Pages, Sun OS 4.01.  I don't have OS 4 source.
IF I use my 4.3 bsd login.c, will that work fine with OS 4, or are there
differences from the OS 4 login that will cause problems?

QUESTION:  instead of modifying login, can I ask the /etc/passwd login
shell to do something at login time, like run a script, that will let a
user determine the login gid?  How would I do this?

I would like to let users change their /etc/passwd gid, as they already
can change their shell.  However, use of Yellow Pages means such a change
needs root intervention, to propogate the changed passwd data and update
the Yellow Pages databases.  

QUESTION:  What is a good way to let a user change her/his passwd gid, on
OS4 running Yellow Pages? 

(QUESTION:  Our yppasswd daemon isn't running.  What are the steps I
should follow, to get yppasswd to work.)

Thanks in advance for your help.

George Planansky, Atmosphere Environment Research, Cambridge Mass.
617 547-6207

Please email replies to: gplan at ra.umb.edu



More information about the Comp.sys.sun mailing list