Forcing actions at login

David H. Brierley dave at galaxia.Newport.RI.US
Fri Jan 18 12:48:50 AEST 1991


I took a slightly different approach to this problem.  I modified the login
program so that when it got done validating the password and doing whatever
else it wanted, instead of execing the users shell it execed a program that
I had written called 'sh_init'.  The sh_init program then took care of all
of the global stuff that needed to be done including displaying the motd
file, setting a bunch of variables in the environment, and asking the user
what 'charge number' they would be using for this session.  The program
also has hooks for running a machine-specific init file.

Admittedly, this approach requires that you have source to the login program
but there are enough PD login programs floating around that this should not
be a real problem.
-- 
David H. Brierley
Home: dave at galaxia.Newport.RI.US    Work: dhb at quahog.ssd.ray.com
Can I be excused, my brain is full.



More information about the Comp.unix.admin mailing list