READ.ME

Httpd Password Suite

 

 

 

 

File Names Description Location

password_admin.cgi Web Password admin system cgi-bin
password_subscribe.cgi Subscription system cgi-bin
signup.htm Subscription Web Interface htdocs

dwcgi-lib.pl Basic CGI library cgi-bin
password_lib.cgi Httpd Password Library cgi-bin
credit_card_validation_lib.pl Credit Card Validation Library cgi-bin

demo.pass Local Configuration File /accounts/

NOTE: the xxx.pass file's location can be changed in the $account_dir="/accounts/";
statements in:
password_admin.cgi and password_subscribe.cgi

 

The call to run password_admin see below:

 

SUITE Manual

password_admin.cgi

The purpose of password_admin is to provide an automated httpd based password system. The program is written in Perl and runs quickly. (average execution times not applicable)
IMPORTANT: You should have a basic understanding of how users and groups work before using this software, see below!

PASSED VARIABLES:

account: demo (users account name)

EXAMPLE GET CALL:
<HTML>
<HEAD>
<TITLE>admin page</TITLE>
</HEAD>
<BODY BGCOLOR="#c4d4ff">
<CENTER><H2>admin page</H2></CENTER>
<HR>
<a href= "/cgi-bin/password_admin.cgi?account=demo">Password System</a>
</BODY>
</HTML>

This system places 2 files in your directory /foo/bar/users_groups/. The files contain all the groups and users for the password system. This directory MUST be chmod a+rwx or the system will not work.
The 2 files are hidden.



About httpd passwords:

  1. What is a group and user?

      A user is a name that contains no spaces and has a password assocated with it.
      A group is a name that has a set of users names attached to it.

  2. RELATIONSHIPS:
  3. What is stored where? and why?
    The httpd password system consists of 3 files to work:
    1. .htaccess this file contains the instructions to the web server to password
      protect a directory and what group/password file to use .
    2. .htgroup this file has a list of groups and the members of each group.
    3. .htpassword this file contains all the users and their passwords (encrypted).

For a directory to be password protected it must have an .htaccess file that holds the locations of the .htpassword file and the .htgroup file as well as the name of the group of users that can access the directory. The users are stored in a file called .htpassword it contains the user names and the password for every user. The Groups are stored in a file called .htgroup. This file has the group names followed by all the user names that are members of that group.

 

 

 

password_subscribe.cgi

The purpose of password_subscribe is to provide an automated httpd based password purchasing system. The program is written in Perl and runs quickly. (average execution times .03 seconds)
IMPORTANT: This script is designed to work with SSL and a specific set of variables posted from an HTML form, the variable names can not be changed and have the script operate properly

PASSED VARIABLES:

