Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 1 Sep 2014 08:55:06 -0400
From:      Monah Baki <monahbaki@gmail.com>
To:        FreeBSD Questions <freebsd-questions@freebsd.org>
Subject:   CGI scripts not working
Message-ID:  <CALP3=x-9TJFWKzCvTo%2BiLp9cZZOKKt3vBxunmLLtor_tVWRQkg@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi all,

I installed on FreeBSD 9.3 apache 2.4 from ports

I am trying to run the following test script located in
/home/ipaudit/public_html/cgi-bin/test

#!/usr/bin/perl -w
print "Content-type: text/html\r\n\r\n";
print "Hello there!<br />\nJust testing .<br />\n";
for ($i=0; $i<35; $i++)
{
print $i."<br />";
}

All I get is the script itself and not the output. My httpd-error.log
shows no error



Here is what I have in my httpd.conf

ScriptAlias /cgi-bin/ "/usr/home/ipaudit/public_html/cgi-bin/"

<Directory "/usr/home/ipaudit/public_html/cgi-bin/">
    AllowOverride None
#    Options None
    Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
    Order allow,deny
    Allow from all
    Require all granted
</Directory>

 AddHandler cgi-script .cgi

ls -la /home/ip[audit/public_html/cgi-bin
drwxr-xr-x   2 root     wheel     512 Sep  1 07:55 cgi-bin

and

-rwxr-xr-x  1 ipaudit  ipaudit    165 Sep  1 08:31 test



Here is what I have in my httpd-userdir.conf

UserDir public_html

<Directory "/home/*/public_html">
    AllowOverride FileInfo AuthConfig Limit Indexes
    Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
    Require method GET POST OPTIONS
</Directory>




Am I missing anything else?



Thanks
Monah



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CALP3=x-9TJFWKzCvTo%2BiLp9cZZOKKt3vBxunmLLtor_tVWRQkg>