#!/usr/bin/perl ################################################################# # Title : User Identification CGI # Author : Walter Moore aperson@aperson.com # Created : 2/07/97 # Version : 1.0 # Comments : This CGI determines the users system, then displays # : the detected information to them. It can alternately # : link to HTML pages to provide more information for # : both Netscape and Microsoft browsers. # : Copyright,1997 Aperson.Com. ################################################################ ################### # Define Variables and set to default values. Do not change these ################### $browser = " $ENV{'HTTP_USER_AGENT'}"; # Browser name, version, OS. $lastsite = " $ENV{'HTTP_REFERER'}"; # Last visited site $yoursite = " $ENV{'REMOTE_HOST'}"; # The e-mail address(sort of) $yourip = " $ENV{'REMOTE_ADDR'}"; # The IP address $yourid = " $ENV{'REMOTE_IDENT'}"; # Identity if any $realos = " Windows 3"; # the Operating System(OS) $realone = " $ENV{'HTTP_USER_AGENT'}"; # the browser name $realver = " 2"; # the browser version. $javalive = " Yes"; # Does OS support Java? Default yes. ################## # If you want to link to different pages for each browser browsercheck should be "Y". # If "Y" then change the URL links accordingly. # our_url should reference your home page regardless if browsercheck is used. ################# $browsercheck = "Y"; # change to N if no HTML checks wanted $microsoft_url = "/r.cgi?F=checkem"; # where to go if Microsoft V3+ $netscape_url = "/r.cgi?F=checknn"; # where to go if Netscape V2+ $our_url = "http://aperson.com"; # where to go for other browsers ################## # Some variables may be blank after default setting. Handle them # You should change these values. ################## if ($yourid = " ") {$yourid = " Not Available";} if ($lastsite = " ") {$lastsite = " Not Available";} ################## # Detect and handle Anonymizer...says sorry. # anyone else has to remove this. It goes to secure services ################## if ($yoursite =~ /infonex.com/) { print "Content-type: text/html\n\n"; print "
\n\n
\n";
}
print "
"; print "Below you will find information about you that can be detected by a server."; print " This is not my fault! Any server can detect(or record) this stuff."; print " There are sections for Server and Browser detected information.
"; print "
WARNING
\n"; print "If your 'User ID' below is your e-mail address(without the '\@') you are not surfing"; print " anonymously. That is not good, see Solutions below! "; print " As long as you are anonymous, who cares....But if your not you should!
"; ################## # now the actual form to display. # This should not be modified. ################## print "
\n"; ################## # end of form. Now if they have Netscape or Microsoft show more checking options. # This section links to HTML page for each browser to display their info options. # Can be removed/modified or choose "N" for browsercheck in variables above. ################## if ($browsercheck =~ "Y") { if ($realone =~ "Explorer") { if (substr($realver,$[,1) > 2) { print "Internet Explorer can detect most of the above plus much more.
\n"; print ""; print "Want to detect even more information?
\n"; print "I detect if you have JavaScript, VBScript, Activex, Layouts, and other"; print " functions enabled and report this to you.
\n"; } } else { if ($realone =~ "Netscape") { if (substr($realver,$[,1) >= 2) { print "Netscape Navigator can detect most of the above plus more.
\n"; print ""; print "Want to detect even more information?
\n"; print "I can detect if you have JavaScript, Frames and other"; print " functions enabled. "; } } else { # neither Netscape v2+ or Microsoft V3+ browser print " Browser information is only available with Microsoft V3+ or "; print "Netscape V2+ browsers. Sorry.
\n"; } } } #end of browsercheck ################## # display the trailer information # modify/delete this for your display ################## print "
Solutions
\n"; print " If your 'User ID' is your e-mail address you have a 'static' IP address. Talk to your"; print " service provider(ISP) and request a 'dynamic' IP address. This will ensure you don't get any more"; print " servers(we don't do that here) grabbing your email address. You still have to watch out for Newsgroups but that is another issue.
"; print " Remember, this information can be recorded without your knowledge!
"; print " This might explain some of those mail lists you are on.
"; print " Another solution is to go to a site like www.anonymizer.com"; print " to hide this info. Unfortunately, many sites will think you"; print " have Netscape V2 on an unknown system and may send you to the wrong pages(not good) and"; print " errors may occur when visiting some sites(try this page).
"; print " I am sure that anonymizer will eventually give the client options, just not yet."; print " They provide an excellent service for those that are concerned about this info.
\n"; print "
\n"; print "
\n \n"; $homepage = "http://aperson.com"; # default homepage if ($browser =~ /MSIE/) { # They are using microsoft browser if (substr($browser,$[+8,1) >= 3){ $homepage = "/r.cgi?F=intro" } } else { if (substr($browser,$[+8,1) >= 2){ $homepage = "/r.cgi?F=intro" } } print "\n"; print " Home | \n"; print "\n"; print " Site Search | \n"; print "\n"; print " Web Search | \n"; print "\n"; print " GuestBook | \n"; print "\n"; print " Changes | \n"; print "\n"; print " Contact Me\n"; $mailme = 'webmaster@aperson.com'; $date = `/bin/date`; chop($date); print "
\n\n"; print "\n\n\n"; print "\n\n";\n"; print "This document created on $date \n
\n"; print "Copyright © 1996,1997 Aperson.Com
\n"; print "For problems with this site please e-mail \n"; print "$mailme
\n"; print "