Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!lll-winken!elroy.jpl.nasa.gov!swrinde!mips!dimacs.rutgers.edu!aramis.rutgers.edu!paul.rutgers.edu!njin!princeton!phoenix.Princeton.EDU!subbarao From: subbarao@phoenix.Princeton.EDU (Kartik Subbarao) Newsgroups: comp.unix.admin Subject: Re: Network Logins Message-ID: Date: 28 May 91 18:27:10 GMT References: <1991May28.135719.13805@cs.utk.edu> <1991May28.174505.10471@jato.jpl.nasa.gov> Sender: news@idunno.Princeton.EDU Reply-To: subbarao@phoenix.Princeton.EDU (Kartik Subbarao) Organization: American Chemical Society Lines: 30 In article <1991May28.174505.10471@jato.jpl.nasa.gov> mwette@csi.jpl.nasa.gov (Matt Wette) writes: >Here what I can suggest if you're willing to use rlogin instead of >telnet. You may be able to cook up something from it. > >Say the host machine is mach0 and the remote machine is mach1. In >the /etc/passwd file on mach0 I put in the following entry: > > mach1::9999:999:remoteLogin:/usr/local:/usr/local/etc/rxlogin > >/usr/local has a .hushlogin file so that /etc/motd doesn't get >printed. The file /usr/local/etc/rxlogin is the following: > #!/bin/sh > machine=$USER > echo -n "$machine login: "; read username > exec /usr/ucb/rlogin $machine -l $username What's to stop the user from hitting a ^C or something in the middle of this shellscript? Of course, you could do a trap for every signal, but there's really no need for a kludgey shellscript as a login shell. Just make /usr/ucb/telnet the login shell; You don't need anything more than telling the user to type "open" before the host that he wants to connect to... -Kartik -- internet% whoami subbarao@phoenix.Princeton.EDU -| Internet kartik@silvertone.Princeton.EDU (NeXT mail) SUBBARAO@PUCC.BITNET - Bitnet