Automatic login script execution

Blair P. Houghton bph at buengc.BU.EDU
Thu Apr 12 06:59:25 AEST 1990


In article <262284c4.2013 at petunia.CalPoly.EDU> apippin at polyslo.CalPoly.EDU (Pinhead at Spikes) writes:
>
>Add then schriste at uceng.UC.EDU (Steven V. Christensen) babbles...
>~Can anyone point me to a login.c replacement which causes a global
>~.login file to be executed first? I assume I would place a "source ~/.login"
>~as the last line of this global file.
>
>	Put a file ~/.login with owner root and mode 644.  The last
>	line should source ~/.userlogin, if it exists.

Then the user does

    rm .login

and unless root owns his home directory, it's gone.

You'd have to have root own his home directory.  You could
create a subdirectory owned by the user for the user's
files.  Then you could maybe write a setuid-root C program
that allows the user to write files into the root-owned home
directory, but not overwriting the .login file.

				--Blair
				  "Or you could give them the
				   root password..."



More information about the Comp.unix.wizards mailing list