home *** CD-ROM | disk | FTP | other *** search
- #! /usr/local/bin/perl
-
- print "Content-Type: text/html \n\n";
-
- print <<'EOF';
- <HTM>
- <HEAD><TITLE> GENERATING A UNIQUE CUSTOMER ID </TITLE>
- </HEAD>
- <BODY>
-
- <h3> The following unique customer id is made up of three parts: <h3>
- <ul>
- <li>The first part is the process id. The process id is unique for each
- process, while that process is running.
- <li>The second part, separated by the dash character (-), is the IP address of
- the Web Customer.
- <li>The last part, also separated by the dash character (-), is the number of
- non-leap seconds since January 1, 1970.
- </ul>
- <h3> This should produce a unique value that is difficult to predict, and
- therfore hard to forge. </h3>
- <hr noshade>
- EOF
- $unique_customer_id = $$ . "-" . $ENV{'REMOTE_ADDR'} . "-" . time();
- print " $unique_customer_id <BR>";
- print <<'EOF' ;
- </BODY>
- </HTML>
- EOF
-
-