sherab has asked for the wisdom of the Perl Monks concerning the following question:
Hello monks. I come back to the well once again with a question. In some of our corporate code we use this..
$ENV{'PATH'} = '/bin:/usr/bin'; delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV'};
Reason is for taint checking. If I were to follow best practices and localize this wouldn't that defeat the purpose?
I know that by not localizing $ENV that there exists a possibility of other things like modules in the script exhibiting unpredictable behavior.Any insight?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Localizing Magic Variable? Should I?
by ikegami (Patriarch) on Nov 17, 2009 at 22:43 UTC | |
|
Re: Localizing Magic Variable? Should I?
by JavaFan (Canon) on Nov 17, 2009 at 22:18 UTC |