#!/usr/bin/perl # adult.cgi - produces an age verification screen for adult material. # $author = "Tad 'Baxil' Ramspott"; $version = "1.2.1, 2013-09-04"; # Changes from 1.2: Bugfix, text files need to have text/html header # (also fixed for new server). # Changes from 1.1: Added substitutions, finished debugging, fixed behavior # after cookie set/reset. Probably final for a while. (2007-02-18) # (Oh, and: New cookie-has-been-set message.) # Changes from 1.0.1: Removing e-mail from error messages; # general 2007 twiddling; streamline for new template work :), # adultSubstitute fixed based on new template algorithm (2007-02-14) # Changes from 1.0: Added check for newlines in file name; shouldn't be # necessary as a security measure, but better safe than sorry. (10-27-02) require("/var/www/vhosts/tomorrowlands.org/httpdocs/cgisrc/tyrforms.pl"); # which calls tyrfuncs.pl require($rootdir . "cgisrc/tyrtemplates.pl"); $legalese = "adultwarning"; # filename for the little legal blurb $adultdir = $rootdir . "_adult/"; # where the incriminating stuff is $logfile = "error_log"; $infoSuffix = ".info"; $adultCName = "adultauth"; $graceHours = 24; # how long before cookie expires $pageTitle = "Age Verification"; # default for
EOF
# Actually, let's go with this version instead:
$cookieWarning = <
EOF
# DEBUG
# clearCookie($adultCName);
# print "\n
Current cookie settings - theCookies -> " . (scalar %theCookies) . ".
\n";
}
sub badFileMessage($) {
my $foo = shift;
$extraForm = <No can do