First of all what shell are your users running? If they are not running
bash/ash/zsh /etc/profile doesn't get read at login. Tcsh and csh read
/etc/csh.login and /etc/csh.cshrc at login. The proper way to do it is to
turn off telnet in your /etc/inetd.conf (or equivalant). Just comment out
the telnet line in inetd.conf, then 'kill -HUP <inetd pid>'. That should
take care of all remote logins.
On Sun, 1 Nov 1998, Vikrant Potnis wrote:
> Hi all,
> I put the following shell script in /etc/profile.
> for i in `ps | grep telnet | cut -d " " -f 1`
> do
> kill -9 $i
> done
>
> When i telnet and login as root the process is killed...
> When i login as user , the process does not get killed
> Why??? Is there any other way of stopping root from remote login?
> Vikrant
>
>
>
>