title: (13)Permission denied: access to /cgi-bin/test.cgi denied
body: <p>I am trying out CGI-scripts for the first time but without success. I have read many tutorials and followed may threads in different forums but I can not make it work.
  I am using a appache web server on a Fedora 10 machine.
  I always have problem with </p>
  
  <pre><code>[Wed Oct 21 20:47:36 2009] [notice] SELinux policy enabled; httpd running as context unconfined_u:system_r:httpd_t:s0
  [Wed Oct 21 20:47:36 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
  [Wed Oct 21 20:47:36 2009] [notice] Digest: generating secret for digest authentication ...
  [Wed Oct 21 20:47:36 2009] [notice] Digest: done
  [Wed Oct 21 20:47:36 2009] [notice] Apache/2.2.11 (Unix) DAV/2 PHP/5.2.9 mod_ssl/2.2.11 OpenSSL/0.9.8g configured -- resuming normal operations
  </code></pre>
  
  <p>I need help.
  This is what my environment looks like.</p>
  
  <pre><code>uname -a
  Linux localhost.localdomain 2.6.27.5-117.fc10.i686 #1 SMP Tue Nov 18 12:19:59 EST 2008 i686 i686 i386 GNU/Linux
  
  ls -l /var/www/cgi-bin/
  total 36
  -rwxrwxrwx 1 root root   106 2009-10-21 18:29 index.html
  -rwxr-xr-x 1 root root 11089 2009-02-24 20:11 squidGuard.cgi
  -rwxr-xr-x 1 root root  5720 2009-02-24 20:11 squidGuard-simple.cgi
  -rwxr-xr-x 1 root root  5945 2009-02-24 20:11 squidGuard-simple-de.cgi
  -rwxrwxrwx 1 root root   110 2009-10-21 17:38 test.cgi
  
  apachectl -v
  Server version: Apache/2.2.11 (Unix)
  Server built:   Mar  6 2009 09:12:25
  
  perl -version
  This is perl, v5.10.0 built for i386-linux-thread-multi
  Copyright 1987-2007, Larry Wall
  </code></pre>
  
  <p>My script</p>
  
  <pre><code>cat test.cgi
  #!/usr/bin/perl
  print "Content-Type: text/html\n\n";
  print "Hello, world!\n";
  </code></pre>
  
  <p>The error message I gen when I try to access the web page server "<a href="http://192.168.50.29/cgi-bin/test.cgi" rel="noreferrer">http://192.168.50.29/cgi-bin/test.cgi</a>" looks like this:</p>
  
  <pre><code>[Wed Oct 21 21:00:27 2009] [error] [client 192.168.50.69] (13)Permission denied: access to /cgi-bin/test.cgi denied
  </code></pre>
  
  <p>I have added the line:</p>
  
  <pre><code>ScriptAlias /cgi-bin/ "/var/www/cgi-bin/"
  </code></pre>
  
  <p>to /etc/httpd/conf/httpd.conf</p>
  
  <p>I just can not make it work.
  Can anyone help me?</p>