Here's how to stop shell escapes from vi

Leslie Mikesell les at chinet.chi.il.us
Mon Sep 24 14:07:45 AEST 1990


In article <27387:Sep2320:07:3890 at kramden.acf.nyu.edu> brnstnd at kramden.acf.nyu.edu (Dan Bernstein) writes:
>    [ trash the colon with pty -0 tr \: \? | pty vi ]
>
>I did mention that you have to set up appropriate macros as well, and
>turn off keyboard interrupts. The only thing that you can't completely
>control from within vi is the mapping of the colon---and my solution
>handles that.

Umm... Well, there's 'Q' to go to ex mode and stay there while you
type sh, or if the tmp file that you start out with contains the
outlawed ":" and/or "!" characters (or you manage to read them in
from some other file) you can just edit them into the construction
you need, yank to a register and execute.  Leaves something to 
be desired as a form of security....

Les Mikesell
  les at chinet.chi.il.us



More information about the Comp.unix.sysv386 mailing list