What
file permissions do I need for my CGI script?
CGIs must be set with executable file permissions, or requests for
the script from the web server will result in an Internal Server
error. Scripts that need to be executable should have their permission
set with chmod 755. This sets the file's permissions so that the
file's owner may read, write, and execute the file; and anyone else
can only read and execute it. This is how to execute CGI scripts
under a secure connection.
How
do I call a CGI script securely?
Using your local
CGI BIN, your path would look like this:
https://secure_server.com/your_domain/cgi-bin/filename.pl
The secure_sever.com
represents the server your domain is hosted on.
If you would
like to use 'formmail.pl' securely you first need to:
- Save a copy
of this script on your local hard drive.
- Upload the
'formmail.pl' file into your local /cgi-bin directory.
Then instead of calling the universal /cgi-sys directory,
you would call your own /cgi-bin directory.
It would look something like this:
https://host.virtualhostingsolutions.net/your_domain/cgi-bin/formmail.pl
NOTE: You do NOT include the extension of your
domain (ie. '.com', '.net', '.org').
What is your server path to PERL and Sendmail?
Our server path
to PERL is:
!/usr/local/bin/perl
The path to
the Sendmail program is:
/usr/lib/sendmail
How
do I set permissions inside my CGI BIN?
If the browser
returns "Internal Server Error" every time you
submit your form, you did not have the right permission set for
your script. Do the following to set the permission:
- Telnet into
your /cgi-bin directory and issue the following
command:
chmod 755 filename.pl
This will give universal execute permissions
for that file
|