User login time

Boris Burtin 6600bori at ucsbuxa.ucsb.edu
Tue Feb 5 13:00:37 AEST 1991


I have been assigned by my company the task of writing a C program on a Sun  
Sparcstation 1+ that will keep a user log.  The general idea is that it 
determines when they logged on and off, and writes the information to a file.
The problem is this: I would like to determine both the login and logout times
in one program (executed from .logout).  Is there a library function that
returns the time that the user logged into the machine?  Or does that have to
be done at the time that it happens (from .login)?

	- Boris Burtin
	(6600bori at ucsbuxa.ucsb.edu)



More information about the Comp.unix.programmer mailing list