httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Slive <jsl...@gmail.com>
Subject Re: [users@httpd] DirectoryIndex /mybin/myindex.cgi
Date Thu, 08 Sep 2005 12:58:25 GMT
On 9/8/05, Andrew Clarke <aclarke@civica.com.au> wrote:
> <Directory /home/*/public_html>
>     AllowOverride FileInfo AuthConfig Limit Indexes
>     Options MultiViews Indexes SymLinksIfOwnerMatch Includes ExecCGI
>     DirectoryIndex /cgi/myindex.cgi
>     <Limit ...
>     <LimitExcept ...
> </Directory>

> When it was installed in /srv/www/htdocs/cgi, and invoked as
> http://myhost/cgi/myindex.cgi then I get the expected output.
> 
> When I try to invoke the script via http://myhost/~username it fails.
> 
> error_log contains:
> 
> [Thu Sep 08 21:24:12 2005] [error] [client 127.0.0.1] Premature end of script
> headers: myindex.cgi
> 
> and suexec.log contains:
> 
> [2005-09-08 21:24:12]: uid: (400/username) gid: (100/100) cmd: myindex.cgi
> [2005-09-08 21:24:12]: command not in docroot
> (/srv/www/htdocs/cgi/myindex.cgi)

Interesting.  I haven't looked into it in detail, but I suspect that
what you are trying to do is not possible with suexec activated.  If
the request is run through mod_userdir, then it must follow the
user-specific suexec rules.  That includes the script living under
/home/user/public_html and being owned by the user.

So you have two choices:

1. Don't use suexec.  This would be the thing to do unless you really
need suexec.

2. Install the script under each user's public_html directory and
owned by the user.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message