You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by "Lawrence, Sean" <sl...@seveninteractive.com> on 2001/12/27 17:32:29 UTC

CGI Issue

I thought I setup Apache correctly to use CGI

I set up a user then added that user as User and Group in Apache, docroot is
set to that users home directory.  I then setup the vhost and the line 
Options ExecCGI
AddHandler cgi-script .cgi

But when I try to view any files *.cgi it throws a 403 and the log says that
ExecCGI isn't turned in that directory
The files are permissioned correctly.
Anybody have an idea?


---------------------------------------------------------------------
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
For additional commands, e-mail: users-help@httpd.apache.org

---------------------------------------------------------------------
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
For additional commands, e-mail: users-help@httpd.apache.org


RE: CGI Issue

Posted by Joshua Slive <jo...@slive.ca>.
> From: Lawrence, Sean [mailto:slawrence@seveninteractive.com]

>
> I thought I setup Apache correctly to use CGI
>
> I set up a user then added that user as User and Group in Apache,
> docroot is
> set to that users home directory.  I then setup the vhost and the line
> Options ExecCGI
> AddHandler cgi-script .cgi
>
> But when I try to view any files *.cgi it throws a 403 and the
> log says that
> ExecCGI isn't turned in that directory
> The files are permissioned correctly.
> Anybody have an idea?

Can you tell me specifically what documentation you are reading?  I have
seen this problem MANY times over the past few months, and if you are
reading something in the apache documentation, then it needs to be improved.

Anyway, the problem is that you don't properly understand how the Options
directive works.  See http://httpd.apache.org/docs/mod/core.html#options for
all the details.

The important point is that Options directives that apply to particular
<Directory>s will override an Options directive applying in the main server
or <VirtualHost> context.  So you need to either add "ExecCGI" to the
Options that already applies to the relevant <Directory> or add something
like

<Directory /full/path/to/directory>
Options +ExecCGI
</Directory>

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
For additional commands, e-mail: users-help@httpd.apache.org