I am having yet another problem with getting forbidden on my cgi-bin folder in Centos 5.5, here are my versions of perl:
I typed in: "perl --version" this came up:
Quote:
This is perl, v5.8.8 built for i386-linux-thread-multi
Copyright 1987-2006, Larry Wall
Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.
Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl". If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.
|
Then I typed in "rpm -q mod_perl" as this is the language I am wanting to write in and this came up:
Is there a compatibility problem with these versions at all?
I was following this tutorial again:
http://httpd.apache.org/docs/1.3/howto/cgi.html
Then added these in:
Quote:
ScriptAlias /cgi-bin/ /www/example.com/cgi-bin/
<Directory /www/example.com/cgi-bin>
Options +ExecCGI
Order deny,allow
Allow from all
</Directory>
|
Then of course:
Quote:
AddHandler cgi-script cgi pl
|
But its now bringing up instead of:
Quote:
client denied by server configuration: /www/example.com/cgi-bin/
|
It's bringing up:
Quote:
attempt to invoke directory as script: /www/example.com/cgi-bin/
|
Is there any obvious error I am making here as to why its bringing this error message up?
Thanks and I look forward to any replies,
Jez.
PS I have run the script and its producing output from the shell not a web browser, tried using:
Quote:
#!/usr/bin/perl
print "Content-type: text/html\n\n";
print "Hello, World.";
|
Same error so it can't be the program/script itself, must be something wrong with my configs, but of course it could be the headers in the output to html?
This is the script of course:
Quote:
#!/usr/bin/perl
print "Hello, World.";
|
Double checked the which perl command and its coming up with the same directory.
Hmm I'm really confused.