http://qs1969.pair.com?node_id=11755


in reply to Problems with Sys::Syslog and taint

It's required that you untaint the ENV{PATH} when you run any system command line apps via system, exec ot anything of that nature.
Doing:
local %ENV = (PATH => '/bin');
Works like mdillon pointed out. It's actually better than what I was using which was:
local $ENV{'PATH'} = '/bin';
His code will clear out ENV before it sets that path. Anyhow, localizing ENV and setting the PATH is required for tainted scripts that use system calls. This makes sure you don't have some path in the ENV that you don't know about and can be explioted by others.

-- philip
We put the 'K' in kwality!