TIP: Click on subject to list as thread! ANSI
echo: rberrypi
to: ALL
from: =?UTF-8?Q?BENGT_T=C3=B6RN
date: 2018-01-30 10:27:00
subject: How to enable cgi script

With an earlier Raspian version I have succeeded in execution of cgi scripts.
Now it seems to me that the process to enable cgi execution has been modified.


My test script, presently "open" for all users "-rwxrwxrwx 1 root root...", in
the /usr/lib/cgi-bin/ folder is:

#!/bin/bash
echo -e "Content-type: text/html\n\n"
echo ""

echo "This is start of test.cgi"

echo "#!/bin/bash" >test1.script
echo "echo \"This is test1.script\"" >>test1.script
chmod 755 test1.script
/usr/lib/cgi-bin/test1.script

echo "This is end of test.cgi"
echo ""


The result in a browser screen becomes:

This is start of test.cgi
This is end of test.cgi


The /var/log/apache2/error.log shows:

.../usr/lib/cgi-bin/test.cgi: line 10: /usr/lib/cgi-bin/test1.script: No such
file or directory: /usr/lib/cgi-bin/test.cgi, referer...

Obviously some configuration to allow the cgi script to execute and write is
missing. I can however not find out where and how.

I kindly ask for assistance and advises.

--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)

SOURCE: echomail via QWK@docsplace.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.