Kemin Zhou wrote: [...]
"." is automatically removed when that taint mode (-T) is on. Refer to the perlsec Perl manpage for more info. This has nothing to do with mod_perl.Thaks Stas for the pointer. I can go around this limitation for Taint checking (which is a must for server side programing).
> /usr/local/apache2/ > /usr/local/apache2/lib/perl
are added when running mod_perl 2, for mp1 compatibility. http://perl.apache.org/docs/2.0/user/install/install.html#MP_COMPAT_1X disable it to avoid this from happening.
That's right. I did try to suggest to turn that off, just pointed out that the removal of '.' is done by Perl as a side-effect of having -T on. :)
Now the Apache/perl
(not just mod_perl but cgi too) user can either put their module into some standard place or do "use lib /absolute/path/tomodule/.
In mod_perl we don't manually call our programs at the command line, that gave you a chance to change the
lib-path with -I/some/path. Even this is possible it is not onece for all solution. Under mod_perl, in most cases, we have to convert our regular perl programs into modules to avoid
the problem of wrapping our program inside sub handler { # the whole perl programs with more than one sub { } }
Here the programmer's convinence is gone. Is there a way to put modules in the /perl directory by configure the
apache httpd.conf file? (This is just a wish)
What is the common practice if Taint check is turned on for perl?
The common practice is to add:
use lib qw(/absolute/path/tomodule/libs);
at the server startup. (e.g. startup.pl). That won't work for mod_cgi of course.
another practice is to adjust PERL5LIB, which is again ignored when -T is on.
-- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
-- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html