home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.perl
- Path: sparky!uunet!timbuk.cray.com!hemlock.cray.com!roehrich
- From: roehrich@cray.com (Dean Roehrich)
- Subject: Re: setuid question
- Message-ID: <1992Dec23.172428.8929@hemlock.cray.com>
- Lines: 20
- Nntp-Posting-Host: fig36
- Organization: Cray Research, Inc.
- References: <1992Dec23.211810.9925@uvaarpa.Virginia.EDU> <1992Dec23.213406.22114@porthos.cc.bellcore.com>
- Date: 23 Dec 92 17:24:27 CST
-
- In article <1992Dec23.213406.22114@porthos.cc.bellcore.com> rdm2@donner.cc.bellcore.com (mcburnett,roe d) writes:
- >In article <1992Dec23.211810.9925> gaspar@st-louis-emh2.army.mil writes:
- >> 1. open(FOO,"ps ax|");
- >> 2. open(FOO,"-|") || exec 'ps -af';
- >>
- >>Tainperl keeps saying that my path is insecure. Is there a way to do
- >>this? Thanks for the help.
- >
- >Try "/bin/ps ax|" instead.
-
- You must go one step beyond this, actually. Taintperl will not execute
- another process while the PATH environment variable is tainted. By using
- absolute pathnames you really do not address the problem as far as taintperl
- is concerned.
-
- Add $ENV{PATH}="some/suitable/path"
- early in the script/program to untaint the path.
-
- Dean Roehrich
- roehrich@cray.com
-