CGIWrap - User Instructions
- Cgiwrap is a gateway program
that will allow you to run cgi scripts from your own cgi-bin directory. Your scripts
are run under the control and protection of cgiwrap so you need not be worried about
comprising the security of our web server or damaging files of other users. In addition,
cgiwrap allows your cgi programs to run under your username rather than as the web
server. This means that you can collect data and create files that are inaccessible
by other users.
The following are instructions for
setting up your account to be able to use cgiwrap to execute cgi scripts. It is assumed
that you are familiar with writing CGI scripts and writing HTML documents for the
In the following instructions, we'll assume your login name, home directory, CGI
directory, script name and domain name are:
- Login Name: joe
- Home Directory: /home/joe
- CGI Directory: /home/joe/www/cgi-bin
- Name of Script: yourscript.cgi
- Domain Name: domain.com
Note: Use the name of the script
you want to run instead of "yourscript.cgi".
If you do not already have a cgi-bin
directory set up, create one:
- cd /home/joe/www
- mkdir cgi-bin
Install the script into your cgi-bin
directory, and set the proper execution permissions on the file.
- cp yourscript.cgi /cgi-bin/yourscript.cgi
- chmod 755 /cgi-bin/yourscript.cgi
The script is executed using the
If you wish to see debugging output
for your CGI, specify cgiwrapd instead of cgiwrap, as in the following
If the script is an nph-
style script, you will need to run it using the following URL's:
- Make sure you've created a directory
with the name 'cgi-bin' in your login directory. If your login name is 'joe'
then the directory would be '/home/joe/www/cgi-bin'
- Make sure the permissions for
your cgi-bin directory and cgi program are set at 755.
- If you're using a Perl script
the first line of the script must read '#!/usr/bin/perl'. This allows your
script to find Perl. (We use Perl 5.8 or better.)
- If you want to use the sendmail
program the correct location is '/usr/sbin/sendmail'.
- Make sure you're calling your
cgi program properly. A sample Form Action command would be <form action="cgi-bin/cgiwrap/joe/yourscript.cgi"
to Support Index
Copyright 1996-2005 Intersessions Inc. all rights
Box 555, Tenafly, NJ 07670
201-569-1762 (Voice), 201-569-7898 (Fax)