account: demo (your account name)
accttype: (Special variable of GROUP & PRICE "groupname|price")
adname: (users real name is required)
adaddress: (users real address is required)
adcity : (users real city is required)
adstate: (users real state is required)
adcountry: (users real country)
adzip: (users real zip code is required)
adphone: (users real phone # is required)
ademail: (users email address is required (username will be email address))
cctype: (users credit card valid values are VISA, MASTERCARD, AMEX, DISCOVER)
ccno: (users credit card number is required)
ccname: (name on the users credit card is required)
bzip: (credit card billing zip is required)
ccexmonth ccexyear : (credit card expiration date is required (single field usage is ccexmonth)

EXAMPLE POST CALL:

<HTML><HEAD><TITLE> Subscriptions</TITLE></HEAD>
<BODY><FORM ACTION="https://www.initco.net/cgi-bin/password_subscribe.cgi" METHOD="POST">
<H1><CENTER>SUBSCRIPTION FORM</CENTER></H1><P><CENTER>
<FONT COLOR="#DB1224" SIZE=+2>This Information is Encoded Via SSL<BR> <blink>for Your Security </blink></FONT></B></CENTER></P><P><CENTER>
<TABLE WIDTH="100%" BORDER="1" CELLSPACING="2" CELLPADDING="0">
<TR><TD BGCOLOR="#fdf76a"><P> <FONT COLOR="#F40404">Before you purchase a subscription please</FONT><BR CLEAR="ALL"><B><FONT COLOR="#F40404">Read the TERMS and CONDITIONS
below:</FONT></B></P><P>Subscriptions to the cost <B>$19.95 US Dollars for the yearly subscription</B>which includes current issues for one full calendar year from purchase
of subscription.</P><P>Monthly subscriptions <B>$9.95 US Dollars for the Current Months issue
only. </B>With Either subscription you will receive a password and username
which will be required to enter areas of the mag.</P>
<P><CENTER><B><FONT COLOR="#0000FF">PLEASE WRITE YOUR USERNAME AND PASSWORD DOWN </FONT> </B> </CENTER></P><P><CENTER><FONT COLOR="#FF0000">Note: that passwords and usernames are
CaSe SenSitive</FONT></CENTER></TD></TR></TABLE>
</CENTER></P><P><CENTER><TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" HEIGHT="413"
WIDTH="94%"><CAPTION ALIGN="TOP"><B>Required fields are marked with a *</B></CAPTION>
<TR><TD HEIGHT="24" VALIGN="TOP" NOWRAP ALIGN="RIGHT" WIDTH="41%"> <B>SUBSCRIPTION TYPE:</B></TD><TD VALIGN="TOP" WIDTH="59%">
<INPUTTYPE="radio" VALUE="monthly|9.95" NAME="accttype"><B>1 Month $9.95
<INPUT TYPE="radio" VALUE="yearly|19.95" NAME="accttype" CHECKED="true">1 Year
$19.95</B> </TD></TR>
<TR><TD HEIGHT="28" VALIGN="TOP" ALIGN="RIGHT">* <B>Name:</B></TD>
<TD VALIGN="TOP"> <INPUT NAME="adname" TYPE="text" SIZE="22"></TD></TR>
<TR><TD HEIGHT="28" VALIGN="TOP" ALIGN="RIGHT">* <B>Address:</B></TD>
<TD VALIGN="TOP"> <INPUT NAME="adaddress" TYPE="text" SIZE="39"></TD></TR>
<TR><TD HEIGHT="28" VALIGN="TOP" ALIGN="RIGHT">* <B>City :</B></TD>
<TD VALIGN="TOP"> <INPUT NAME="adcity" TYPE="text" SIZE="36"></TD></TR><TR>
<TD HEIGHT="28" VALIGN="TOP" NOWRAP ALIGN="RIGHT">* <B>State/Prov.:</B></TD>
<TD VALIGN="TOP"> <INPUT NAME="adstate" TYPE="text" SIZE="14"></TD></TR>
<TR><TD HEIGHT="28" ALIGN="RIGHT"> <B>Country:</B></TD>
<TD VALIGN="TOP"> <INPUT NAME="adcountry" TYPE="text" SIZE="30"></TD></TR>
<TR><TD HEIGHT="28" VALIGN="TOP" ALIGN="RIGHT">* <B>Zip code:</B></TD>
<TD VALIGN="TOP"> <INPUT NAME="adzip" TYPE="text" SIZE="8"></TD></TR><TR>
<TD HEIGHT="28" VALIGN="TOP" ALIGN="RIGHT">* <B>Phone #:</B></TD><TD VALIGN="TOP"> <INPUT NAME="adphone" TYPE="text" SIZE="30"></TD></TR>
<TR><TD HEIGHT="28" ALIGN="RIGHT"><B>Email:</B></TD>
<TD> <INPUT NAME="ademail" TYPE="text" SIZE="30"></TD></TR><TR>
<TD HEIGHT="28"><P ALIGN=RIGHT>* <B>Password:</B></TD>
<TD> <INPUT TYPE="text" SIZE="8" NAME="pw" MAXLENGTH="8"></TD></TR><TR>
<TD HEIGHT="28" NOWRAP ALIGN="RIGHT">* <B>CREDIT CARD NUMBER:</B></TD>
<TD> <INPUT NAME="ccno" TYPE="text" SIZE="30" MAXLENGTH="30"></TD></TR><TR>
<TD HEIGHT="31" ALIGN="RIGHT">* <B>CARD TYPE:</B></TD>
<TD> <SELECT NAME="cctype">
<OPTION VALUE="VISA" SELECTED>Visa
<OPTION VALUE="MASTERCARD">Mastercard
</SELECT></TD></TR><TR><TD HEIGHT="29" ALIGN="RIGHT">* <B>NAME ON CARD:</B></TD>
<TD> <INPUT NAME="ccname" TYPE="text" SIZE="30"></TD></TR><TR><TD ALIGN="RIGHT" VALIGN="TOP">* <B>Billing Zip code:</B></TD>
<TD> <INPUT NAME="bzip" TYPE="text" SIZE="10"></TD></TR><TR><TD HEIGHT="31" ALIGN="RIGHT"><B> EXPIRATION DATE:</B></TD>
<TD> <SELECT NAME="ccexmonth">
<OPTION SELECTED>01
<OPTION>02
<OPTION>03
<OPTION>04
<OPTION>05
<OPTION>06
<OPTION>07
<OPTION>08
<OPTION>09
<OPTION>10
<OPTION>11
<OPTION>12
</SELECT><SELECT NAME="ccexyear">
<OPTION>97
<OPTION SELECTED>99
<OPTION>00
<OPTION>01
<OPTION>02
<OPTION>03
<OPTION>04
<OPTION>05
</SELECT></TD></TR>
</TABLE></CENTER></P><P><CENTER>
<INPUT TYPE="hidden" NAME="account" VALUE="demo"><INPUT VALUE="Submit Secure Subscription Order" TYPE="submit"></CENTER></FORM></BODY></HTML>

 

 

END READ.ME