How to prevent VI from getting a shell?
Jim Webb
jrw at mtune.ATT.COM
Tue Sep 18 01:20:55 AEST 1990
In article <570 at DIALix.UUCP>, bernie at DIALix.UUCP (Bernd Felsche) writes:
> In article <501 at trux.UUCP> car at trux.UUCP (Chris Rende) writes:
> >If I want to give someone access to VI and yet deny them access to a shell,
> >how do I prevent the user from using VI's "<ESC>:!" command?
>
> set SHELL in the environment to something which doest nothing, say
> /bin/true. vi forks-execs whatever SHELL is defined to be, or the
> shell if undefined.
True, but.....
$ SHELL=/bin/true ex # ex is easier to deal with here :-)
:sh # run a shell....
! # comes right back
:set shell=/bin/sh # hmmm....
:sh # now what can I do....
$
Later,
--
Jim Webb "Out of Phase -- Get Help" att!mtune!jrw
"I'm bored with this....Let's Dance!"
More information about the Comp.unix.questions
mailing list