Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!samsung!ctrsol!lll-winken!arisia!sgi!shinobu!odin!mds!mds From: mds@mds.sgi.com (Mark D. Stadler) Newsgroups: comp.sys.sgi Subject: Re: cron and logins Message-ID: <1636@odin.SGI.COM> Date: 27 Nov 89 23:16:21 GMT References: <8911242042.aa26144@SMOKE.BRL.MIL> Sender: news@odin.SGI.COM Organization: Silicon Graphics, Inc., Mountain View, CA Lines: 19 In article <8911242042.aa26144@SMOKE.BRL.MIL> S090726@UMRVMA.UMR.EDU ("Bob B. Funchess") writes: >I want to set up a system on our 4D/20 where certain users can only login >at certain times, such as non-prime hours. The only way I can think of to >do this is to have cron swap /etc/passwd in and out at these times, and >frankly this frightens me a little :). Does anyone have such a setup? >Will you share your secrets? You can mail me direct at the address below... > > > < Bob S090726@UMRVMA.UMR.EDU Funchess > the last field in the /etc/passwd file is the program to exec upon logging in. usually this is /bin/sh, /bin/ksh etc... you could write your own program that validates users according to the time and kick off the appropriate shell from there. (put your validation program name in the /etc/passwd file with an argument of what to invoke if restrictions don't inhibit anything further) it means you have to write your own validation program, but you can get exactly what you want without hacking too much. -- mds [aka Mark D Stadler mds@sgi.com ...!uunet!sgi!mds (415)335-1327]