Re: only one program per login
From: Stuart J. Browne (stuart_at_promed.com.au)
Date: 05/26/04
- Next message: Jean-Pierre Radley: "Re: only one program per login"
- Previous message: John DuBois: "Re: only one program per login"
- In reply to: John DuBois: "Re: only one program per login"
- Next in thread: Jean-Pierre Radley: "Re: only one program per login"
- Reply: Jean-Pierre Radley: "Re: only one program per login"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 26 May 2004 12:06:49 +1000
"John DuBois" <spcecdt@deeptht.armory.com> wrote in message
news:40b3bf1c$0$439$8eec23a@newsreader.tycho.net...
> In article <fd1496bf.0405251239.1c21d7db@posting.google.com>,
> pablo hernandez <pablo@crecat.com> wrote:
> >We have some users connecting my server ( Os507 ) via ssh .
> >
> >I want to limit those users to only one program , and then exit again
from server.
> >
> >I do not want them , in any case to go to the shell.
> >
> >To achieve this I put in the .profile
> >>>>>
> >run myprogram
> >
> >logout
> >
> >>>>>
> >
> >having also eliminating the possibility of QUIT KILL and DEL .
> >
> >
> >Is this a safe procedure , or can be broken by the user ?
> >
> >Any advise for a better option ?
>
> If you want to be *certain* that the user can't escape from this by
hitting an
> interrupt key at just the right moment during login, make a shell script
that
> contains:
>
> #!/bin/sh
> run myprogram
>
> Make the script publicly readable & executable, and make it be the user's
login
> shell. If you do any important environment setup in /etc/profile, you'll
need
> to duplicate that in the script, or perhaps just source /etc/profile from
it:
>
> #!/bin/sh
> . /etc/profile
> run myprogram
wouldn't it also be advisable to 'exec myprogram' at the end of the script,
instead of just running it?
bkx
- Next message: Jean-Pierre Radley: "Re: only one program per login"
- Previous message: John DuBois: "Re: only one program per login"
- In reply to: John DuBois: "Re: only one program per login"
- Next in thread: Jean-Pierre Radley: "Re: only one program per login"
- Reply: Jean-Pierre Radley: "Re: only one program per login"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|