Allegedly, on or about 10 May 2018, Alex sent:
I've done a bit of searching, and it appears apache thinks the
files are scripts and not executables. How can I configure apache to
interpret these files properly?
On my system, CGI scripts have filenames that give away the content
type (e.g. scripts ending with .pl), and binary files had .cgi or no
suffix (apparently some binaries may use a .bin suffix).
It may not be required, but makes managing things more obvious to me.
Without doing anything fancy, and admittedly on an old version of
Apache, it seems to just run what it finds in the CGI directory (much
the the same way the command line will run scripts and binaries without
you having to do anything special).
A common problem with webserving is people not setting up the cgi-bin
directory to be a CGI binary directory, and the server just tries to
load the files as plain files. Though you'd expect to just see garbage
in the web browser, much the the same as if you'd used the "less"
command to view a binary file.
I'm not familar with nagios. Have you tried just testing the default
CGI examples that come with Apache?
Also check your file permissions, and that SELinux is not interfering.
Generally, if you create or install your scripts into the usual
locations for cgi-bin, it will work. But if you move a file from one
place to the cgi-bin directory, it'll have the security contexts of the
prior location, and execution will be denied.
[tim@localhost ~]$ uname -rsvp
Linux 4.15.17-200.fc26.x86_64 #1 SMP Thu Apr 12 18:28:26 UTC 2018 x86_64
Boilerplate: All mail to my mailbox is automatically deleted.
There is no point trying to privately email me, I only get to see
the messages posted to the mailing list.
America, you've had a Bush show you that any idiot can become president,
don't let a Trump prove that any asshole can.