Blue Reef Technical Support Blue Reef Virtual Server Reseller ProgramInstallation instructions, manuals, how-tos, and more!About Blue Reef Consulting, Inc.

About Blue Reef Virtual ServersEcommerce Solutions for your Virtual ServerSearch the Blue Reef Virtual Server web site
Return to Blue Reef Virtual Servers Home Page
Order virtual servers, software, computers, and more!
Return to Blue Reef Main Home Page
Specials
Site Map
CGi Library of scripts to help you do business with your Virtual Serve and to have a better web site.



Blue Reef Virtual Servers
Virtual Server Support
Virtual Server Addons
CGI Library for use with a Virtual Server
CGI Library Overview
FormMail
PGP FormMail
Simple Visitor Counter
Count 2.5 Visitor Counter
Guestlist
User Information (Finger)
Password-protect files with User Authentication
URL Redirection
Tool to Check Domain Name Availability
Lookup details for domain records
Domain Record Modification Tools
Excite Search Engine for your site
SWISH-E search engine for your site
JavaScript Library
Java Library
Request help using our Problem Tracking System
Order a Blue Reef Virtual Server now!


PGP FormMail

FormMail is a generic WWW form-to-email gateway, which will take the results of any web-based form and send them to the specified user. This script has many formatting and operational options, most of which can be specified through the form, meaning you don't need any programming knowledge or multiple scripts for multiple forms. This also makes FormMail the perfect system-wide solution for allowing users form-based user feedback capabilities without the risks of allowing freedom of CGI access. PGP FormMail takes advantage of your server's PGP technology to securely send the form results to the desired recipient.

PGP (Pretty Good Privacy), originally developed by Phil Zimmerman, is a high security cryptographic software application for MSDOS, UNIX, VAX/VMS, and other computers. PGP allows people to exchange files or messages with privacy, authentication, and convenience.

Installing PGP FormMail
To install PGP FormMail v1.6, Telnet or SSH to your Virtual Server and do the following:
  1. Install PGP 5.0

  2. Untar the PGP FormMail tar file located in the /usr/local/contrib area.

      % cd (this will put you in your home directory)
      % tar -xvf /usr/local/contrib/pgp5formmail.tar

    This will install the two files, pgp5formmail.pl and pgp5formmail.README.txt, into your ~/www/cgi-bin directory.
Using PGP FormMail
  1. Create a form that you would like the contents mailed to some address. The form should include the following fields (at the very least):

      recipient = specifies who mail is sent to
      pgpuserid = specifies your PGP user ID

    Other optional fields can also be used to enhance the operation of FormMail for you site, for example:

      subject = specify the email's subject
      email = the user specifies a return email address
      realname = allow the user to input their real name
      redirect = URL of page to return to
      required = comma-separated list of required fields

    Several other fields are supported, please see the README document for a complete presentation of the supported fields.

    For example, the HTML source for your form may look like this:

      <form method="POST"
      action="/cgi-bin/formmail.pl">
      <input type="hidden" name="recipient" value="order@yourdomain.com">
      <input type="hidden" name="pgpuserid" value="your_userid">
      <input type="hidden"
      name="subject" value="Order Request">
      <input type="hidden" name="required" value="realname,username,phone">
      Please Enter Your Name:<br>
      <input name="realname" size="40">
      <p>
      Please Enter Your Email Address:<Br>
      <input name="email" size="40">
      <p>
      Please Enter Your Phone Number:<Br>
      <input name="phone" size="40"> <p>
      .
      .
      .
      <input type="submit" value="Submit">
      <input type="reset" value="Reset">
      </form>

    your_userid is the user ID for your public key. If your user ID contains characters that could be misinterpreted by a web browser, such as '<' and '>', you will want to replace these characters with the proper escape sequences. For example if your user ID were:

      John Q. Smith <12345.6789@compuserve.com>

    represent the user ID with the following string (note the &lt; and &gt; escape sequences):

      John Q. Smith &lt;12345.6789@compuserve.com&gt;

    NOTE: In order to use the pgp5formmail.pl script, you will have to install the PGP 5.0 executable onto your virtual server, and either generate a public/secret key pair or have added an existing key file's contents to your public key ring.
     
  2. Set the referer* information such that only your server will have privileges to use the formmail.pl script. Near the top of the formmail.pl script you will find the following line:

    @referers = ('YOURDOMAIN.NAME','YOUR.IP.ADDR.ESS');

    Substitute your domain name and Virtual Server IP address for the values YOURDOMAIN.NAME and YOUR.IP.ADDR.ESS respectively.
Tip
One way to modify the pgp5formmail.pl script is have it "autorespond" to the client filling out the form. You can do this by simply uncommenting out the call to "autorespond" located near the top of the script. The autorespond function is placed at the end of the file and can be modified to suit your needs.

*This is not a misspelling of the word "referrer". In the context of web servers, this word should be spelled "referer".
SEE ALSO:

Installing CGI Scripts

CGI Security Issues

CGI Scriptorium

About Perl

Perl Modules

Server Side Includes

Mime Types

About Apache Server

BOOKS TO HELP YOU:

CGI Programming 101
CGI Programming 101

$24.95

CGI Programming With Perl
CGI Programming With Perl

$26.36

PGP: Pretty Good Privacy
PGP:
Pretty Good Privacy

$27.96


Web Security:
A Step-by-Step Reference Guide

$23.96


Official Guide to Programming With CGI.pm
Official Guide to Programming With CGI.pm

$27.99

Javascript Bible
Javascript Bible,
3rd Edition

$34.99

Core Web Programming
Core Web Programming

$34.39

Apache: Web Server Directives Guidebook Apache:
Web Server Directives Guidebook

$15.95

Amazon.com logo
Search for :
Enter keywords...