On Today at 2:42pm, SB=>Stas Bekman <[EMAIL PROTECTED]> wrote:
SB> > Comments are welcome. And we really should have a newline at the end of
SB> > ModPerl-Registry/t/conf/extra.conf.in
SB>
SB> certainly, but does it break anything?
SB>
Hi Stas,
Doesn't break anything really, but when I was using the >> operator to
tack on some directives at the end of this file not having the newline
caused me some grief as the last line and my added line got stuck on the
same line (oops that makes it a misspelled directive - sheepish grin :-))
SB> [...]
SB>
SB> > +SetEnv TMPDIR /tmp
SB>
SB> This is not a portable change. If you have a particular problem with
SB> regards to temp dir it needs to be solved where it arises (e.g. using
SB> File::Temp), but you don't tell what the problem is, so I can't give
SB> you a solution.
I really should spend more time explaining the issue rather than jumping
to the solution. Thanks for listening. Here's the issue. As I mentioned
Gentoo's pacakge mgmt. system has the capability to build/install as a
non-root user. Somewhere down line during the tests, the following tests
are failing when run under the non-root user.
modules/cgi....................NOK 3# Failed test 3 in modules/cgi.t at
line 41
modules/cgi....................FAILED test 3
Failed 1/5 tests, 80.00% okay
modules/cgiupload..............NOK 1# Failed test 1 in modules/cgiupload.t
at line 32
modules/cgiupload..............NOK 2# Failed test 2 in modules/cgiupload.t
at line 32 fail #2
modules/cgiupload..............FAILED tests 1-2
Failed 2/2 tests, 0.00% okay
Looing at t/logs/error_log, we find:
[Wed Oct 01 18:15:18 2003] [error] (13)Permission denied: Couldn't unlink
unix domain socket /var/run/cgisock
[Wed Oct 01 18:15:18 2003] [error] (98)Address already in use: Couldn't
bind unix domain socket /var/run/cgisock
ACCESS DENIED unlink: /var/run/cgisock
As I mentioned earlier, the permissions for /var/run/cgisock are not
accissible by the non-root user. In addition, it is a violation of the
sandbox principle. My fix for ScriptSock was meant to appease mod_cgid
into creating the cgisock in the logs directory instead which will make it
self-contained and won't violate the sandbox.
In the case of SetEnv TMPDIR /tmp, CGI.pm uses /tmp as its temporary
repository. Access to /tmp is again a violation of the sandbox. I agree
that /tmp is not a portable solution but setting TMPDIR is the only way
that I can think of to vary CGI.pm's behavior thru the httpd conf file.
Perhaps, a kludge like:
SetEnv TMPDIR logs
would suffice. I believe CGI.pm cleans up after itself anyway.
SB>
SB> > +ScriptSock logs/cgisock
SB>
SB> We don't use mod_cgi in the mod_perl test suite. It's just a left-over
SB> from testing. Does this patch fix things for you?
SB>
Nope, the patch had no effect whatsoever in the tests not failing.
Regards,
--
Haroon Rafique
<[EMAIL PROTECTED]>