'cgi-bin in http server is returning the content in the file rather than the output of shell command that is kept in the file
I kept a shell script under cgi-bin folder, gave execute perm , added shebang , set content-ttype in the file and kept a shell command ls /bin. When im trying to access the file from the browser it is returning the content but not executing the command.
So i updated httpd.conf file with Options +Exct
LoadModule cgi-mod.so
AddHandler .sh .cgi
Ignore spelling mistakes above but i have updated correctly in the file.
Restarted httpd process
After that i am ending up with 500 error saying "invalid arguments to daemon cgi " in the error log.
This is on linux.
Please help if am missed anything in httpd.conf
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
