You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Stas Bekman <st...@stason.org> on 2001/02/12 08:30:25 UTC

Re: PerlTaintMode and PERL5LIB/PERL5OPT env vars.

sorry for delay in followup, I was working on other book chapters and I'm
not good at having too many context switches :(

On Fri, 26 Jan 2001, Doug MacEachern wrote:

> On Tue, 9 Jan 2001, Stas Bekman wrote:
>
> > I've lost the original email, but this is reply from Doug to my
> > email. I've asked to confirm that PERL5LIB is ignored with PerlTaintMode
> > is on. Apparently the Perl docs say a different thing...
> >
> > Anybody has any insights about this situation? Does it has anything to do
> > with Perl versions?
> ...
> > But according to perlrun manpage (dist 5.00503):
> >
> >        PERL5LIB    A colon-separated list of directories in which
>
> mod_perl special cases this one, from mod_perl.c:
> 	char *path = (char *)table_get(r->subprocess_env, "PERL5LIB");
>
> 	if (path) {
> 	    perl_incpush(path);
> 	    MP_INCPUSH_on(cld);
> 	}

Well, what I see is weird. I run under -X and issue /perl-status?inc
(Apache::Status). I have this setting:

  PerlTaintCheck Off
  PerlSetEnv PERL5LIB /tmp

No matter what's the value of PerlTaintCheck, on the first
request I get /tmp in @INC, and on the rest I don't.

I use perl5.6.1-PATCH2 and mod_perl-1.25

> >        PERL5OPT    Command-line options (switches).  Switches in
>
> there is not special case for this, it was ignored last time i checked.
> 5.6.0 has some taint related bugs so it could be related to that.
> where/how do you set PERL5OPT ?

In fact with my current setup PERL5OPT is not respected at all if set in
httpd.conf:

  % setenv PERL5OPT -Dt
  % httpd -X

works (I get the trace), but

  PerlSetEnv PERL5OPT -Dt

in httpd.conf doesn't work at all, no matter what's the value of
PerlTaintCheck.

Thanks!

_____________________________________________________________________
Stas Bekman              JAm_pH     --   Just Another mod_perl Hacker
http://stason.org/       mod_perl Guide  http://perl.apache.org/guide
mailto:stas@stason.org   http://apachetoday.com http://logilune.com/
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/